I think there is no analytical solution for $$ \int_{K}^{\infty} \frac{exp(-x)}{x} dx $$ where $K > 0$. Instead, is there an analytical approximation?
Analytical approximation of an integral
1.1k Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail AtThere are 4 best solutions below
On
There is an asymptotic approximation for large $K$ which can be obtained by repeated integration by parts.
This can also be obtained from Watson's lemma by making the change of variables $x=K(1+y)$ to get
$$ \begin{align} \int_K^\infty \frac{e^{-x}}{x}\,dx &= e^{-K} \int_0^\infty \frac{e^{-K y}}{1+y}\,dy \\ &\sim e^{-K} \sum_{n=0}^{\infty} (-1)^n \int_0^\infty e^{-Ky} y^n\,dy \\ &= e^{-K} \sum_{n=0}^{\infty} \frac{(-1)^n n!}{K^{n+1}} \end{align} $$
as $K \to \infty$.
On
Consider $$ f(k)=e^k\int_k^\infty\frac{e^{-t}}{t}\mathrm{d}t\tag{1} $$ Differentiating $(1)$, we get $$ \begin{align} f(k) &=\frac1k+f'(k)\\ &=\frac1k-\frac1{k^2}+f''(k)\\ &=\frac1k-\frac1{k^2}+\frac2{k^3}+f'''(k)\\ &=\frac1k-\frac1{k^2}+\frac2{k^3}-\frac6{k^4}+f''''(k)\\ &\vdots\\ &=\frac1k-\frac1{k^2}+\frac2{k^3}-\frac6{k^4}+\dots+(-1)^n\frac{n!}{k^{n+1}}+f^{(n+1)}(k)\tag{2} \end{align} $$ Note that since $$ f(k)=\int_0^\infty\frac{e^{-t}}{t+k}\mathrm{d}t\tag{3} $$ we have $$ \begin{align} |f^{(n+1)}(k)| &=\int_0^\infty\frac{(n+1)!\,e^{-t}}{(t+k)^{n+2}}\mathrm{d}t\\ &\le\frac{(n+1)!}{k^{n+2}}\tag{4} \end{align} $$ Combining $(1)$, $(2)$, and $(4)$ yields $$ \int_k^\infty\frac{e^{-t}}{t}\mathrm{d}t=e^{-k}\left(\frac1k-\frac1{k^2}+\frac2{k^3}-\frac6{k^4}+\dots+(-1)^n\frac{n!}{k^{n+1}}+O\left(\frac1{k^{n+2}}\right)\right)\tag{5} $$ $(4)$ says that the error is smaller than the first term omitted.
On
Another possibility, due to E.J. Weniger, is to use a so-called factorial series to approximate your exponential integral.
We start from the asymptotic expansion in robjohn's and Antonio's answers:
$$f(k)\sim\exp(-k)\sum_{n=0}^\infty \frac{(-1)^n n!}{k^{n+1}}$$
Weniger gives the remarkable formula
$$\sum_{j=0}^\infty \frac{c_j}{z^{j+1}}=\sum_{\ell=0}^\infty \frac1{(z)_{\ell+1}}\sum_{r=0}^\ell\left[{{\ell}\atop{r}}\right]c_r$$
where $(z)_k$ is a Pochhammer symbol, and $\left[{{n}\atop{k}}\right]$ is a Stirling cycle number. Applied to your exponential integral, we have the formula
$$f(k)=\exp(-k)\sum_{\ell=0}^\infty \frac1{(k)_{\ell+1}}\sum_{r=0}^\ell(-1)^r\left[{{\ell}\atop{r}}\right]r!$$
For instance, taking $k=3$, the tenth partial sum gives a value $\approx0.013049262$, and the twentieth partial sum gives a value $\approx0.013048481$; compare this with $E_1(3)\approx0.0130483811$. As with asymptotic series, this approximation performs much better for larger arguments.
In particular, for $E_1(x) = \int_{x}^{\infty}t^{-1}e^{-t}dt$, my favorite bound is \begin{align} \frac{1}{2}\log\left(1+\frac{2}{x}\right) < e^x E_1(x) < \log\left(1+\frac{1}{x}\right),\,x>0 \end{align} which will be quite tight for large $x$.