## Intuiting the Chain Rule

If you’ve just learned the chain rule but feel that you have no intuition for it, this post might help.

Recall that the chain rule tells us how to compute the derivative of a composite function. Specifically, suppose $f : \Bbb{R} \to \Bbb{R}$ and $g: \Bbb{R} \to \Bbb{R}$ are differentiable functions.  Let $f'(x)$ be the derivative of $f(x)$ with respect to $x$ and let $g'(x)$ be the derivative of $g(x)$ with respect to $x$.

Then $\frac{d}{dx} f(g(x)) = f'(g(x))g'(x)$.

One way to gain an intuitive feel for the chain rule is to think of an example of a composite function that you understand well and then see that what you think about the example is consistent with what the chain rule says. Here, I’ll describe a scenario that I often use to explain the chain rule and seems to help.

## Filming a race car

Imaging filming a car racing along a long straight road. The film begins just as the car takes off from the starting line. The car accelerates rapidly. Maybe it slows down to avoid a passing chicken. Whatever. Let $D(t)$ represent the distance the driver has traveled from the starting line at time $t$.

The driver’s speed at time $t$ is given by the derivative $\frac{d}{dt} D(t)$.

Now let’s watch this film in a movie theater. If we operate the projector normally, you’ll see the race car traveling along the road just as if you were watching the actual race car, and you would judge the speed of the race car to be just as you saw it when you filmed it. (There’s a possible ambiguity here that I want to make sure does not become a point of confusion. One calculates the speed of the car by paying attention to the distances the car travels along the road and not to the distance traversed by the image of the car along the theater screen, which could even be no distance at all if the camera is following the car.)

But what if we feed the film through the projector twice as fast as normal?

Well, then, like those sped up comedy skits, you’d see the race car zipping along seemingly twice as fast as when you filmed it.  It would finish the race in half the time.

And what if we feed the film through the projector half as fast as normal?

Then you’ve entered slowmo. The car creeps along at half the speed it was actually going.

What if the reel gets stuck in the projector?

Then you see the race car get stuck in place.

And what if we feed the reel through the projector in reverse?

You get the idea.

The situation is modeled by a composite function $D(T(t))$, where $T(t)$ is the function that tells the time along the film as a function of the actual time that passes as you sit in the theater watching. Under normal theater operations, $T(t) = t$. That is, film time and actual time are in sync. In slowmo, we might have $T(t) = t/2$.

The derivative $\frac{d}{dt} D(T(t))$ tells us what we’d judge the speed of the race car to be by watching the movie.

The common chain rule error is to write $\frac{d}{dt} D(T(t)) = D'(T(t))$. But if you write this, you’re saying that the speed of the race car on the screen does not depend on how we feed the reel through the projector. But we know that the apparent speed of the race car is scaled exactly by $\frac{d}{dt} T(t)$. That is, we intuit that $\frac{d}{dt} D(T(t)) = D'(T(t)) \cdot T'(t)$, just as the chain rule dictates!