Intuition behind rotation matrices?

Inertigratus
Messages
123
Reaction score
0
I probably can remember the matrices by just trying to, but I hate having to "remember" things without actually understanding them.
Is there no intuition behind these matrices so that I can remember it (the intuition) and then from it produce the wanted matrix?
To me the matrices look like some kind of cross product between a position vector and the derivative of that position vector but in polar coordinates.
But in 3 dimensions the row with the zeros and the single 1 changes depending on which axis the rotation is about and the order matters...

I hope you understand the way I wrote this, not sure how to type the matrices on here.

Once again, the reason I'm asking is because I don't want to just remember a couple of trigonometric matrices but rather a method or intuition from which I can produce the desired matrix depending on the kind of rotation I'm looking for.

Thanks!
 
Physics news on Phys.org
One of the most straightforward ways to compute a matrix from a linear transformation is to simply transform the basis vectors.
 
And how do you do that? how about rotations in 3 dimensions?
 
Well let's do an example in 3D then. Consider the rotation around the x-axis of 90°.

We only need to figure out where (1,0,0), (0,1,0) and (0,0,1) end up. Obviously (1,0,0) remains fixed. (0,1,0) is being sent to (0,0,-1) (or (,0,0,1) depending on how you rotate). And (0,0,1) is being sent to (0,1,0) (or (0,-1,0)). So our rototation matrix has the form

\left(\begin{array}{ccc} 1 & 0 & 0 \\ 0 & 0 & 1 \\ 0 & -1 & 0\\ \end{array}\right)

That's how you solve these things in general...
 
If you rotate the vector i= <1, 0> through angle \theta around the origin. You will get a vector of length 1 which is the hypotenuse of a right triangle. It follows that the "near side", which is the i component of the vector, is cos(\theta) and the "far side", which is the j component of the vector, is sin(\theta). That is, <1, 0> is rotated into &lt;cos(\theta), sin(\theta)&gt;.

Similarly if you rotate the vector j= <0, 1> through angle \theta around the origin. You will get a vector of length 1 which is the hypotenuse of right triangle. This time, the "near side" is along the y-axis while the "opposite side" points in the direction of the negative x axis. The i component is -sin(\theta) and the j component if cos(\theta). <0, 1> is rotated to &lt;-sin(\theta), cos(\theta)&gt;.

As Hurkyl said, you can construct a matrix by using, as columns, the vectors the basis vectors are mapped into. Since <1, 0> is mapped into &lt;cos(\theta), sin(\theta)&gt; and <0, 1> is mapped into &lt;-sin(\theta), cos(\theta)&gt;, the rotation matrix is
\begin{bmatrix}cos(\theta) &amp; -sin(\theta) \\ sin(\theta) &amp; cos(\theta)\end{bmatrix}.

As for three dimensions, it is easy to see that a rotation around the z-axis does not change the z component of any point so rotation around the z axis through angle \theta is given by
\begin{bmatrix}cos(\theta) &amp; -sin(\theta) &amp; 0 \\ sin(\theta) &amp; cos(\theta) &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}
and it should be clear that a rotation about the y-axis through angle \theta is
\begin{bmatrix}cos(\theta) &amp; 0 &amp; -sin(\theta) \\ 0 &amp; 1 &amp; 0 \\ sin(\theta) &amp; 0 &amp; cos(\theta)\end{bmatrix}
and a rotation about the x-axis through angle \theta is
\begin{bmatrix}1 &amp; 0 &amp; 0 \\ 0 &amp; cos(\theta) &amp; -sin(\theta) \\ 0 &amp; sin(\theta) &amp; cos(\theta)\end{bmatrix}

Finally, to rotate around a general vector, <a, b, c>, through an angle \theta, find a matrix, A, that rotates the axis, <a, b, c>, around the z-axis into the yz-plane so that the i component is 0. It is easy to see, with a little work, that the matrix that does that is
\begin{bmatrix}\frac{b}{r} &amp; -\frac{a}{r} &amp; 0 \\ \frac{a}{r} &amp; \frac{b}{r} &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}
where r= \sqrt{a^2+ b^2}.

Next, rotate around the x-axis so that axis is rotated into the z-axis. That requires matrix
B= \begin{bmatrix}1 &amp; 0 &amp; 0 \\ 0 &amp; \frac{c}{\rho} &amp; -\frac{r}{\rho} \\ 0 &amp; \frac{r}{\rho} &amp; \frac{c}{\rho}\end{bmatrix}

Once you have done that, use the matrix
\begin{bmatrix}cos(\theta) &amp; -sin(\theta) &amp; 0 \\ sin(\theta) &amp; cos(\theta) &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}

Finally, use the inverses of matrices B and A to rotate back to the original position. Of course, the inverse matrix just rotates through the negative angle- and since cosine (the diagonal elements) is an even function while sine (the off diagonal elements) is an odd function, that just requires changing the sign on the off diagonal elements.

That is, to rotate a vector through angle \theta, around axis <a, b, c> multiply by the matrix product:
\begin{bmatrix}\frac{b}{r} &amp; \frac{a}{r} &amp; 0 \\ -\frac{a}{r} &amp; \frac{b}{r} &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}\begin{bmatrix}1 &amp; 0 &amp; 0 \\ 0 &amp; \frac{c}{\rho} &amp; -\frac{r}{\rho} \\ 0 &amp; \frac{r}{\rho} &amp; \frac{c}{\rho}\end{bmatrix}\begin{bmatrix}cos(\theta) &amp; -sin(\theta) &amp; 0 \\ sin(\theta) &amp; cos(\theta) &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}\begin{bmatrix}1 &amp; 0 &amp; 0 \\ 0 &amp; \frac{c}{\rho} &amp; -\frac{r}{\rho} \\ 0 &amp; \frac{r}{\rho} &amp; \frac{c}{\rho}\end{bmatrix}\begin{bmatrix}\frac{b}{r} &amp; -\frac{a}{r} &amp; 0 \\ \frac{a}{r} &amp; \frac{b}{r} &amp; 0 \\ 0 &amp; 0 &amp; 1\end{bmatrix}
 
Last edited by a moderator:
Wow, thanks a great deal! That really made sense... now I can find the matrix by just doing a quick picture of how the basis vectors are transformed.

Ivy, I understood most of what you explained... except the general vector part, will re-read it a little bit later. However, when rotating about the y-axis... where did that minus sign appear from? On the x-component of the z-basis vector. I tried painting a picture but to me the minus seems wrong?
Both the x and z basis vectors rotate about the y-axis clockwise (right-hand rule?) and then the x-component should be positive?
(Clockwise if you look towards the direction of the y-axis)
 
Last edited:

Similar threads

Back
Top