Introduction
There is a formula we use to differentiate a composite function \(h(x) = g(f(x))\).
$$\frac{dy}{dx} = \frac{dy}{du} \cdot \frac{du}{dx}$$Here \(y = g(u)\) and \(u = f(x)\). When you first see the formula, a doubt arises.
"If I cancel \(du\) from the top and bottom like a fraction, am I left with \(dy/dx\)? Is this just a lucky coincidence of notation, or is there a real reason?"
The one-sentence answer first — it is because, when \(x\) changes a little, you can ask how fast \(u\) responds, and when \(u\) changes, how fast \(y\) responds; multiplying the two speeds gives the speed from \(x\) all the way to \(y\). The "multiplication" is not a coincidence. It is an inevitable consequence of the structure in which rates of change are passed along like a chain.
What Is a Composite Function — A Function Inside a Function
A composite function is what you get when you feed the output of one function as the input of another. Take \(y = (x^2+1)^3\) as an example. This expression can be split into two steps.
$$u = f(x) = x^2 + 1 \qquad\qquad y = g(u) = u^3$$In the first step we take \(x\) and produce \(u = x^2 + 1\); in the second step we take that result \(u\) and produce \(y = u^3\). Writing the whole flow on one line:
$$x \;\xrightarrow{\ f\ }\; u \;\xrightarrow{\ g\ }\; y$$When \(x\) changes, \(u\) changes; when \(u\) changes, \(y\) changes in turn. The change is passed along like a chain.
A Gear Analogy — The Chained Transfer of Rates of Change
Imagine two meshed gears (toothed wheels). If turning the first gear by 1 turns the second gear by 3, and turning the second gear by 1 turns the third gear by 2 — then turning the first gear by 1 turns the third gear by 3 × 2 = 6. The middle gear's "amount of rotation" drops out of the picture, and all that remains is the product of the two ratios.
Differentiation of a composite function has exactly this structure.
- When \(x\) changes a little, \(u\) changes by (the rate of change \(du/dx\)) times that amount.
- When \(u\) changes a little, \(y\) changes by (the rate of change \(dy/du\)) times that amount.
- So when \(x\) changes a little, \(y\) changes by the product of the two rates of change.
Confirming It With the Formula — Why the Multiplication Appears
Suppose \(x\) changes by \(\Delta x\). Then \(u\) changes by \(\Delta u\), and \(y\) changes by \(\Delta y\). In this case, if \(\Delta u \neq 0\):
$$\frac{\Delta y}{\Delta x} = \frac{\Delta y}{\Delta u} \cdot \frac{\Delta u}{\Delta x}$$The \(\Delta u\) on the right cancels purely — that is just the basic property of multiplying fractions. Now take the limit as \(\Delta x \to 0\); then \(\Delta u \to 0\) follows as well (if f is continuous), and each ratio converges to a derivative.
$$\frac{dy}{dx} = \lim_{\Delta x \to 0}\frac{\Delta y}{\Delta x} = \lim_{\Delta x \to 0}\left(\frac{\Delta y}{\Delta u} \cdot \frac{\Delta u}{\Delta x}\right) = \frac{dy}{du} \cdot \frac{du}{dx}$$There is one caveat: when \(\Delta u = 0\) (which happens when f has a local extremum near some point), this simple cancellation argument breaks down. A rigorous proof handles this case separately, but for intuition the understanding that "rates of change are passed along like a chain and multiplied" is enough.
A Concrete Example — Computing \((x^2+1)^3\) Directly
We decompose into \(f(x) = x^2 + 1\) and \(g(u) = u^3\), then apply the chain rule.
| Step | Result |
|---|---|
| Inner rate of change \(du/dx\) | \(2x\) |
| Outer rate of change \(dy/du\) | \(3u^2\) |
| Applying the chain rule: \(dy/dx\) | \(3(x^2+1)^2 \cdot 2x\) |
Tidying up:
$$\frac{d}{dx}(x^2+1)^3 = 3(x^2+1)^2 \cdot 2x = 6x(x^2+1)^2$$Let us check at a few points.
- \(x = 1\): inner rate of change \(2 \cdot 1 = 2\), outer rate of change \(3 \cdot (1^2+1)^2 = 3 \cdot 4 = 12\), composite rate of change \(2 \times 12 = 24\).
- \(x = 0\): inner rate of change \(2 \cdot 0 = 0\) → so the composite rate of change is also \(0\). When the inner gear stops, the outer gear stops too.
- \(x = -0.8\): the inner rate of change is \(-1.6\) (negative — as x increases, u actually decreases), so the composite rate of change is negative as well.
Try It Yourself
In the interactive below, move the x slider. The inner rate of change (\(du/dx\)) and the outer rate of change (\(dy/du\)) update in real time, and you can confirm that the product of the two values exactly matches the slope of the tangent line on the graph.
Pressing the preset "x = 1" shows inner rate of change 2.000 × outer rate of change 12.000 = composite rate of change 24.000. At "x = −0.8" the inner rate of change becomes negative, so the whole tangent line tilts downward.
Is the "Cancellation" Real — A Note on Leibniz Notation
In \(dy/dx = (dy/du) \cdot (du/dx)\), there is a reason why \(du\) seems to vanish from top and bottom. Leibniz devised a notation that treats \(dy\) and \(dx\) as if they were "infinitesimally small changes." Strictly speaking, \(dy/dx\) is not a fraction but the result of a limit; yet this notation lets us manipulate many differentiation rules, including the chain rule, "as if they were fractions."
Why does it line up as though by coincidence — there was already a clue in the process of deriving that the derivative is the 'instantaneous slope'. It is because, in the process of approximating with a limit, the changes really do behave like ratios. The "cancellation" in the chain rule is not a notational convenience but the result of Leibniz notation faithfully reflecting the reality that rates of change are passed along in a chain.
Key Takeaways
| Question | Answer |
|---|---|
| What is the chain rule? | The derivative of a composite function h = g(f(x)): h'(x) = g'(f(x)) · f'(x) |
| Why a multiplication? | The x→u rate of change and the u→y rate of change are passed along in a chain and multiplied |
| What is the derivative of (x²+1)³? | \(6x(x^2+1)^2\) |
| Does du really cancel? | At the approximation step (Δu≠0) it cancels exactly; the result is confirmed to hold under the limit |
Studying This With AI
AI handles applying the chain rule well. Ask specifically about the points where you get stuck.
Useful example questions:
- "Differentiate \(\sin(x^3)\) using the chain rule." (inner function \(x^3\), outer function \(\sin u\))
- "Derive the derivative of \(e^{-x^2}\)." (an example connected to the normal distribution)
- "Give me an example of a composite function that needs the chain rule applied twice."
Wrapping Up
The heart of the chain rule is not the notational "cancellation" but the chained transfer of rates of change. When \(x\) affects \(y\) through \(u\), the rate of change at each step multiplies to become the overall rate of change. The very structure in which speed is transmitted, like meshed gears, is the chain rule.
Related reading — Read first: Why Is the Derivative the 'Instantaneous Slope' · Why Is the Exponential e Precisely 2.718… → Up next: What on Earth Are the du and dv in Integration by Parts · Draw the graphs yourself: Desmos · Wolfram Alpha