Chain rule

Also: chain rule of calculus

If y = f(g(x)), then dy/dx = f′(g(x))·g′(x). Applied layer by layer through a network it gives every weight's gradient, which is exactly what backpropagation computes.

dy/dx = dy/du · du/dx

Chain rule: the gradient flows backward and multiplies local derivatives

Example

For y = (3x + 1)², let u = 3x + 1: dy/du = 2u and du/dx = 3, so dy/dx = 6(3x + 1), which is 24 at x = 1.

See it in the lesson: Linear Algebra & Calculus Refresher →

Related terms

More in Linear Algebra & Calculus