<s>[INST] Find all real numbers $t$ such that the quadratic form $f$ is positive definite. Where $$f(x_1,x_2,x_3)=2x_1^2+x_2^2+3x_3^2+2tx_1x_2+2x_1x_3$$.
This is a problem in my Matrix Analysis homework. Below is my effort.

Let $x=(x_1,x_2,x_3)^T$, then we have $$f=x^*Sx$$, in which $$S=\left(\begin{matrix}2&t&1\\t&1&0\\1&0&3\end{matrix}\right)$$. $f$ is positive definite is equivalent to $S$ is positive definite which is equivalent to all the eigenvalues of $S$ is positive.
The characteristic polynomial of $S$ is: $$\begin{align}|\lambda I-S|&=-\lambda^3+6\lambda^2+(3t^2-10)\lambda+(-3t^2+5)\\&=(-3+3\lambda)t^2+(-\lambda^3+6\lambda^2-10\lambda+5)\end{align}$$.
Now the only problem left is that how do I find all the possible real values of $t$ that makes this polynomial of $\lambda$ only has positive roots?
 [/INST] We can solve it writing $x^tSx$ as a sum of squares. We have 
\begin{align}
x^tSx&=(x_2+tx_1)^2-t^2x_1^2+2x_1^2+3x_3^2+2x_1x_3\\
&=(x_2+tx_1)^2+3\left(x_3^2+\frac 23x_1x_3\right)+(2-t^2)x_1^2\\
&=(x_2+tx_1)^2+3\left(x_3+\frac{x_1}3\right)^2-3\frac{x_1^2}9+(2-t^2)x_1^2\\
&=(x_2+tx_1)^2+3\left(x_3+\frac{x_1}3\right)^2+\left(\frac 53-t^2\right)x_1^2.
\end{align}
</s>