U-substitution, explained with examples
U-substitution is the chain rule in reverse. It turns a complicated integral into a simple one by renaming part of it, and it is the most used integration technique in AP Calculus AB and BC.
On this page
The idea
The chain rule says that the derivative of f(g(x)) is f'(g(x)) · g'(x). So if an integral contains a function of g(x) multiplied by g'(x), it is the result of a chain rule, and we can undo it. U-substitution makes this systematic: let u = g(x), so that du = g'(x) dx, and the integral becomes ∫ f'(u) du, which is usually straightforward.
How to spot it
Look for an “inside function” whose derivative also appears in the integrand, possibly up to a constant multiple. Typical signs:
- a bracket raised to a power, with the derivative of the bracket outside, such as 2x(x² + 1)5;
- a function of something, such as cos(x³), multiplied by that something's derivative, 3x²;
- a fraction where the top is the derivative of the bottom, such as 2x/(x² + 4);
- e to a power, multiplied by the derivative of the power.
The method
- Choose u, usually the inside function.
- Differentiate: find du/dx, and rearrange to get dx or the matching piece of the integrand in terms of du.
- Substitute so the integral contains only u and du. No x should be left.
- Integrate with respect to u.
- Substitute back u = g(x) and add + C.
Worked examples
Example 1: a power of a bracket
Find ∫ 2x(x² + 1)5 dx.
- Let u = x² + 1, so du = 2x dx.
- ∫ u5 du = u6/6 + C = (x² + 1)6/6 + C.
Example 2: adjusting a constant
Find ∫ x² cos(x³) dx.
- Let u = x³, so du = 3x² dx, which means x² dx = du/3.
- ∫ cos u · du/3 = (1/3) sin u + C = (1/3) sin(x³) + C. A missing constant is fine; a missing variable is not.
Example 3: a logarithm
Find ∫ 2x/(x² + 4) dx.
- Let u = x² + 4, so du = 2x dx.
- ∫ 1/u du = ln|u| + C = ln(x² + 4) + C. No modulus needed, since x² + 4 is always positive.
Example 4: an exponential
Find ∫ e5x dx.
- Let u = 5x, so dx = du/5.
- (1/5)e5x + C. With practice, linear inside functions like 5x can be done in your head.
Example 5: trig
Find ∫ sin x cos4x dx.
- Let u = cos x, so du = −sin x dx and sin x dx = −du.
- ∫ −u4 du = −u5/5 + C = −cos5x/5 + C.
Example 6: tan x
Find ∫ tan x dx.
- Write tan x = sin x/cos x. Let u = cos x, du = −sin x dx.
- ∫ −1/u du = −ln|u| + C = −ln|cos x| + C, which also equals ln|sec x| + C.
Example 7: a leftover x
Find ∫ x√(x + 1) dx.
- Let u = x + 1, so du = dx and x = u − 1.
- ∫ (u − 1)u1/2 du = ∫ (u3/2 − u1/2) du = (2/5)u5/2 − (2/3)u3/2 + C.
- = (2/5)(x + 1)5/2 − (2/3)(x + 1)3/2 + C. When an extra x is left over, express it in terms of u.
Choosing between two possible u
Sometimes more than one choice looks reasonable. A good rule is to pick the expression that is “inside” something else: inside a bracket with a power, inside a square root, in the exponent of e, or inside a trig function. Then check quickly: is du, or a constant multiple of it, present in the integrand? If yes, proceed. If substituting leaves a mess, go back and try the other option; trying costs only a few seconds.
Check by differentiating
Every indefinite integral can be checked by differentiating your answer. If you get back the original integrand, you are right. For Example 1, the derivative of (x² + 1)6/6 is (x² + 1)5 · 2x, which matches. This is the fastest way to catch a missing constant factor.
Definite integrals: change the limits
For a definite integral, the limits belong to x. When you switch to u, either change the limits to u-values, or substitute back to x before evaluating. Changing the limits is usually quicker and avoids errors. On AP free-response questions, write the new limits clearly; mixing x-limits with a u-integral is a common lost point.
Example 8: with new limits
Evaluate ∫02 x(x² + 1)³ dx.
- Let u = x² + 1, du = 2x dx, so x dx = du/2. When x = 0, u = 1; when x = 2, u = 5.
- ∫15 (1/2)u³ du = (1/8)[u4]15 = (1/8)(625 − 1) = 78.
When u-substitution is not the answer
If no part of the integrand is the derivative of another part, substitution usually will not help. A product of unrelated functions, such as x ex, calls for integration by parts. A rational function such as 1/((x + 1)(x + 2)) calls for partial fractions. Some integrals, like ∫ ex² dx, have no elementary answer at all; on the AP exam these appear only as definite integrals for your calculator.
Common mistakes
- Leaving some x in the integral after substituting.
- Forgetting to adjust for a constant, such as the 1/3 in Example 2.
- Using x-limits on a u-integral.
- Forgetting to substitute back, or to add + C on indefinite integrals.
Practice questions
Try each one before opening the answer.
Q1. Find ∫ 3x²(x³ − 2)4 dx.
Show answer
Q2. Find ∫ cos(4x) dx.
Show answer
Q3. Find ∫ ex/(1 + ex) dx.
Show answer
Q4. Find ∫ ln x / x dx.
Show answer
Q5. Evaluate ∫0π/2 sin x cos x dx.
Show answer
Frequently asked questions
Is u-substitution on AP Calculus AB?
Yes. It is in Unit 6 of both AB and BC, and it appears in multiple-choice and free-response questions.
Is it the same as integration by substitution in A level Maths?
Yes. A level calls it integration by substitution, and it is in the second year. Questions often tell you which substitution to use.
Key takeaways
- U-substitution reverses the chain rule.
- Choose u as an inside function whose derivative appears.
- Constant factors can be adjusted; leftover x must be rewritten in u.
- Change the limits for definite integrals.
- If no derivative pairing exists, try parts or partial fractions.