Linear Algebra - check my solution, product of symmetric positive-definite matrices We are given $A,B \in Mat_n(\mathbb R)$ are symmetric positive-definite matrices such that $AB=BA$
Show that $AB$ is positive-definite
What I did:
First I showed that $AB$ is symmetric, this is easily shown from $(AB)^t=B^tA^t=BA=AB$
Now I'm trying to think, why are the eigenvalues of $AB$ all positive? Just because the eigenvalues of $A$ and $B$ are positive does not imply that $AB$'s eigenvalues are.
However, from sylvester's criterion, we know that all the leading principal minors of $A$ and $B$ have a positive determinant, and since the determinant of the product is the product of the determinants, we can infer that every leading principal minor of $AB$ is positive. Proof:
$det(AB_{ii})=det(A_{ii})det(B_{ii}) \geq 0$ since $\forall i,  det(A_{ii}),det(B_{ii}) \geq 0$
So $AB$ is a symmetric matrix where every leading principal minor has a positive determinant, and so $AB$ is indeed positive-definite.
This is kind of a roundabout way of solving it, is there a way of actually showing the eigenvalues of $AB$ are positive? Did my solution even make sense?
 A: $AB=BA$ is a interesting condition. Let $v$ be an eigenvector of $A$ such that $Av=\lambda v$. Then $A(Bv)=B(Av)=B(\lambda v)=\lambda(Bv)$. This implies that the eigenvector space $V_{\lambda}$ of $A$ is invariant space of $B$. Now we can find all eigenvalues of $B$ on $V_{\lambda}$. Take the basis of $V_{\lambda}'s$ for both $A$ and $B$, you will find what you need.
A: It is not true that $\det(AB)_{ii}=\det A_{ii}\det B_{ii}$ as the following example shows $A=B=\begin{pmatrix}2&1\\1&1\end{pmatrix}$, so $AB=\begin{pmatrix}5&3\\3&2\end{pmatrix}$ and $\det(AB)_{11}=5\neq 2\cdot2=\det(A_{11})\det(B_{11})$
So your argument has a gap.
Try to use the Spectral Theorem.
A: More generally, if $A,B$ are any real $n\times n$ matrices s.t. $AB=BA$ and $A,B$ have only positive eigenvalues, then $A+B$ and $AB$ have positive eigenvalues.
Proof: The $2$ conditions imply that $A,B$ are simultaneously triangularizable over $\mathbb{R}$. Then we may assume that they are upper-triangular with positive diagonals and we are done.
