Why is the determinant of $\sum_{i=1}^n A_i^2$ non-negative? 
Let $A_i$ be an $n\times n$ matrix in $\mathbb{R}$ and $\{A_i\}_{i=1}^k$ are pairwise commutative: $A_iA_j = A_jA_i$. How to show $det(\sum_{i=1}^k A_i^2)\geq 0$?

We may consider this question in the complex field $\mathbb{C}$. Each $A_i$ is triangulable. Since they are commutative , there exists $P\in GL_n(\mathbb{C})$ such that $\{A_i\}_{i=1}^k$ are simultaneously triangluated. Say $B_i = P^{-1}A_iP$ is upper triangular. Denote the $(j,j)$-th element in $B_i$ by $b_{i,j}$. Thus, $det(\sum_{i=1}^k A_i^2) = det(\sum_{i=1}^k B_i^2) = \prod_{j=1}^n\sum_{i=1}^k b_{i,j}^2$. But how to show this value is always non-negative?
Indeed, I don't know how the "pairwise commutative" condition helps here. Many thanks.
 A: It is true. cf. http://www.artofproblemsolving.com/community/c7h274989
Specially see posts 1,12,13,14. The proof comes essentially from "Yury".
EDIT for Yuval. (The following proof, for $k=3$ matrices $A,B,C$, by Yury, can be easily generalized for any $k$) 
Proof. Assume the contrary. Consider the smallest $ n$ for which the statement is false; consider the corresponding counterexample. Observe that $ A$, $ B$ and $ C$ don't have a common non-trivial invariant (real) subspace. Indeed, assume that $ U$ is an invariant subspace. Denote the restrictions of $ A$, $ B$, $ C$ to $ U$ by $ A_U$, $ B_U$, $ C_U$. Note that since $ U$ is an invariant subspace for $ A$, $ B$, $ C$, they act on the quotient space $ V/U$ (here $ V$ is the whole space). We have 
$\det(A^2 + B^2 + C^2) = \det(A^2_U + B^2_U + C^2_U)\det(A^2_{V/U} + B^2_{V/U} +C^2_{V/U})$.
But since $ \dim U < n$ and $ \dim V/U <n$, both determinants in the righ-hand side are non-negative.
Now consider the ring of fractions $ \cal A$ generated by $ I$, $ A$, $ B$ and $ C$. First of all, $ \cal A$ is a commutative associative algebra of linear operators. Consider a non-zero element $ X$ of $ \cal A$; $ \ker X$ is an invariant subspace for $ A$, $ B$ and $ C$, thus $ \ker X$ is trivial. That is, $ X$ is non-singular. We conclude that $ \cal A$ is a commutative division algebra. Thus $ \cal A\simeq \mathbb R$ or $ \cal A\simeq \mathbb C$ ( [url]http://en.wikipedia.org/wiki/Frobenius_theorem_(real_division_algebras)[/url] ). In the former case,  $ n=1$ and the statement trivially holds. In the latter case, $ n=2$, operators $ A$, $ B$, $ C$ are of the form 
$ \begin{pmatrix} a& -b\\b&a\end{pmatrix}$.
The sum of their squares also has this form. The determinant is $ a^2+b^2 \geq 0$.
