Proving $ \int_0^\infty \frac { e^{-ax} - e^{-bx} } x dx = \ln \frac b a $ How can we prove this identity? (Taken from Wikipedia's List of Definite Integrals)
$$ \int_0^\infty \frac { e^{-ax} - e^{-bx} } x dx = \ln \frac b a $$
It seems that the integral is not elementary and
$$ \int_0^\infty \frac { e^{-ax} - 1 } x dx $$
does not converge.
 A: Another approach to this integral is to write it as the limit
$$
\begin{align}
\int_0^\infty\frac{e^{-ax}-e^{-bx}}{x}\,\mathrm{d}x
&=\lim_{\epsilon\to0^+}\int_\epsilon^\infty\frac{e^{-ax}-e^{-bx}}{x}\,\mathrm{d}x\\
&=\lim_{\epsilon\to0^+}\left(\int_\epsilon^\infty\frac{e^{-ax}}{x}\,\mathrm{d}x-\int_\epsilon^\infty\frac{e^{-bx}}{x}\,\mathrm{d}x\right)\\
&=\lim_{\epsilon\to0^+}\left(\int_a^\infty\frac{e^{-\epsilon x}}{x}\,\mathrm{d}x-\int_b^\infty\frac{e^{-\epsilon x}}{x}\,\mathrm{d}x\right)\\
&=\lim_{\epsilon\to0^+}\int_a^b\frac{e^{-\epsilon x}}{x}\,\mathrm{d}x\\
&=\int_a^b\frac1{x}\,\mathrm{d}x\\[9pt]
&=\log(b/a)
\end{align}
$$
A: This one has a really cute trick, namely that the integrand is equal to
$$\int_a^b e^{-xt} \, dt$$
as you can verify by a direct computation. This means we can write a double integral and change the order of integration, yielding
\begin{align*}
\int_a^b \int_0^{\infty} e^{-xt} \, dx \, dt &= \int_a^b -\frac{e^{-xt}}{t}\big|_{x = 0}^{x = \infty} \, dt \\
&= \int_a^b \frac 1 t \, dt \\
&= \ln \frac b a
\end{align*}

By the way, the integral you mention does converge. It's bounded by $e^{-ax}$ as $x \to \infty$, and bounded at the origin because $e^{-ax} - 1 = -ax + O(x^2)$. 
A: A more tricky solution.
$$I_a=\int \frac{e^{-ax}}x\,dx=\text{Ei}(-a x)\implies J_a=\int_k^\infty \frac{e^{-ax}}x\,dx=\Gamma (0,a k)+\log(k)$$ Using Taylor expansion around $k=0$
$$J_a=-\log (a)-\gamma +a k+O\left(k^2\right)$$ and then $$J_a-J_b=\int_k^\infty \frac{e^{-ax}-e^{-bx}}x\,dx=\log\left(\frac b a \right)+(a-b)k+O\left(k^2\right)$$
A: Here's a solution that uses differentiation under the integral:
Introduce a parameter $s$ and define
$$ I(s) = \int_0^{\infty} \dfrac{e^{-ax} - e^{-bx}}{x} e^{-sx}dx$$
Differentiate with respect to the parameter to get
$$ I'(s) = \int_0^{\infty} [e^{-(s+b)x} - e^{-(s+a)x}]dx = \dfrac{1}{s+b} - \dfrac{1}{s+a}$$ 
Integrating both sides gives
$$I(s) = \ln \dfrac{s+b}{s+a}$$
Evaluate at $s=0$ to get the result.
