# Find the characteristic polynomial of the matrix

Find the characteristic polynomial of the matrix : $A =$ $\begin{bmatrix} 5 & -2 & 0 \\ 0 & -1 & -2 \\ 3 & 2 & 0 \\ \end{bmatrix}$

$p(x) = ?$

So here's what I did :

$det(A-\lambda I)=0$ $=$ $\begin{bmatrix} 5-\lambda & -2 & 0 \\ 0 & -1-\lambda & -2 \\ 3 & 2 & 0-\lambda \\ \end{bmatrix}$

Which gave me

$(5-\lambda)(-1-\lambda)(-\lambda)+12+4(5-\lambda)$

$p(x)=-x^3+4x^2+x+32$

Unfortunalty this isn't the right answer (I'm working with an automated system that corrects my homework). I've went threw each step very carefully but cannot find where the mistakes is!

• By any chance, is $p(x) = x^3-4x^2-x-32$ the correct answer? If so, they may define $p(\lambda) = \det(\lambda I - A)$. – JimmyK4542 Jun 20 '15 at 2:05
• Wow what. that worked. May I ask how am I suppose to know when to use $det(\lambda I - A) vs det(A - \lambda I) ?$ – Michael Villeneuve Jun 20 '15 at 2:08

Wolfram alpha confirms that your answer is correct. It's possible that the source you are using defines the characteristic polynomial as $\det(\lambda I-A)$ in which case the characteristic polynomial would be your answer multiplied by $-1$.
• I think that $\det(\lambda I-A)$ is more standard but you should consult whatever source you are using. Note that it doesn't matter if all you care about are the roots. – Brian Fitzpatrick Jun 20 '15 at 2:33
Since det $(\lambda I - A) = 0$, there is nothing wrong in calculating det $(A - \lambda I)$, in your answer, $-x^3 + 4x^2 +x +32 =0$ ,multiply by -1 on both sides...