Contour integration w/ exponential and cosine functions

478 Views Asked by At

I am trying to solve the integral $$\int_0^\infty \frac{e^{-x}-\cos(x)}{x}dx$$ using contour integration. However, I do not know where to begin. Any suggestions would be appreciated.

1

There are 1 best solutions below

2
On BEST ANSWER

With some research, I developed these approaches: Complex analysis, Laplace transform, and special functions

1. Complex Analysis (recommended)

If we were to calculate the following integral

$$\oint_C{e^{-z}-e^{iz}\over z}\mathrm{d}z\equiv\int\limits_{\gamma+C_1+\Gamma+C_2}f(z)\mathrm{d}z$$

with the contour being

contour

Since $f(z)$ is analytic on and within the contour, LHS is automatically zero. Now, let's look at RHS (with the $C_1$ part parametrized):

$$ 0=\int_{\gamma+\Gamma} f(z)\mathrm{d}z+\int_\varepsilon^R{e^{-t}-e^{it}\over t}\mathrm{d}t+\int_{C_2}f(z)\mathrm{d}z $$

Now, let's bring substitution $z=it,\mathrm{d}z=i\mathrm{d}t$ to $\int_{C_2}f(z)\mathrm{d}z$

$$ \int_{C_2}f(z)\mathrm{d}z=\int_R^\varepsilon{e^{-it}-e^{-t}\over t}\mathrm{d}t =\int_\varepsilon^R{e^{-t}-e^{-it}\over t}\mathrm{d}t $$

As a result, we have

$$ \int_{C_1+C_2}f(z)\mathrm{d}z =\int_\varepsilon^R{2e^{-t}-(e^{it}+e^{-it})\over t}\mathrm{d}t $$

With the Euler's formula $2\cos\theta=e^{i\theta}+e^{-i\theta}$, we obtain

$$ \int_{C_1+C_2}f(z)\mathrm{d}z=2\int_\varepsilon^R{e^{-t}-\cos(t)\over t}\mathrm{d}t $$

Plugging the result back into our original contour integration equation, we can discover

$$ 0=\int_{\gamma+\Gamma}f(z)\mathrm{d}z+2\int_\varepsilon^R{e^{-t}-\cos(t)\over t}\mathrm{d}t $$

Now, take the limit on both side as $R\to\infty$ and $\varepsilon\to0$:

$$ 0=\lim_{(\varepsilon,n)\to(0,\infty)}\int_{\gamma+\Gamma}f(z)\mathrm{d}z+2\int_0^\infty{e^{-t}-\cos(t)\over t}\mathrm{d}t $$

I think it would be a trivial task to show that the remaining limit is zero, leaving us the answer that

$$\int_0^\infty{e^{-t}-\cos(t)\over t}\mathrm{d}t=0$$

2. Laplace transform

Since we are integrating this function from zero to infinity, we can find its Laplace transform first, and then evaluate the formula at $s=0$. Basically, we construct the following function:

$$ F(s)=\int_0^\infty{e^{-t}-\cos(t)\over t}e^{-st}\mathrm{d}t $$

Now, let's use Feynman's trick to eliminate the denominator:

$$ F'(s)=\int_0^\infty{\partial\over\partial s}{e^{-t}-\cos(t)\over t}e^{-st}\mathrm{d}t=\int_0^\infty(\cos(t)-e^{-t})e^{-st}\mathrm{d}t =\mathcal{L}\{\cos(t)-e^{-st}\} $$

Due to the linearity of Laplace transform operator, we can split the integrand, and using table of Laplace transform allows us to quickly find its answer:

$$ F'(s)=\mathcal{L}\{\cos(t)\}-\mathcal{L}\{e^{-t}\} ={s\over s^2+1}-{1\over s+1} $$

Now, we have found a convenient expression for $F'(s)$ to work with, so let's find its antiderivative $F(s)$:

$$ F(s)=\int\left[{s\over s^2+1}-{1\over s+1}\right]\mathrm{d}s ={1\over2}\ln|s^2+1|-\ln|s+1|+C=\ln\left|\sqrt{s^2+1}\over s+1\right|+C $$

Recall the integral definition of $F(s)$, we know that the integral goes to zero as $s\to\infty$, so

$$ \lim_{s\to\infty}\ln\left|\sqrt{s^2+1}\over s+1\right|+C=C \Rightarrow C=0 $$

As a result, we know $F(s)=\ln\left|\sqrt{s^2+1}\over s+1\right|$. If we set $s=0$, we can also find the same answer that the integral equals to zero:

$$ \int_0^\infty{e^{-t}-\cos(t)\over t}\mathrm{d}x=F(0)=\ln(1)=0 $$

3. Special functions (incomplete, I asked Wolfram Alpha for help)

To prevent dealing with nasty divergence problems, we split the integrands:

$$ \int_0^\infty{e^{-x}-\cos(x)\over x}\mathrm{d}x=\int_0^\infty{e^{-x}-1\over x}\mathrm{d}x+\int_0^\infty{1-\cos(x)\over x}\mathrm{d}x $$

By dominated convergence theorem, we can show that

$$ \int_0^\infty{e^{-x}-1\over x}\mathrm{d}x=\lim_{n\to\infty}\int_0^n{\left(1-{x\over n}\right)^n-1\over x}\mathrm{d}x\equiv\lim_{n\to\infty}I_1 $$

It is also not difficult to show that the original integral is equivalent to:

$$ \int_0^\infty{e^{-x}-\cos(x)\over x}\mathrm{d}x=\lim_{n\to\infty}\left(I_1+\underbrace{\int_0^n{1-\cos(x)\over x}\mathrm{d}x}_\text{We will call it $I_2$ later}\right) $$

If we were perform substitution $u={1-x\over n}$ and $-n\mathrm{d}u=\mathrm{d}x$, we can turn this integral into a neat form:

$$ \begin{aligned} I_1&=-\int_0^1{1-u^n\over1-u}\mathrm{d}u \\ &=-\int_0^1\sum_{k=0}^{n-1}u^k\mathrm{d}u \\ &=-\sum_{k=0}^{n-1}\int_0^1u^k\mathrm{d}u \\ &=-\sum_{k=0}^{n-1}{1\over k+1}\equiv -H_n \end{aligned} $$

Now, let's look at $I_2$. To prevent divergence, let's also split it:

$$ \begin{aligned} I_2&=\int_0^1{1-\cos(x)\over x}\mathrm{d}x+\int_1^n{1-\cos(x)\over x}\mathrm{d}x \\ &=\int_0^1{1-\cos(x)\over x}\mathrm{d}x+\ln(n)-\int_1^n{\cos(x)\over x}\mathrm{d}x \end{aligned} $$

Now, if we go back to the original integral, we found

$$ \begin{aligned} \int_0^\infty{e^{-x}-\cos(x)\over x}\mathrm{d}x &=\lim_{n\to\infty}\left[-(H_n-\ln(n))+\int_0^1{1-\cos(x)\over x}\mathrm{d}x-\int_1^n{\cos(x)\over x}\mathrm{d}x\right] \\ &=-\gamma+\int_0^1{1-\cos(x)\over x}\mathrm{d}x-\lim_{n\to\infty}\left[\int_1^n{\cos(x)\over x}\mathrm{d}x\right] \\ &=-\gamma+\mathrm{Ci}(1)+\int_0^1{1-\cos(x)\over x}\mathrm{d}x \end{aligned} $$

Due to my limited math ability, I ask Wolfram Alpha for help, and it turns out that the remaining integral $\int_0^1{1-\cos(x)\over x}\mathrm{d}x$ is exactly $\gamma-\mathrm{Ci}(1)$. As a result, the answer is exactly zero.

$$ \int_0^\infty{e^{-x}-\cos(x)\over x}\mathrm{d}x=-\gamma+\mathrm{Ci}(1)+\gamma-\mathrm{Ci}(1)=0 $$

P.S. I will update this as long as I can figure it out without the help of any answer engines