Householder's method. Notice that the only things that stop A from being already tridiagonal are the 2s at the bottom of the second column and the end of the second row. We somehow have to get rid of them.
Start by splitting A into 2×2 blocks: , where , , .
Let Q be a 2×2 orthogonal matrix, and let P be the 4×4 matrix with 2×2-block decomposition , where I is the identity and the Os are zero matrices. Then P is orthogonal, and
We need to choose Q so that the bottom right-hand element of QC is 0, or in other words . In general, this can be done by Householder's method of using reflection matrices. In this case, there is also a straightforward geometric solution, taking Q to be the matrix representing a clockwise rotation through π/4. Then , and Plug this into the equation (*), and you get
That matrix is visibly symmetric and tridiagonal, and it has the same eigenvalues as A because it is orthogonally equivalent to it.