I am having a bit of trouble with this proof regarding the eigenvalues. My textbook merely stated it but didn't really provide the proof:

Prove that for a matrix $A$ with eigenvalues $\lambda_{i}$: $$Coefficient(\lambda^{N-1}) = -Tr(A)$$

in the characteristic polynomial:

$$p(t) = \det(A-tI) = (-1)^n \big(t^n - (\text{tr} A) \,t^{n-1} + \dots + (-1)^n \det A\big)\,.$$

**My Proof**

We first consider a 3x3 matrix:

$$A-\lambda I =\begin{pmatrix} a_{11} - \lambda & a_{12} & a_{13}\\ a_{21} & a_{22} - \lambda & a_{23} \\ a_{31} & a_{32} & a _{33} - \lambda \end{pmatrix}$$

If we do a cofactor expansion around the 1st row: we obtain

$$|A - \lambda I| = (a_{11} - \lambda)(a_{22} - \lambda)(a_{33} - \lambda) + ...$$

We first note that only the $(a_{11} - \lambda)(a_{22} - \lambda)(a_{33} - \lambda)$ contributes to $\lambda ^ 2$

In fact a co-factor expansion about any row or column would result in $(a_{11} - \lambda)(a_{22} - \lambda)(a_{33} - \lambda)$ ONLY at the position of $a_{ii} - \lambda$

Expanding, we get:

$$(a_{11} - \lambda)(a_{22} - \lambda)(a_{33} - \lambda) = -\lambda^3 + (a_{11} + a_{22} + a_{33})\lambda^2 + \cdots$$

We also note that since this is a $3\times3$ matrix, the coefficient of $\lambda ^3$ (the highest power) is $-1$

We now extend this idea to an $N \times N$ matrix:

Consider

$$A-\lambda I =\begin{pmatrix} a_{11} - \lambda & a_{12} & \cdots & a_{1N}\\ a_{21} & a_{22} - \lambda &\cdots& a_{2N} \\ \vdots & \vdots & & \vdots \\ a_{N1} & a_{N2} &\cdots& a _{NN} - \lambda \end{pmatrix}$$

So using the same logic as the $3 \times 3$ matrix,

A cofactor expansion about any row or column in the $N \times N$ matrix AT THE POSITION of $a_{ii} - \lambda$ would result in the term: $$(a_{11} - \lambda)(a_{22} - \lambda)\cdots(a_{NN} - \lambda)$$ Only this term contribute to $\lambda^N-1$

In which we expect, based on the $3 \times 3$ matrix, the expansion to be:

$$(a_{11} - \lambda)(a_{22} - \lambda)\cdots(a_{NN} - \lambda) = \\ (-1)^N \lambda^N + (-1)^{N-1} (a_{11}+a_{22}+\cdots+a_{NN})\lambda^{N-1} + \cdots \\ = (-1)^N (\lambda^N -(a_{11}+a_{22}+\cdots+a_{NN})\lambda^{N-1}+\cdots) $$

thus proving that: $$Coefficient(\lambda^{N-1}) = -Tr(A)$$

**Note**
I don't know if this is a legitimate form of proof considering that I am just extending from the idea of a $3 \times 3$ matrix