<s>[INST] Show $\sum_{n=1}^\infty\frac{1}{n^2+3n+1}=\frac{\pi\sqrt{5}}{5}\tan\frac{\pi\sqrt{5}}{2}$. How to show that
$$\sum_{n=1}^\infty\frac{1}{n^2+3n+1}=\frac{\pi\sqrt{5}}{5}\tan\frac{\pi\sqrt{5}}{2}$$
?
My try:
We have
$$n+3n+1=\left(n+\frac{3+\sqrt{5}}{2}\right)\left(n+\frac{3-\sqrt{5}}{2}\right),$$
so
$$\frac{1}{n^2+3n+1}=\frac{2}{\sqrt{5}}\left(\frac{1}{2n+3-\sqrt{5}}-\frac{1}{2n+3+\sqrt{5}}\right).$$
Then, I don't know how to proceed.
 [/INST] I think we can make some use of the residue theorem. Write $n^2+3 n+1 = (n+3/2)^2-5/4$ and the sum is
$$\sum_{n=1}^{\infty} \frac1{\left (n+\frac{3}{2} \right )^2-\frac{5}{4}} = \frac12 \sum_{n=-\infty}^{\infty} \frac1{\left (n+\frac{3}{2} \right )^2-\frac{5}{4}} - 1 +1$$
(To get the doubly infinite sum, I had to add back the $n=0$ and $n=-1$ terms, which happen to sum to zero.)
The sum on the RHS may be attacked via the residue theorem, using the following:
$$\sum_{n=-\infty}^{\infty} f(n) = - \pi \sum_k \operatorname*{Res}_{z=z_k} [f(z)\cot{\pi z} ] $$
where $z_k$ is a non-integer pole of $f$.  The poles are at 
$$z_{\pm} = -\frac{3}{2} \pm \frac{\sqrt{5}}{2} $$
The sum is then equal to
$$\frac{\pi}{2 \sqrt{5}} \left [\cot{\left (\frac{3 \pi}{2} - \frac{\sqrt{5} \pi}{2} \right )} - \cot{\left (\frac{3 \pi}{2} + \frac{\sqrt{5} \pi}{2} \right )} \right ] = \frac{\pi}{\sqrt{5}}\tan{\frac{\sqrt{5}\pi}{2}}$$
</s>