# How do you differentiate f(x)=cot(4x-x^2)  using the chain rule?

Jun 5, 2016

$\frac{d}{\mathrm{dx}} \left(\cot \left(4 x - {x}^{2}\right)\right) = - \frac{- 2 x + 4}{{\sin}^{2} \left(4 x - {x}^{2}\right)}$

#### Explanation:

$\frac{d}{\mathrm{dx}} \left(\cot \left(4 x - {x}^{2}\right)\right)$
Applying chain rule,$\frac{\mathrm{df} \left(u\right)}{\mathrm{dx}} = \frac{\mathrm{df}}{\mathrm{du}} \cdot \frac{\mathrm{du}}{\mathrm{dx}}$
Let, $4 x - {x}^{2} = u$
$= \frac{d}{\mathrm{du}} \left(\cot \left(u\right)\right) \frac{d}{\mathrm{dx}} \left(4 x - {x}^{2}\right)$

We know,
$\frac{d}{\mathrm{du}} \left(\cot \left(u\right)\right) = - \frac{1}{{\sin}^{2} \left(u\right)}$
and,
$\frac{d}{\mathrm{dx}} \left(4 x - {x}^{2}\right) = 4 - 2 x$

So,
$= \left(- \frac{1}{{\sin}^{2} \left(u\right)}\right) \left(4 - 2 x\right)$

Substituting back,$4 x - {x}^{2} = u$

$= \left(- \frac{1}{{\sin}^{2} \left(4 x - {x}^{2}\right)}\right) \left(4 - 2 x\right)$

Simplifying it,
$- \frac{- 2 x + 4}{{\sin}^{2} \left(4 x - {x}^{2}\right)}$