When the inner function is itself a standard family
So far the inner function has been a polynomial or a linear expression, so the inner factor was a single term. That is not guaranteed. In \(e^{\sin(3x)}\) the inner function is \(\sin(3x)\), which is itself a composite.
Step 1 — Inventory the layers
- Layer 1 (outermost): \(e^{\square}\).
- Layer 2 (middle): \(\sin(\square)\).
- Layer 3 (innermost): \(3x\).
Three layers, so three factor slots.
Step 2 — Fill the slots outside in
- Slot 1: derivative of \(e^{\square}\) with the inside copied unchanged \(\to e^{\sin(3x)}\).
- Slot 2: derivative of \(\sin(\square)\) with the inside copied unchanged \(\to \cos(3x)\).
- Slot 3: derivative of \(3x\) \(\to 3\).
\[\frac{d}{dx}e^{\sin(3x)} = e^{\sin(3x)} \cdot \cos(3x) \cdot 3\]
Step 3 — Count the factors against the layers
Count the factors written: \(e^{\sin(3x)}\), \(\cos(3x)\), and \(3\). That is three factors. Count the layers inventoried: exponential, sine, linear. That is three layers. The counts match, so no layer was skipped.
What a mismatch tells you
If you had written only \(e^{\sin(3x)} \cdot \cos(3x)\), the factor count would be two against three layers. The missing factor is the innermost one, the derivative of \(3x\). The count check localizes the error without re-deriving anything: the shortfall is always the deepest layer that was never differentiated.
Why the inner factor is not always a constant
In \(e^{2x}\) the inner factor was the number \(2\). In \(e^{\sin(3x)}\) the inner function is a trig composite, so its derivative is not a constant — it is \(\cos(3x) \cdot 3\), which itself has two factors. This is why the layout must be applied again to the inner function rather than treated as a single term.