Sequence of rotation matrices 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

In general, a transformation matrix is just the transformation with respect to the standard basis vectors, and so your matrix will simply be the set $M={v_1^`,v_2^`,v_3^`}$ making your matrix read $$\begin{matrix}{{0,0,1}\\{1,0,0}\\{0,1,0}}\end{matrix}$$
The proof that this works is that matrices are linear transformations, meaning that $T(av+bu)=aT(v)+bT(u)$, and so since any vector can be represented as a combination of the basis vectors, the transformation on any vector is the same as that transformation on the linear combination of basis vectors, and you already know that the basis vectors end up where you want them.
