Differentiation of trigonometric functions

Jump to: navigation, search
Function Derivative
$\sin(x)$ $\cos(x)$
$\cos(x)$ $-\sin(x)$
$\tan(x)$ $\sec^2(x)$
$\cot(x)$ $-\csc^2(x)$
$\sec(x)$ $\sec(x)\tan(x)$
$\csc(x)$ $-\csc(x)\cot(x)$
$\arcsin(x)$ $\frac{1}{\sqrt{1-x^2}}$
$\arccos(x)$ $\frac{-1}{\sqrt{1-x^2}}$
$\arctan(x)$ $\frac{1}{x^2+1}$

The differentiation of trigonometric functions is the mathematical process of finding the rate at which a trigonometric function changes with respect to a variable—the derivative of the trigonometric function. Commonplace trigonometric functions include sin(x), cos(x) and tan(x). For example, in differentiating f(x) = sin(x), one is calculating a function f ′(x) which computes the rate of change of sin(x) at a particular point a. The value of the rate of change at a is thus given by f ′(a). Knowledge of differentiation from first principles is required, along with competence in the use of trigonometric identities and limits. All functions involve the arbitrary variable x, with all differentiation performed with respect to x.

It turns out that once one knows the derivatives of sin(x) and cos(x), one can easily compute the derivatives of the other circular trigonometric functions because they can all be expressed in terms of sine or cosine; the quotient rule is then implemented to differentiate this expression. Proofs of the derivatives of sin(x) and cos(x) are given in the proofs section; the results are quoted in order to give proofs of the derivatives of the other circular trigonometric functions. Finding the derivatives of the inverse trigonometric functions involves using implicit differentiation and the derivatives of regular trigonometric functions also given in the proofs section.

Derivatives of trigonometric functions and their inverses

$\left(\sin(x)\right)' = \cos(x)$
$\left(\cos(x)\right)' = -\sin(x)$
$\left(\tan(x)\right)' = \left(\frac{\sin(x)}{\cos(x)}\right)' = \frac{\cos^2(x) + \sin^2(x)}{\cos^2(x)} = \frac{1}{\cos^2(x)} = \sec^2(x)$
$\left(\cot(x)\right)' = \left(\frac{\cos(x)}{\sin(x)}\right)' = \frac{-\sin^2(x) - \cos^2(x)}{\sin^2(x)} = -(1+\cot^2(x)) = -\csc^2(x)$
$\left(\sec(x)\right)' = \left(\frac{1}{\cos(x)}\right)' = \frac{\sin(x)}{\cos^2(x)} = \frac{1}{\cos(x)}.\frac{\sin(x)}{\cos(x)} = \sec(x)\tan(x)$
$\left(\csc(x)\right)' = \left(\frac{1}{\sin(x)}\right)' = -\frac{\cos(x)}{\sin^2(x)} = -\frac{1}{\sin(x)}.\frac{\cos(x)}{\sin(x)} = -\csc(x)\cot(x)$
$\left(\arcsin(x)\right)' = \frac{1}{\sqrt{1-x^2}}$
$\left(\arccos(x)\right)' = \frac{-1}{\sqrt{1-x^2}}$
$\left(\arctan(x)\right)' = \frac{1}{x^2+1}$

Proofs of derivatives of trigonometric functions

Limit of $\frac{\sin\theta}{\theta}$ as $\theta \to 0$

Circle, centre O, radius r

The diagram on the right shows a circle, centre O and radius r. Let θ be the angle at O made by the two radii OA and OB. Since we are considering the limit as θ tends to zero, we may assume that θ is a very small positive number: 0 < θ ≪ 1.

Consider the following three regions of the diagram: R1 is the triangle OAB, R2 is the circular sector OAB, and R3 is the triangle OAC. Clearly:

$\text{Area}(R_1) < \text{Area}(R_2) < \text{Area}(R_3) \, .$

Using basic trigonometric formulae, the area of the triangle OAB is

$\frac{1}{2} \times ||OA|| \times ||OB|| \times \sin\theta = \frac{1}{2}r^2\sin\theta \, .$

The area of the circular sector OAB is[citation needed] $\frac{1}{2}r^2\theta$, while the area of the triangle OAC is given by

$\frac{1}{2} \times ||OA|| \times ||AC|| = \frac{1}{2}\times r \times r \tan\theta = \frac{1}{2}r^2\tan\theta \, .$

Collecting together these three areas gives:

$\text{Area}(R_1) < \text{Area}(R_2) < \text{Area}(R_3) \iff \frac{1}{2}r^2\sin\theta < \frac{1}{2}r^2\theta < \frac{1}{2}r^2\tan\theta \, .$

Since r > 0 we can divide through by ½·r2; this means that the construction and calculations are all independent of the circle's radius. Moreover, since 0 < θ ≪ 1 it follows that sin(θ) > 0 and we may divide through by a factor of sin(θ), giving:

$1 < \frac{\theta}{\sin\theta} < \frac{1}{\cos\theta} \implies 1 > \frac{\sin\theta}{\theta} > \cos\theta \, .$

In the last step we simply took the reciprocal of each of the three terms. Since all three terms are positive this has the effect of reversing the inequities, e.g. if 2 < 3 then ½ > ⅓.

Squeeze: The curves y = 1 and y = cos(θ) shown in red, the curve y = sin(θ)/θ shown in blue.

We have seen that if 0 < θ ≪ 1 then sin(θ)/θ is always less than 1 and, in addition, is always greater than cos(θ). Notice that as θ gets closer to 0, so cos(θ) gets closer to 1. Informally: as θ gets smaller, sin(θ)/θ is "squeezed" between 1 and cos(θ), which itself it heading towards 1. It follows that sin(θ)/θ tends to 1 as θ tends to 0 from the positive side.

For the case where θ is a very small negative number: –1 ≪ θ < 0, we use the fact that sine is an odd function:

$\lim_{\theta \to 0^-} \frac{\sin\theta}{\theta} = \lim_{\theta\to 0^+}\frac{\sin(-\theta)}{-\theta} = \lim_{\theta \to 0^+}\frac{-\sin\theta}{-\theta} = \lim_{\theta\to 0^+}\frac{\sin\theta}{\theta} = 1 \, .$

Limit of $\frac{\cos\theta - 1}{\theta}$ as $\theta \to 0$

The last section enables us to calculate this new limit relatively easily. This is done by employing a simple trick. In this calculation, the sign of θ is unimportant.

$\lim_{\theta \to 0} \left(\frac{\cos\theta - 1}{\theta}\right) = \lim_{\theta \to 0} \left[ \left( \frac{\cos\theta - 1}{\theta} \right) \left( \frac{\cos\theta + 1}{\cos\theta + 1} \right) \right] = \lim_{\theta \to 0} \left( \frac{\cos^2\theta - 1}{\theta(\cos\theta + 1)} \right) .$

The well-known identity sin2θ + cos2θ = 1 tells us that cos2θ – 1 = –sin2θ. Using this, the fact that the limit of a product is the product of the limits, and the result from the last section, we find that:

$\lim_{\theta \to 0} \left(\frac{\cos\theta - 1}{\theta}\right) = \lim_{\theta \to 0} \left( \frac{-\sin^2\theta}{\theta(\cos\theta+1)} \right) = \lim_{\theta \to 0} \left( \frac{-\sin\theta}{\theta}\right) \times \lim_{\theta \to 0} \left( \frac{\sin\theta}{\cos\theta + 1} \right) = (-1) \times \frac{0}{2} = 0 \, .$

Limit of $\frac{\tan\theta}{\theta}$ as $\theta \to 0$

Using the limit for the sine function, the fact that the tangent function is odd, and the fact that the limit of a product is the product of the limits, we find:

$\lim_{\theta \to 0^-} \frac{\tan\theta}{\theta} = \lim_{\theta\to 0^+} \frac{\tan\theta}{\theta} = \lim_{\theta \to 0} \frac{\tan\theta}{\theta} = \lim_{\theta\to 0} \frac{\sin\theta}{\theta} \times \lim_{\theta\to 0} \frac{1}{\cos\theta} = 1 \times 1 = 1 \, .$

Derivative of the sine function

To calculate the derivative of the sine function sin θ, we use first principles. By definition:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\sin\theta = \lim_{\delta \to 0} \left( \frac{\sin(\theta + \delta) - \sin \theta}{\delta} \right) .$

Using the well-known angle formula sin(α+β) = sin α cos β + sin β cos α, we have:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\sin\theta = \lim_{\delta \to 0} \left( \frac{\sin\theta\cos\delta + \sin\delta\cos\theta-\sin\theta}{\delta} \right) = \lim_{\delta \to 0} \left[ \left(\frac{\sin\delta}{\delta} \cos\theta\right) + \left(\frac{\cos\delta -1}{\delta}\sin\theta\right) \right] .$

Using the limits for the sine and cosine functions:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\sin\theta = (1\times\cos\theta) + (0\times\sin\theta) = \cos\theta \, .$

Derivative of the cosine function

From the definition of the derivative

To calculate the derivative of the cosine function cos θ, we use first principles. By definition:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\cos\theta = \lim_{\delta \to 0} \left( \frac{\cos(\theta+\delta)-\cos\theta}{\delta} \right) .$

Using the well-known angle formula cos(α+β) = cos α cos β – sin α sin β, we have:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\cos\theta = \lim_{\delta \to 0} \left( \frac{\cos\theta\cos\delta - \sin\theta\sin\delta-\cos\theta}{\delta} \right) = \lim_{\delta \to 0} \left[ \left(\frac{\cos\delta -1}{\delta}\cos\theta\right) - \left(\frac{\sin\delta}{\delta} \sin\theta\right) \right] .$

Using the limits for the sine and cosine functions:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\cos\theta = (0 \times \cos\theta) - (1 \times \sin\theta) = -\sin\theta \, .$

From the chain rule

To compute the derivative of the cosine function from the chain rule, first observe the following two facts:

$\cos\theta = \sin\left(\theta + \frac{\pi}{2}\right)$
$\frac{\operatorname{d}}{\operatorname{d}\!\theta} \sin\theta = \cos\theta$

The first is a known trigonometric identity, and the second is proven above. Using these two facts, we can write the following,

$\frac{\operatorname{d}}{\operatorname{d}\!\theta} \cos\theta = \frac{\operatorname{d}}{\operatorname{d}\!\theta} \sin\left(\theta + \frac{\pi}{2}\right)$

We can differentiate this using the chain rule:

$\mbox{Let}\ f\!\left(x\right) = \sin x,\ g\!\left(x\right) = \theta + \frac{\pi}{2}$
$\frac{\operatorname{d}}{\operatorname{d}\!\theta} f\!\left(g\!\left(x\right)\right) = f^\prime\!\left(g\!\left(x\right)\right) \cdot g^\prime\!\left(x\right) = \cos\left(\theta + \frac{\pi}{2}\right) \cdot (1 + 0) = \cos\left(\theta + \frac{\pi}{2}\right)$

But, from above, we can rewrite this as

$\cos\left(\theta + \frac{\pi}{2}\right) = \sin\left(\left(\theta + \frac{\pi}{2}\right) + \frac{\pi}{2}\right) = \sin\left(\theta + \pi\right)$

But, this is an identity relating to horizontally translating the sine function, and therefore,

$\sin\left(\theta + \pi\right) = -\sin\theta$

Therefore, we have proven that

$\frac{\operatorname{d}}{\operatorname{d}\!\theta} \cos\theta = -\sin\theta$.

Derivative of the tangent function

From the definition of the derivative

To calculate the derivative of the tangent function tan θ, we use first principles. By definition:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\tan\theta = \lim_{\delta \to 0} \left( \frac{\tan(\theta+\delta)-\tan\theta}{\delta} \right) .$

Using the well-known angle formula tan(α+β) = (tan α + tan β) / (1 - tan α tan β), we have:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\tan\theta = \lim_{\delta \to 0} \left[ \frac{\frac{\tan\theta + \tan\delta}{1 - \tan\theta\tan\delta} - \tan\theta}{\delta} \right] = \lim_{\delta \to 0} \left[ \frac{\tan\theta + \tan\delta - \tan\theta + \tan^2\theta\tan\delta}{\delta \left( 1 - \tan\theta\tan\delta \right)} \right] .$

Using the fact that the limit of a product is the product of the limits:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\tan\theta = \lim_{\delta \to 0} \frac{\tan\delta}{\delta} \times \lim_{\delta \to 0} \left( \frac{1 + \tan^2\theta}{1 - \tan\theta\tan\delta} \right) .$

Using the limit for the tangent function, and the fact that tan δ tends to 0 as δ tends to 0:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\tan\theta = 1 \times \frac{1 + \tan^2\theta}{1 - 0} = 1 + \tan^2\theta .$

We see immediately that:

$\frac{\operatorname{d}}{\operatorname{d}\!\theta}\,\tan\theta = 1 + \frac{\sin^2\theta}{\cos^2\theta} = \frac{\cos^2\theta + \sin^2\theta}{\cos^2\theta} = \frac{1}{\cos^2\theta} = \sec^2\theta \, .$

From the quotient rule

One can also compute the derivative of the tanget function using the quotient rule.

$\frac{\operatorname{d}}{\operatorname{d}\!\theta} \tan\theta = \frac{\operatorname{d}}{\operatorname{d}\!\theta} \frac{\sin\theta}{\cos\theta} = \frac{\left(\sin\theta\right)^\prime \cdot \cos\theta - \sin\theta \cdot \left(\cos\theta\right)^\prime}{ \cos^2 \theta } = \frac{\cos^2 \theta + \sin^2 \theta}{\cos^2 \theta}$

The numerator can be simplified to 1 by the Pythagorean identity, giving us,

$\frac{1}{\cos^2 \theta} = \sec^2 \theta$

Therefore,

$\frac{\operatorname{d}}{\operatorname{d}\!\theta} \tan\theta = \sec^2 \theta$

Proofs of derivatives of inverse trigonometric functions

The following derivatives are found by setting a variable y equal to the inverse trigonometric function that we wish to take the derivative of. Using implicit differentiation and then solving for dy/dx, the derivative of the inverse function is found in terms of y. To convert dy/dx back into being in terms of x, we can draw a reference triangle on the unit circle, letting θ be y. Using the Pythagorean theorem and the definition of the regular trigonometric functions, we can finally express dy/dx in terms of x.

Differentiating the inverse sine function

We let

$y=\arcsin x\,\!$

Where

$-\frac{\pi}{2}\le y \le \frac{\pi}{2}$

Then

$\sin y=x\,\!$

Using implicit differentiation and solving for dy/dx:

${d \over dx}\sin y={d \over dx}x$
${dy \over dx}\cos y=1\,\!$

Substituting $\cos y = \sqrt{1-\sin^2 y}$ in from above,

${dy \over dx}\sqrt{1-\sin^2 y}=1$

Substituting $x=\sin y$ in from above,

${dy \over dx}\sqrt{1-x^2}=1$
${dy \over dx}=\frac{1}{\sqrt{1-x^2}}$

Differentiating the inverse cosine function

We let

$y=\arccos x\,\!$

Where

$0 \le y \le \pi$

Then

$\cos y=x\,\!$

Using implicit differentiation and solving for dy/dx:

${d \over dx}\cos y={d \over dx}x$
$-{dy \over dx}\sin y=1$

Substituting $\sin y = \sqrt{1-\cos^2 y}\,\!$ in from above, we get

$-{dy \over dx}\sqrt{1-\cos^2 y} =1$

Substituting $x=\cos y\,\!$ in from above, we get

$-{dy \over dx}\sqrt{1-x^2} =1$
${dy \over dx} = -\frac{1}{\sqrt{1-x^2}}$

Differentiating the inverse tangent function

We let

$y=\arctan x\,\!$

Where

$-\frac{\pi}{2} < y < \frac{\pi}{2}$

Then

$\tan y=x\,\!$

Using implicit differentiation and solving for dy/dx:

${d \over dx}\tan y={d \over dx}x$

Left side:

${d \over dx}\tan y = {d \over dx}\frac{\sin y}{\cos y} = \frac{{dy \over dx} \cos^2 y + \sin^2 y {dy \over dx}}{\cos^2 y} = {dy \over dx} \left (1 + \tan^2 y \right)$

Right side:

${d \over dx}x = 1$

Therefore

${dy \over dx}(1+\tan^2 y)=1$

Substituting $x=\tan y\,\!$ in from above, we get

${dy \over dx}(1+x^2)=1$
${dy \over dx}=\frac{1}{1+x^2}$

Differentiating the inverse cotangent function

We let

$y=\arccot x\,\!$

Where

$0 < y < \pi$

Then

$\cot y=x\,\!$

Using implicit differentiation and solving for dy/dx:

${d \over dx}\cot y={d \over dx}x$
${dy \over dx}-\csc^2 y=1$

Substituting $1+\cot^2 y = \csc^2 y\,\!$ into the above,

${dy \over dx}-(1+\cot^2 y)=1$

Substituting $x=\cot y\,\!$ in from above, we get

${dy \over dx}-(1+x^2)=1$
${dy \over dx}=-\frac{1}{1+x^2}$