The Chain Rule
Why this matters
Imagine you have one of those giant, multi-layered jawbreakers from a candy shop in Chicago. The color changes as you get deeper into it. Now, let's think like a calculus student. The rate at which the color changes depends on two things: first, how fast you're licking the jawbreaker (the rate of change of the radius), and second, how thick each colored layer is. You can't find the overall rate of color change without considering both parts—the "outer" action and the "inner" layers.
This is exactly the kind of problem the chain rule solves. It helps us deal with functions that are layered, or "nested," inside of each other. It’s one of the most powerful and common derivative rules you'll use. So, let's break it down and learn how to handle these mathematical jawbreakers.
Concept overview
flowchart TD
A[Start with h(x)] --> B{Is h(x) a composite function f(g(x))?};
B -->|No| C[Use other rules: Power, Product, Quotient];
B -->|Yes| D[Identify outer f(u) and inner g(x)];
D --> E[Find derivative of outer function: f'(u)];
D --> F[Find derivative of inner function: g'(x)];
E --> G[Assemble the derivative: f'(g(x))];
G & F --> H[Multiply the parts: h'(x) = f'(g(x)) * g'(x)];
H --> I[Simplify and check for more layers];
I --> J[Final Answer];
Core explanation
Alright, let's dive into one of the most important rules in all of calculus: the chain rule.
So far, you’ve gotten really good at finding derivatives of standard functions.
- The derivative of
x^4is4x^3. (Power Rule) - The derivative of
sin(x)iscos(x). (Trig Rule)
But what happens when we combine them? What is the derivative of sin(x^4)?
This is not a simple product or sum. This is a composite function—a function living inside another function. In this case, the x^4 function is inside the sin(x) function. To handle this, we need the chain rule.
The "Russian Nesting Doll" Analogy
Think of a composite function like a set of Russian nesting dolls (Matryoshka dolls). You have a big doll on the outside, and when you open it, there's a smaller doll inside, and maybe another inside that one.
f(g(x)) is exactly like this:
- Outer Function
f( )is the biggest, outermost doll. - Inner Function
g(x)is the doll nested inside.
To find the derivative, you can't just jump to the innermost doll. You have to deal with each layer, from the outside in. The chain rule is the process of opening each doll, one at a time.
The Rule Itself
Let's look at the rule in its most common form. If you have a function h(x) = f(g(x)), its derivative is:
h'(x) = f'(g(x)) * g'(x)
This looks a little abstract, so let's translate it into plain English. This is the mantra you should repeat to yourself:
"The derivative of the outside function (leaving the inside function alone), times the derivative of the inside function."
Let's break down that phrase:
f'(g(x)): This is the "derivative of the outside, leaving the inside alone." You look at the outermost function,f, and take its derivative,f'. But notice what's still inside the parentheses: the original inner function,g(x). You don't touch it in this step.- *` g'(x)
**: This is the "times the derivative of the inside." After you've handled the outer layer, you multiply your result by the derivative of the inner function,g'(x)`.
Let's Try It: A Step-by-Step Example
Let's find the derivative of h(x) = (x^2 + 5)^3.
Step 1: Identify the outer and inner functions.
- What is the main thing happening to the expression? It's being cubed. So, our outer function is "something cubed." Let's call it
f(u) = u^3. - What is the "something" being cubed? It's
x^2 + 5. This is our inner function. Let's call itg(x) = x^2 + 5.
Step 2: Take the derivative of the outside function.
- The derivative of our outer function
f(u) = u^3isf'(u) = 3u^2. - Now, apply the first part of our mantra: "derivative of the outside, leaving the inside alone." We'll take that
3u^2structure and plug our original inside function (x^2 + 5) back in foru. - This gives us
3(x^2 + 5)^2.
Step 3: Take the derivative of the inside function.
- Our inner function is
g(x) = x^2 + 5. - Its derivative is simple:
g'(x) = 2x.
Step 4: Multiply the results from Step 2 and Step 3.
h'(x) = [Result from Step 2] * [Result from Step 3]h'(x) = 3(x^2 + 5)^2 * (2x)
And that's it! You can simplify it to 6x(x^2 + 5)^2 for a final answer.
You have successfully "unpacked" the nesting doll. You dealt with the outer "cubing" layer first, then multiplied by the derivative of the inner x^2 + 5 layer. This process covers the core requirement of the AP exam: calculating the derivative of a composite function (LO FUN-3.C).
Another Notation (Leibniz Notation)
Sometimes you'll see the chain rule written like this:
If y = f(u) and u = g(x), then dy/dx = dy/du * du/dx.
This is just another way of saying the exact same thing. dy/du is the derivative of the outer function with respect to its temporary variable u, and du/dx is the derivative of the inner function with respect to x. It's helpful because it almost looks like the du terms cancel out, leaving you with dy/dx.
No matter which notation you prefer, the process is the same: outside, then inside.
Worked examples
Let's walk through a couple of examples together. The key is to be systematic: identify layers, differentiate the outside, then multiply by the derivative of the inside.
A Trigonometric Function
Problem: Find the derivative of y = cos(4x^3).
Solution:
-
Identify the layers. This can trip people up because the parentheses are the only clue.
- The "outer" function is the main operation:
cos(u). - The "inner" function is the stuff inside the cosine:
u = 4x^3.
- The "outer" function is the main operation:
-
Find the derivative of the outer function,
cos(u).- The derivative of
cos(u)is-sin(u). - Now, apply the "leave the inside alone" rule. We substitute our original inner function back in for
u. This gives us-sin(4x^3).
- The derivative of
-
Find the derivative of the inner function,
4x^3.- Using the power rule, the derivative of
4x^3is12x^2.
- Using the power rule, the derivative of
-
Multiply the results.
y' = (Derivative of outside) * (Derivative of inside)y' = -sin(4x^3) * (12x^2)
-
Clean it up. It's standard practice to move the polynomial part to the front to avoid confusion.
y' = -12x^2 * sin(4x^3)
A Multi-Layer Chain Rule
Problem: Find the derivative of f(x) = sin^4(2x).
Hold on! This looks tricky. The first step is always to rewrite it to make the layers obvious. sin^4(2x) is just a shorthand way of writing [sin(2x)]^4.
Solution: Now we can see we have three layers, like a triple nesting doll!
- Outermost layer
u^4(something to the fourth power) - Middle layer
sin(v) - Innermost layer
2x
We just apply the chain rule from the outside in, peeling one layer at a time.
-
Differentiate the outermost layer,
u^4.- The derivative is
4u^3. We leave everything inside it alone. 4[sin(2x)]^3
- The derivative is
-
Multiply by the derivative of the next layer in,
sin(2x).- What's the derivative of
sin(2x)? Uh oh, this is another chain rule!- Outer:
sin(v). Derivative iscos(v). - Inner:
2x. Derivative is2. - So, the derivative of
sin(2x)iscos(2x) * 2.
- Outer:
- Let's chain this onto our result from step 1.
f'(x) = 4[sin(2x)]^3 * [cos(2x) * 2]
- What's the derivative of
-
Clean it up.
f'(x) = 8 * sin^3(2x) * cos(2x)
We handled the ( )^4 layer, then the sin( ) layer, and finally the 2x layer, multiplying all the derivatives together.
Try it yourself
Ready to try a couple on your own? Don't worry about getting the perfect answer right away. Focus on identifying the layers and applying the process.
-
Find the derivative of
f(x) = sqrt(x^2 + 3x)- Hint: How can you rewrite a square root as a power? Once you do that, the "outer" function becomes much clearer.
-
Find the derivative of
g(t) = e^(sin(t))- Hint: The base is
e, so you know the derivative of the outer layer will look very similar to the original function. What's the inner function you need to multiply by the derivative of?
- Hint: The base is
Take your time, write out the steps, and say the mantra to yourself. You can do this.
In simple terms, the chain rule is a method for finding the derivative of a "function inside a function," like figuring out how fast a balloon's volume changes as its radius grows.
- FUN-3.C: Calculate derivatives of compositions of differentiable functions.
- FUN-3.C.1
- The chain rule provides a way to differentiate composite functions.
flowchart TD
A[Start with h(x)] --> B{Is h(x) a composite function f(g(x))?};
B -->|No| C[Use other rules: Power, Product, Quotient];
B -->|Yes| D[Identify outer f(u) and inner g(x)];
D --> E[Find derivative of outer function: f'(u)];
D --> F[Find derivative of inner function: g'(x)];
E --> G[Assemble the derivative: f'(g(x))];
G & F --> H[Multiply the parts: h'(x) = f'(g(x)) * g'(x)];
H --> I[Simplify and check for more layers];
I --> J[Final Answer];
Read what Saavi narrates
Hello, and welcome to Shrutam. I'm Saavi, and today we're going to tackle one of the most important tools in your calculus toolbox: the chain rule.
Imagine you have one of those giant, multi-layered jawbreakers. The rate at which the color changes depends on two things: how fast you're licking it, and how thick each colored layer is. You need to consider both the outer action and the inner layers. The chain rule is our mathematical way of doing just that. It's for finding the derivative of a composite function... which is just a fancy name for a function that's nested inside another one.
Let's look at an example together. How would you find the derivative of the function y equals cosine of four x cubed?
First, we need to identify the layers. The main, or outer, function is the cosine. The inner function is the stuff inside... the four x cubed.
The rule is: take the derivative of the outside, leaving the inside alone... and then multiply by the derivative of the inside.
So, the derivative of the outer cosine function is negative sine. We leave the inside alone, so we have negative sine of four x cubed.
Now for the second part of the rule. We multiply by the derivative of the inside. The derivative of four x cubed is, using the power rule, twelve x squared.
Putting it all together, our answer is negative sine of four x cubed... times... twelve x squared. We usually write that as negative twelve x squared times sine of four x cubed, just to keep it neat.
The most common mistake here is to forget that last part... forgetting to multiply by the derivative of the inside. It's so easy to do the first step and feel like you're done. Always remember to finish the job and multiply by the derivative of that inner function.
The chain rule can feel a little strange at first, but like anything, practice makes it click. You are fully capable of mastering this. Keep working at it, and you'll see it's a pattern you'll start to recognize everywhere. You've got this.
You're only doing half the rule. Finding the derivative of `(x^2+1)^3` as just `3(x^2+1)^2` ignores how the *inside* part is changing.
Always finish the mantra: "...times the derivative of the inside." Your final step should always be to multiply by that `g'(x)`.
The rule is `f'(g(x))`, not `f'(g'(x))`. You must leave the original inner function `g(x)` inside the derivative of the outer function.
Follow a two-step thought process: 1) Differentiate the outer part, copy-pasting the inside exactly as it was. 2) THEN multiply by the derivative of the inside.
They are completely different functions. `sin^2(x)` is `(sin(x))^2`, where the outer function is `u^2`. `sin(x^2)` has `sin(u)` as the outer function.
If you see `sin^2(x)`, `cos^3(x)`, or `tan^5(x)`, immediately rewrite it as `(sin(x))^2`, `(cos(x))^3`, or `(tan(x))^5` to make the outer function clear.
You missed a layer! The derivative of the inside function, `e^(5x)`, is itself a chain rule problem.
Keep asking "is there another layer?" The derivative of `e^(5x)` is `e^(5x) * 5`. The full derivative is `-sin(e^(5x)) * e^(5x) * 5`.
This is not a composite function; it's one function (`x^2`) multiplied by another (`sin(x)`). The chain rule is for functions *inside* functions.
Identify the overall structure first. If you see `f(x) * g(x)`, use the product rule. If you see `f(g(x))`, use the chain rule.