Question: What is the value of $$\sum\_{n=1}^{\infty}\frac1{1+n^2}$$
I don't know how to solve it.  

I tried to solve it by power series, but I failed.

Answer: 
I will give an elementary solution based on the following lemmas:

> 
> **Lemma 1.** For any $n\in\mathbb{N}^+$,
>  $$ \int\_{0}^{+\infty}\frac{\sin(nx)}{n}e^{-x}\,dx = \frac{1}{1+n^2}.$$
>  **Proof:** integration by parts.
> 
> 
> **Lemma 2.** The following series is the Fourier series of a $2\pi$-periodic sawtooth wave $f(x)$,  
>  that over the interval $(0,2\pi)$ equals $\frac{\pi-x}{2}$:
>  $$ f(x)=\sum\_{n\geq 1}\frac{\sin nx}{n} $$
>  **Proof:** direct computation of Fourier coefficients.
> 
> 
> 

By Lemma **1** and Lemma **2**,
$$\begin{eqnarray\*}\sum\_{n\geq 1}\frac{1}{n^2+1}&=&\int\_{0}^{+\infty}f(x)e^{-x}\,dx\\(\text{periodicity of } f(x))\qquad&=&\left(1+\frac{1}{e^{2\pi}}+\frac{1}{e^{4\pi}}+\ldots\right)\int\_{0}^{2\pi}f(x)e^{-x}\,dx\\[0.2cm]&=&\frac{e^{2\pi}}{e^{2\pi}-1}\int\_{0}^{2\pi}\frac{\pi-x}{2}e^{-x}\,dx\\[0.2cm](\text{direct computation})\qquad &=&\color{red}{\frac{\pi\coth\pi-1}{2}}.\end{eqnarray\*} $$
**Hint.** It's [well-known](https://en.wikipedia.org/wiki/Trigonometric_functions#Cotangent) that
$$\pi\cot(\pi z)=\frac{1}{z}+2\sum\_{n=1}^\infty \frac{z}{z^2-n^2}$$