# Different Formula for Variance & Standard Deviation

The formula for Variance:

${\sigma ^2} = \frac{{\sum\limits_{i = 1}^n {{{\left( {{X_i} – \bar X} \right)}^2}} }}{n}$

It can also be written as follows:

${\sigma ^2} = \frac{{\sum {\left( {X_i^2 – 2\bar X{X_i} + {{\bar X}^2}} \right)} }}{n}$

$or,\,\,\,{\sigma ^2} = \frac{{\sum {X_i^2} – 2\bar X\sum {{X_i}} + n{{\bar X}^2}}}{n}$

$or,\,\,\,{\sigma ^2} = \frac{{\sum {X_i^2} }}{n} – 2\bar X\bar X + \bar X\bar X$

$or,\,\,\,{\sigma ^2} = \frac{{\sum {X_i^2} }}{n} – \bar X\bar X$

$\therefore \,\,\,{\sigma ^2} = \frac{{\sum {X_i^2} }}{n} – {\left( {\frac{{\sum {{X_i}} }}{n}} \right)^2}$