# Thread: [SOLVED] proving a theorem regarding expected value

1. ## [SOLVED] proving a theorem regarding expected value

prove that $\displaystyle E[X-E(X)]^2 = E(X^2)-[E(X)]^2$

2. Originally Posted by takeyourmark
prove that $\displaystyle E[X-E(X)]^2 = E(x^2)-[E(x)]^2$
$\displaystyle E\left( {\left[ {X - E(X)} \right]^2 } \right) = E\left( {X^2 - 2XE\left( X \right) + E^2 \left( X \right)} \right)$$\displaystyle = E\left( {X^2 } \right) - 2E\left( X \right)E\left( X \right) + E^2 \left( X \right) = E\left( {X^2 } \right) - E^2 \left( X \right)$