# How to Integrate e^(1/x)

TR Smith is a teacher and creator who uses mathematics in her line of work every day.

Joined: 5 years agoFollowers: 215Articles: 453

The function y = e^(1/x) is a solution to the differential equation (x^2)y' = -y. It has a horizontal asymptote at y = 1, meaning as x goes to infinity or negative infinity, the function e^(1/x) tends toward the value of 1. However, at x = 0, the behavior of e^(1/x) is a little strange. On the positive side of the x-axis, e^(1/x) goes to infinity as x goes to 0. But on the negative side, e^(1/x) goes to 0 as x goes to 0. See graph below.

A function of the form h(x) = e^(x^n) can be integrated only if the exponent n is equal to 1, 1/2, 1/3, 1/4, 1/5, etc. That means f(x) = e^(x^-1) = e^(1/x) is non-integrable; in other words, you can't calculate the integral of e^(1/x) in terms of elementary functions. It is possible, however, to approximate the antiderivative of e^(1/x) with an infinite series, and use that series to estimate definite integrals. You can also use Riemann sums to estimate definite integrals.

## An Infinite Series for the Integral of e^(1/x)

The Taylor series expansion of ew is

ew = 1 + w + w2/2 + w3/6 + w4/24 + w5/120 + ... + wn/n! + ...

If we replace w with 1/x, we get a series for e1/x:

e1/x = 1 + 1/x + 1/(2x2) + 1/(6x3) + 1/(24x4) + 1/(120x5) + ...

Now if we integrate this series term by term we can obtain an infinite series for the integral of e^(1/x):

∫ e1/x dx = x + Ln|x| - 1/(2x) - 1/(12x2) - 1/(72x3) - 1/(480x4) - ...

This series is convergent for all values of x except for 0, so you can truncate it somewhere and use it to estimate the definite integral of e1/x from x = -2 to x = -0.5, or from x = 3 to x = 7, for example. But you can't use it to evaluate the integral from -2 to 3, since that interval includes the discontinuity at 0, and so does not converge. The more terms you include in the truncation, the more accurate the estimate.

## An Asymptotic Series for the Integral of e^(1/x)

We can use the technique of integration by parts to find an asymptotic series (non-convergent series) for the integral of e1/x that provides a good estimate for values of x that are near zero. First we rewrite the integral in an equivalent form.

∫ e1/x dx = ∫ [-e1/x / x2] * [-x2] dx

If we let v' = -e1/x/x2 and u = -x2, then we get u' = -2x and v = e1/x. This gives us the new integral equation

∫ e1/x dx = -x2e1/x + 2∫ xe1/x dx

Now we replace the integrand x*e^(1/x) with the equivalent [-e1/x/x2]*[-x3] and apply integration by parts again using the same assignment with v' = -e1/x/x2. This gives us

∫ e1/x dx = -x2e1/x - 2x3e1/x - 6∫ x2e1/x dx

Repeating this process over and over gives us the infinite series

∫ e1/x dx = -[e1/x]*[x2 + 2x3 + 6x4 + 24x5 + ... + n!xn+1 + ...]

## More Integration Tutorials

For general help with integration techniques and finding antiderivatives, see also the Table of Integrals and Four Common Mistakes Students Make with u-Substitution.

This series doesn't converge for any value of x, however, if you truncate it after a finite number of terms and plug in a values of x that are near zero and on the same side of the x-axis, then it provides a good estimate of the definite integral. For example, you can use it to evaluate the integral of e1/x from x = 0.1 to x = 0.2 using four terms.

How many terms you should use depends on the limits of the integral. If the limits are x = p to x = q, with p and q positive and q greater than p, then you should use (1/q - 1) terms, where (1/q - 1) is rounded up to a whole number. For example, if q = 0.15, you would use 6 terms, since (1/0.15 - 1) = 5.67.

If p and q are negative with q less than p, use (1/|q| - 1) terms, with (1/|q| - 1) rounded up to a whole number.

One way in which asymptotic series are different from convergent series is that if you include more terms in the truncation, you actually get a worse estimate.

## Example 1

We can use the first series to estimate the definite integral of e1/x from x = -3 to x = -1. This region is shaded in green in the figure below.

Using the truncated series

∫ e1/x dx ≈ x + Ln|x| - 1/(2x) - 1/(12x2) - 1/(72x3) - 1/(480x4)

we plug in x = -1 and x = -3 and subtract. This gives us

[-823/1440] - [Ln(3) - 110501/38880] ≈ 1.171964

With a numerical integrator, we find the area under the curve from x = -3 to x = -1 is closer to 1.172211, so the truncated series with six terms underestimates the area by about 0.000247. With more terms we would get an even more accurate approximation.

## Example 2

Let's use the asymptotic series to estimate the area under the curve y = e1/x from x = 0.12 to x = 0.18. This area is shaded in green in the graph below.

Since the upper endpoint is 0.18, we compute 1/0.18 - 1 = 4.56 and round this up to 5. This means we take 5 terms of the asymptotic series. Our integral approximation formula is then

∫ e1/x dx ≈ [-e1/x]*[x2 + 2x3 + 6x4 + 24x5 + 120x6]

Plugging in the endpoints 0.18 and 0.12 and subtracting gives us

-15.256133 - (-83.436862) = 68.180729

Using a numerical integrator gives us an answer closer to 70.9762, so our estimate is off by about 4% from the true answer. We could get a more accurate estimate using the convergent series in the first example, but we would need many more terms.

## Is the Improper Integral of e^(1/x) - 1 Convergent?

The area under curve f(x) = e^(1/x) - 1 gets smaller and smaller as x approaches infinity. Since the similar integral of e^(-x) from x = a to x = ∞ converges, it is natural to wonder if the integral of e^(1/x) - 1 from x = a to x = ∞ also converges. It turns out that the answer is no.

Since e^(1/x) - 1 is always greater than 1/x for values of x larger than 1, and the infinite integral of 1/x is divergent, then e^(1/x) - 1 is also divergent.

0

2

0

0

## Popular

30

31

• ### Names of Geometric Shapes—With Pictures

30

0 of 8192 characters used

• Dilan 21 months ago

Thanks

• ed wilke 2 months ago

Can the integral of 1/((x^3) (e^(1/x)-1)) be found? Using Mcclurins, e^x = 1 +x, so e^(1/x)= 1 +1/x... Substituting, at large x, this should go to 1/x^2=0, and for small x...e^(1/x) should grow faster than 1/x^3....so the integral should go to 0 at x=0. Am i right? Thanks, ed wilke

• ed wilke 2 months ago

If the intergral of f(x) is divergent, then is the integral of 1/f(x) convergent? always?

• Author

TR Smith 2 months ago from Germany

Hi Ed, thanks for your questions. The function you gave, g(x) = [(e^(1/x) - 1)x^3]^(-1), does not have a closed-form antiderivative so you would have to use an approximation method to calculate a definite integral.

As to your second question, if the integral of f(x) over some interval (possibly infinite) is divergent, it is not necessarily true that the integral of 1/f(x) over that same interval is convergent. For example, consider the integral of f(x) = x, from 1 to infinity. This integral is divergent, but so is the integral of 1/x, from 1 to infinity.