Canonical form and basis of orthogonal operator Find canonical form and canonical basis of orthogonal operator $f$ which has the following matrix in some orthonormal basis $$A_f=\frac{1}{3}\begin{bmatrix}
2 & -1 & 2 \\
2 & 2 & -1 \\
-1 & 2 & 2 
\end{bmatrix}.$$
I will show my approach and could you help me to proceed my reasoning, please?
Approach: We know that for any orthogonal operator there is a canonical basis such that matrix of the operator $f$ in this basis is $$\begin{bmatrix}
\pm 1 & 0 & 0 \\
0 & \cos \varphi & -\sin \varphi \\
0 & \sin \varphi & \cos \varphi 
\end{bmatrix}.$$ Since the determinant and trace of matrix of linear operator are the same in any basis we make the following remark: since $\det A_f=1$ then in canonical form the first element of the first row should be equal to $1$. Since $\text{tr}A_f=2$ then $2\cos \varphi+1=2 \Leftrightarrow \cos \varphi =\frac{1}{2}$. So $\sin \varphi=\pm \dfrac{\sqrt{3}}{2}$.
Also it follows that $1$ is an eigenvalue of operator $f$ and corresponding eigenvector is $e_1=\frac{1}{\sqrt{3}}(1,1,1)$.  So $e_1$ can be taken as the first vector of canonical basis and we know that canonical form is $$\begin{bmatrix}
 1 & 0 & 0 \\
0 & \cos \varphi & -\sin \varphi \\
0 & \sin \varphi & \cos \varphi 
\end{bmatrix}.$$
I cannot solve by myself rigorously the following questions:
1) How to find the rest two vectors of canonical basis?
2) And which value of $\sin \varphi=\pm\dfrac{\sqrt{3}}{2}$ I need to take?
I will highly appreciate your detailed answer! I was trying to think on this question for the last 2 days but I failed to solve rigorously.
 A: Consider the two-dimensional subspace consisting of vectors orthogonal to $e_1$. On this two-dimensional subspace, $A_f$ acts as a rotation of angle $\varphi$. You can perform Gram-Schmidt on $e_1$ to find two other vectors $e_2$ and $e_3$ that together form an orthonormal basis. You can check that $A_f$ acts on $e_2$ and $e_3$ like the rotation matrix by $\varphi = \pi/3$ or $\varphi=-\pi/3$; I think the angle will flip if you negate $e_2$ or $e_3$, or if you swap the order of these two basis vectors.

Response to comments:
What my previous comment was saying is that if you are indeed familiar with the theorem and its proof, then you should be able to answer your questions. But anyway, a sketch: Joppy's comment shows you that the orthogonal complement of $e_1$ (the span of $e_2$ and $e_3$) is preserved by $f$; that is, if $u \in \text{span}\{e_2, e_3\}$, then $A_f u \in \text{span}\{e_2, e_3\}$. This is reflected in the block diagonal structure of your matrix in the new basis: the $1 \times 1$ block corresponds to how $A_f$ acts on the span of $e_1$, and the $2 \times 2$ block corresponds to how $A_f$ acts on the span of $e_2$ and $e_3$.
Because we chose $e_2$ and $e_3$ to be orthogonal, we know $A_f e_2$ and $A_f e_3$ must be orthogonal because $A_f$ is an orthogonal matrix. Thus, when restricted to this two-dimensional subspace, $A_f$ is an orthogonal transformation with determinant $+1$.
Then the question reduces to a two-dimensional problem. You may already know that any orthogonal transformation on a two-dimensional space (with respect to an orthonormal basis) that has determinant $+1$ must be of the form $\begin{bmatrix} \cos \varphi & -\sin \varphi \\ \sin \varphi & \cos \varphi \end{bmatrix}$ for some $\varphi$. The choice of basis in this two-dimensional space will not change anything except possibly the value of $\varphi$.

With $e_2 = \frac{1}{\sqrt{2}}(0, 1, -1)$ and $e_3 = \frac{1}{\sqrt{6}}(2, -1, -1)$ we have
$$A_f e_2 = \frac{1}{\sqrt{2}}(-1, 1,0) = \frac{1}{2}  e_2 -\frac{\sqrt{3}}{2} e_3$$
$$A_f e_3 = \frac{1}{\sqrt{6}}(1,1,-2) = \frac{\sqrt{3}}{2} e_2 + \frac{1}{2} e_3$$
A: Note that we want to find some orthogonal $U$ such that $UA_fU^T$ has the desired form so 
that $(U A_f U^T)^T (U A_f U^T) = UA_f^TA_f U^T = I$. 
Since it is normal we know that there is an orthogonal basis of eigenvectors.
Since it is orthogonal and real, one eigenvalue must be real hence equal to $\pm 1$.
It is not too hard to see that $A_f e = e$ where $e=(1,1,1)$.
By inspection, note that $v_2=(1,-1,0) , v_3=(1,1,-2)$ are orthogonal (not normal yet).
(Note that any two orthogonal vectors that lie in $e^\bot$ will do.)
If we let $U = \begin{bmatrix} {e \over \|e\|} & {v_1 \over \|v_1\|} & {v_2 \over \|v_2\|} 
 \end{bmatrix}$, then  $U^T A_f U$ has the form
$\begin{bmatrix} 1 & \\  & B  \end{bmatrix}$ and we must have $B^T B = I$.
Hence $B$ is a two dimensional rotation and $\det B = 1$ so it is proper (otherwise it would take a similar but slightly different form). Hence it has the form $\begin{bmatrix} c & -s \\ s & c  \end{bmatrix}$, where $c^2+s^2 = 1$ and from this
we can determine an angle.
If we grind through the computations we get
$UA_fU^T = \begin{bmatrix} 1 & & \\
 & {1 \over 2} &  -{\sqrt{3} \over 2} \\
& {\sqrt{3} \over 2} & {1 \over 2}  \end{bmatrix}$ and from this we
get $\theta = { \pi \over 3}$.
