# Variance of the Norm of a Gaussian Random Vector

If $$\mathbf{X} \sim \mathcal{N}_N(\mathbf{m}, \mathbf{C})$$ is an $$N$$-dimensional gaussian vector, where $$\mathbf{m} \in \mathbb{R}^N$$ and $$\mathbf{C} \in \mathbb{R}^{N \times N}$$, what is the variance of $$Y=\|\mathbf{X}\|^2$$ where $$\|\cdot\|$$ denotes the $$L_2$$-norm (Euclidean norm) ?

As pointed out by this question, $$Y$$ has a generalised chi-squared distribution and its mean can be obtained easily. However, I want to know what is its variance. Can anybody please give some help?

• Using this, the variance is $\operatorname{Var}(\mathbf X^T \mathbf X)=2\operatorname{tr}(\mathbf C^2)+4\mathbf m^T \mathbf C \mathbf m$. Jun 29, 2023 at 13:43
• @StubbornAtom Thanks for your reply! But do you know what is the mean and variance of the norm without squaring, i.e., $Y=\|\mathbf{X}\|$. Jun 30, 2023 at 10:23
• No. Check stats.stackexchange.com/q/144893/119261. Jun 30, 2023 at 15:22

Since $$\mathrm{Var}(Y) = \mathbb{E} Y^2 - (\mathbb{E} Y)^2$$ and the latter is known, it boils down to computing $$\mathbb{E} Y^2$$. Now $$Y^2 = (\sum_{i=1}^N X_i^2)^2 = \sum_{i=1}^N X_i^4 + \sum_{i \ne j} X_i^2 X_j^2$$, so $$\mathbb{E} Y^2 = \sum_{i=1}^N \mathbb{E} X_i^4 + \sum_{i \ne j} \mathbb{E} X_i^2 X_j^2$$. By putting in formulas for $$\mathbb{E} X_i^4$$ and $$\mathbb{E} X_i^2 X_j^2$$ using the fact $$X \sim N(m, C)$$ (the formulas for the moments on Wikipedia for the normal distribution and the multivariate version might be helpful), you would be done after some hard algebraic work. For example, if we take $$m = 0$$ for simplicity, then $$\mathbb{E} X_i^4 = 3 C_{ii}^2$$ and $$\mathbb{E} X_i^2 X_j^2 = C_{ii} C_{jj} + 2 C_{ij}^2$$.
• I suppose $Y^2=\left(\sum_{i=1}^N X_i^2\right)^2=\sum_{i=1}^N X_i^4+2\sum_{i \neq j} X_i^2 X_j^2$? Jun 30, 2023 at 9:04
• The notation $\sum_{i,j} X_i^2 X_j^2$ means we sum over all distinct pairs $(i, j)$, where order matters. E.g. we sum $X_1^2 X_2^2$ and $X_2^2 X_1^2$. If you like having a factor of $2$, then it is the same as $2 \sum_{1 \leq i < j \leq N} X_i^2 X_j^2$ (note that this is different to what you wrote).
• Thanks for your answer! BTW, do you know what is the mean and variance of the norm without squaring, i.e., $Y=\|\mathbf{X}\|$? Jun 30, 2023 at 10:24
$$X\sim m+C^{1/2}Z$$ where $$Z\sim N(0,I_n).$$ Write $$C=U^TD^2U$$ where $$U$$ is orthogonal and $$D=\mathrm{diag}(c_1,\ldots,c_n).$$ Since $$UZ\sim Z$$ we have $$X\sim m+DZ.$$ Denote $$c=(c_1,\ldots,c_n)$$ and $$mc=(m_1c_1,\ldots,m_nc_n).$$ Therefore $$Y\sim \|m\|^2+2\langle m,DZ \rangle +\|DZ\|^2=\|m\|^2+2\langle mc,Z \rangle +\|DZ\|^2$$ which implies $$E(Y)=\|m\|^2+0+\|c\|^2=\|m\|^2+\mathrm{trace }\, C.$$ Next $$E(Y^2)= E\left((\|m\|^2+2\langle mc,Z \rangle +\|DZ\|^2)^2\right)=\|m\|^4+\|mc\|^2+2\|m\|^2\|c\|^2+E(\|DZ\|^4)$$ since the odd term $$\langle mc,Z \rangle \times \|DZ\|^2$$ has expectation $$0.$$ We are left with the calculation of $$E(\|DZ\|^4)=3\sum_{i=1}^nc_i^4+2\sum_{i Finally (please check, I could have make mistakes)$$\sigma^2(Y)=\|mc\|^2+2\, \mathrm{trace }\, C^2.$$