# How do you differentiate  f(x)=sqrt(ln(xe^x)) using the chain rule.?

##### 1 Answer
Dec 13, 2015

$\frac{1 + x}{2 x \sqrt{\ln \left(x {e}^{x}\right)}}$

#### Explanation:

The chain rule states that if you have two nested functions, where $f \left(x\right) = g \left(h \left(x\right)\right)$, the derivative is;

$f ' \left(x\right) = g ' \left(h \left(x\right)\right) \cdot h ' \left(x\right)$

When you have functions with many nested radicals, its often easiest to go through each function step by step.

$\frac{d}{\mathrm{dx}} \sqrt{\ln \left(x {e}^{x}\right)}$

The first function is the square root function. We can rewrite a square root as;

$\sqrt{f \left(x\right)} = f {\left(x\right)}^{\frac{1}{2}}$

Using the power rule;

$\frac{d}{\mathrm{dx}} f {\left(x\right)}^{\frac{1}{2}} = \frac{1}{2} f {\left(x\right)}^{- \frac{1}{2}} \cdot f ' \left(x\right)$

$= \frac{1}{2 f {\left(x\right)}^{\frac{1}{2}}} \cdot f ' \left(x\right)$

$= \frac{1}{2 \sqrt{f \left(x\right)}} \cdot f ' \left(x\right)$

Let $f \left(x\right) = \ln \left(x {e}^{x}\right)$.

$\frac{d}{\mathrm{dx}} \sqrt{\ln \left(x {e}^{x}\right)} = \frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{d}{\mathrm{dx}} \ln \left(x {e}^{x}\right)$

Next we look at the $\ln$. The derivative of $\ln \left(f \left(x\right)\right)$ is $1 \text{/} f \left(x\right) \cdot f ' \left(x\right)$.

$\frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{d}{\mathrm{dx}} \ln \left(x {e}^{x}\right) = \frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{1}{x {e}^{x}} \frac{d}{\mathrm{dx}} x {e}^{x}$

The last part of the derivative can be solved using the product rule.

$\frac{d}{\mathrm{dx}} f \left(x\right) g \left(x\right) = f ' \left(x\right) g \left(x\right) + f \left(x\right) g ' \left(x\right)$

Remember that $\frac{d}{\mathrm{dx}} {e}^{x} = {e}^{x}$.

$\frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{1}{x {e}^{x}} \frac{d}{\mathrm{dx}} x {e}^{x} = \frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{1}{x {e}^{x}} \left({e}^{x} + x {e}^{x}\right)$

We can simplify by canceling out all of the ${e}^{x}$ terms

$\frac{1}{2 \sqrt{\ln \left(x {e}^{x}\right)}} \frac{1}{x \textcolor{red}{\cancel{\textcolor{b l a c k}{{e}^{x}}}}} \left(\textcolor{red}{\cancel{\textcolor{b l a c k}{{e}^{x}}}} + x \textcolor{red}{\cancel{\textcolor{b l a c k}{{e}^{x}}}}\right) = \frac{1 + x}{2 x \sqrt{\ln \left(x {e}^{x}\right)}}$