$\int_0^\infty \frac{x}{e^x-1} dx$ with series I've been looking at the following integral, and trying to solve it through series:
$$\int_0^\infty \frac{x}{e^x-1} dx$$
I tried expanding out $e^x-1$:
$$\int_0^\infty \frac{x}{x+x^2/2!+x^3/3!+x^4/4!+\cdots} dx$$
but I do not know how to continue from there; I feel like it would have something to do with long division, but I don't know how. 
I also tried the substitution
$$t=e^x-1$$
$$dt=e^xdx$$
$$x=\ln(1+t)$$
So after multiplying the integrand by $1 = e^x/e^x$ and substituting I got
$$\int_0^\infty \frac{\ln(1+t)}{t(1+t)}dt$$
I tried using series as well, but I was stuck after
$$\int_0^\infty \frac{t-t^2/2+t^3/3-t^4/4+\cdots}{t(1+t)}dt$$
$$\int_0^\infty \frac{1}{t+1}-\frac{t}{2(t+1)}+\frac{t^2}{3(t+1)}-\frac{t^3}{4(t+1)}+\cdots dt$$
I know that it is supposed to equal $\frac {\pi^2}{6}$, so I know that after doing everything it should come out to $\frac{1}{1^2}+\frac{1}{2^2}+\frac{1}{3^2}+\cdots$, but I do not know how to get there.
Thanks!
P.s. Wolfram Alpha gives a closed form for the antiderivative of $\frac{x}{e^x-1}$ as $\operatorname{Li}_2(e^x)-\frac{x^2}{2}+x\ln(1-e^x)+c$
 A: Instead of trying to expand the denominator, try instead to expand the full fraction $\frac{1}{e^x-1}$ in a series. We have
$$\frac{1}{e^x-1} = e^{-x}\frac{1}{1-e^{-x}}$$
Now if $x>0$ then $e^{-x}<1$ so we can expand in a geometrical series 
$$\frac{1}{e^x-1} = e^{-x}\sum_{k=0}^\infty e^{-kx} = \sum_{k=1}^\infty e^{-kx}$$
This gives the integral
$$\int_0^\infty\frac{x}{e^x-1}\,{\rm d}x = \int_0^\infty \sum_{k=1}^\infty xe^{-kx}\,{\rm d}x \\= \sum_{k=1}^\infty \int_0^\infty xe^{-kx}\,{\rm d}x  = \sum_{k=1}^\infty \frac{1}{k^2}\int_0^\infty (kx)e^{-kx}\,{\rm d}(kx)  = \sum_{k=1}^\infty\frac{1}{k^2}\int_0^\infty ye^{-y}\,{\rm d}y $$
where the switching of the summation and integration is justified by Fubini's theorem; see this answer for more details. The final integral can be evaluated using integration by parts. 
The same series approach can be used to compute the integral $\int_0^\infty\frac{x^{s-1}}{e^x-1}{\rm d}x = \Gamma(s)\zeta(s)$ where $\Gamma$ is the $\Gamma$-function and $\zeta$ is the Riemann $\zeta$-function.
For an alternative way of deriving the result using contour integration, see this answer.
A: $$
\begin{align}
\int_0^\infty\frac{x}{e^x-1}\,\mathrm{d}x
&=\int_1^\infty\frac{\log(x)}{x(x-1)}\,\mathrm{d}x\tag{1}\\
&=-\int_0^1\frac{\log(x)}{1-x}\,\mathrm{d}x\tag{2}\\
&=-\int_0^1\frac{\log(1-x)}{x}\,\mathrm{d}x\tag{3}\\
&=\sum_{k=1}^\infty\int_0^1\frac{x^{k-1}}{k}\,\mathrm{d}x\tag{4}\\
&=\sum_{k=1}^\infty\frac1{k^2}\tag{5}\\
&=\frac{\pi^2}6\tag{6}
\end{align}
$$
Explanation:
$(1)$: Substitute $x\mapsto\log(x)$
$(2)$: Substitute $x\mapsto\frac1x$
$(3)$: Substitute $x\mapsto1-x$
$(4)$: Expand the series for $\log(1-x)$
$(5)$: Integrate each term
$(6)$: $\zeta(2)=\frac{\pi^2}6$
