0

I saw the following integral $$\int^\infty_0 \mathrm{d}x \left(\frac{1-e^{-x}}{x}\right)^2$$ on Michael Penn's video, and tried to solve it myself. My solution is as follows:

Let $I$ denote the integral, integrating by parts we have $$ I = \int^\infty_0 \mathrm{d}x \left(\frac{1-e^{-x}}{x}\right)^2 = \left.x\left(\frac{1-e^{-x}}{x}\right)^2\right|^\infty_0 + 2\int^\infty_0 \mathrm{d}x \left[ \left(\frac{1-e^{-x}}{x}\right)^2 - \left(\frac{1-e^{-x}}{x}\right)e^{-x}\right] , $$

$$ I = 2I - 2\int^\infty_0 \mathrm{d}x \left(\frac{1-e^{-x}}{x}\right)e^{-x} , $$ So $$ I = 2 \left(\int^\infty_0 \mathrm{d}x \frac{e^{-x}}{x} - \int^\infty_0 \mathrm{d}x \frac{e^{-2x}}{x} \right). $$

The following integrals are improper integrals related to the exponential integral. In evaluating them I use Feynman's trick: Let $\bar{I}(\alpha) = \int^\infty_0 \mathrm{d}x \frac{e^{-\alpha x}}{x} $ Then $$ \frac{\mathrm{d}\bar{I}}{\mathrm{d}\alpha} = - \int^\infty_0 \mathrm{d}x \text{ } e^{-\alpha x} = -\frac{1}{\alpha} , $$ $$ \bar{I}(\alpha) = -\ln(\alpha) + \bar{C} . $$

Since $\bar{C}$ is constant for different values of $\alpha$, it cancels out nicely in the difference, and $$ I = 2\left(\bar{I}(1)-\bar{I}(2)\right) = 2\ln 2. $$


My first question is why the difference calculated this way yields the right answer, since the two integrals seem to be identical with a change of variable: $$ \int^\infty_0 \mathrm{d}x\text{ }\frac{e^{-2x}}{x} = \int^\infty_0 \mathrm{d}(2x)\text{ }\frac{e^{-2x}}{2x} = \int^\infty_0 \mathrm{d}x\text{ }\frac{e^{-x}}{x} .$$

My second question is ifi there's some way to calculate the value of $\bar{C}$ in the above equation. Normally I think this would be done by substituting suitable values for $\alpha$, but it doesn't seem like there's any value that would make the integral doable.

Jono94
  • 271
  • This is $I_2$ in this question: https://math.stackexchange.com/q/4586011 Note that the integral $\bar{I}(\alpha)$ you wrote is divergent because of the non integrable singularity at the origin. – Gary Nov 14 '23 at 08:18
  • 1
    Your expression $$ I = 2 \left(\int^\infty_0 \mathrm{d}x \frac{e^{-x}}{x} - \int^\infty_0 \mathrm{d}x \frac{e^{-2x}}{x} \right). $$ is an indeterminate form of $\infty-\infty$, Which is not always zero – Dheeraj Gujrathi Nov 14 '23 at 08:23

1 Answers1

3

The problem is that $$\int_{x=0}^\infty \frac{e^{-x}}{x} \, dx$$ does not converge, so you have basically rewritten the integral in the previous step $$\int_{x=0}^\infty \left(\frac{1-e^{-x}}{x}\right)e^{-x} \, dx$$ as a difference of integrals that are divergent--i.e., as an indeterminate form $\infty - \infty$. This is why, upon transformation of the second integral, you get an apparent cancellation that is invalid.

The corresponding discrete phenomenon can be expressed more clearly in the familiar alternating harmonic series example $$\sum_{k=1}^\infty \frac{(-1)^{k+1}}{k} = \log 2.$$ If we were to separate the positive and negative terms of the sum, we would get something nonsensical: $$\log 2 = \sum_{k=1}^\infty \frac{1}{2k} - \sum_{k=1}^\infty \frac{1}{2k-1},$$ as each of these sums is divergent.

You can address this issue and resolve the paradox by being more careful about the lower limit of integration, which also illustrates why the cancellation after the variable substitution $u = 2x$ does not result in zero. You would write $$I = \lim_{\epsilon \to 0^+} 2 \left( \int_{x=\epsilon}^\infty \frac{e^{-x}}{x} \, dx - \int_{x=\epsilon}^\infty \frac{e^{-2x}}{x} \, dx \right).$$ Then the substitution $u = 2x$ in the second integral yields $$I = \lim_{\epsilon \to 0^+} 2 \left( \int_{x=\epsilon}^\infty \frac{e^{-x}}{x} \, dx - \int_{u=2\epsilon}^{\infty} \frac{e^{-u}}{u} \, du \right) = \lim_{\epsilon \to 0^+} 2 \int_{x=\epsilon}^{2\epsilon} \frac{e^{-x}}{x} \, dx.$$

The evaluation of this finite integral can then proceed using the same trick you employed:

$$\bar I(\alpha) = \int_{x = \epsilon}^{2\epsilon} \frac{e^{-\alpha x}}{x} \, dx, \quad \frac{\partial\bar I}{\partial\alpha} = \int_{x = \epsilon}^{2\epsilon} -e^{-\alpha x} \, dx = -\frac{e^{-\alpha \epsilon} (1 - e^{-\alpha \epsilon})}{\alpha}.$$

But now integrating with respect to $\alpha$ leads you to the same integrand as before.

heropup
  • 135,869