Variance of a sum (source code)

= Variance of a sum

For square-integrable random variables,
$$
\operatorname{Var}\left(\sum_iX_i\right)
=\sum_i\sum_j\operatorname{Cov}(X_i,X_j).
$$