MathLabs
TheoremProved

The Variance Shortcut Formula

Statement

For any random variable XX with finite mean, Var(X)=E[X2]−E[X]2\mathrm{Var}(X) = E[X^2] - E[X]^2.

Why is it true?

The definition of variance involves squaring a difference, which is awkward to compute directly; expanding that square and using linearity of expectation turns it into two easy quantities, E[X2]E[X^2] and E[X]E[X], that we already know how to compute.

Proof sketch

By definition, Var(X)=E[(X−μ)2]\mathrm{Var}(X) = E[(X-\mu)^2] where μ=E[X]\mu = E[X]. Expand the square inside the expectation: (X−μ)2=X2−2μX+μ2(X-\mu)^2 = X^2 - 2\mu X + \mu^2.

Apply linearity of expectation term by term: E[(X−μ)2]=E[X2]−2μE[X]+μ2E[(X-\mu)^2] = E[X^2] - 2\mu E[X] + \mu^2. Since μ\mu is a constant (it does not depend on the outcome), it can be pulled out of the expectation in the middle and last terms.

Now substitute E[X]=μE[X] = \mu back in: E[X2]−2μ⋅μ+μ2=E[X2]−2μ2+μ2=E[X2]−μ2E[X^2] - 2\mu\cdot\mu + \mu^2 = E[X^2] - 2\mu^2 + \mu^2 = E[X^2] - \mu^2. Replacing μ\mu with E[X]E[X] gives exactly Var(X)=E[X2]−E[X]2\mathrm{Var}(X) = E[X^2] - E[X]^2, as claimed.

Topics that use this theorem

Step-by-step proofs

No step-by-step proof yet for this theorem.

References

  1. Charles M. Grinstead, J. Laurie Snell (1997). Introduction to Probability
  2. Sheldon Ross (2019). A First Course in Probability