Skip to main content

Chain Rule Calculator

Free Chain rule Calculator for calculus. Enter values to get step-by-step solutions with formulas and graphs. Get results you can export or share.

Reviewed by Manoj Kumar, Mathematics Educator

Reviewed by Manoj Kumar, Mathematics Educator

Formula

d/dx[f(g(x))] = f'(g(x)) * g'(x)

The chain rule states that the derivative of a composite function f(g(x)) equals the derivative of the outer function evaluated at the inner function, multiplied by the derivative of the inner function. This rule is essential for differentiating nested or composed functions.

Worked Examples

Example 1: Power of a Polynomial

Problem:Find the derivative of f(x) = (2x^2 + 1)^3 at x = 1 using the chain rule.

Solution:Outer: f(u) = u^3, so f'(u) = 3u^2\nInner: g(x) = 2x^2 + 1, so g'(x) = 4x\ng(1) = 2(1) + 1 = 3\nf'(g(1)) = 3(3)^2 = 27\ng'(1) = 4(1) = 4\nChain rule: dy/dx = 27 * 4 = 108

Result:dy/dx at x = 1 is 108

Example 2: Sine of an Exponential

Problem:Find the derivative of f(x) = sin(e^x) at x = 0.

Solution:Outer: f(u) = sin(u), so f'(u) = cos(u)\nInner: g(x) = e^x, so g'(x) = e^x\ng(0) = e^0 = 1\nf'(g(0)) = cos(1) = 0.5403\ng'(0) = e^0 = 1\nChain rule: dy/dx = 0.5403 * 1 = 0.5403

Result:dy/dx at x = 0 is 0.5403

Frequently Asked Questions

What is the chain rule in calculus?

The chain rule is a fundamental differentiation technique used to find the derivative of a composite function. When you have a function composed of an outer function f and an inner function g, written as f(g(x)), the chain rule states that the derivative equals the derivative of the outer function evaluated at the inner function, multiplied by the derivative of the inner function. In notation, d/dx[f(g(x))] equals f prime of g(x) times g prime of x. This rule is essential because many real-world functions are compositions of simpler functions, and without the chain rule, differentiating them would require expanding and simplifying complex expressions first, which is often impractical or impossible.

Can the chain rule be applied multiple times?

Yes, the chain rule can be applied repeatedly for functions with multiple layers of composition. If you have f(g(h(x))), a three-layer composition, you apply the chain rule twice. The derivative is f prime of g(h(x)) times g prime of h(x) times h prime of x. Each additional layer of composition adds another factor to the product. For example, to differentiate sin(cos(x squared)), you have three layers: the outer sin, the middle cos, and the inner x squared. The derivative is cos(cos(x squared)) times negative sin(x squared) times 2x. This multi-layer application is sometimes called the generalized chain rule and is common in neural network backpropagation algorithms used in machine learning.

What is the Leibniz notation for the chain rule?

In Leibniz notation, the chain rule is written as dy/dx equals dy/du times du/dx, where u represents the inner function. This notation makes the chain rule look like a fraction multiplication where du cancels out, which is a helpful mnemonic even though derivatives are not actually fractions. For example, if y equals u cubed and u equals 2x plus 1, then dy/du equals 3u squared and du/dx equals 2, giving dy/dx equals 3u squared times 2 equals 6(2x plus 1) squared. Leibniz notation extends naturally to multiple compositions: dy/dx equals dy/du times du/dv times dv/dx for three layers. This notation is particularly intuitive for related rates problems and implicit differentiation.

How does the chain rule relate to implicit differentiation?

Implicit differentiation is fundamentally an application of the chain rule. When you have an equation like x squared plus y squared equals 25, where y is implicitly defined as a function of x, differentiating the y terms requires the chain rule because y itself is a function of x. The derivative of y squared with respect to x is 2y times dy/dx, where 2y comes from the power rule and dy/dx comes from the chain rule treating y as the inner function. Without the chain rule, implicit differentiation would not work. This technique is essential for finding derivatives of curves that cannot be expressed as explicit functions, such as circles, ellipses, and other algebraic curves defined by equations in x and y.

References

Reviewed by Manoj Kumar, Mathematics Educator ยท Editorial policy