I want a rotation matrix $R$ that transforms +x axis to +y, +y to +z, and +z to +x. One way of doing it is by a rotation about +x by 90 deg anti-clockwise, followed by a rotation about +y by 90 deg anti-clockwise. The matrices respectively are:
$$R_1 = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 0 & -1 \\ 0 & 1 & 0 \\ \end{bmatrix}$$
$$R_2 = \begin{bmatrix} 0 & 0 & 1 \\ 0 & 1 & 0 \\ -1 & 0 & 0 \\ \end{bmatrix}$$
Since R1 first operates first followed by R2, the resultant, I think, is R=(R2)(R1). But when I cross-check by applying R to an arbitrary point, say (1,2,3), I don't get the right transform of (3,1,2). Instead, I get it right when I do R=(R1)(R2) which doesn't make sense to me. Please help
Good attempt Blaze! But seems that you made a common mistake. Before we start, let's review a theorem about the standard matrices for linear transformations:
This theorem appears in most texts about linear transformation, say Friedberg, Lay, etc. Indeed your matrix can be easily found with this theorem. First we reformulate the problem in the language of the theorem:
We are dealing with 3-dimensional space. So we want a linear transformation $T: \mathbb R^3 \rightarrow \mathbb R^3 $.
You want to map the x-axis to y-axis. And we have the 1st column of the identity matrix $I_3$, $\textbf{e}_1=(1,0,0)$ pointing in the x-direction. We also have the 2nd column $I_3$ pointing in the y-direction. Then we have $\hspace{0.5mm}T(\textbf{e}_1) = \textbf{e}_2$. Similarly, $\hspace{0.5mm}T(\textbf{e}_2) = \textbf{e}_3$ and $\hspace{0.5mm}T(\textbf{e}_3) = \textbf{e}_1$.
Then the standard matrix $A$ of our transformation is $A=[\hspace{1mm} T(\textbf{e}_1) \hspace{3mm} T(\textbf{e}_2)\hspace{3mm} T(\textbf{e}_3)\hspace{1mm} ] = [\hspace{1mm} \textbf{e}_2 \hspace{3mm} \textbf{e}_3\hspace{3mm} \textbf{e}_1\hspace{1mm} ]$= \begin{pmatrix} 0 & 0 & 1 \\ 1 & 0 & 0 \\ 0 & 1 & 0\\ \end{pmatrix}
This method shall be cleanest and quickest :)
However, what's wrong with your attempt then? Your think correctly but you read the matrices wrongly. Let's use the theorem in the box to read your matrices:
For $R_1$ , the linear transformation $T_1:\mathbb R^3 \rightarrow \mathbb R^3 $ defined by $T_1(\textbf{x})=R_1\textbf{x}$ does no change to +x-axis ($\textbf{e}_1$). It maps $\textbf{e}_2$ to $\textbf{e}_3$. And it maps $\textbf{e}_3$ to $-\textbf{e}_2$.
It is a good exercise for you to read $T_2(\textbf{x})=R_2\textbf{x}$ yourself. Then you will discover that if you do $T_1$ then $T_2$, you are mapping the $\textbf{e}_1$ to $-\textbf{e}_3$ which does not make sense. To learn more about this, compute $R=R_2R_1$. Then the first column shall exactly be $\textbf{e}_3=T_2(T_1(\textbf{e}_1))$. Doing matrix multiplication on two standard matrices of linear transformations corresponds to composition of the two linear transformation!
Hope that I, a non-math major undergrad can help! I am trying to type as most things as possible since I am trying to learn Latex:) Good luck!