Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm looking for a method to evaluate the following integral:

$\displaystyle \int_0^{\infty} \left( \frac{1}{e^x - 1} - \frac{1}{x} + \frac{e^{-x}}{2} \right) \frac{1}{x} dx$


Using the link, here's what I've done so far. Define

$F(s) = \displaystyle \int_0^{\infty} e^{-sx} \left (\frac{1}{e^x - 1} - \frac{1}{x} + \frac{e^{-x}}{2} \right) \frac{1}{x} dx$.

Supposing we've shown that this integral converges nicely enough to justify differentiating underneath it, we have that

$F'(s) = \displaystyle -\int_0^{\infty} e^{-sx} \left(\frac{1}{e^x - 1} - \frac{1}{x} + \frac{e^{-x}}{2} \right) dx = - \left( \int_0^{\infty}e^{-sx} \frac{e^{-x}}{2} dx + \int_0^{\infty} e^{-sx} \left( -\frac{1}{x} + \frac{1}{e^x - 1} \right) dx \right)$.

We recognize that the first integral is the Laplace transform of $\frac{e^{-x}}{2}$ and so the integral evaluates to $\frac{1}{2(s+1)}$.

Setting $F_2(s) \displaystyle \int_0^{\infty} e^{-sx} \left(-\frac{1}{x} + \frac{1}{e^{x} - 1} \right) dx$, (and assuming a similar analysis will justify the differentiation), we find that

$F'_2(s) = \displaystyle \int_0^{\infty} e^{-sx} - \frac{x e^{-sx}}{e^x - 1} dx = \frac{1}{s} - \int_0^{\infty} \frac{xe^{-sx}}{e^x - 1} dx $.

While I'm pretty sure I can justify the convergence of all the relevant integrals to differentiate, this last integral is not the Laplace transform of a function I'm familiar with (which doesn't mean much, because I'm not familiar with many). Any tips on how to take care of the last integral?

share|cite|improve this question
Do you mean that the expression in divided by x or $d(\frac xx)$ – Student Mar 3 '13 at 19:40
The entire expression is divided by x. I've changed the notation to reduce ambiguity. – anonymous Mar 3 '13 at 19:42
Ah. I did not see that at all, deleted my first response. – muzzlator Mar 3 '13 at 19:43
A related problem. – Mhenni Benghorbal Mar 3 '13 at 19:48
up vote 4 down vote accepted

$$f(\lambda)=\int_0^{\infty} \frac{e^{-\lambda x}}{x}\left(\frac{1}{e^x-1}+\frac{1}{2e^x}-\frac{1}{x}\right)dx$$

$$\begin{align*}f''(\lambda)&=\int_0^{\infty} e^{-\lambda x}\left(\frac{x}{e^x-1}+\frac{x}{2e^x}-1 \right)dx\\&=\int_0^{\infty} \frac{x}{e^{\lambda x}(e^x-1)}dx+\int_0^{\infty}\frac{x}{2e^{(\lambda +1)x}}dx-\int_0^{\infty} e^{-\lambda x} dx\\&=\int_0^{\infty} \frac{x}{e^{\lambda x}(e^x-1)}dx+\frac{1}{2(\lambda+1)^2}-\frac{1}{\lambda}\end{align*}$$

Recall the Hurwitz zeta function:

$$\zeta (s,w)=\frac{1}{\Gamma (s)}\int_0^{\infty}\frac{t^{s-1}}{e^{wt}(1-e^{-t})}dt$$



Now integrate back twice:

$$\int f''(\lambda)d\lambda =\frac{d}{d\lambda}\ln\Gamma (\lambda+1)-\frac{1}{2(\lambda+1)}-\ln \lambda+\mathcal{C}$$

Letting $\lambda\to\infty$ reveals that $\mathcal{C}=0$

$$\int f'(\lambda)d\lambda =\ln\Gamma (\lambda+1)+\lambda (1-\ln\lambda)-\frac{1}{2}\ln (\lambda +1)+\mathcal{C'}$$

Taking $\lambda\to\infty$ we have $\mathcal{C'}=\ln\sqrt{\dfrac{1}{2\pi}}$ (easily deduced using Stirling's approximation)

Now letting $\lambda\to 0$ gives us the result:

$$\int_0^{\infty} \frac{1}{x}\left(\frac{1}{e^x-1}+\frac{1}{2e^x}-\frac{1}{x}\right)dx=\ln\sqrt{\dfrac{1}{2\pi}}$$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.