Achievable logoAchievable logo
AP Calculus AB
Sign in
Sign up
Purchase
Textbook
Practice exams
Support
How it works
Exam catalog
Mountain with a flag at the peak
Textbook
Introduction
1. Limits
2. Derivative basics
3. Advanced differentiation
4. Contextual uses
5. Analytical uses
6. Integration
6.1 Accumulation of change
6.2 Riemann sums & area
6.3 Definite integrals
6.4 Accumulation functions
6.5 Behavior of accumulation functions
6.6 Fundamental theorem of calculus
6.7 Indefinite integrals
6.8 u-substitution
6.9 Long division & completing the square
7. Differential equations
8. Applications of integrals
Wrapping up
Achievable logoAchievable logo
6.8 u-substitution
Achievable AP Calculus AB
6. Integration
Our AP Calculus AB course is now in "early access" - get 50% off for a limited time.

u-substitution

9 min read
Font
Discuss
Share
Feedback

What you’ll learn

  • How to use u-substitution to simplify an integral
  • Evaluating definite integrals with u-substitution

u-substitution is essentially the reverse chain rule. Use it when one function is nested inside another, and the derivative of the inner function (or something close to it) also appears in the integrand. By temporarily switching to a new variable, you can simplify the integral and apply basic integration rules more directly.

Step-by-step process

Step 1: Choose u=g(x).

Pick the “inner” function. Look for something nested, or an expression whose derivative shows up elsewhere in the integrand. Avoid choosing u=x, since that doesn’t simplify anything.

Step 2: Differentiate u.

Differentiate with respect to x:

dxdu​=g′(x)

Then rewrite it in differential form:

du=g′(x)dx

For clarity, an additional step is to solve for dx:

dx=g′(x)du​

Step 3: Rewrite the integral in terms of u.

Substitute both u and dx into the integral. After this step, all x-terms should cancel, leaving an integral written entirely in terms of u.

Step 4: Integrate with respect to u.

Apply the usual integration rules, treating u as the variable. For an indefinite integral, include the constant of integration +C.

Step 5: Plug g(x) back in.

Write your answer in terms of the original variable.

Example 1: Basic nested functions

∫2xcos(x2)dx

Solution

The expression x2 is the nested function inside the cosine, so choose

u=x2

Differentiate:

du=2xdx

This matches the 2xdx that is also in the integrand. To make the substitution more explicit, solve for dx by dividing both sides by 2x:

dx=2x1​du

Then substituting u=x2 and dx=2x1​du into the integral:

∫2xcos(x2)dx=∫2xcos(u)⋅2x1​du​dx​=∫cos(u)du=sin(u)+C

Lastly, back-substitute u=x2 so that the final answer is written in terms of x:

sin(x2)+C​

Example 2: Rational functions

For fractions, a common strategy is to choose u as the denominator (or a nested part of it). That often produces a factor that can cancel with the numerator.

∫x2−2x+3x−1​dx

Solution

(spoiler)

Let

u=x2−2x+3

Then

du=(2x−2)dx

Solve for dx:

dx​=2x−21​du=2(x−1)1​du​

Rewrite the integral in terms of u:

∫x2−2x+3x−1​dx=∫ux−1​​⋅2(x−1)​1​du=21​∫u1​du=21​ln∣u∣+C=21​ln(x2−2x+3)+C​

Example 3: Negative exponential powers

When a fraction features an exponential in the denominator, rewriting it as a product with a negative power cleanly exposes the nested exponent.

∫ex2x​dx

Solution

First, rewrite the integral as a product:

∫xe−x2dx

Now choose u:

(spoiler)

The nested function is −x2, so let

udu​=−x2=−2xdx​

Solving for dx,

dx=−2x1​du

Now rewrite the integral in terms of u:

∫xe−x2dx=∫x​⋅eu⋅2x​−1​du=−21​∫eudu=−21​eu+C=−21​ex2+C​

Example 4: Logarithms

The following example also involves a quotient, but choosing u=x simply swaps variables without changing the form of the integral, which does not help simplify it.

∫2xln(x2)​

Choosing u=x2 is also ineffective because the resulting 2x term appears in the denominator, not the numerator.

Solution

Using trial-and-error is a standard part of finding the right substitution. Recall the derivative rule:

dxd​(lnx)=x1​

This x1​ structure is present in the integrand.

If we choose u=ln(x2), then

(spoiler)

du=x2​dx

Then dx=2x​du, and the integral in terms of u is

∫2xln(x2)​=21​∫x​u​⋅2x​​du=41​∫udu=41​u2+C=41​ln2(x2)+C​

Example 5: Extended substitution technique

Sometimes, choosing u leaves a leftover x in the integrand. An additional algebraic step is needed to express all remaining variables in terms of u.

∫xx−1​ dx

Solution

(spoiler)

Let

u=x−1⟹du=dx

The remaining issue is the x outside of the square root. The trick is to rewrite your original definition of u and solve for x:

u=x−1⟹x=u+1

Now rewrite the integral:

∫xx−1​ dx=∫((u+1)⋅u​)du

Distribute u​:

∫(uu​+u​)du=∫(u3/2+u1/2)du

Integrate term-by-term:

52​u5/2+32​u3/2+C=52​(x−1)5/2+32​(x−1)3/2+C​

The next example combines extended substitution with an extra algebraic step: splitting the numerator apart to isolate the terms needed.

∫ex+1e3x​dx

Solution

(spoiler)

Let

udu​=ex+1=exdx​

Notice that our du only gives a single ex, while the numerator is e3x. To resolve this, split the higher power into separate components:

∫ex+1e2x⋅ex​dx

Then applying the extended substitution technique,

(spoiler)

u=ex+1⟹ex=u−1

Squaring both sides,

e2x=(u−1)2

Substituting these components into the integral gives

∫ex+1e2x⋅ex​dx=∫u(u−1)2​dx

To integrate, expand the numerator and separate the fraction:

(spoiler)

∫u(u−1)2​dx=∫uu2−2u+1​dx=∫(uu2​−u2u​+u1​)dx=∫(u−2+u1​)dx=21​u2−2u+ln∣u∣+C=21​(ex+1)2−2(ex+1)+ln(ex+1)+C​

Definite integrals and changing bounds

When you use u-substitution on a definite integral, you have two standard ways to finish the problem.

Option 1: Change the bounds

Convert the limits from x-values to u-values. Then you can evaluate the antiderivative in terms of u without switching back to x.

Option 2: Don’t change the bounds.

Find the antiderivative, convert back to x after integrating, and then evaluate using the original x-bounds.

Sidenote
Equivalent representations

While both options yield the same numeric answer, Option 1 is essential for the AP exam. An MCQ might ask you to identify an equivalent definite integral expression in terms of u rather than a final number.

An answer choice that pairs the new u-variable with the original x-bounds is a classic distractor. If the variable is changed to u, the bounds must also change to u.

Example

If the substitution u=cos(2x) is made, choose the resulting expression that is equivalent to

∫0π/6​tan(2x)dx

(A)−21​∫11/2​u1​du

(B)∫11/2​u1​du

(C)−21​∫0π/6​u1​du

(D)−∫11/2​u1​du

(spoiler)

First, tan(2x) can be expressed as a quotient:

tan(2x)=cos(2x)sin(2x)​

Then if u=cos(2x),

du=−2sin(2x)dx

and

−21​du=sin(2x)dx

Next, transform the bounds:

When x=0 (lower bound),

u=cos(0)=1

When x=6π​ (upper bound),

u=cos(62π​)=21​

Then the integral in terms of u is

∫0π/6​cos(2x)sin(2x)​dx=−21​∫11/2​u1​du

So the correct answer choice is (A).

Now that we have established the correct equivalent expression in terms of u, we can evaluate the definite integral.

(spoiler)

−21​∫11/2​u1​du=−21​ln∣u∣​11/2​=−21​ln(21​)

Alternatively, with option 2, keep the original x-bounds, integrate, and then back-substitute the original x-expression before evaluating.

(spoiler)

∫0π/6​tan(2x)dx=−21​ln∣u∣​x=0x=π/6​=−21​ln(cos(2x))​0π/6​=−21​ln(cos(62π​))−(−21​ln(cos0))=−21​ln(21​)

u-substitution basics

  • Reverse chain rule; used when an inner function and its derivative both appear in the integrand
  • Choose u = inner/nested function g(x); avoid u = x

Step-by-step process

  • Set u = g(x), compute du = g’(x)dx, solve for dx
  • Substitute u and dx so all x-terms cancel
  • Integrate in terms of u, then back-substitute g(x); add +C for indefinite integrals

Choosing u strategically

  • Rational functions: try u = denominator so numerator cancels
  • Negative exponential powers: rewrite as e^(–x²) to expose nested exponent
  • Logarithms: use derivative rule d/dx(ln x) = 1/x to identify u

Extended substitution technique

  • If a leftover x remains after substitution, solve u = g(x) for x and replace it
  • Split higher-power exponentials (e.g., e^(3x) = e^(2x)·e^x) to match du, then express remaining terms via u

Definite integrals with u-substitution

  • Option 1: convert x-bounds to u-bounds and evaluate entirely in u
  • Option 2: integrate in u, back-substitute to x, then apply original x-bounds
  • AP exam note: if the variable changes to u, bounds must also change to u-values — pairing u with original x-bounds is a classic wrong answer

Sign up for free to take 12 quiz questions on this topic

All rights reserved ©2016 - 2026 Achievable, Inc.

u-substitution

What you’ll learn

  • How to use u-substitution to simplify an integral
  • Evaluating definite integrals with u-substitution

u-substitution is essentially the reverse chain rule. Use it when one function is nested inside another, and the derivative of the inner function (or something close to it) also appears in the integrand. By temporarily switching to a new variable, you can simplify the integral and apply basic integration rules more directly.

Step-by-step process

Step 1: Choose u=g(x).

Pick the “inner” function. Look for something nested, or an expression whose derivative shows up elsewhere in the integrand. Avoid choosing u=x, since that doesn’t simplify anything.

Step 2: Differentiate u.

Differentiate with respect to x:

dxdu​=g′(x)

Then rewrite it in differential form:

du=g′(x)dx

For clarity, an additional step is to solve for dx:

dx=g′(x)du​

Step 3: Rewrite the integral in terms of u.

Substitute both u and dx into the integral. After this step, all x-terms should cancel, leaving an integral written entirely in terms of u.

Step 4: Integrate with respect to u.

Apply the usual integration rules, treating u as the variable. For an indefinite integral, include the constant of integration +C.

Step 5: Plug g(x) back in.

Write your answer in terms of the original variable.

Example 1: Basic nested functions

∫2xcos(x2)dx

Solution

The expression x2 is the nested function inside the cosine, so choose

u=x2

Differentiate:

du=2xdx

This matches the 2xdx that is also in the integrand. To make the substitution more explicit, solve for dx by dividing both sides by 2x:

dx=2x1​du

Then substituting u=x2 and dx=2x1​du into the integral:

∫2xcos(x2)dx=∫2xcos(u)⋅2x1​du​dx​=∫cos(u)du=sin(u)+C

Lastly, back-substitute u=x2 so that the final answer is written in terms of x:

sin(x2)+C​

Example 2: Rational functions

For fractions, a common strategy is to choose u as the denominator (or a nested part of it). That often produces a factor that can cancel with the numerator.

∫x2−2x+3x−1​dx

Solution

(spoiler)

Let

u=x2−2x+3

Then

du=(2x−2)dx

Solve for dx:

dx​=2x−21​du=2(x−1)1​du​

Rewrite the integral in terms of u:

∫x2−2x+3x−1​dx=∫ux−1​​⋅2(x−1)​1​du=21​∫u1​du=21​ln∣u∣+C=21​ln(x2−2x+3)+C​

Example 3: Negative exponential powers

When a fraction features an exponential in the denominator, rewriting it as a product with a negative power cleanly exposes the nested exponent.

∫ex2x​dx

Solution

First, rewrite the integral as a product:

∫xe−x2dx

Now choose u:

(spoiler)

The nested function is −x2, so let

udu​=−x2=−2xdx​

Solving for dx,

dx=−2x1​du

Now rewrite the integral in terms of u:

∫xe−x2dx=∫x​⋅eu⋅2x​−1​du=−21​∫eudu=−21​eu+C=−21​ex2+C​

Example 4: Logarithms

The following example also involves a quotient, but choosing u=x simply swaps variables without changing the form of the integral, which does not help simplify it.

∫2xln(x2)​

Choosing u=x2 is also ineffective because the resulting 2x term appears in the denominator, not the numerator.

Solution

Using trial-and-error is a standard part of finding the right substitution. Recall the derivative rule:

dxd​(lnx)=x1​

This x1​ structure is present in the integrand.

If we choose u=ln(x2), then

(spoiler)

du=x2​dx

Then dx=2x​du, and the integral in terms of u is

∫2xln(x2)​=21​∫x​u​⋅2x​​du=41​∫udu=41​u2+C=41​ln2(x2)+C​

Example 5: Extended substitution technique

Sometimes, choosing u leaves a leftover x in the integrand. An additional algebraic step is needed to express all remaining variables in terms of u.

∫xx−1​ dx

Solution

(spoiler)

Let

u=x−1⟹du=dx

The remaining issue is the x outside of the square root. The trick is to rewrite your original definition of u and solve for x:

u=x−1⟹x=u+1

Now rewrite the integral:

∫xx−1​ dx=∫((u+1)⋅u​)du

Distribute u​:

∫(uu​+u​)du=∫(u3/2+u1/2)du

Integrate term-by-term:

52​u5/2+32​u3/2+C=52​(x−1)5/2+32​(x−1)3/2+C​

The next example combines extended substitution with an extra algebraic step: splitting the numerator apart to isolate the terms needed.

∫ex+1e3x​dx

Solution

(spoiler)

Let

udu​=ex+1=exdx​

Notice that our du only gives a single ex, while the numerator is e3x. To resolve this, split the higher power into separate components:

∫ex+1e2x⋅ex​dx

Then applying the extended substitution technique,

(spoiler)

u=ex+1⟹ex=u−1

Squaring both sides,

e2x=(u−1)2

Substituting these components into the integral gives

∫ex+1e2x⋅ex​dx=∫u(u−1)2​dx

To integrate, expand the numerator and separate the fraction:

(spoiler)

∫u(u−1)2​dx=∫uu2−2u+1​dx=∫(uu2​−u2u​+u1​)dx=∫(u−2+u1​)dx=21​u2−2u+ln∣u∣+C=21​(ex+1)2−2(ex+1)+ln(ex+1)+C​

Definite integrals and changing bounds

When you use u-substitution on a definite integral, you have two standard ways to finish the problem.

Option 1: Change the bounds

Convert the limits from x-values to u-values. Then you can evaluate the antiderivative in terms of u without switching back to x.

Option 2: Don’t change the bounds.

Find the antiderivative, convert back to x after integrating, and then evaluate using the original x-bounds.

Sidenote
Equivalent representations

While both options yield the same numeric answer, Option 1 is essential for the AP exam. An MCQ might ask you to identify an equivalent definite integral expression in terms of u rather than a final number.

An answer choice that pairs the new u-variable with the original x-bounds is a classic distractor. If the variable is changed to u, the bounds must also change to u.

Example

If the substitution u=cos(2x) is made, choose the resulting expression that is equivalent to

∫0π/6​tan(2x)dx

(A)−21​∫11/2​u1​du

(B)∫11/2​u1​du

(C)−21​∫0π/6​u1​du

(D)−∫11/2​u1​du

(spoiler)

First, tan(2x) can be expressed as a quotient:

tan(2x)=cos(2x)sin(2x)​

Then if u=cos(2x),

du=−2sin(2x)dx

and

−21​du=sin(2x)dx

Next, transform the bounds:

When x=0 (lower bound),

u=cos(0)=1

When x=6π​ (upper bound),

u=cos(62π​)=21​

Then the integral in terms of u is

∫0π/6​cos(2x)sin(2x)​dx=−21​∫11/2​u1​du

So the correct answer choice is (A).

Now that we have established the correct equivalent expression in terms of u, we can evaluate the definite integral.

(spoiler)

−21​∫11/2​u1​du=−21​ln∣u∣​11/2​=−21​ln(21​)

Alternatively, with option 2, keep the original x-bounds, integrate, and then back-substitute the original x-expression before evaluating.

(spoiler)

∫0π/6​tan(2x)dx=−21​ln∣u∣​x=0x=π/6​=−21​ln(cos(2x))​0π/6​=−21​ln(cos(62π​))−(−21​ln(cos0))=−21​ln(21​)

Key points

u-substitution basics

  • Reverse chain rule; used when an inner function and its derivative both appear in the integrand
  • Choose u = inner/nested function g(x); avoid u = x

Step-by-step process

  • Set u = g(x), compute du = g’(x)dx, solve for dx
  • Substitute u and dx so all x-terms cancel
  • Integrate in terms of u, then back-substitute g(x); add +C for indefinite integrals

Choosing u strategically

  • Rational functions: try u = denominator so numerator cancels
  • Negative exponential powers: rewrite as e^(–x²) to expose nested exponent
  • Logarithms: use derivative rule d/dx(ln x) = 1/x to identify u

Extended substitution technique

  • If a leftover x remains after substitution, solve u = g(x) for x and replace it
  • Split higher-power exponentials (e.g., e^(3x) = e^(2x)·e^x) to match du, then express remaining terms via u

Definite integrals with u-substitution

  • Option 1: convert x-bounds to u-bounds and evaluate entirely in u
  • Option 2: integrate in u, back-substitute to x, then apply original x-bounds
  • AP exam note: if the variable changes to u, bounds must also change to u-values — pairing u with original x-bounds is a classic wrong answer

More from Integration

  • Accumulation of change
  • Riemann sums & area
  • Definite integrals
  • Accumulation functions
  • Behavior of accumulation functions