Given the following rotation matrix
$$\left[ \begin{matrix} -1/3 & 2/3 & -2/3 \\ 2/3 & -1/3 & -2/3 \\ -2/3 & -2/3 & -1/3 \\ \end{matrix} \right]$$
what is the corresponding axis-angle representation assuming the angle is restricted to [0, $\pi$]?
How can I solve this question without MatLab and using MatLab?
Trick: if an orthogonal matrix represent a rotation around some axis with amplitude $\theta$, such a matrix is similar to $$\begin{pmatrix}\cos \theta & -\sin\theta & 0 \\ \sin\theta & \cos\theta & 0 \\ 0 & 0 & 1 \end{pmatrix}$$ but the trace of a matrix is left unchanged by matrix conjugation, hence in your case $$1+2\cos\theta = -\frac{1}{3}-\frac{1}{3}-\frac{1}{3} = -1 $$ gives $\theta=\pm\pi$. A second trick is to notice that your matrix is both orthogonal and symmetric, so its eigenvalues belong to $\{-1,1\}$. The trace is $-1$, hence the spectrum is $\{-1,-1,1\}$. The rotation axis is given by the eigenvector associated with the eigenvalue $\lambda=1$, hence it is given by $(-1,-1,1)$.