The Most Important Calculus Rule for AI
You almost never see a function in isolation in ML. Most are compositions: where one function feeds into another. To differentiate , you need the chain rule:
In words: "the derivative of the outer function (evaluated at the inner) times the derivative of the inner function." Multiply, don't add. The slopes compose multiplicatively as you nest functions.
Why It's the Backbone of Backprop
A neural network is a massive composition of functions: input → linear layer → activation → linear layer → activation → ... → loss. To compute how a loss changes with respect to a weight in the very first layer, you have to chain derivatives across every layer in between. The chain rule is the bookkeeping that makes this possible.
Backpropagation (next track) is just the chain rule applied systematically, one layer at a time, with intermediate values cached during the forward pass.
Quick Examples
- where for the sigmoid.