Differentiating sin(x), cos(x) and tan(x)

When differentiating trigonometric functions we obtain the following derivatives:


Consider the derivative of \sin(x), for example. This can be proven using differentiation from first principles, compound angle formulae and the small angle approximations:

\begin{array}{lll}\frac{d}{dx}\left(\sin(x)\right)&=&\lim_{h\rightarrow 0}\frac{\sin(x+h)-\sin(x)}{h}\hspace{5pt}=\hspace{5pt}\lim_{h\rightarrow 0}\frac{\sin(x)\cos(h)+\cos(x)\sin(h)-\sin(x)}{h}\\&\approx&\lim_{h\rightarrow 0}\frac{\sin(x)\times 1+\cos(x)\times h-\sin(x)}{h}\hspace{5pt}=\hspace{5pt}\lim_{h\rightarrow 0}\cos(x)\hspace{5pt}=\hspace{5pt}\cos(x)\end{array}

Note that we can use \cos(h)\approx 1 instead of \cos(h)\approx 1-\frac{h^2}{2} for particularly small h. This is because for tiny h, h^2 would be negligible. If included in the expansion, as with any other higher order terms, it disappears as h\rightarrow 0 and the same result holds.

It can be shown using either differentiation from first principles or using the chain rule that:

\begin{array}{lll}\frac{d}{dx}\left(\sin(kx)\right)&=&k\cos(kx)\\\frac{d}{dx}\left(\cos(kx)\right)&=&-k\sin(kx)\\\frac{d}{dx}\left(\tan(kx)\right)&=&k\text{ sec}^2(kx)\end{array}

where k is a real constant. See Example 1. The derivative of \tan(kx) is given in the Edexcel Formula Booklet along with the derivatives of the reciprocal functions as below. However, the rest of the derivatives seen on this page are not given and should be memorised. A question may ask you to differentiate linear combinations of trigonometric functions (see Example 2) or possibly even more complex functions (see product, quotient and chain rule). 

Differentiating Reciprocal Trigonometric Functions

The derivatives of the reciprocal trigonometric functions are as follows:

\begin{array}{lll}\frac{d}{dx}\left(\text{cosec}(x)\right)&=&-\text{ cosec}(x)\text{cot}(x)\\\frac{d}{dx}\left(\text{sec}(x)\right)&=&\text{sec}(x)\tan(x)\\\frac{d}{dx}\left(\text{cot}(x)\right)&=&-\text{cosec}^2(x)\end{array}

We can show these derivatives using the quotient rule or implicit differentiation.

Similarly to the above, we can also show using the chain rule that:

\begin{array}{lll}\frac{d}{dx}\left(\text{cosec}(kx)\right)&=&-k\text{ cosec}(kx)\text{cot}(kx)\\\frac{d}{dx}\left(\text{sec}(kx)\right)&=&k\text{sec}(kx)\tan(kx)\\\frac{d}{dx}\left(\text{cot}(kx)\right)&=&-k\text{ cosec}^2(kx)\end{array}

 An exam question could ask all the usual things that require differentiation without explicitly stating it. See Example 2 for the use of differentiating reciprocal trigonometric functions in an example. 

Differentiating Inverse Trigonometric Functions

The derivatives of the inverse trigonometric functions are as follows:


We can show these derivatives using the fact that \frac{dy}{dx}=\frac{1}{\frac{dx}{dy}} (see more on this). Consider the derivative of y=\arcsin(x), for example. We can write this as x=\sin(y) and differentiate with respect to y: \frac{dx}{dy}=\cos(y). Hence, it follows that \frac{dy}{dx}=\frac{1}{\cos(y)}. To write this as a function of x, we note that \cos(y)=\pm\sqrt{1-\sin^2(y)}=\pm\sqrt{1-x^2}. Recall that \sin(y) is one-to-one on the default interval -\frac{\pi}{2}\leq y\leq\frac{\pi}{2}. It follows that \cos(y) is positive on this interval. Hence \frac{d}{dx}\left(\arcsin(x)\right)=\frac{1}{\sqrt{1-x^2}}. A similar process can be applied to the derivative of \arccos(x). See Example 3 for an example finding and using the derivative of \arctan(x)


Differentiate \cos(kx) from first principles, where k is a real constant.


\begin{array}{lll}\frac{d}{dx}\left(\cos(kx)\right)&=&\lim_{h\rightarrow 0}\frac{\cos(k(x+h))-\cos(kx)}{h}\\&=&\lim_{h\rightarrow 0}\frac{\cos(kx)\cos(kh)-\sin(kx)\sin(kh)-\cos(kx)}{h}\\&\approx&\lim_{h\rightarrow 0}\frac{\cos(kx)\times 1-\sin(kx)\times kh-\cos(kx)}{h}\\&=&\lim_{h\rightarrow 0}-k\sin(kx)\\&=&-k\sin(kx)\end{array}

Note that we have used \cos(kh)\rightarrow 1 and \sin(kh)\rightarrow kh as h\rightarrow 0.

Calculate the gradient of the curve of f(x)=3\text{ cosec}(x)+\text{sec}(4x) at the point with x-coordinate x=\frac{\pi}{4}. (See more on gradients).


Differentiating gives: f'(x)=-3\text{ cosec}(x)\cot(x)+4\sec(4x)\tan(4x)

Substituting x=\frac{\pi}{4} gives: f'\left(\frac{\pi}{4}\right)=-3\times\frac{1}{\sin\left(\frac{\pi}{4}\right)\tan\left(\frac{\pi}{4}\right)}+4\frac{\tan\left(\frac{\pi}{4}\right)}{\cos\left(\frac{\pi}{4}\right)}=\sqrt{2}.

See more on reciprocal trigonometric functions. Hence the gradient of the curve at x=\frac{\pi}{4} is \sqrt{2}.

  1. Show that the derivative of \arctan(x) is \frac{1}{1+x^2}.
  2.  Hence find the stationary points of the curve y=\arctan(x)-\frac{1}{2}x (see more on stationary points).


  1. Let y=\arctan(x). We can write this as x=\tan(y) and differentiate with respect to y: \frac{dx}{dy}=\sec^2(y)=\frac{1}{\cos^2(y)}. Hence, it follows that \frac{dy}{dx}=\cos^2(y). To write this as a function of x, we note that \frac{1}{1+x^2}=\frac{1}{1+\frac{\sin^2(y)}{\cos^2(y)}}=\frac{\cos^2(y)}{\cos^2(y)+\sin^2(y)}=\cos^2(y)  Hence \frac{d}{dx}\left(\arctan(x)\right)=\frac{1}{1+x^2}
  2. To find the stationary points we solve \frac{dy}{dx}=0. In this case we solve \frac{1}{1+x^2}-\frac{1}{2}=0.  It follows that 1=\frac{1}{2}(1+x^2), that is x^2=1 or x=\pm 1. It follows that the stationary points are (1,0.285) and (-1,-0.285) to 3 decimal places.