# Calculating an integral using the Laplace transform

I'm looking for a "polite" way to calculate this integral using Laplace transform:

$$\int_0^{+\infty} \frac{e^{-ax} - e^{-bx} }{x} dx.$$

Now the impolite way is to invoke a famous theorem from basic differential equations: $$\mathcal{L}( f(x)/x) = \int_s^\infty F(t) dt,$$

Where $$F$$ is the LT of $$f$$. Setting $$f(x)/x= 1/x$$ in this theorem (and recalling the definition of LT) gives $$\int_0^\infty \frac{e^{-ax}}{x} = \infty - \ln(a).$$ Similarly $$\int_0^\infty \frac{e^{-bx}}{x} = \infty - \ln(b).$$

Putting the results together and cancelling infinity gives the final result $$\ln \frac{b}{a}$$ which I know for a fact is the true value of the integral. But I also know too well that cancelling infinity is not allowed. So what is the trick?

• Hi @Erfan, I'm no expert in Laplace transforms but perhaps this may come in handy proofwiki.org/wiki/… Commented Dec 27, 2020 at 10:11
• Maybe of interest: math.stackexchange.com/questions/61828/… Commented Dec 27, 2020 at 10:15
• Have you ever heard of Frullani's Integral? Commented Dec 27, 2020 at 15:40
• @Dmoreno Hi it was indeed helpful thanks Commented Dec 27, 2020 at 18:29
• @Hans I think the Laplace method isn't discussed there, nevertheless it was insightful. Thanks! Commented Dec 27, 2020 at 18:30

$$g(x) = \frac{e^{-ax} - e^{-bx} }{x} = \frac{(1-e^{-bx}) - (1-e^{-ax}) }{x}= \frac{f_b(x)}{x} - \frac{f_a(x)}{x}$$ where
$$f_c(x) = (1- e^{-cx})$$ for $$c \gt 0$$. Then denoting the step function by $$u$$ we have $$\mathcal L(f_c \cdot u)(s) = \frac{c}{s(s+c)}$$ and
\begin{aligned}\mathcal{L}( g)(s) &= \int_s^\infty F(t) dt = \int_s^\infty \left(\frac{b}{t(t+b)}-\frac{a}{t(t+a)}\right) \ dt\\ &= \int_s^\infty \left(\frac{1}{t+a}-\frac{1}{t+b}\right) \ dt\\ &= \ln\left(\frac{s+b}{s+a}\right) \end{aligned}
The desired equality is finally obtained by plugging in $$s=0$$ in previous equation.
• Thanks for the answer. Is $u(t)$ the unit step function? Commented Dec 27, 2020 at 18:34