# Find $$\frac {dy}{dx}$$ in the following: $$sin^2y + cos \: xy = k$$

Toolbox:
• For equations that are not of the form $y = f(x)$, we need to differentiate each term separately on LHS and RHS and then calculate $\large \frac{dy}{dx}$
• $\; \large \frac{d(sin^2x)}{dx} $$= 2\;sinx\;cosx = sin\;2x Given sin^2y + cos \: xy = k This is not a standard differentiation of the form y = f(x). We need to differentiate each term separately on LHS and RHS and then calculate \large \frac{dy}{dx} \textbf{Step 1}: Let us first calculate \; \large \frac{d(\cos xy)}{dx} , we'll apply the chain rule, with g=xy According to the Chain Rule for differentiation, given two functions f(x) and g(x), and y=f(g(x)) \rightarrow y' = f'(g(x)).g'(x). \Rightarrow g' = x\;dy+y\;dx \Rightarrow f'(g) = -\sin xy \Rightarrow d(\cos xy) = f'(g).g' = -\sin xy. (x\;dy+y\;dx) \textbf{Step 2}: We know that \; \large \frac{d(sin^2y)}{dy}$$=\sin \;2y$
Therefore, if we differentiate both sides, we get:
$\Rightarrow \sin 2y \; dy -\sin xy. (x\;dy+y\;dx) = 0$
$\Rightarrow (\sin 2y \; -x\;\sin xy) \;dy = y\; \sin xy\;dx$
$\Rightarrow \large \frac{dy}{dx}= \frac{y\;\sin xy}{\sin 2y - x\;\sin\;xy}$