# How do you implicitly differentiate -1=xycot^2(x-y) ?

Feb 24, 2017

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) - y {\cot}^{2} \left(x - y\right)}{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)}$

#### Explanation:

When we differentiate $y$ wrt $x$ we get $\frac{\mathrm{dy}}{\mathrm{dx}}$.

However, we cannot differentiate a non implicit function of $y$ wrt $x$. But if we apply the chain rule we can differentiate a function of $y$ wrt $y$ but we must also multiply the result by $\frac{\mathrm{dy}}{\mathrm{dx}}$.

When this is done in situ it is known as implicit differentiation.

We have:

$- 1 = x y {\cot}^{2} \left(x - y\right)$

Differentiate wrt $x$ (applying triple product rule):

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

$\therefore 0 = \left(x\right) \left(y\right) \left(2 \cot \left(x - y\right) \left(- {\csc}^{2} \left(x - y\right)\right) \left(1 - \frac{\mathrm{dy}}{\mathrm{dx}}\right)\right) + \left(x\right) \left(\frac{\mathrm{dy}}{\mathrm{dx}}\right) \left({\cot}^{2} \left(x - y\right)\right) + \left(1\right) \left(y\right) \left({\cot}^{2} \left(x - y\right)\right)$

$\therefore 0 = - 2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) \left(1 - \frac{\mathrm{dy}}{\mathrm{dx}}\right) + x \frac{\mathrm{dy}}{\mathrm{dx}} {\cot}^{2} \left(x - y\right) + y {\cot}^{2} \left(x - y\right)$

 :. 2xycot(x-y)csc^2(x-y)dy/dx + xdy/dx(cot^2(x-y) = 2xycot(x-y)csc^2(x-y) - ycot^2(x-y)

$\therefore \left\{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)\right\} \frac{\mathrm{dy}}{\mathrm{dx}} = 2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) - y {\cot}^{2} \left(x - y\right)$

$\therefore \frac{\mathrm{dy}}{\mathrm{dx}} = \frac{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) - y {\cot}^{2} \left(x - y\right)}{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)}$

There is another (often faster) approach using partial derivatives. Suppose we cannot find $y$ explicitly as a function of $x$, only implicitly through the equation $F \left(x , y\right) = 0$ which defines $y$ as a function of $x , y = y \left(x\right)$. Therefore we can write $F \left(x , y\right) = 0$ as $F \left(x , y \left(x\right)\right) = 0$. Differentiating both sides of this, using the partial chain rule gives us

 (partial F)/(partial x) (1) + (partial F)/(partial y) dy/dx = 0 => dy/dx = −((partial F)/(partial x)) / ((partial F)/(partial y))

So Let $F \left(x , y\right) = x y {\cot}^{2} \left(x - y\right) + 1$; Then using the product rule;

$\frac{\partial F}{\partial x} = \left(x y\right) \left(\frac{\partial}{\partial x} {\cot}^{2} \left(x - y\right)\right) + \left(\frac{\partial}{\partial x} x y\right) \left({\cot}^{2} \left(x - y\right)\right)$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus = \left(x y\right) \left(2 \cot \left(x - y\right) \left(- {\csc}^{2} \left(x - y\right)\right)\right) + \left(y\right) \left({\cot}^{2} \left(x - y\right)\right)$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus = - 2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + y {\cot}^{2} \left(x - y\right)$

$\frac{\partial F}{\partial x} = \left(x y\right) \left(\frac{\partial}{\partial y} {\cot}^{2} \left(x - y\right)\right) + \left(\frac{\partial}{\partial y} x y\right) \left({\cot}^{2} \left(x - y\right)\right)$
 \ \ \ \ \ \ \ = (xy)(2cot(x-y)(-csc^2(x-y)(-1)) + (x)(cot^2(x-y))
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus = 2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)$

And so:

$\frac{\mathrm{dy}}{\mathrm{dx}} = - \frac{- 2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + y {\cot}^{2} \left(x - y\right)}{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)}$

$\setminus \setminus \setminus \setminus \setminus = \frac{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) - y {\cot}^{2} \left(x - y\right)}{2 x y \cot \left(x - y\right) {\csc}^{2} \left(x - y\right) + x {\cot}^{2} \left(x - y\right)}$

Here we get an immediate implicit function for the derivative, so here if you are familiar with partial differentiation the solution is much easier