# How do you find the derivative of cot x?

In a right-angled triangle, the cotangent of an angle is defined as the ratio of the length of the adjacent side to the length of the side opposite of the angle.

### Answer: Derivative of cot x is −cosec^{2}x

We can proceed step by step to find the derivative.

**Explanation:**

As per trigonometric identities, cot x can also be written as cosx / sinx ------- (i)

Now we can use quotient rule of differentiation to find the derivative of cot x.

d cotx/ dx = d(cosx / sinx)/dx

Quotient rule: d (uv)/ dx ={ ( vdu / dx− udv / dx) / v^{2}}

Here u = cos x, v = sin x

d(cosx / sinx)/dx = [(d (cos x)/dx)sin x − cosx (d(sin x)/ dx )] / sin^{2}x -------- (ii)

We can substitute the formulae for the derivatives of sin x and cos x given by

d(cos x) /dx = −sin x and d(sin x)/dx = cos x

On putting the above values in equation (ii), we get

d(cot x)/dx = {−sin x sin x − cos x cos x } / sin^{2}x

= - (sin^{2}x + cos^{2}x) / sin^{2}x

= −1 / sin^{2}x

= −(cosec^{2}x)

⇒ d(cotx)/dx = −(cosec^{2}x)