How can I tell which function to use on which matrix to get the signs correct?
Read here for an explanation to the above question.
I am taking a linear algebra college class. We are learning about Eigenvalues where we have a square matrix:
$\begin{bmatrix}4&0&1\\-2&1&0\\-2&0&1\end{bmatrix}$
The textbook provides the function $\det(\lambda I-A)=0$ to find the characteristic function from which I can retrieve the eigenvalues. I used this on the matrix above but I ended up with a polynomial but with the opposite signs. EX: $\lambda^3 - 6\lambda^2 + 11\lambda - 6$ instead of $-\lambda^3 + 6\lambda^2 - 11\lambda + 6$ (I have been checking my answer with an online eigenvalue calculator).
I found a variation of this function on the Internet in the form of: $\det(A-\lambda I)=0$. Using this function give the same values as $\det(\lambda I-A)=0$ except the signs are opposite, and correct for this matrix.
How can I tell which function to use on which matrix to get the signs correct?
Since $A-\lambda I=-(\lambda I-A)$, we have $$ \det(A-\lambda I)=\det\bigl(-(\lambda I-A)\bigr)= (-1)^n\det(\lambda I-A) $$ where $n$ is the number of rows of the matrix $A$. Thus the roots are the same and it's immaterial which one to use.