Eigenvectors of Laplacian matrix of path graph

525 Views Asked by At

I would like to diagonalize the $N \times N$ matrix

$$\begin{pmatrix} 1 & -1 & & & & & 0 \\ -1 & 2 & -1 & & & & \\ & -1 & 2 & -1 & & & \\ & & & \ddots & & & \\ & & & -1 & 2 & -1 & \\ & & & & -1 & 2 & -1 \\ 0 & & & & & -1 & 1 \\ \end{pmatrix}$$

By curve fitting, I managed to guess the eigenvalues to be of the form $2 - 2 \cos(\frac{k \pi}{N})$, with $k \in \{0, 1, \ldots, N-1\}$. Any tips on how to get the eigenvectors?