$\int_0^\infty \frac{x}{(e^{2\pi x}-1)(x^2+1)^2}dx$? How to calculate integral $\int_0^\infty \frac{x}{(e^{2\pi x}-1)(x^2+1)^2}dx$? I got this integral by using Abel-Plana formula on series $\sum_{n=0}^\infty \frac{1}{(n+1)^2}$. This integral can be splitted into two integrals with bounds from 0 to 1 and from 1 to infinity and the both integrals converge, so does the sum. I checked with WolframAlpha and the value of the integral is $\frac{-9 + \pi^2}{24}$, but I don't know how to compute it. Also, I tried to write $\frac{2xdx}{(1+x^2)^2}=d\frac{1}{x^2+1}$ and then tried to use partial integration, but didn't succeded.
Any help is welcome. Thanks in advance.

Here is a brutal-force computation using contour integral.

Let $\operatorname{Log}(\cdot)$ be the logarithm with the branch cut $[0, \infty)$ so that $\operatorname{Arg}(z) \in (0, 2\pi)$. Also, for $s > 0$ we define
$$ I(s) = \int_{0^+ i}^{\infty + 0^+ i} f_s(z) \, \mathrm{d}z, \quad \text{where} \quad f_s(z) = \frac{e^{s\operatorname{Log}(z)}}{(e^{2\pi z}-1)(z^2+1)^2}. $$
Then by noting that the contour integral of $f_s(z)$ along the square with the corners $(\pm1 \pm i)(N+\frac{1}{2})$ vanishes as $N \to \infty$, we get
\begin{align*}
(1 - e^{2\pi i s}) I(s)
&= \int_{0^+ i}^{\infty + 0^+ i} f_s(z) \, \mathrm{d}z + \int_{\infty + 0^- i}^{0^- i} f_s(z) \, \mathrm{d}z 
= 2\pi i \sum_{n \neq 0} \mathop{\mathrm{Res}}_{z=ni} f_s(z).
\end{align*}
Some tedious computation yields:
$$ 2\pi i \mathop{\mathrm{Res}}_{z=ni} f_s(z) = \begin{cases}
e^{i\pi s/2} \left( \frac{is^2}{8} - \frac{3is}{8} + \frac{3i}{16} - \frac{i\pi^2}{12} + \frac{\pi(s-1)}{4} \right), & n = 1, \\
e^{3i\pi s/2} \left( \frac{is^2}{8} - \frac{3is}{8} + \frac{3i}{16} - \frac{i\pi^2}{12} - ​\frac{\pi(s-1)}{4} \right), & n = -1, \\
i e^{i\pi s/2} \frac{n^s}{(n^2-1)^2}, & n \geq 2, \\
i e^{3i\pi s/2} \frac{|n|^s}{(n^2-1)^2}, & n \leq -2. \\
\end{cases} $$
Assuming in addition that $s \notin \mathbb{Z}$, we get
\begin{align*}
I(s)
&= 
+ \frac{e^{i\pi s/2} + e^{3i\pi s/2}}{1 - e^{2\pi i s}} \left( \frac{is^2}{8} - \frac{3is}{8} + \frac{3i}{16} - \frac{i\pi^2}{12} \right) \\
&\quad + \frac{e^{i\pi s/2} - e^{3i\pi s/2}}{1 - e^{2\pi i s}} \frac{\pi(s-1)}{4} \\
&\quad + \frac{i(e^{i\pi s/2} + e^{3i\pi s/2})}{1 - e^{2\pi i s}} \sum_{n=2}^{\infty} \frac{n^s}{(n^2-1)^2}
\end{align*}
Letting $s \to 1$,
\begin{align*}
I(1)
&= \left( \frac{1}{32}+\frac{\pi ^2}{24} \right) - \frac{1}{4} - \frac{1}{2} \sum_{n=2}^{\infty} \frac{n}{(n^2-1)^2}
\end{align*}
Then the desired answer follows from
$$ \sum_{n=2}^{\infty} \frac{n}{(n^2-1)^2}
= \frac{1}{4} \sum_{n=2}^{\infty} \left( \frac{1}{(n-1)^2} - \frac{1}{(n+1)^2} \right)
= \frac{5}{16}. $$
