So, $A$ is defined on a Hilbert space $X$ and all of its eigenvalues are non-negative. Show that $\langle Ax,x \rangle \geq 0, \forall x \in X $.
My attempt so far: Since $A$ is compact and Hermitian, we can invoke the Spectral theorem and have $Ax = \sum \lambda_i \langle x, e_i \rangle e_i$ for an appropriate orthonormal sequence $[e_i]$. Now, forming $\langle Ax,x \rangle $ we have: $$\langle Ax,x \rangle = \Big \langle \sum \lambda_i \langle x, e_i \rangle e_i, x \Big\rangle = \sum \lambda_i \langle x,e_i\rangle \langle e_i,x \rangle $$ Now the third term in the RHS, i.e., $\langle e_i,x \rangle $, is causing trouble, since if the order of terms in it were reversed, then the proof would have been complete. But, now with $\langle e_i,x \rangle = \overline{\langle x,e_i \rangle } $, how can I get from $\lambda_i \geq 0$ to $\langle Ax,x \rangle \geq 0 $? (The Hermitian property does not seem to be helpful either, as forming $\langle x, Ax\rangle $ would recreate a similar result.)
On the contrary - it's exactly the way you want it.
Which yields $ \langle x, e_i \rangle \langle e_i, x \rangle = \langle x, e_i \rangle \overline{\langle x, e_i \rangle} = |\langle x, e_i \rangle|^2 \ge 0$.
You are now done because every term in the sum is nonnegative.
On the other hand, having $\langle x, e_i \rangle^2$ would not have helped, since the square of a complex number does not have to be nonnegative.