---
tag: 007QED3E0Y
kind: definition
name: Variance
msc: [60A05]
defines: 0477R9PYAE
uses: [0DCT0QZVQ1, 0DKRR22AEQ]
sources:
  - url: https://en.wikipedia.org/wiki/Variance
    locator: Definition
---

## Definition

Let $X$ be an integrable real [[random variable|0DKRR22AEQ]] with mean $\mu = E[X]$.
The variance of $X$ is
$$\operatorname{Var}(X) = E\left[(X - \mu)^2\right] \in [0, \infty].$$

## Remarks

Other notations are $\operatorname{V}(X)$, $\sigma^2$ and $\sigma_X^2$. The variance is finite if and only if $E[X^2] < \infty$.
For a discrete $X$ with values $x_i$, $\operatorname{Var}(X) = \sum_i (x_i - \mu)^2 P(X = x_i)$. For $X$ with density $f$, $\operatorname{Var}(X) = \int (x - \mu)^2 f(x) \, dx$.
$\operatorname{Var}(X) = 0$ if and only if $X = \mu$ almost surely.
For a fair die, $\mu = 7/2$ and $\operatorname{Var}(X) = 35/12$.

## Explanations

### L1 human

The variance tells how far, on average, the values of $X$ are from the mean. The distances are squared, so that large deviations count more and positive and negative deviations do not cancel.
Its square root, the standard deviation, is in the same units as $X$.
