Take \(f(x)=(3x^2+1)^5\). The layer inventory is already written: outer \((\square)^5\), inner \(3x^2+1\), two layers.
Step 1 — Outer factor. Differentiate the outer power, keeping the inner block intact:
\[5(3x^2+1)^4\]
Step 2 — Inner factor. Differentiate the inner function:
\[\frac{d}{dx}(3x^2+1)=6x\]
Step 3 — Write the full product.
\[f'(x)=5(3x^2+1)^4\cdot 6x\]
Each factor carries a label naming the layer it came from:
| Factor | Layer | Built from |
|---|---|---|
| \(5(3x^2+1)^4\) | outer | derivative of \((\square)^5\) at the inner function |
| \(6x\) | inner | derivative of \(3x^2+1\) |
Step 4 — Simplify last. Only now combine the constants: \(f'(x)=30x(3x^2+1)^4\).
The order matters. Writing the outer factor first guarantees the inner block is still intact when it is copied; if you differentiate the inner function first you are tempted to substitute \(6x\) into the outer factor, which is the classic \(4(6x)^3\) error.