# If random variable X has a probability density function of f(x)=1/x on the interval[e,e^2], what is the standard deviation of X?

Jul 22, 2016

$3.3361599515537$

#### Explanation:

if the PDF of $x$ is $f \left(x\right) = \frac{1}{x}$ on the interval of $\left[e , {e}^{2}\right]$ then ${\int}_{e}^{{e}^{2}} f \left(x\right) \mathrm{dx} = 1$

The expected standard deviation is given by

$E \left[\sigma\right] = \sqrt{{\int}_{e}^{{e}^{2}} {\left(x - \mu\right)}^{2} f \left(x\right) \mathrm{dx}}$

$= \sqrt{{\int}_{e}^{{e}^{2}} \frac{{x}^{2} - 2 x \mu + {\mu}^{2}}{x} \mathrm{dx}}$

the integral being
${x}^{2} / 2 - 2 \mu x + {\mu}^{2} \ln \left(x\right)$

and
$E \left[\sigma\right] = \sqrt{\frac{{e}^{4} - {e}^{2}}{2} + {\mu}^{2} + 2 \mu - 2 {\mu}^{2}}$

now we need to solve for $\mu$ and we shall have our final answer

$E \left[\mu\right] = {\int}_{e}^{{e}^{2}} x f \left(x\right) \mathrm{dx}$

$= {\int}_{e}^{{e}^{2}} \frac{1}{x} \cdot x \mathrm{dx}$

$= {e}^{2} - e = 4.6707742704716$

$E \left[\sigma\right] = 3.3361599515537$