I want to calculate $$\sum_{n=-\infty}^{n=\infty}\frac{1}{n^2+n+1}$$ The hint given is to calculate the integral $$\oint \frac{\pi\cot{\pi z}}{z^2+z+1}dz$$ over the square with corners $\pm(N+1/2)(1\pm i)$ where $N\in \mathbb{N}$ and then let $N\to\infty$.
My attempt was to parametrize the integral with and then integrate $\int_0^{2N+1}\frac{\pi\cot{\pi(N+1/2+i(N+1/2-t))}}{(N+1/2+i(N+1/2-t))^2+(N+1/2+i(N+1/2-t))+1}(-i)\;dt$ etc. but this seems far too complicated to be the intended solution.