Skip to main content
Open In Colab A 2×22 \times 2 matrix has four entries, so you can treat it as a point in R4\mathbb{R}^4. Most of these points are not rotations. A rotation matrix has columns of unit length (two constraints) that are perpendicular (one more constraint). Four entries minus three constraints leaves one free number, the angle θ\theta: R(θ)=[cos⁡θ−sin⁡θsin⁡θcos⁡θ]R(\theta) = \begin{bmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta \end{bmatrix} As θ\theta changes, R(θ)R(\theta) moves along a curve in R4\mathbb{R}^4. That curve is SO(2)SO(2). This section draws it, shows that it is a circle, and finds its tangent at the identity, which is the Lie algebra so(2)\mathfrak{so}(2). These two objects are the first two rows of the Lie cheatsheet.

Sampling the curve

Each angle gives one rotation matrix. Write its entries in a row, (r11,r12,r21,r22)(r_{11}, r_{12}, r_{21}, r_{22}), and you get a point in R4\mathbb{R}^4. The code also checks that every sample is a rotation.

The shape of the curve

The point for angle θ\theta is (cos⁡θ,−sin⁡θ,sin⁡θ,cos⁡θ)(\cos\theta, -\sin\theta, \sin\theta, \cos\theta). Two entries repeat the others: r22=r11r_{22} = r_{11} and r12=−r21r_{12} = -r_{21}. These two equations keep the curve in a plane. Inside that plane, r112+r212=1r_{11}^2 + r_{21}^2 = 1, which is a circle. Every point is 2\sqrt{2} from the origin, and the circle closes because θ\theta and θ+2π\theta + 2\pi give the same matrix.

Drawing the curve

You cannot draw R4\mathbb{R}^4. But r22r_{22} always equals r11r_{11}, so you can drop it. The plot uses (r11,r21,r12)(r_{11}, r_{21}, r_{12}) and colors each point by θ\theta. The result is a tilted circle around the origin. Output from cell 3

Rotations and reflections

Perpendicular unit columns are not enough to make a rotation. The matrices F(θ)=[cos⁡θsin⁡θsin⁡θ−cos⁡θ]F(\theta) = \begin{bmatrix} \cos\theta & \sin\theta \\ \sin\theta & -\cos\theta \end{bmatrix} have them too, but their determinant is −1-1. Each one is a reflection across a line through the origin. The reflections form a second circle in R4\mathbb{R}^4. Together the two circles make up O(2)O(2), the group of all orthogonal 2×22 \times 2 matrices. Along any path of orthogonal matrices the determinant would have to jump from +1+1 to −1-1 to reach a reflection, and it cannot jump. So SO(2)SO(2) is the circle that contains the identity.

One column is enough

The first column of R(θ)R(\theta) is (cos⁡θ,sin⁡θ)(\cos\theta, \sin\theta), a point on the unit circle in the plane. The second column is the first one turned by 90°90° counterclockwise, so it adds nothing new. Each rotation matches one point on the unit circle, and each point matches one rotation. This is another way to see that SO(2)SO(2) is a circle. The top panel follows the first column as θ\theta grows. The row below shows the whole rotated frame {Re1,Re2}\{R\mathbf{e}_1, R\mathbf{e}_2\} at the same angles. Output from cell 4

The tangent at the identity

Seen up close, a curve looks like a straight line. At the identity, θ=0\theta = 0, that line points along the derivative of R(θ)R(\theta): dRdθ∣θ=0=[−sin⁡0−cos⁡0cos⁡0−sin⁡0]=[0−110]=G\left.\frac{dR}{d\theta}\right|_{\theta=0} = \begin{bmatrix} -\sin 0 & -\cos 0 \\ \cos 0 & -\sin 0 \end{bmatrix} = \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix} = G The matrix GG is skew-symmetric. Every velocity at the identity is ωG\omega G for some angular rate ω\omega: so(2)={ωG:ω∈R}=span⁡{G}\mathfrak{so}(2) = \left\{ \omega G : \omega \in \mathbb{R} \right\} = \operatorname{span}\{G\} So so(2)\mathfrak{so}(2) is one-dimensional, like SO(2)SO(2), and GG is its single generator. The matrix exponential leads back to the curve: eθG=R(θ)e^{\theta G} = R(\theta). The code below checks the derivative, the skew symmetry and the exponential. Lie I covers tangent spaces and the exponential map in general. Appendix D of Corke (Corke, 2023) repeats this construction for SO(3)SO(3), which has three generators.

References

  • Corke, P. (2023). Robotics, vision and control: Fundamental algorithms in python.

Found an error on this page? Report an issue.