1.2 Calculus for ML
Interview-ready field notes
The 20-second answer
Calculus tells a model how changing each parameter changes the loss; backpropagation applies the chain rule efficiently to get all those changes.
Core ideas to retain
- A partial derivative changes one variable while holding the rest fixed. The gradient collects all partial derivatives.
- The gradient points uphill; gradient descent moves in : .
- The chain rule multiplies local derivatives along a path. Backprop reuses this from the output loss back to every weight.
- A Jacobian is first derivatives of a vector output; a Hessian is second derivatives of a scalar loss and describes curvature.
Interview / OA rule
In a derivative OA question, draw the computation graph, work backward, and multiply the local derivative by the upstream gradient. Check the resulting gradient shape.
One good written resource
3Blue1Brown — Essence of Calculus — read this after the video when you want a clearer mental model, not more pages of notes.
Most asked
Interview questions to practise aloud
Each answer is the level of detail expected for a strong fundamentals round.
Why does gradient descent subtract the gradient?
The gradient is the direction of fastest local increase. Its negative is the direction of fastest local decrease.
What is backpropagation?
Reverse-mode automatic differentiation: one backward pass applies the chain rule to compute the gradient of a scalar loss with respect to every parameter.
What is a saddle point?
A stationary point that goes up in some directions and down in others. Deep loss surfaces have many of them; it is not a local minimum.