Show $\sum_{n=-\infty}^{\infty}e^{2\pi inx}\int_{-\infty}^{\infty}\frac{1}{y^2} e^{-2\pi iny}dy=\frac{\pi^2}{(\sin \pi x)^2}$ Regarding the question $\sum_{n=-\infty}^{\infty}\frac{1}{(n+\alpha)^2}=\frac{\pi^2}{(\sin \pi \alpha)^2}$? , the following integration was needed to be done $$\sum_{n=-\infty}^{\infty}e^{2\pi inx}\int_{-\infty}^{\infty}\frac{1}{y^2} e^{-2\pi iny}dy =\frac{\pi^2}{(\sin \pi x)^2}$$ and it was done using some concepts of complex analysis with which I am not much comfortable. So, can someone please tell me how to solve this integration using some other way? 
 A: If we start from the Weierstrass product for the $\Gamma$ function
$$ \Gamma(x+1) = e^{-\gamma x}\prod_{n\geq 1}\left(1+\frac{x}{n}\right)^{-1}e^{x/n} \tag{1}$$
we get, by logarithmic differentiation (wrt $x$), that
$$ \sum_{n\geq 1}\left(\frac{1}{n}-\frac{1}{n+\alpha}\right) = \gamma+\psi(\alpha+1) = \gamma+\frac{\Gamma'(a+1)}{\Gamma(a+1)}\tag{2} $$
and by differentiating again (this time, wrt $\alpha$) it follows that
$$ \sum_{n\geq 1}\frac{1}{(n+\alpha)^2}=\psi'(\alpha+1)=\psi'(\alpha)-\frac{1}{\alpha^2},\qquad \sum_{n\geq 1}\frac{1}{(-n+\alpha)^2}=\psi'(1-\alpha) \tag{3} $$
so:
$$ \sum_{n=-\infty}^{+\infty}\frac{1}{(n+\alpha)^2} = \psi'(\alpha)+\psi'(1-\alpha).\tag{4} $$
Now it is enough to exploit the reflection formula for the $\Gamma$ function, i.e. the following interesting consequence of $(1)$:
$$ \Gamma(x)\cdot\Gamma(1-x)=\frac{\pi}{\sin(\pi x)},\qquad \log\Gamma(x)+\log\Gamma(1-x)=\log\pi-\log\sin(\pi x)\tag{5} $$
leading to:
$$ \psi(x)-\psi(1-x)=-\pi\cot(\pi x)\tag{6} $$
and finally to:
$$ \boxed{\sum_{n=-\infty}^{+\infty}\frac{1}{(n+\alpha)^2} = -\pi\frac{d}{d\alpha}\cot(\pi \alpha) = \color{red}{\frac{\pi^2}{\sin^2(\pi \alpha)}}}\tag{7}$$
as wanted. Back to OP's integral, the identity
$$ \int_{0}^{+\infty}\frac{1-\cos(2\pi n x)}{x^2}\,dx = 2\pi|n|\int_{0}^{+\infty}\frac{\sin(2\pi|n|x)}{x}\,dx = \pi^2 |n|\tag{8}$$
just follows from integration by parts and a famous integral. The remaining part is just to compute a minor variation on a geometric series, leading as well to the RHS of $(7)$.
