Evaluate $\sum\limits_{n=0}^\infty \frac{1}{4n^2+1}$ by using complex contour integration How do you evaluate $\displaystyle\sum\limits_{n=0}^\infty \frac{1}{4n^2+1}$ by using complex contour integration?
I'm trying to attempt this question by considering the integral of some function about a square in the complex plane, whose residues at each singularity on the real axis evaluate to $\large\frac{1}{4k^2+1}$ for all integers $k$. Maybe a function similar to
$$\frac {\cot \pi z}{4z^2+1}$$
Maybe then define a square centred on the origin with sides of length $2N+1$ then letting $N \to \infty$ we can split up the integral to evaluate the sum of the residues? Which would be our summation. Sorry if this is poorly explained, but as I say, i'm having trouble understanding this, so i'm not that sure myself, I know it's possible though!
 A: If you choose to evaluate this using a contour it will not just be similar, but identical to the contour for  $\cot(\pi z)$ with a variable change.
It is literally identical, with only a variable change, and you can also choose to do this variable change before or after the integration itself.  What you are asking for in the question is doing the variable change before the contour integration, what follows below is doing the variable change after:

By contour integration we have that $$\pi z\cot(\pi z)=1+2z^2\sum_{n=1}^\infty \frac{1}{z^2-n^2}.$$  Let $z=\frac{i}{2}$, then this is $$ \frac{\pi i}{2}\cot\left(\frac{\pi i}{2}\right)=1+2\sum_{n=1}^\infty \frac{1}{4n^2+1}.$$  Since $\coth(z)=i\cot(iz)$ we conclude that $$\sum_{n=0}^\infty \frac{1}{4n^2+1}=\frac{1}{2}+\frac{\pi}{4}\coth\left(\frac{\pi}{2}\right).$$ as desired.

If you want to do the variable change before the contour integration, just look at $z\rightarrow \frac{iz}{2}$.  Then we are integrating the function $\pi z \coth \left( \frac{\pi z}{2}\right)$, which really the same function as $\pi z\cot\left(\pi z\right)$. 
