Chapter 3 Rates multiply
The chain rule
When x drives u and u drives y, the rate of y with respect to x is the product of the two rates. Turn the gears and stretch the number lines to see why.
The chain rule says how to differentiate a function of a function. If y depends on u and u depends on x, then the rate at which y changes with x is built from the two rates dy/du and du/dx. How they combine, and where the outer rate has to be measured, is what this chapter shows.
The rule is short, and it is easier to believe once you have held it in your hands. This chapter starts with gears, where rates are constant and multiplication is plain to see, moves to number lines that stretch, where the rates vary from point to point, and ends with a balloon whose radius slows down even though you pump air into it at a steady rate.
Gears: rates that multiply
When one gear drives another, their teeth pass the meeting point at the same speed. A 30-tooth gear turning once pushes 30 teeth past; a 15-tooth gear in mesh with it must therefore turn twice, in the opposite direction. The speed ratio is the inverse ratio of the tooth counts[1].
Now mount a second gear on the same shaft as the 15-tooth one, so the two turn together, and let it drive a fourth gear. This is a compound gear train, the arrangement inside a clock or a car’s manual gearbox. Call the angle of the first gear x, the angle of the shared shaft u, and the angle of the last gear y.
With the default gears, the shaft turns at du/dx = −30/15 = −2 times the rate of gear A, and the last gear at dy/du = −12/36 = −⅓ times the rate of the shaft. Gear D therefore turns at (−⅓)(−2) = ⅔ of A’s rate, in the same direction. The partial ratios of a compound train multiply[1], and that product is the chain rule for constant rates:
Leibniz’s notation makes equation (3.1) look like cancelling fractions, and for gears it nearly is. In a simple train, where each gear meshes with the next and no two share a shaft, the middle tooth counts really do cancel: (30/15)(15/40) = 30/40, and an intermediate “idler” gear changes only the direction of rotation, never the overall ratio[1]. The notation is a gift, but dy/dx is a single limit, not a ratio of two numbers. The cancellation is a reliable memory aid, not a proof.
Functions as gears whose ratio changes
Gears have a fixed ratio. A function like u = x² does not: near x = 1 it turns small changes in x into changes in u twice as large, and near x = 3 six times as large. The previous chapter gave the right way to think about this: magnified enough, a differentiable function is a straight line, so near a point, it acts like multiplication by its derivative. Put a short interval of width dx into the function and an interval of width about g′(x) dx comes out.
Now feed that interval to a second function. It stretches it again, by its own derivative, taken where the interval now is. The figure follows one small interval through both steps.
Take y = sin(x²) at x = 1.2. The inner function squares, and its stretch factor there is 2 × 1.2 = 2.4. The interval lands near u = 1.44, where the sine curve has slope cos 1.44 ≈ 0.130, so the outer function squashes it to about an eighth of its width. The total stretch is 2.4 × 0.130 ≈ 0.313, and that is the derivative of sin(x²) at 1.2. In symbols[2]:
Notice where f′ is evaluated: at g(x), the point the interval has been carried to, not at x. Forgetting this gives cos(x) instead of cos(x²); forgetting the inner factor gives cos(x²) instead of 2x cos(x²). Research on how students learn the chain rule has traced many such errors to trouble with composition itself: seeing which function is inside which, and what the inner function hands to the outer one[3]. The stretching picture keeps both straight. Each factor is a stretch, measured where the interval actually is.
Three worked examples
Each example names the inner function u, then multiplies the outer derivative (in terms of u) by du/dx. You can check every answer in the calculator at the end of the chapter.
| Function | Inner u | Outer | Derivative |
|---|---|---|---|
| (3x + 1)5 | 3x + 1 | u5 | 5(3x + 1)4 · 3 = 15(3x + 1)4 |
| esin x | sin x | eu | esin x · cos x |
| √(1 + x²) | 1 + x² | √u | 12√(1 + x²) · 2x = x√(1 + x²) |
Longer chains work the same way. For sin((3x + 1)5) there are three links, and the derivative is a product of three factors: cos((3x + 1)5) · 5(3x + 1)4 · 3. Like a gear train with more stages, every link contributes its own ratio.
Related rates: the balloon that slows down
The chain rule earns its keep whenever two quantities are tied together and one changes in time. Blow air into a spherical balloon at a steady 20 cm³ every second. The volume rises steadily. Does the radius?
Volume and radius are linked by V = (4/3)πr³, and both depend on time. Differentiating with respect to t, with the chain rule applied to r³, gives[2]
The factor 4πr² is the balloon’s surface area, and equation (3.3) has a physical reading: new air spreads as a thin shell over the whole skin, so the radius grows by the volume added divided by the area it is spread over. As the balloon grows, the same 20 cm³ is spread thinner. In the standard textbook version of this problem, air enters at 2 cm³/s and the radius is 3 cm; then dr/dt = 2/(4π · 9) = 1/(18π), about 0.018 cm/s[2].
Every related-rates problem has this shape. Write the equation that ties the quantities together, differentiate both sides with respect to time using the chain rule, and substitute the numbers you know at the instant you care about. The ladder sliding down a wall, the shadow lengthening as you walk away from a lamp and the water level rising in a conical tank are all equation (3.1) in different clothes.
More than one chain
Sometimes a quantity depends on several intermediate variables at once. The temperature you feel on a walk depends on your position x and y, which both depend on time. Then each path from t to the temperature z contributes a product of rates, and the contributions add[4]:
Multiply along each chain, add across chains. With one intermediate variable this is equation (3.1) again; with many, it is the same bookkeeping done once per path.
Check your own chain-rule answers
The calculator below applies the same rules to the formula you type, and it also checks its answer against slopes of ever-shorter secants, which use no rules at all. Use it to check derivatives you work out by hand. Compute the derivative of sin(x²) at x = 1.2 from equation (3.2), 2(1.2) cos(1.44) ≈ 0.3130, and compare.
sin(x^2) or sqrt(1+x^2), and a point. Compare the number with the chain-rule formula you derive by hand. Open “Show the work” to see how the difference quotients converge.#The chain rule completes the toolkit for derivatives. With it, the power, product and quotient rules, and the derivatives of a handful of basic functions, every formula can be differentiated. The next chapter turns to the other half of calculus: not how fast a quantity changes, but how much it adds up to.