How do you compute eigenvalues/vectors of big $n\times n$ matrix?

By inspection (because of all the zeros in the matrix) you can see that the span $W_2$ of the first and fifth standard basis vectors is an invariant subspace, as is the span $W_3$ of the remaining three standard basis vectors. You therefore have a decomposition $\Bbb R^5=W_2\oplus W_3$ a direct sum of two invariant subspaces (of dimension $2$ and $3$), and you can find the eigenvalues of the restrictions to those subspaces separately, and then combine them.

For $W_2$ you linear operator is a rank $1$ matrix with trace $2$, so you get eigenvalues $0$ and $2$. For $W_3$ the action is given by the $3\times 3$ sub-matrix at the center. It is rank $1$ with trace $3$, so the eigenvalues are $0$ (double) and $3$. So your nonzero (simple) eigenvalues are $2,3$ and $2\times3=6$.

This uses that fact that a rank$~1$ matrix of size $n>1$ has an eigenvalue$~0$ of multiplicity at least $n-1$ (the dimension of its kernel), and a final eigenvalue equal to its trace (which is the sum of the eigenvalues). And that a nonzero matrix with all entries equal has rank$~1$. These facts are obvious, whence "by inspection". I did not need the eigenvectors of the rank$~1$ matrices themselves, but clearly any (nonzero) column of such a matrix is an eigenvector. In this case, taking into account the initial decomposition into invariant subspaces, this gives you as eigenvectors the first two columns of your original matrix.


Since they are asking for the product of nonzero eigenvalues and your matrix is diagonalisable (since symmetric), you could alternatively interpret that number as the determinant of the action of this matrix on its image subspace. That image has (by inspection) the first two columns of you matrix as basis, and on that basis the restricted action is given by the matrix $({2\atop0}~{0\atop3})$ which has determinant $6$.


You can easily see that the rank of the matrix is $2$: a row reduction brings it in the form $$ \begin{pmatrix} 1 & 0 & 0 & 0 & 1 \\ 0 & 1 & 1 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 \end{pmatrix} $$

Thus you know that the $0$ eigenvalue has geometric multiplicity $5-2=3$. On the other hand, the vectors $$ \begin{pmatrix} 1 \\ 0 \\ 0 \\ 0 \\ 1 \end{pmatrix} \qquad\text{and}\qquad \begin{pmatrix} 0 \\ 1 \\ 1 \\ 1 \\ 0 \end{pmatrix} $$ are clearly eigenvectors relative to $2$ and $3$ respectively.

Denote by $m(\lambda)$ and $d(\lambda)$ the algebraic and geometric multiplicities of $\lambda$ as eigenvalue of the matrix. Then you have \begin{gather} d(0)=3\le m(0) \\[6px] m(2)\ge 1,\quad m(3)\ge 1\\[6px] m(2)+m(3)+m(0)\le5 \end{gather} and so you can conclude that $$ m(2)=1,\quad m(3)=1,\quad m(0)=3 $$ and that there are no more eigenvalues.

Thus the product of the nonzero eigenvalues is $6$.


You can do it by guess-and-check in this case, although in general of course this won't work. The rank is $2$, so there are only two non-zero eigenvalues.

One sees by guess-and-check the eigenvectors are $\begin{bmatrix} 1 \\ 0 \\ 0 \\ 0 \\ 1 \end{bmatrix}$ and $\begin{bmatrix} 0 \\ 1 \\ 1 \\ 1 \\ 0 \end{bmatrix}$ with eigenvalues $2$ and $3$. (When guessing and checking, it's not a bad idea to start with a vector of all $1$s. If you do that in this case, it won't work, but you'll quickly see why these two vectors are the right guess.)