We are now going to compute the derivatives of the various trigonometric functions, \(\sin x\text{,}\)\(\cos x\) and so on. The computations are more involved than the others that we have done so far and will take several steps. Fortunately, the final answers will be very simple.
Observe that we only need to work out the derivatives of \(\sin x\) and \(\cos x\text{,}\) since the other trigonometric functions are really just quotients of these two functions. Recall:
\begin{align*}
\tan x &= \frac{\sin x}{\cos x} &
\cot x &= \frac{\cos x}{\sin x} &
\csc x &= \frac{1}{\sin x} &
\sec x &= \frac{1}{\cos x}.
\end{align*}
The first steps towards computing the derivatives of \(\sin x, \cos x\) is to find their derivatives at \(x=0\text{.}\) The derivatives at general points \(x\) will follow quickly from these, using trig identities. It is important to note that we must measure angles in radians 1
In science, radians is the standard unit for measuring angles. While you may be more familiar with degrees, radians should be used in any computation involving calculus. Using degrees will cause errors. Thankfully it is easy to translate between these two measures since \(360^\circ
= 2\pi\) radians. See Appendix B.2.1.
, rather than degrees, in what follows. Indeed — unless explicitly stated otherwise, any number that is put into a trigonometric function is measured in radians.
Subsection2.8.1These Proofs are Optional, the Results are Not.
While we expect you to read and follow these proofs, we do not expect you to be able to reproduce them. You will be required to know the results, in particular Theorem 2.8.5 below.
We will prove this limit by use of the squeeze theorem (Theorem 1.4.18). To get there we will first need to do some geometry. But first we will build some intuition.
The figure below contains part of a circle of radius 1. Recall that an arc of length \(h\) on such a circle subtends an angle of \(h\)radians at the centre of the circle. So the darkened arc in the figure has length \(h\) and the darkened vertical line in the figure has length \(\sin h\text{.}\) We must determine what happens to the ratio of the lengths of the darkened vertical line and darkened arc as \(h\) tends to zero.
This particular figure has been drawn with \(h=.4\) radians. Here are three more such blow ups. In each successive figure, the value of \(h\) is smaller. To make the figures clearer, the degree of magnification was increased each time \(h\) was decreased.
As we make \(h\) smaller and smaller and look at the figure with ever increasing magnification, the arc of length \(h\) and vertical line of length \(\sin h\) look more and more alike. We would guess from this that
Now we can use a few geometric facts about this figure to establish both an upper bound and a lower bound on \(\frac{\sin h}{h}\) with both the upper and lower bounds tending to \(1\) as \(h\) tends to \(0\text{.}\) So the squeeze theorem will tell us that \(\frac{\sin h}{h}\) also tends to \(1\) as \(h\) tends to \(0\text{.}\)
The triangle \(OPR\) has base \(1\) and height \(\sin h\text{,}\) and hence
\begin{align*}
\text{area of }\triangle OPR &= \half\times1\times\sin h=\frac{\sin h}{2}.
\end{align*}
The “piece of pie” \(OPR\) cut out of the circle is the fraction \(\frac{h}{2\pi}\) of the whole circle (since the angle at the corner of the piece of pie is \(h\) radians and the angle for the whole circle is \(2\pi\) radians). Since the circle has radius \(1\) we have
\begin{align*}
\text{area of pie } OPR &=
\frac{h}{2\pi} \cdot
(\text{area of circle}) = \frac{h}{2\pi} \pi \cdot 1^2= \frac{h}{2}
\end{align*}
Now the triangle \(OPR\) is contained inside the piece of pie \(OPR\text{.}\) and so the area of the triangle is smaller than the area of the piece of pie. Similarly, the piece of pie \(OPR\) is contained inside the triangle \(OQR\text{.}\) Thus we have
\begin{gather*}
\text{area of triangle } OPR \leq \text{ area of pie } OPR
\leq \text{ area of triangle } OQR
\end{gather*}
\begin{gather*}
\cos h \leq \frac{\sin h}{h} \leq 1
\end{gather*}
We know 2
Again, refresh your memory by looking up Appendix A.5.
that
\begin{align*}
\lim_{h \to 0} \cos h &=1.
\end{align*}
Since \(\tfrac{\sin h}{h}\) is sandwiched between \(\cos h\) and 1, we can apply the squeeze theorem for limits (Theorem 1.4.18) to deduce the following lemma:
Fortunately we don’t have to wade through geometry like we did for the previous step. Instead we can recycle our work and massage the above limit to rewrite it in terms of expressions involving \(\frac{\sin h}{h}\text{.}\) Thanks to Lemma 2.8.1 the work is then easy.
We’ll show you two ways to proceed — one uses a method similar to “multiplying by the conjugate” that we have already used a few times (see Example 1.4.17 and 2.2.9 ), while the other uses a nice trick involving the double–angle formula 3
See Appendix A.14 if you have forgotten. You should also recall that \(\sin^2\theta + \cos^2\theta =
1\text{.}\) Sorry for nagging.
\begin{align*}
\frac{\cos h - 1}{h}
&= \frac{-2\big(\sin\tfrac{h}{2}\big)^2}{h}\\
\end{align*}
Now this begins to look like \(\frac{\sin h?}{h}\text{,}\) except that inside the \(\sin(\cdot)\) we have \(h/2\text{.}\) So, setting \(\theta =h/2\text{,}\)
where we have used the fact that \(\ds \lim_{h \to 0} \frac{\sin h}{h} = 1\) and that the limit of a product is the product of limits (i.e. Lemma 2.8.1 and Theorem 1.4.3).
Subsection2.8.5Step 3: \(\diff{}{x} \{ \sin x \}\) and \(\diff{}{x} \{ \cos x\}\) for General \(x\)
To proceed to the general derivatives of \(\sin x\) and \(\cos x\) we are going to use the above two results and a couple of trig identities. Remember the addition formulae 5
You really should. Look this up in Appendix A.8 if you have forgotten.
These formulae are pretty easy to remember — applying \(\diff{}{x}\) to \(\sin x\) and \(\cos x\) just exchanges \(\sin x\) and \(\cos x\text{,}\) except for the minus sign 6
There is a bad pun somewhere in here about sine errors and sign errors.
Remark2.8.4.Optional — Another derivation of \(\diff{}{x}\cos x =-\sin x\).
We remark that, once one knows that \(\diff{}{x}\sin x =\cos x\text{,}\) it is easy to use it and the trig identity \(\cos(x) = \sin\big(\frac{\pi}{2}-x\big)\) to derive \(\diff{}{x}\cos x =-\sin x\text{.}\) Here is how 7
We thank Serban Raianu for suggesting that we include this.
Note that if \(x\) is measured in degrees, then the formulas of Lemma 2.8.3 are wrong. There are similar formulas, but we need the chain rule to build them — that is the subject of the next section. But first we should find the derivatives of the other trig functions.
Theorem2.8.5.Derivatives of trigonometric functions.
The derivatives of \(\sin x\) and \(\cos x\) are
\begin{align*}
\diff{}{x} \sin x &= \cos x & \diff{}{x} \cos x &= - \sin x
\end{align*}
Consequently the derivatives of the other trigonometric functions are
\begin{align*}
\diff{}{x} \tan x &= \sec^2 x &
\diff{}{x} \cot x &= -\csc^2 x\\
\diff{}{x} \csc x &= -\csc x \cot x &
\diff{}{x} \sec x &= \sec x \tan x
\end{align*}
Of these 6 derivatives you should really memorise those of sine, cosine and tangent. We certainly expect you to be able to work out those of cotangent, cosecant and secant.
Graph sine and cosine on the same axes, from \(x=-2\pi\) to \(x=2\pi\text{.}\) Mark the points where \(\sin x\) has a horizontal tangent. What do these points correspond to, on the graph of cosine?
Graph sine and cosine on the same axes, from \(x=-2\pi\) to \(x=2\pi\text{.}\) Mark the points where \(\sin x\) has a tangent line of maximum (positive) slope. What do these points correspond to, on the graph of cosine?