I'm trying to find the sign of the eigenvalues of a certain $n\times n$ symmetric matrix $M$. I know that i can write this matrix as $$M = PDP^T,$$
with $D$ $p\times p $ diagonal with positive or null entries, and $P$ a $n \times p$ matrix. Can I conclude that the eigenvalues of $M$ are positive or null ?
For all $x\in\mathbb{R}^n$,
$$\langle x, Mx\rangle=\langle x, PDP^T x\rangle=\langle P^T x, DP^T x\rangle=\langle D^{1/2} P^T x, D^{1/2} P^T x\rangle\ge 0.$$
So all eigenvalues of $M$ are nonnegative.