The Mean and Variance of the Chi-Squared Distribution
Formula
If $X \sim \chi^{2} (r)$ then $$ E(X) = r \\ \operatorname{Var} (X) = 2r $$
Derivation
Strategy: Fortunately, the moment generating function of the chi-squared distribution is known.
Moment of the chi-squared distribution: Let’s say $X \sim \chi^{2} (r)$. If $k > - r/ 2$, then there exists the $k$th moment $$ E X^{k} = {{ 2^{k} \Gamma (r/2 + k) } \over { \Gamma (r/2) }} $$
Mean
$$ EX^{1} = {{ 2^{1} \Gamma (r/2 + 1) } \over { \Gamma (r/2) }} = 2 \cdot {{ r } \over { 2 }} = r $$
■
Variance
$$ EX^{2} = {{ 2^{2} \Gamma (r/2 + 2) } \over { \Gamma (r/2) }} = 4 \cdot {{ r + 2 } \over { 2 }} \cdot {{ r } \over { 2 }} = r^{2} + 2r $$ Therefore, $$ \operatorname{Var}(X) = \left( r^{2} + 2r \right) - r^{2} = 2r $$
■