Calculating a rotation matrix: error and properties

358 Views Asked by At

Given an axis $u=\begin{bmatrix} \sqrt 3/3, \sqrt 3 /3, \sqrt 3 /3 \end{bmatrix}$ and an angle $\phi =\frac{2\pi}{3}$ I want to calculate the related rotation matrix:

Well given Rodriguez’s formula:

\begin{align*}Rot(u,\phi)&=I\cos\phi+uu^T(1-\cos\phi)+\hat u \sin\phi\\ &=\begin{pmatrix} \cos\phi & 0 & 0\\ 0 & \cos\phi & 0\\ 0 & 0 & \cos\phi \end{pmatrix}+(1-cos\phi)+\hat u\sin\phi \end{align*} Yet,

\begin{align*} \hat u &=\begin{bmatrix} \hat u_1\\ u_2\\ u_3 \end{bmatrix}\\ &=\begin{pmatrix} 0 & -u_3 & u_2\\ u_3 & 0 & -u_1\\ -u_2 & u_1 & 0 \end{pmatrix}\\ &=\begin{pmatrix} 0 & -\sqrt 3/3 & \sqrt 3/3\\ \sqrt 3/3 & 0 & -\sqrt 3/3\\ -\sqrt 3/3 & \sqrt 3/3 & 0 \end{pmatrix} \end{align*}

Therfore:

\begin{align*} Rot(u,\phi)&=\begin{pmatrix} \cos\phi & 0 & 0\\ 0 & \cos\phi & 0\\ 0 & 0 & \cos\phi \end{pmatrix}+3(1-cos\phi)+ \begin{pmatrix} 0 & -\sqrt 3/3 & \sqrt 3/3\\ \sqrt 3/3 & 0 & -\sqrt 3/3\\ -\sqrt 3/3 & \sqrt 3/3 & 0 \end{pmatrix}\sin\phi\\ &= \begin{pmatrix} 1 & 0 & 0\\ 0 & 1 & 0\\ 0 & 0 & 1 \end{pmatrix}+ \begin{pmatrix} 0 & -\sqrt 3/3 & \sqrt 3/3\\ \sqrt 3/3 & 0 & -\sqrt 3/3\\ -\sqrt 3/3 & \sqrt 3/3 & 0 \end{pmatrix}\sin\phi\\ &=\begin{pmatrix} 1 & -1/2 & 1/2\\ 1/2 & 1 & -1/2\\ -1/2 & 1/2 & 1 \end{pmatrix} \end{align*}

It seems to be false and even violate the translation matrix properties (which I don't remember)

Therefore can you help me know which properties does I violate and what should be the actual rotation matrix?

I've heard that there is another way than Roderiguez's formula to calculate $Rot(u,\phi)$, do yu know which?