# Math Help - Expected Value and Variance

1. ## Expected Value and Variance

I need some help on this:

E(X)=(1/(sigma(sqrt (2pi))) ∫(-infinity to infinity) xexp(-(x-m)^2/(2sigma^2)dx

Show E(X)=m.

I know to add and subtract m to the first x, but I don't know where to go from there.

Thanks for any help.

2. Originally Posted by taypez
I need some help on this:

E(X)=(1/(sigma(sqrt (2pi))) ∫(-infinity to infinity) xexp(-(x-m)^2/(2sigma^2)dx

Show E(X)=m.

I know to add and subtract m to the first x, but I don't know where to go from there.

Thanks for any help.
Make the substitution $u = \frac{x-m}{\sigma \sqrt{2}}$.

After the appropriate substitutions and simplifying you should get:

$E(X) = \frac{1}{\sqrt{pi}} \int_{-\infty}^{+\infty} \sigma \, \sqrt{2} \, u \, e^{-u^2} + m e^{-u^2} \, du$.

The integral of the first bit is zero because $u \, e^{-u^2}$ is odd.

So $E(X) = \frac{m}{\sqrt{\pi}} \int_{-\infty}^{+\infty} e^{-u^2} \, du = m$.