Integrating $\int_0^\infty \frac{x}{(4x^2+\pi^2)\sinh x} dx$ using residues $$\int_0^\infty \frac{x}{(4x^2+\pi^2)\sinh x} dx$$
I'm stuck with this integral since I can't figure out the contour I should be using.
It doesn't fit in into standard ones like circle with a cut for integrals like
$\int_{0}^\infty \frac{\ln  x}{polynomial} dx.$ Or infinite band for functions with imaginary period. I don't know what to do...
 A: Here is a sketch of a way forward.  The details are left to the reader.
First, note that the integrand is an even function.  Hence, we can write
$$\int_0^\infty \frac{x}{(4x^2+\pi^2)\sinh(x)}\,dx=\frac12\int_{-\infty}^\infty \frac{x}{(4x^2+\pi^2)\sinh(x)}\,dx$$

Next, note that $\sinh(z)=0$ when $z=in\pi$, $n\in\mathbb{Z}$.  So we choose a contour $C_N$ in the complex plane comprised of $(i)$ a straight line segment from $z=-(N+1/2)\pi$ to $z=(N+1/2)\pi$ and $(ii)$ a circular arc centered at $z=0$ and with radius $R_N=(N+1/2)\pi$.  
Then, we evaluate the contour integral 
$$\begin{align}
\oint_{C_N}\frac{z}{(4z^2+\pi^2)\sinh(z)}\,dz&=\int_{-(N+1/2)\pi}^{(N+1/2)\pi}\frac{x}{(4x^2+\pi^2)\sinh(x)}\,dx\\\\
&+\int_0^\pi \frac{i(N+1/2)^2\pi^2 e^{i2\phi}}{(4(N+1/2)^2\pi^2 e^{i2\phi})+\pi^2)\sinh((N+1/2)\pi e^{i\phi})}\,\,d\phi\tag1\\\\
&=2\pi i \text{Res}\left(\frac{z}{(4z^2+\pi^2)\sinh(z)}, z=i\pi/2\right)\\\\
&+2\pi i \sum_{n=1}^N \text{Res}\left(\frac{z}{(4z^2+\pi^2)\sinh(z)}, z=in\pi\right)\tag2
\end{align}$$

Show that as $N\to\infty$, the second integral on the right-hand side of $(1)$ approaches $0$.  Then, evaluate the residues on the right-hand side of $(2)$.
Can you finish now?
A: I think that I managed to apply @NinadMunshi's idea here. 
We can try to compute an integral of the function $\frac{1}{(2z-\pi i)}\sinh(z)$ at the contour that is an infinite rectangle of height $\pi$ (let us denote it $\Gamma$). It has one simple pole inside and two on the boundary. 
By comparing what we get on the real axis and on the line $\operatorname{Im}=\pi i$ we get the following identity:
\begin{gather}
\oint_{\Gamma}\frac{1}{(2z-\pi i)\sinh(z)}\,dz=\\\\\int_{-\infty}^{+\infty}\frac{1}{(2z-\pi i)\sinh(z)}\,dz+\int_{-\infty}^{+\infty}\frac{1}{(2z+\pi i)\sinh(z)}\,dz
=4\int_{-\infty}^{+\infty}\frac{z}{(4z^2+\pi^2)\sinh(z)}\,dz=\\\\=2\pi i \operatorname{Res}_{\frac{\pi i}{ 2}}\frac{1}{(2z-\pi i)\sinh(z)}+ \pi i\bigg[\operatorname{Res}_{\pi i}\frac{1}{(2z-\pi i)\sinh(z)}-\operatorname{Res}_{0}\frac{1}{(2z-\pi i)\sinh(z)}\bigg]=\pi
\end{gather}
