Differentiate a function of a function with the chain rule, handle powers, trigonometric and mixed expressions, and use $\dfrac{dy}{dx} = 1\Big/\dfrac{dx}{dy}$.
Many functions are built by putting one function inside another: $\sin(3x^2)$ is "$\sin$ of $3x^2$", and $(2x+1)^5$ is "the fifth power of $2x+1$". Such a composite function is written $y = f(u)$ with $u = g(x)$. Its rate of change is found by multiplying the rates along the chain.
Chain rule. If $y = f(u)$ and $u = g(x)$ are differentiable, $$\frac{dy}{dx} = \frac{dy}{du}\cdot\frac{du}{dx}.$$ Idea: a small change $\delta x$ in $x$ causes $\delta u \approx g'(x)\delta x$ in $u$, which causes $\delta y \approx f'(u)\delta u$ in $y$. For example if $u$ changes 3 times as fast as $x$, and $y$ changes 2 times as fast as $u$, then $y$ changes $2 \times 3 = 6$ times as fast as $x$.
In practice, work from the outside in:
Example: Differentiate $y = (3x^2 + 1)^5$. Let $u = 3x^2 + 1$, so $y = u^5$. $\dfrac{dy}{du} = 5u^4$ and $\dfrac{du}{dx} = 6x$. Therefore $\dfrac{dy}{dx} = 5(3x^2+1)^4\cdot 6x = 30x(3x^2+1)^4$.
Combining the chain rule with the basic derivatives: $$\frac{d}{dx}\big[g(x)\big]^n = n\big[g(x)\big]^{n-1}g'(x),\qquad \frac{d}{dx}\sin g(x) = g'(x)\cos g(x),$$ $$\frac{d}{dx}\cos g(x) = -g'(x)\sin g(x),\qquad \frac{d}{dx}\tan g(x) = g'(x)\sec^2 g(x).$$ When the inside is linear, $g(x) = ax + b$, we get $\dfrac{d}{dx}f(ax+b) = a,f'(ax+b)$. For instance $\dfrac{d}{dx}\sin 4x = 4\cos 4x$ and $\dfrac{d}{dx}(5 - 2x)^3 = -6(5-2x)^2$.
Example: Differentiate $y = \sin^3(2x)$, that is $y = \big[\sin 2x\big]^3$. There are three layers: the cube, then $\sin$, then $2x$. $\dfrac{dy}{dx} = 3\sin^2(2x)\cdot\cos(2x)\cdot 2 = 6\sin^2(2x)\cos(2x)$.
Example: Differentiate $y = \sqrt{x^2 + 4}$. Write $y = (x^2+4)^{1/2}$. $\dfrac{dy}{dx} = \tfrac12(x^2+4)^{-1/2}\cdot 2x = \dfrac{x}{\sqrt{x^2+4}}$.
Real questions use several rules together. Decide the outermost operation first: if the expression is a product, use the product rule, and inside it use the chain rule for each factor; if it is a quotient, use the quotient rule, and so on.
Example: Differentiate $y = x\sqrt{1 - x^2}$. This is a product with $u = x$ and $v = (1 - x^2)^{1/2}$. $v' = \tfrac12(1-x^2)^{-1/2}(-2x) = \dfrac{-x}{\sqrt{1-x^2}}$. So $\dfrac{dy}{dx} = \sqrt{1-x^2} + x\cdot\dfrac{-x}{\sqrt{1-x^2}} = \dfrac{(1 - x^2) - x^2}{\sqrt{1-x^2}} = \dfrac{1 - 2x^2}{\sqrt{1-x^2}}$.
If $y = f(x)$ has an inverse, $x$ is a function of $y$ as well. By the chain rule applied to $x = x(y(x))$, $1 = \dfrac{dx}{dy}\cdot\dfrac{dy}{dx}$, so $$\frac{dy}{dx} = \frac{1}{;dx/dy;} \qquad \left(\frac{dx}{dy} \ne 0\right).$$ This is useful when $x$ is easy to differentiate with respect to $y$ but $y$ is not given directly; it is how the derivatives of the inverse trigonometric functions are found in the next lesson.
Example: If $x = y^3 + y$, find $\dfrac{dy}{dx}$ when $y = 1$. $\dfrac{dx}{dy} = 3y^2 + 1 = 4$ at $y = 1$. So $\dfrac{dy}{dx} = \dfrac14$ there.
Exam tip: In Paper I the chain rule is rarely a question on its own; it is hidden inside tangent-and-normal, stationary-point and rate-of-change questions. The usual errors are forgetting the factor $g'(x)$ (for example writing $\dfrac{d}{dx}\sin 3x = \cos 3x$) and mishandling $\sin^2 x$ versus $\sin x^2$: $\dfrac{d}{dx}\sin^2 x = 2\sin x\cos x$, but $\dfrac{d}{dx}\sin(x^2) = 2x\cos(x^2)$. Check your answer by testing the layers one at a time.