Solution (source code)

= Solution

Here $M^2=-I$, so its even powers alternate between $\pm I$ and its odd powers between $\pm M$. Collecting even and odd terms of the <matrix exponential> yields
$$
R(\phi)=I\cos\phi+M\sin\phi
=\boxed{\begin{pmatrix}\cos\phi&-\sin\phi\\\sin\phi&\cos\phi\end{pmatrix}.}
$$
Thus $R^TR=I$, $\det R=1$, and $R(\phi)(1,0)^T=(\cos\phi,\sin\phi)^T$. It is the <rotation matrix> for a counterclockwise <rotation> through angle $\phi$, preserving <lengths> and <orientation>.