# Differentiate the following functions with respect to x :

Question:

Differentiate the following functions with respect to $x$ :

$\frac{3 x^{2} \sin x}{\sqrt{7-x^{2}}}$

Solution:

Let $y=\frac{3 x^{2} \sin x}{\sqrt{7-x^{2}}}$

On differentiating $y$ with respect to $x$, we get

$\frac{d y}{d x}=\frac{d}{d x}\left(\frac{3 x^{2} \sin x}{\sqrt{7-x^{2}}}\right)$

$\Rightarrow \frac{d y}{d x}=3 \frac{d}{d x}\left(\frac{x^{2} \sin x}{\sqrt{7-x^{2}}}\right)$

Recall that $\left(\frac{\mathrm{u}}{\mathrm{v}}\right)^{\prime}=\frac{\mathrm{vu}^{\prime}-\mathrm{uv}^{\prime}}{\mathrm{v}^{2}}$ (quotient rule)

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\sqrt{7-x^{2}} \frac{d}{d x}\left(x^{2} \sin x\right)-\left(x^{2} \sin x\right) \frac{d}{d x}\left(\sqrt{7-x^{2}}\right)}{\left(\sqrt{7-x^{2}}\right)^{2}}\right]$

We have (uv)' $=v u^{\prime}+u v^{\prime}$ (product rule)

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\sqrt{7-x^{2}}\left(\sin x \frac{d}{d x}\left(x^{2}\right)+x^{2} \frac{d}{d x}(\sin x)\right)-\left(x^{2} \sin x\right) \frac{d}{d x}\left(\left(7-x^{2}\right)^{\frac{1}{2}}\right)}{7-x^{2}}\right]$

We know $\frac{d}{d x}(\sin x)=\cos x$ and $\frac{d}{d x}\left(x^{n}\right)=n x^{n-1}$

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\sqrt{7-x^{2}}\left(\sin x(2 x)+x^{2}(\cos x)\right)-\left(x^{2} \sin x\right) \frac{1}{2}\left(7-x^{2}\right)^{\frac{1}{2}-1} \frac{d}{d x}\left(-x^{2}\right)}{7-x^{2}}\right]$

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\sqrt{7-x^{2}}\left(2 x \sin x+x^{2} \cos x\right)+\frac{x^{2}}{2}\left(7-x^{2}\right)^{-\frac{1}{2}} \sin x \frac{d}{d x}\left(x^{2}\right)}{7-x^{2}}\right]$

However, $\frac{\mathrm{d}}{\mathrm{dx}}\left(\mathrm{x}^{2}\right)=2 \mathrm{x}$

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\left(2 x \sin x+x^{2} \cos x\right)\left(7-x^{2}\right)^{\frac{1}{2}}+x^{3} \sin x\left(7-x^{2}\right)^{-\frac{1}{2}}}{7-x^{2}}\right]$

$\Rightarrow \frac{d y}{d x}=3\left[\frac{\left(2 x \sin x+x^{2} \cos x\right)\left(7-x^{2}\right)^{\frac{1}{2}}}{7-x^{2}}+\frac{x^{3} \sin x\left(7-x^{2}\right)^{-\frac{1}{2}}}{7-x^{2}}\right]$

$\Rightarrow \frac{d y}{d x}=3\left[\frac{2 x \sin x+x^{2} \cos x}{\left(7-x^{2}\right)^{\frac{1}{2}}}+\frac{x^{3} \sin x}{\left(7-x^{2}\right)^{\frac{3}{2}}}\right]$

$\Rightarrow \frac{d y}{d x}=\frac{3 x}{\left(7-x^{2}\right)^{\frac{1}{2}}}\left[2 \sin x+x \cos x+\frac{x^{2} \sin x}{7-x^{2}}\right]$

$\therefore \frac{d y}{d x}=\frac{3 x}{\sqrt{7-x^{2}}}\left(2 \sin x+x \cos x+\frac{x^{2} \sin x}{7-x^{2}}\right)$

Thus, $\frac{d}{d x}\left(\frac{3 x^{2} \sin x}{\sqrt{7-x^{2}}}\right)=\frac{3 x}{\sqrt{7-x^{2}}}\left(2 \sin x+x \cos x+\frac{x^{2} \sin x}{7-x^{2}}\right)$