27.2 Exponential and Logarithmic Integrals
SL 5.10
- how to integrate \(\mathrm{e}^x\) and \(\mathrm{e}^{ax + b}\)
- how to integrate \(\dfrac{1}{x}\) and \(\dfrac{1}{ax + b}\), and why the answer has a modulus \(\lvert\;\rvert\)
- three patterns that reverse the chain rule: \(\dfrac{f'(x)}{f(x)}\), \(\;f'(x)\big[f(x)\big]^n\) and \(f'(x)\,\mathrm{e}^{f(x)}\)
- (Extension) using partial fractions with a repeated factor before integrating
This is integration by inspection: you recognise the integrand as the derivative of something you know.
Exponential functions
From differentiation we know
\[ \frac{\mathrm{d}}{\mathrm{d}x}\mathrm{e}^x = \mathrm{e}^x \qquad\text{and}\qquad \frac{\mathrm{d}}{\mathrm{d}x}\mathrm{e}^{ax + b} = a\,\mathrm{e}^{ax + b}, \qquad\text{so}\qquad \frac{\mathrm{d}}{\mathrm{d}x}\left(\frac{1}{a}\mathrm{e}^{ax + b}\right) = \mathrm{e}^{ax + b}\quad(a \neq 0). \]
Integrals of exponential functions Partly in the formula booklet
\[ \int \mathrm{e}^x\,\mathrm{d}x = \mathrm{e}^x + C \]
In the booklet
\[ \int \mathrm{e}^{ax + b}\,\mathrm{d}x = \frac{1}{a}\mathrm{e}^{ax + b} + C, \quad a \neq 0. \]
- \(a\): the coefficient of \(x\) in the power (\(a \neq 0\))
- \(b\): the constant term in the power
- \(C\): the constant of integration
Example 1 Integrate with respect to \(x\):
(a) \(\mathrm{e}^{3 - 4x}\) \(\qquad\) (b) \(\dfrac{6}{5\mathrm{e}^{2x + 1}}\)
(a) \(a = -4\): \(\displaystyle\int \mathrm{e}^{3 - 4x}\,\mathrm{d}x = -\frac{1}{4}\mathrm{e}^{3 - 4x} + C\)
(b) Move the exponential to the top: \(\dfrac{6}{5\mathrm{e}^{2x + 1}} = \dfrac{6}{5}\mathrm{e}^{-2x - 1}\). Here \(a = -2\):
\[ \int \frac{6}{5}\mathrm{e}^{-2x - 1}\,\mathrm{d}x = \frac{6}{5} \times \left(-\frac{1}{2}\right)\mathrm{e}^{-2x - 1} + C = -\frac{3}{5}\mathrm{e}^{-2x - 1} + C \]
Since \(\dfrac{\mathrm{d}}{\mathrm{d}x}a^x = a^x \ln a\), we have
\[ \int a^x\,\mathrm{d}x = \frac{a^x}{\ln a} + C, \qquad a > 0,\ a \neq 1. \]
This is in the HL formula booklet. For example, \(\displaystyle\int 5^x\,\mathrm{d}x = \frac{5^x}{\ln 5} + C\).
Logarithmic functions
From differentiation, \(\dfrac{\mathrm{d}}{\mathrm{d}x}\ln x = \dfrac{1}{x}\) for \(x > 0\). With the chain rule, for \(ax + b > 0\),
\[ \frac{\mathrm{d}}{\mathrm{d}x}\left[\frac{1}{a}\ln(ax + b)\right] = \frac{1}{a} \cdot \frac{a}{ax + b} = \frac{1}{ax + b}. \]
What if \(x < 0\)? Then \(\ln(-x)\) is defined, and \(\dfrac{\mathrm{d}}{\mathrm{d}x}\ln(-x) = \dfrac{-1}{-x} = \dfrac{1}{x}\) too. Both cases are covered by writing \(\ln\lvert x\rvert\).
Integrals giving logarithms Partly in the formula booklet
\[ \int \frac{1}{x}\,\mathrm{d}x = \ln\lvert x\rvert + C \]
In the booklet
\[ \int \frac{1}{ax + b}\,\mathrm{d}x = \frac{1}{a}\ln\lvert ax + b\rvert + C, \quad a \neq 0. \]
This fills the gap in the power rule: the case \(n = -1\).
- \(a\): the coefficient of \(x\) (\(a \neq 0\))
- \(b\): the constant term
- \(C\): the constant of integration
Example 2 Find
(a) \(\displaystyle\int \frac{5}{x}\,\mathrm{d}x\)
(b) \(\displaystyle\int \frac{1}{3x + 2}\,\mathrm{d}x\)
(c) \(\displaystyle\int \frac{4}{3 - 2x}\,\mathrm{d}x\)
(a) \(5\ln\lvert x\rvert + C\)
(b) \(\dfrac{1}{3}\ln\lvert 3x + 2\rvert + C\)
(c) \(a = -2\): \(\;4 \times \left(-\dfrac{1}{2}\right)\ln\lvert 3 - 2x\rvert + C = -2\ln\lvert 3 - 2x\rvert + C\)
The IB syllabus uses partial fractions only with two different linear factors (see Section 3.1 and Section 27.4). A repeated factor such as \((x + 1)^2\) needs an extra term \(\dfrac{C}{(x + 1)^2}\).
Example A.
(a) Express \(\dfrac{5x^2 + 8x + 2}{x(x + 1)^2}\) in partial fractions. \(\;\)
(b) Hence find \(\displaystyle\int \frac{5x^2 + 8x + 2}{x(x + 1)^2}\,\mathrm{d}x\).
(a) Write \(\dfrac{5x^2 + 8x + 2}{x(x + 1)^2} = \dfrac{A}{x} + \dfrac{B}{x + 1} + \dfrac{C}{(x + 1)^2}\), so
\[ 5x^2 + 8x + 2 = A(x + 1)^2 + Bx(x + 1) + Cx. \]
\(x = 0\): \(A = 2\). \(\quad x = -1\): \(5 - 8 + 2 = -C\), so \(C = 1\). \(\quad\) Coefficients of \(x^2\): \(A + B = 5\), so \(B = 3\).
\[ \frac{5x^2 + 8x + 2}{x(x + 1)^2} = \frac{2}{x} + \frac{3}{x + 1} + \frac{1}{(x + 1)^2} \]
(b) The last term is a power of a linear expression: \(\int (x + 1)^{-2}\,\mathrm{d}x = -(x + 1)^{-1}\).
\[ \int \frac{5x^2 + 8x + 2}{x(x + 1)^2}\,\mathrm{d}x = 2\ln\lvert x\rvert + 3\ln\lvert x + 1\rvert - \frac{1}{x + 1} + C \]
Reversing the chain rule
Three results from differentiation (with \(f\) a function of \(x\)):
\[ \frac{\mathrm{d}}{\mathrm{d}x}\ln\lvert f(x)\rvert = \frac{f'(x)}{f(x)}, \qquad \frac{\mathrm{d}}{\mathrm{d}x}\left(\frac{\big[f(x)\big]^{n+1}}{n + 1}\right) = f'(x)\big[f(x)\big]^n, \qquad \frac{\mathrm{d}}{\mathrm{d}x}\mathrm{e}^{f(x)} = f'(x)\,\mathrm{e}^{f(x)}. \]
Reading them backwards gives three integration patterns.
Integration by inspection Not in the formula booklet
- \(\displaystyle\int \frac{f'(x)}{f(x)}\,\mathrm{d}x = \ln\lvert f(x)\rvert + C\)
- \(\displaystyle\int f'(x)\big[f(x)\big]^n\,\mathrm{d}x = \frac{\big[f(x)\big]^{n+1}}{n + 1} + C, \quad n \neq -1\)
- \(\displaystyle\int f'(x)\,\mathrm{e}^{f(x)}\,\mathrm{d}x = \mathrm{e}^{f(x)} + C\)
Look for a function and its derivative. If the derivative is there up to a constant factor, adjust the constant.
- \(f(x)\): a function of \(x\)
- \(f'(x)\): the derivative of \(f(x)\)
- \(n\): a constant power (\(n \neq -1\))
- \(C\): the constant of integration
Example 3 Find
(a) \(\displaystyle\int \frac{4x + 3}{2x^2 + 3x + 5}\,\mathrm{d}x\)
(b) \(\displaystyle\int \frac{x - 1}{(x^2 - 2x + 7)^2}\,\mathrm{d}x\)
(c) AHL \(\displaystyle\int \frac{\mathrm{e}^{\arctan x}}{1 + x^2}\,\mathrm{d}x\)
(a) \(f(x) = 2x^2 + 3x + 5\) has \(f'(x) = 4x + 3\), exactly the numerator. Pattern 1:
\[ \int \frac{4x + 3}{2x^2 + 3x + 5}\,\mathrm{d}x = \ln\left(2x^2 + 3x + 5\right) + C. \]
(The discriminant is \(9 - 40 < 0\), so \(2x^2 + 3x + 5 > 0\) and no modulus is needed.)
(b) \(f(x) = x^2 - 2x + 7\) has \(f'(x) = 2x - 2 = 2(x - 1)\). So \(x - 1 = \dfrac{1}{2}f'(x)\). Pattern 2 with \(n = -2\):
\[ \int \frac{x - 1}{(x^2 - 2x + 7)^2}\,\mathrm{d}x = \frac{1}{2} \cdot \frac{(x^2 - 2x + 7)^{-1}}{-1} + C = -\frac{1}{2(x^2 - 2x + 7)} + C. \]
(c) \(f(x) = \arctan x\) has \(f'(x) = \dfrac{1}{1 + x^2}\). Pattern 3:
\[ \int \frac{1}{1 + x^2}\,\mathrm{e}^{\arctan x}\,\mathrm{d}x = \mathrm{e}^{\arctan x} + C. \]
Example 4 Find
(a) \(\displaystyle\int \frac{2 - x}{\sqrt{5 + 4x - x^2}}\,\mathrm{d}x\)
(b) \(\displaystyle\int \frac{\mathrm{e}^{3x} - \mathrm{e}^{-3x}}{\mathrm{e}^{3x} + \mathrm{e}^{-3x}}\,\mathrm{d}x\)
(a) \(f(x) = 5 + 4x - x^2\) has \(f'(x) = 4 - 2x = 2(2 - x)\). So the integrand is \(\dfrac{1}{2}f'(x)\big[f(x)\big]^{-\frac{1}{2}}\).
\[ \int \frac{2 - x}{\sqrt{5 + 4x - x^2}}\,\mathrm{d}x = \frac{1}{2} \cdot \frac{\big[f(x)\big]^{\frac{1}{2}}}{\frac{1}{2}} + C = \sqrt{5 + 4x - x^2} + C. \]
(b) \(f(x) = \mathrm{e}^{3x} + \mathrm{e}^{-3x}\) has \(f'(x) = 3\mathrm{e}^{3x} - 3\mathrm{e}^{-3x}\), which is \(3 \times\) the numerator.
\[ \int \frac{\mathrm{e}^{3x} - \mathrm{e}^{-3x}}{\mathrm{e}^{3x} + \mathrm{e}^{-3x}}\,\mathrm{d}x = \frac{1}{3}\ln\left(\mathrm{e}^{3x} + \mathrm{e}^{-3x}\right) + C. \]
Common errors
| ✗ Wrong | ✓ Right | Why |
|---|---|---|
| \(\int \mathrm{e}^{4x}\,\mathrm{d}x = 4\mathrm{e}^{4x}\) | \(\dfrac{1}{4}\mathrm{e}^{4x} + C\) | Integration divides by \(a\); differentiation multiplies. |
| \(\int \mathrm{e}^{x^2}\,\mathrm{d}x = \dfrac{\mathrm{e}^{x^2}}{2x}\) | (no simple anti-derivative) | Dividing by \(a\) works only for linear \(ax + b\); check by differentiating. |
| \(\int \dfrac{1}{x}\,\mathrm{d}x = \ln x + C\) for all \(x\) | \(\ln\lvert x\rvert + C\) | \(\ln x\) is not defined for \(x < 0\). |
| \(\int \dfrac{1}{2x + 1}\,\mathrm{d}x = \ln\lvert 2x + 1\rvert\) | \(\dfrac{1}{2}\ln\lvert 2x + 1\rvert + C\) | Divide by the coefficient of \(x\). |
| \(\int \dfrac{1}{x^2 + 1}\,\mathrm{d}x = \ln(x^2 + 1)\) | \(\arctan x + C\) | The numerator is not \(f'(x) = 2x\). |
Exercises
1 Find \(\displaystyle\int \mathrm{e}^{5x}\,\mathrm{d}x\).
\(\dfrac{1}{5}\mathrm{e}^{5x} + C\).
2 Find \(\displaystyle\int \left(\mathrm{e}^x + \mathrm{e}^{-x}\right)^2\mathrm{d}x\).
Expand: \(\mathrm{e}^{2x} + 2 + \mathrm{e}^{-2x}\). So the integral is \(\dfrac{1}{2}\mathrm{e}^{2x} + 2x - \dfrac{1}{2}\mathrm{e}^{-2x} + C\).
3 Find \(\displaystyle\int \frac{8}{\mathrm{e}^{4x - 1}}\,\mathrm{d}x\).
\(\displaystyle\int 8\mathrm{e}^{1 - 4x}\,\mathrm{d}x = 8 \times \left(-\frac{1}{4}\right)\mathrm{e}^{1 - 4x} + C = -2\mathrm{e}^{1 - 4x} + C\).
4 Find \(\displaystyle\int \left(\frac{3}{x} - \frac{2}{x^2}\right)\mathrm{d}x\).
\(3\ln\lvert x\rvert - 2 \cdot \dfrac{x^{-1}}{-1} + C = 3\ln\lvert x\rvert + \dfrac{2}{x} + C\).
5 Find \(\displaystyle\int \frac{6}{2x + 5}\,\mathrm{d}x\).
\(6 \times \dfrac{1}{2}\ln\lvert 2x + 5\rvert + C = 3\ln\lvert 2x + 5\rvert + C\).
6 Find \(\displaystyle\int \frac{x^2 + 3}{x}\,\mathrm{d}x\).
\(\displaystyle\int \left(x + \frac{3}{x}\right)\mathrm{d}x = \frac{x^2}{2} + 3\ln\lvert x\rvert + C\).
7 Find \(\displaystyle\int x\,\mathrm{e}^{3x^2}\,\mathrm{d}x\).
\(f(x) = 3x^2\), \(f'(x) = 6x\), so \(x = \dfrac{1}{6}f'(x)\): \(\;\displaystyle\int x\,\mathrm{e}^{3x^2}\,\mathrm{d}x = \frac{1}{6}\mathrm{e}^{3x^2} + C\).
8 Find \(\displaystyle\int \frac{2x + 1}{x^2 + x + 4}\,\mathrm{d}x\).
The numerator is the derivative of the denominator: \(\ln\left(x^2 + x + 4\right) + C\) (the denominator is always positive, since \(1 - 16 < 0\)).
9 Find \(\displaystyle\int \frac{(\ln x)^3}{x}\,\mathrm{d}x\), \(\;x > 0\).
\(f(x) = \ln x\), \(f'(x) = \dfrac{1}{x}\). Pattern 2 with \(n = 3\): \(\;\dfrac{(\ln x)^4}{4} + C\).
10 A curve has \(\dfrac{\mathrm{d}y}{\mathrm{d}x} = \dfrac{2}{x + 1} + \mathrm{e}^{-x}\) for \(x > -1\), and passes through \((0, 4)\). Find \(y\) in terms of \(x\).
\(y = 2\ln(x + 1) - \mathrm{e}^{-x} + C\). At \((0, 4)\): \(4 = 0 - 1 + C\), so \(C = 5\).
\(y = 2\ln(x + 1) - \mathrm{e}^{-x} + 5\).