TITLE: Waring's problem for matrices
QUESTION [9 upvotes]: Probably a well-know question, but I haven't solved it, so I'll ask.
I can show that every matrix in $M_2(\mathbb{R})$ is the sum of two squares of matrices in $M_2(\mathbb{R})$.
If $n>2$, I can also show that every matrix in $M_n(\mathbb{R})$ is the sum of three squares of matrices in $M_n(\mathbb{R})$.
So my question is : Is every matrix in $M_n(\mathbb{R})$ is the sum of two squares of matrices in $M_n(\mathbb{R})$ (n>2)?

REPLY [14 votes]: The answer is YES if $n$ is even.  But if $n$ is odd, then the answer is NO since $-I$ is not a sum of two squares.
See 
Griffin and Krusemeyer, Matrices as sums of squares, Linear and Multilinear Algebra 5 (1977/78), no. 1, 33-44
for the proofs of these facts and generalizations.