Differentiate
$\left(\frac{\sin x-\cos x}{\sin x+\cos x}\right)$
To find: Differentiation of $\left(\frac{\sin x-\cos x}{\sin x+\cos x}\right)$
Formula used: (i) $\left(\frac{u}{v}\right)^{\prime}=\frac{u^{\prime} v-u v^{\prime}}{v^{2}}$ where $v \neq 0$ (Quotient rule)
(ii) $\frac{d \sin x}{d x}=\cos x$
(iii) $\frac{d \cos x}{d x}=-\sin x$
Let us take $u=(\sin x-\cos x)$ and $v=(\sin x+\cos x)$
$u^{\prime}=\frac{d u}{d x}=\frac{d(\sin x-\cos x)}{d x}=(\cos x+\sin x)$
$v^{\prime}=\frac{d v}{d x}=\frac{d(\sin x+\cos x)}{d x}=(\cos x-\sin x)$
Putting the above obtained values in the formula:-
$\left(\frac{u}{v}\right)^{\prime}=\frac{u^{\prime} v-u v^{\prime}}{v^{2}}$ where $v \neq 0$ (Quotient rule)
$\left[\frac{\sin x-\cos x}{\sin x+\cos x}\right]^{\prime}=\frac{(\cos x+\sin x) \times(\sin x+\cos x)-(\sin x-\cos x) \times(\cos x-\sin x)}{(\sin x+\cos x)^{2}}$
$=\frac{\sin ^{2} x+\cos ^{2} x+2 \sin x \cos x-(\sin x-\cos x) x-(\sin x-\cos x)}{(\sin x+\cos x)^{2}}$
$=\frac{\sin ^{2} x+\cos ^{2} x+2 \sin x \cos x+\sin ^{2} x+\cos ^{2} x-2 \sin x \cos x}{(\sin x+\cos x)^{2}}$
$=\frac{2\left(\sin ^{2} x+\cos ^{2} x\right)}{\sin ^{2} x+\cos ^{2} x+2 \sin x \cos x}$
$=\frac{2}{1+\sin 2 x}$
Ans) $=\frac{2}{1+\sin 2 x}$