7.4 Rules for differentiation

First principles is the definition; in practice we use rules. For constants \(a\) and \(n\):

Function Derivative
\(ax^n\) \(anx^{n-1}\)
constant \(c\) \(0\)
\(\sin x\) \(\cos x\)
\(\cos x\) \(-\sin x\)
\(\tan x\) \(\sec ^2x\)
\(e^x\) \(e^x\)
\(\ln x\) \(\frac {1}{x}\)
Table 16: Standard derivatives. Note \(e^x\) is unchanged by differentiation.

Rule Statement
Sum \((u+v)'=u'+v'\)
Product \((uv)'=u'v+uv'\)
Quotient \(\left (\frac {u}{v}\right )'=\frac {u'v-uv'}{v^2}\)
Chain \(\frac {dy}{dx}=\frac {dy}{du}\cdot \frac {du}{dx}\)
Table 17: The four rules. The quotient rule’s numerator is a subtraction, so its order matters.

Note 7.19. In the product rule the order of the two terms does not matter, since they are added. In the quotient rule it does: the term with \(u'\) comes first. Writing \(uv'-u'v\) gives the answer with the wrong sign throughout.

Example 7.20. Differentiate (a) \(y=\frac {3x-2}{x+4}\), (b) \(y=\cos ^4(3x-1)\), (c) \(y=x^3e^{4x}\).

Solution. (a) Quotient rule. Take \(u=3x-2\) and \(v=x+4\), so \(u'=3\) and \(v'=1\): \[\frac {dy}{dx}=\frac {u'v-uv'}{v^2}=\frac {3(x+4)-(3x-2)(1)}{(x+4)^2} =\frac {3x+12-3x+2}{(x+4)^2}=\frac {14}{(x+4)^2}.\] The \(x\) terms cancel, leaving a derivative that is positive everywhere — the curve is always increasing, which is worth noticing as a check.

(b) Chain rule, twice. Write \(y=\left [\cos (3x-1)\right ]^4\). The outermost operation is raising to the fourth power, then the cosine, then the linear inside. \[\frac {dy}{dx}=4\left [\cos (3x-1)\right ]^3\cdot \left (-\sin (3x-1)\right )\cdot 3 =-12\cos ^3(3x-1)\sin (3x-1).\] Work from the outside in, and multiply by the derivative of the inside at each stage. The factor of \(3\) at the end comes from differentiating \(3x-1\), and forgetting it is the usual chain-rule error. The minus sign comes from differentiating the cosine.

(c) Product rule with a chain inside. Take \(u=x^3\) and \(v=e^{4x}\), so \(u'=3x^2\) and, by the chain rule, \(v'=4e^{4x}\): \[\frac {dy}{dx}=u'v+uv'=3x^2e^{4x}+x^3\left (4e^{4x}\right ) =3x^2e^{4x}+4x^3e^{4x}.\] Factorising makes it tidier and easier to use later: \[\frac {dy}{dx}=x^2e^{4x}\left (3+4x\right ).\]

Questions on this section

Stuck on something here? Ask below and it stays attached to this topic.