Differentiating Through Dependencies
When and both and depend on , the total rate of change adds one contribution per route of dependence: .
Draw the dependency tree ( on top, and below, at the bottom): multiply derivatives ALONG each path, add ACROSS paths. The rule extends to any number of variables and any depth of nesting — partials with respect to several inputs just select which bottom variable you follow. Intuition: a small change perturbs by and by ; the tangent-plane approximation converts each into a -change, and to first order the two effects simply add.
Training a neural network is nothing but this chain rule applied through thousands of nested dependencies: the loss depends on outputs, which depend on weights through layer after layer. "Multiply along paths, add across paths" is precisely the backpropagation algorithm — the multivariable chain rule is arguably the most economically important formula in modern computing.
A curve given implicitly by has slope wherever — no solving for , ever. Derivation in one line: differentiate by the chain rule: .
This retires the ad-hoc implicit differentiation of first-year calculus: compute two partials, form the ratio, attach a minus sign. In three variables, a surface has by the same argument, and is the surface normal — tangent planes to implicit surfaces come free.
For find at . Work: ; and at the point; slope . Confirm the point first ( ✓) — implicit-differentiation errors are usually really point-not-on-curve errors.
Proofs & Why It Matters
Differentiability means , where shrinks faster than . Divide by : .
As the difference quotients converge to , and because is sub-linear in the displacement. What survives is exactly the chain rule. SIGNIFICANCE: every related-rates problem, every implicit derivative, every Jacobian change of variables, and every gradient-descent step is this limit argument reused.
Suppose for all (homogeneity of degree ). Differentiate BOTH sides with respect to — the left by the chain rule: ; the right: . Set : .
SIGNIFICANCE: in economics this says total output equals the sum of inputs paid their marginal products (constant returns to scale); in thermodynamics it generates the Gibbs–Duhem relation — one chain-rule differentiation, two sciences.
Going Deeper: Worked Problems
The radius of a cylinder grows at cm/s while its height shrinks at cm/s. How fast is the volume changing when and ?
Step 1 — depends on two moving inputs, so .
Step 2 — partials: and at the given moment.
Step 3 — plug in the rates: cm/s.
Step 4 — interpret: the radius term dominates because volume is quadratic in but only linear in — the chain rule made that visible as the sizes of the two partials.
Find the tangent plane to the sphere at .
Step 1 — write the surface as ; the normal to a level surface is the gradient .
Step 2 — evaluate: , or just after scaling.
Step 3 — the plane through the point with that normal: , i.e. .
Step 4 — sanity: for a sphere centered at the origin the normal at a point IS the point's position vector, and on the right equals — both facts confirm the plane without redoing anything.