Instant PDF download, name-and-email checkout. Complete bundle: every Economics, Statistics and Mathematics book
Mathematics

Integration by Substitution: Examples, Changing Limits and Real Cases

Learn integration by substitution as the chain rule in reverse, with worked examples on drug absorption, app downloads and exam-style integrals.

In 30 seconds
  • Integration by substitution (u-substitution) is the chain rule run backwards: it turns an awkward integral in \( x \) into a simple one in \( u \).
  • Look for an “inside” function \( g(x) \) whose derivative \( g'(x) \) also appears (up to a constant) as a factor. Set \( u = g(x) \).
  • Replace \( g'(x)\,dx \) by \( du \), integrate in \( u \), then substitute back, or, for a definite integral, change the limits to \( u \)-values.
  • Real use: turning a rate (mg per hour, downloads per week) into a total.
  • Always check your answer by differentiating it.

The case: how much of a tablet has been absorbed?

When you swallow a tablet, the medicine does not reach your bloodstream all at once. It dissolves, passes through the gut wall, and enters the blood at a rate that rises, peaks and then fades. Pharmacologists model that rate with smooth curves. In this illustrative model (it is a teaching example, not dosing guidance), a 60 mg tablet is absorbed at a rate of

\[ r(t) = 60t\,e^{-t^2/2} \]

milligrams per hour, where \( t \) is the time in hours after the tablet is taken. A nurse wants to know: how many milligrams have been absorbed after 2 hours, and how long it takes for half of the dose to get in?

The amount absorbed is the area under the rate curve, \( \int_0^2 60t\,e^{-t^2/2}\,dt \). None of the basic integration rules handles a product like \( t\,e^{-t^2/2} \) directly. But look closely: the exponent is \( -t^2/2 \), and its derivative is \( -t \), which is sitting right there in front. That is the signal for substitution.

The concept: spotting the hidden chain rule

When you differentiate a function of a function, the chain rule says: differentiate the outside, keep the inside, then multiply by the derivative of the inside. For example, \( \dfrac{d}{dt}\,e^{-t^2/2} = e^{-t^2/2} \times (-t) \). So any integral that looks like “outside function of the inside, times the derivative of the inside” must have come from a chain rule. Substitution undoes it.

The trick is to give the inside its own name, \( u \). The messy integral in \( t \) becomes a plain integral in \( u \) that you already know how to do. It is like changing currency: you convert to the one where the sum is easy, do the sum, and convert back.

Key termIntegration by substitution: a method that replaces part of the integrand, usually an inner function \( g(x) \), with a new variable \( u = g(x) \), and replaces \( dx \) using \( du = g'(x)\,dx \), so the integral becomes simpler in terms of \( u \).

The formula

\[ \int f\big(g(x)\big)\,g'(x)\,dx \] \[ = \int f(u)\,du \]

where \( u = g(x) \) and \( du = g'(x)\,dx \). For a definite integral, the limits change with the variable:

\[ \int_a^b f\big(g(x)\big)\,g'(x)\,dx \] \[ = \int_{g(a)}^{g(b)} f(u)\,du \]

Here \( g(x) \) is the inner function, \( g'(x) \) its derivative, \( f \) the outer function, and \( a \), \( b \) the original limits in \( x \). The new limits \( g(a) \) and \( g(b) \) are the values of \( u \) at those endpoints[1].

Mathematics Made Simple textbook coverChapter 14 of Mathematics Made Simple covers substitution, parts and partial fractions step by step.Get the textbook · $12

Why this formula fits the case

The integrand \( 60t\,e^{-t^2/2} \) has exactly the shape the formula needs: an outer function (the exponential) of an inner function \( -t^2/2 \), multiplied by something that is a constant times the inner function’s derivative. That is why substitution works here and why it works so cleanly.

It is the wrong first choice when the “derivative of the inside” is missing. For \( \int e^{-t^2/2}\,dt \), with no \( t \) in front, no substitution helps at all; that integral has no elementary answer and is found numerically (it is the normal distribution’s area)[2]. And for a product of two unrelated functions, such as \( t\,e^{-t} \), where neither factor is the derivative of something inside the other, integration by parts is the better tool.

Setting it up

  • Choose \( u \): the inner function, \( u = -\dfrac{t^2}{2} \).
  • Find \( du \): \( \dfrac{du}{dt} = -t \), so \( du = -t\,dt \), which means \( t\,dt = -du \).
  • Change the limits: when \( t = 0 \), \( u = 0 \); when \( t = 2 \), \( u = -2 \).
  • Units: the rate is in mg per hour and \( dt \) is in hours, so the integral is in mg.

Every piece of the old integral now has a replacement: \( e^{-t^2/2} \) becomes \( e^{u} \), \( t\,dt \) becomes \( -du \), and the limits 0 and 2 become 0 and \( -2 \).

Solving it

Worked example 1

Find the amount absorbed in the first 2 hours, \( \displaystyle A = \int_0^2 60t\,e^{-t^2/2}\,dt \).

Step 1Let \( u = -t^2/2 \), so \( t\,dt = -du \). Limits: \( t = 0 \to u = 0 \), \( t = 2 \to u = -2 \).
Step 2Substitute: \( A = \displaystyle\int_0^{-2} 60\,e^{u}\,(-du) \).
Step 3Flip the limits to absorb the minus sign: \( A = 60\displaystyle\int_{-2}^{0} e^{u}\,du \).
Step 4Integrate: \( A = 60\big[e^{u}\big]_{-2}^{0} = 60\,(e^{0}-e^{-2}) \).
Step 5Evaluate: \( A = 60(1-0.13534) \), which is \( 60 \times 0.86466 \approx 51.88 \) mg.
Step 6Check by differentiating: \( \dfrac{d}{dt}\big(-60e^{-t^2/2}\big) = 60t\,e^{-t^2/2} \), which matches \( r(t) \).

After 2 hours about 51.9 mg, or 86.5% of the dose, has been absorbed.

Absorption rate r(t) = 60t·e^(−t²/2) mg per hour
rate of absorption r(t)
123456102030400t (hours)rpeak (1, 36.4)area ≈ 51.9 mg
Figure 1. The shaded area under the rate curve from t = 0 to t = 2 is the amount absorbed in the first two hours: 60(1 − e⁻²) ≈ 51.9 mg of the 60 mg dose. The rate peaks after one hour and then tails off.

The same method also gives a general formula. The amount absorbed by time \( T \) is \( A(T) = 60\big(1-e^{-T^2/2}\big) \). Half the dose is 30 mg, so we need \( e^{-T^2/2} = 0.5 \), which gives \( T^2 = 2\ln 2 \), so \( T = \sqrt{2\ln 2} \approx 1.18 \) hours, a little over 70 minutes.

The second case is from business. The pattern is different: the derivative of the inside sits on top of a fraction, which leads to a logarithm.

Worked example 2

A new study app is downloaded at a rate of \( d(t) = \dfrac{3000t}{t^2 + 16} \) downloads per week, \( t \) weeks after launch (illustrative figures). Find the total downloads in the first 4 weeks, and in weeks 4 to 12.

Step 1Let \( u = t^2 + 16 \), so \( du = 2t\,dt \) and \( 3000t\,dt = 1500\,du \).
Step 2Limits for weeks 0 to 4: \( u(0) = 16 \) and \( u(4) = 32 \).
Step 3\( \displaystyle\int_0^4 \frac{3000t}{t^2 + 16}\,dt = 1500\int_{16}^{32} \frac{1}{u}\,du \).
Step 4Integrate: \( 1500\big[\ln u\big]_{16}^{32} = 1500\ln\dfrac{32}{16} \), which is \( 1500\ln 2 \).
Step 5So the first 4 weeks give \( 1500 \times 0.6931 \approx 1040 \) downloads.
Step 6For weeks 4 to 12, the limits are \( u(4) = 32 \) and \( u(12) = 160 \).
Step 7Total: \( 1500\ln\dfrac{160}{32} = 1500\ln 5 \approx 2414 \) downloads.

About 1,040 downloads arrive in the first month and about 2,414 more over the next eight weeks, so roughly 3,454 by week 12.

Worked example 3 (exam style: when \( x \) is left over)

Use the substitution \( u = 2x + 1 \) to find the exact value of \( \displaystyle\int_0^4 x\sqrt{2x + 1}\,dx \).

Step 1\( u = 2x + 1 \) gives \( x = \dfrac{u-1}{2} \) and \( dx = \dfrac{du}{2} \).
Step 2Limits: \( x = 0 \to u = 1 \), \( x = 4 \to u = 9 \).
Step 3\( \displaystyle\int_1^9 \frac{u-1}{2}\,u^{1/2}\,\frac{du}{2} \), which simplifies to \( \displaystyle\frac14\int_1^9 \big(u^{3/2}-u^{1/2}\big)\,du \).
Step 4Integrate: \( \dfrac14\Big[\tfrac25 u^{5/2}-\tfrac23 u^{3/2}\Big]_1^9 \).
Step 5At \( u = 9 \): \( \tfrac25(243)-\tfrac23(27) = \tfrac{486}{5}-18 = \tfrac{1188}{15} \).
Step 6At \( u = 1 \): \( \tfrac25-\tfrac23 = -\tfrac{4}{15} \).
Step 7Result: \( \dfrac14\Big(\dfrac{1188}{15} + \dfrac{4}{15}\Big) \), which is \( \dfrac14 \times \dfrac{1192}{15} = \dfrac{298}{15} \).

The exact value is \( \dfrac{298}{15} \approx 19.87 \). Here the leftover \( x \) had to be written in terms of \( u \) as well; nothing in \( x \) may remain after substituting.

Mathematics Made Simple Practice Questions coverMaster every substitution pattern with 1,565 practice questions and fully worked answers.Get 1,565 questions · $9

What the answer tells us

For the tablet, 51.9 mg out of 60 mg after 2 hours is sensible: the answer is positive, it is less than the full dose, and the units are milligrams. The formula \( A(T) = 60(1-e^{-T^2/2}) \) also tends to 60 as \( T \) grows, so the model never absorbs more than the tablet contains. The rate peaks at \( t = 1 \) hour, at \( 60e^{-1/2} \approx 36.4 \) mg per hour, and the half-dose time of about 1.18 hours comes just after that peak, which fits the shape of the curve.

For the app, the logarithm carries a business message. Because \( \ln \) grows slowly, each extra week adds fewer downloads than the last. Doubling the time window from 12 to 24 weeks would add only \( 1500\ln\dfrac{592}{160} \approx 1962 \) more downloads, fewer than the 2,414 of weeks 4 to 12. A marketing team reading this would plan a fresh push once growth flattens, rather than waiting for the curve to recover on its own.

Sensitivity is easy to read off the formula: the 1500 in front scales everything, so a campaign that raised the rate by 20% would raise every total by 20%. The 16 inside sets when the rate peaks (at \( t = \sqrt{16} = 4 \) weeks).

Total downloads D(T) = 1500 ln((T² + 16)/16) downloads
cumulative downloads
2468101250010001500200025003000350040000T (weeks)D(4, 1040)(12, 3454)
Figure 2. Cumulative downloads reach about 1,040 by week 4 and about 3,454 by week 12. The weekly rate peaks at week 4 and then falls, so the total keeps rising but ever more slowly, like a logarithm.
Common mistakeChanging the variable but not the limits. In Worked example 2, writing \( 1500\big[\ln u\big]_0^4 \) mixes \( t \)-limits with a \( u \)-integral and gives nonsense (\( \ln 0 \) is undefined). Either change the limits to \( u \)-values, or substitute back to \( t \) before using the original limits. Never mix the two.
Common mistakeDropping the constant from \( du \). With \( u = t^2 + 16 \), \( du = 2t\,dt \), so \( t\,dt = \tfrac12\,du \). Forgetting the \( \tfrac12 \) doubles the answer.
Exam tipAP Calculus AB/BC tests this in topic 6.9, “Integrating Using Substitution”, and free-response questions often expect you to change the limits[3]. In Cambridge 9709, substitution is in Pure Mathematics 3 (topic 3.5), where the substitution is usually given, as in Worked example 3[4]. IB Mathematics: analysis and approaches expects integration “by inspection or substitution” of the form \( \int k\,g'(x)f(g(x))\,dx \) at SL 5.10, with more general substitutions at HL 5.16[5].

For the full toolkit, including when to switch to parts or partial fractions, see the Mathematics Made Simple textbook; for drill, the Mathematics Made Simple practice questions book has worked answers to every question.

Mathematics Made Simple bundle coverGet both Mathematics Made Simple books for $16: learn substitution, then practise it to exam standard.Both books · $16

Practice questions

EasyQ1. Find \( \int 2x\cos(x^2)\,dx \). Show worked answer
Let \( u = x^2 \), so \( du = 2x\,dx \).
\( \int \cos u\,du = \sin u + C \).
Answer: \( \sin(x^2) + C \). Check: \( \dfrac{d}{dx}\sin(x^2) = 2x\cos(x^2) \).
EasyQ2. Find \( \int e^{5x-2}\,dx \). Show worked answer
Let \( u = 5x-2 \), so \( du = 5\,dx \) and \( dx = \tfrac15\,du \).
\( \tfrac15\int e^{u}\,du = \tfrac15 e^{u} + C \).
Answer: \( \tfrac15 e^{5x-2} + C \).
MediumQ3. Find the exact value of \( \displaystyle\int_0^2 x^2\sqrt{x^3 + 1}\,dx \). Show worked answer
Let \( u = x^3 + 1 \), so \( du = 3x^2\,dx \) and \( x^2\,dx = \tfrac13\,du \).
Limits: \( x = 0 \to u = 1 \); \( x = 2 \to u = 9 \).
\( \tfrac13\displaystyle\int_1^9 u^{1/2}\,du = \tfrac13 \cdot \tfrac23\big[u^{3/2}\big]_1^9 = \tfrac29(27-1) \).
Answer: \( \dfrac{52}{9} \approx 5.78 \).
MediumQ4. Find the exact value of \( \displaystyle\int_0^{\pi/2} \cos x\,e^{\sin x}\,dx \). Show worked answer
Let \( u = \sin x \), so \( du = \cos x\,dx \).
Limits: \( x = 0 \to u = 0 \); \( x = \pi/2 \to u = 1 \).
\( \displaystyle\int_0^1 e^{u}\,du = e-1 \approx 1.718 \).
ExamQ5. Oil leaks from a damaged tank at a rate of \( L(t) = \dfrac{48t}{\sqrt{t^2 + 16}} \) litres per hour, \( t \) hours after the damage. (a) Use the substitution \( u = t^2 + 16 \) to show that the oil lost in the first 3 hours is \( \displaystyle 24\int_{16}^{25} u^{-1/2}\,du \). [3] (b) Hence find the oil lost in the first 3 hours. [2] (c) Find the exact time at which a total of 96 litres has leaked. [3] Show worked answer
(a) \( u = t^2 + 16 \) gives \( du = 2t\,dt \), so \( 48t\,dt = 24\,du \) [1]. Limits: \( t = 0 \to u = 16 \), \( t = 3 \to u = 25 \) [1]. So \( \displaystyle\int_0^3 \frac{48t}{\sqrt{t^2 + 16}}\,dt = 24\int_{16}^{25} u^{-1/2}\,du \) [1].
(b) \( 24\big[2u^{1/2}\big]_{16}^{25} = 48(5-4) \) [1] \( = 48 \) litres [1].
(c) Total by time \( T \): \( 48\big(\sqrt{T^2 + 16}-4\big) \) [1]. Set equal to 96: \( \sqrt{T^2 + 16} = 6 \), so \( T^2 = 20 \) [1] and \( T = 2\sqrt5 \approx 4.47 \) hours [1].

Frequently asked questions

How do I choose what to call \( u \)?

Pick the “inside” part: the expression inside a bracket, a root, an exponent or a denominator, whose derivative also appears as a factor (up to a constant). If the first choice does not get rid of every \( x \), try another.

Do I have to change the limits?

No, but it is usually quicker and examiners like it. The alternative is to find the antiderivative in \( u \), substitute back to \( x \), and then use the original limits. Both give the same answer; mixing them does not.

What if the derivative is out by a constant?

That is fine. Constants can be moved outside the integral, so \( 3000t\,dt = 1500\,du \) is allowed. What you cannot fix is a missing variable factor, such as a missing \( t \).

How is substitution related to the chain rule?

It is the chain rule in reverse. Every substitution answer can be checked by differentiating it with the chain rule, which should give back the original integrand.

References

  1. Strang, G. and Herman, E. (2016) Calculus Volume 1, Section 5.5 “Substitution”. Houston, TX: OpenStax. https://openstax.org/details/books/calculus-volume-1
  2. Stewart, J., Clegg, D. and Watson, S. (2020) Calculus: Early Transcendentals, 9th edn, Section 5.5 “The Substitution Rule”. Boston, MA: Cengage.
  3. College Board (2020) AP Calculus AB and AP Calculus BC Course and Exam Description, Unit 6, topic 6.9. New York: College Board.
  4. Cambridge International (2024) Cambridge International AS & A Level Mathematics 9709: Syllabus for examination in 2026 and 2027, Pure Mathematics 3, topic 3.5 Integration. Cambridge: Cambridge University Press & Assessment.
  5. International Baccalaureate Organization (2019) Mathematics: analysis and approaches guide (first assessment 2021), SL 5.10 and AHL 5.16. Cardiff: IBO.
Mathematics Made Simple complete bundle cover
This topic has a full chapter in Mathematics Made Simple, with 1,565 fully worked practice questions in the bundle.Mathematics Made Simple Complete Bundle — Textbook + 1,565 Practice Questions
Get it for $16
E

The EconTutorials team writes clear, exam-focused lessons in economics and statistics for A-Level, IB, AP and university students, with more than 13 years of classroom teaching behind every guide and book in the Made Simple series.