Rewrite the whole integral consistently
Strips that change shape
The teal region lies under the curve \(y = x\sqrt{2x^2+1}\), from \(x = 0\) to \(x = 1\). It is cut into thin strips, each \(dx\) wide.
Press the button to relabel the axis with \(u = 2x^2 + 1\). Every point slides to its \(u\)-value, so \(x = 0\) goes to \(u = 1\) and \(x = 1\) goes to \(u = 3\).
The orange strip runs from \(x = 0.9\) to \(x = 1\). It becomes about 4 times as wide, because \(du = 4x\,dx\) and \(4x\) is about 4 there. It also becomes about a quarter as tall, so its area stays 0.159.
After the slide, the curve is \(y = \tfrac14\sqrt{u}\). Each old strip has area \(\sqrt{2x^2+1}\cdot x\,dx\), and \(x\,dx = \tfrac14\,du\), so it is now a strip of area \(\tfrac14\sqrt{u}\,du\).
The region has the same area before and after, \(\tfrac{3\sqrt3 - 1}{6} \approx 0.699\).
Any substitution
The integrand is \(f(g(x))\,g'(x)\), and the new variable is \(u = g(x)\).
Drag the orange strip. Then move the slider. A strip of width \(dx\) becomes one of width \(g'(x)\,dx\), which is \(du\).
The strip becomes wider where \(g'\) is large and narrower where \(g'\) is small, and its height changes by the opposite factor.
The area of every strip stays the same, so the integral in \(x\) and the integral in \(u\) have the same value.
To rewrite the integral, write the curve in terms of \(u\) and replace \(dx\) with \(du\). No \(x\) may remain.
Notation
Start with an integrand that contains the slope of the inside function.
\[\int f(g(x))\,g'(x)\,dx\]Name the inside function. The differential \(du\) is the small change in \(u\) when \(x\) changes by \(dx\), so it equals the slope of \(g\) times \(dx\).
\[\cy{u = g(x)}, \qquad \cy{du = g'(x)\,dx}\]In words, the integral of \(f(g(x))\,g'(x)\) with respect to \(x\) equals the integral of \(f(u)\) with respect to \(u\).
\[\int f(g(x))\,g'(x)\,dx = \int f(\cy{u})\,\cy{du}\]Often the integrand holds only a constant multiple of \(g'(x)\). Call that part \(p(x)\), so that \(g'(x) = c\,p(x)\) and \(du = c\,p(x)\,dx\). Divide by \(c\), and keep the factor \(\tfrac1c\) in front of the new integral.
\[p(x)\,dx = \dfrac{1}{c}\,du\]Replace every \(x\). If an \(x\) remains, the integral is not yet an integral in \(u\).
The rule needs \(g'\) continuous. It also needs \(f\) continuous on the values of \(g\).
When it fails
Suppose that you replace \(g(x)\) with \(u\) but keep \(dx\). Then each strip keeps its old width at its new place. Press Keep dx. Then relabel the axis.
Where the axis stretches, the red strips leave gaps between them. Where it squeezes, the red strips overlap. Their total area is not the area of the region, so \(dx\) must become \(du\).
Example 1: a scale factor
Rewrite \(\displaystyle\int x^2 e^{x^3}\,dx\) as an integral in \(u\).
The exponent \(x^3\) sits inside the exponential, so choose it as \(u\).
\[u = \cy{x^3}\]The differential is the slope times \(dx\).
\[du = \cy{3x^2}\,dx\]The integrand has \(x^2\,dx\), not \(3x^2\,dx\), so divide both sides by 3.
\[x^2\,dx = \dfrac{1}{3}\,du\]Replace \(x^2\,dx\) with \(\tfrac13\,du\), and \(e^{x^3}\) with \(e^u\). No \(x\) is left, and the factor \(\tfrac13\) stays in front.
\[\int x^2 e^{x^3}\,dx = \dfrac{1}{3}\int e^{u}\,du\]
Example 2: a leftover x
Rewrite \(\displaystyle\int x\sqrt{x+4}\,dx\) as an integral in \(u\).
Choose the expression under the root. Its slope is 1, so \(du = dx\) and the strips keep their width.
\[u = \cy{x + 4}, \qquad du = dx\]The integrand also has a factor \(x\), which is not part of \(du\), so it must be written in \(u\) too.
A tempting wrong move: Write the leftover \(x\) as \(u\), because \(u\) replaces the variable.
\[\int \cr{u}\sqrt{u}\,du\]The strips slide without a change of shape, so at \(u = 4\) they still have height 0, as the original curve does at \(x = 0\). The red curve has height \(4\sqrt4 = 8\) there, so it cannot be their top.
Solving \(u = x + 4\) for \(x\) gives \(x = u - 4\). Replace \(x\) with \(u - 4\), and multiply out. The new curve has height 0 at \(u = 4\), where the strips do.
\[\begin{aligned} x &= u - 4 \\ &\int (u-4)\sqrt{u}\,du \\ &\quad = \int \left(u^{3/2} - 4u^{1/2}\right)du \end{aligned}\]
Practice
Rewrite \(\displaystyle\int x^2\sqrt{1-2x^3}\,dx\) as an integral in \(u\).
Find \(du\). Then divide by the number in front of \(x^2\,dx\), sign included. On the figure, the numbers for \(u\) fall from left to right, because \(u = 1 - 2x^3\) falls as \(x\) grows.
Solution
Choose the expression under the root.
\[u = 1 - 2x^3\]The slope is negative, so \(u\) falls as \(x\) grows.
\[du = -6x^2\,dx\]Divide by \(-6\), and replace the root with \(\sqrt{u}\). The factor \(-\tfrac16\) stays in front.
\[\begin{aligned} x^2\,dx &= -\dfrac{1}{6}\,du \\ &\int x^2\sqrt{1-2x^3}\,dx \\ &\quad = -\dfrac{1}{6}\int \sqrt{u}\,du \end{aligned}\]
Questions
The region under \(y = x\,e^{-x^2}\) was cut into strips 0.05 wide, and the figure shows them after the axis is relabeled with \(u = x^2\). The orange strip started at \(x = 1.5\). The upper row of numbers shows where each \(x\) moved, and the lower row shows \(u\).
On the \(u\) axis, about how many times as wide is the orange strip?
- 3 times
- 2.25 times
- \(\tfrac13\) as wide
- 1.5 times
Answer
3 times
What happens to the area of the orange strip?
- It does not change
- It becomes 3 times as large
- It becomes \(\tfrac13\) as large
Answer
It does not change
Which integral in \(u\) equals \(\displaystyle\int x\cos(x^2)\,dx\) when \(u = x^2\)?
- \(\tfrac12\int \cos u\,du\)
- \(\int \cos u\,du\)
- \(2\int \cos u\,du\)
- \(\tfrac12\int x\cos u\,du\)
Answer
\(\tfrac12\int \cos u\,du\)
Summary
You replace the inside function with u, dx with du divided by the slope of g, and every leftover x with its expression in u.
This works because each strip becomes wider by the same factor that its height becomes smaller, so its area does not change.
You keep the scale factor in front of the new integral, and you confirm that no x remains.
This is one of four skills in topic 6.9 of Which & Why: AP Calculus.