## Differentiating Trigonometric Functions

1. Introduction. So we have investigated several useful trig limits, lets consider the bigger problem: differentiating trigonometric functions.

We will use the following properties without proving them:
(1a)$\displaystyle \cos(\varphi+\psi)=\cos(\varphi)\cos(\psi)-\sin(\varphi)\sin(\psi)$
(1b)$\displaystyle \sin(\varphi+\psi)=\cos(\varphi)\sin(\psi)+\sin(\varphi)\cos(\psi)$
(1c)$\displaystyle \sin(-\varphi)=-\sin(\varphi)$
(1d)$\displaystyle \cos(-\varphi)=\cos(\varphi)$
Where we have $\varphi, \psi$ be arbitrary real numbers.

2. Derivative of Cosine. We see from (1a) that
(2)$\displaystyle \begin{array}{rl}\Delta\cos(\varphi)&=\cos(\varphi+\Delta\varphi)-\cos(\varphi)\\ &=\cos(\varphi)\cos(\Delta\varphi)-\sin(\varphi)\sin(\Delta\varphi)-\cos(\varphi)\\ &=\cos(\varphi)\bigl(\cos(\Delta\varphi)-1\bigr)-\sin(\varphi)\sin(\Delta\varphi)\end{array}$
We divide both sides by $\Delta\varphi$ obtaining
(3)$\displaystyle \frac{\Delta\cos(\varphi)}{\Delta\varphi}=\cos(\varphi)\left(\frac{\cos(\Delta\varphi)-1}{\Delta\varphi}\right)-\sin(\varphi)\frac{\sin(\Delta\varphi)}{\Delta\varphi}$.
Taking the limit as $\Delta\varphi\to0$, and recalling our useful trigonometric limits, we have the definition of the derivative for cosine
(4)$\displaystyle \frac{\mathrm{d}\cos(\varphi)}{\mathrm{d}\varphi}=\cos(\varphi)\left(0\right)-\sin(\varphi)\cdot1=-\sin(\varphi)$.

3. Derivative of Sine. Likewise, using Equation (1b), we find
(5)$\displaystyle \begin{array}{rl} \Delta\sin(\varphi)&=\sin(\varphi+\Delta\varphi)-\sin(\varphi)\\ &=\cos(\varphi)\sin(\Delta\varphi)+\sin(\varphi)\cos(\Delta\varphi)-\sin(\varphi)\\ &=\cos(\varphi)\sin(\Delta\varphi)+\sin(\varphi)\bigl(\cos(\Delta\varphi)-1\bigr)\end{array}$.
Dividing through by $\Delta\varphi$ yields
(6)$\displaystyle\frac{\Delta\sin(\varphi)}{\Delta\varphi}=\cos(\varphi)\left(\frac{\sin(\Delta\varphi)}{\Delta\varphi}\right)+\sin(\varphi)\left(\frac{\cos(\Delta\varphi)-1}{\Delta\varphi}\right)$
Again, taking the limit $\Delta\varphi\to 0$ yields the derivative
(7)$\displaystyle\frac{\mathrm{d}\sin(\varphi)}{\mathrm{d}\varphi}=\lim_{\Delta\varphi\to0}\frac{\Delta\sin(\varphi)}{\Delta\varphi}=\lim_{\Delta\varphi\to0}\cos(\varphi)\left(\frac{\sin(\Delta\varphi)}{\Delta\varphi}\right)+\sin(\varphi)\left(\frac{\cos(\Delta\varphi)-1}{\Delta\varphi}\right)$
Using our beloved trig limits produces:
(8)$\displaystyle\frac{\mathrm{d}\sin(\varphi)}{\mathrm{d}\varphi}=\cos(\varphi)\left(1\right)+\sin(\varphi)\left(0\right)$
Thus we obtain
(9)$\displaystyle\frac{\mathrm{d}\sin(\varphi)}{\mathrm{d}\varphi}=\cos(\varphi)$.

Exercise 1. Prove $\displaystyle\frac{\mathrm{d}\tan(x)}{\mathrm{d}x}=\frac{1}{\cos^{2}(x)}$.

Exercise 2. Recall the secant function is $\sec(x)=1/\cos(x)$. What is its derivative?

Exercise 3. Recall the cosecant function is $\csc(x)=1/\sin(x)$. What is its derivative?

Exercise 4. What is the derivative of $\cos\bigl(\sin(x)\bigr)$ with respect to $x$?