Rotation as a Trigonometric Operation
Learning objectives
- Write the rotation matrix for angle theta
- Apply the rotation matrix to rotate a point
- Compose two rotations and simplify
- Understand rotations as linear transformations
So far the unit circle has been a static picture. Now we make it move. A rotation spins the whole plane around the origin by some angle , taking each point to a new point. The question this section answers: if I know and I rotate by , what are the new coordinates? The answer is a single, beautiful formula, the rotation matrix, whose entries are sine and cosine of . It is also the first time matrices show up in this textbook, and rotations are the cleanest possible introduction to what a matrix really is: a recipe for transforming a vector.
Deriving the formula
Write the point in polar form for some radius and angle . A counterclockwise rotation by keeps the radius and adds to the angle:
Apply the addition formulas:
So the new coordinates are
The rotation matrix
Stack the two scalar equations into one matrix equation:
\begin{pmatrix} x' \\ y' \end{pmatrix} = \begin{pmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \phantom{-}\cos\theta \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix}
The matrix is the rotation matrix, usually written . Multiplying it against the column vector gives the rotated point.
- Computer Graphics: Every 2D rotation in a game engine, character turning, sprite spinning, UI flourish, is ; this single matrix is hand-coded into thousands of game loops.
- Robotics: Rotation matrices about each joint axis are composed to compute the end-effector position; this is forward kinematics, and every industrial robot's controller runs this composition tens of times per second.
- Cryptography: Some lattice-based cryptosystems rely on rotations in high-dimensional integer lattices; the difficulty of recovering small basis vectors after rotation is what makes them post-quantum secure.
(Snap to a standard angle and read off and . Those two values are the entries of the rotation matrix: column one is , column two is . The columns are exactly the images of the basis vectors and
Composition: rotating twice
If you rotate by and then by , the net effect is a rotation by . In matrix form:
The proof is a direct computation using the addition formulas. So the family of rotation matrices is closed under multiplication, with the angle adding modulo . This is the cleanest possible example of an abelian group, and it foreshadows the role of complex multiplication in section 15.2.
Four properties to remember
- Distances are preserved, rotations are rigid motions. .
- Angles between any two vectors are preserved.
- The inverse of is . Rotating by undoes the rotation by .
- The determinant is . Areas are preserved with orientation.
Worked example
Rotate by . From the standard table , :
The image is . Sanity check: the distance from origin is . Same as before, rotations preserve distance.
Try it
- Rotate by . (Expect .)
- Compute . Use the composition rule, not the matrix product, then verify by direct multiplication.
- A point at is the result of rotating some original point by . Find . (Apply the inverse rotation .)
Pause: if a matrix preserves distances and has determinant , it must be a rotation. Can you sketch why? (Hint: a rigid map that fixes the origin sends basis vectors to two perpendicular unit vectors; the determinant being rules out reflection.)
A trap to watch for
The sign convention. Counterclockwise rotations correspond to positive ; clockwise to negative. Computer graphics often uses the opposite convention (because the screen y-axis points down), so a "rotate by 90°" in a CSS transform might look like a rotation in the wrong direction relative to mathematical convention. Always re-check the orientation of the y-axis before plugging into the rotation matrix. In this textbook the y-axis always points up and CCW is positive.
A second trap: the formula holds because rotations commute. This is a luxury, matrix multiplication is not generally commutative. For arbitrary matrices in general. Rotations are special because they form an abelian subgroup of the general linear group.
What you now know
You can write the rotation matrix , apply it to a point to compute the rotated coordinates, compose two rotations by adding angles, recognise that rotations preserve distance and area, and check the sign convention before plugging in. The next chapter switches gears: we leave trigonometry behind and begin analytic geometry, where coordinate methods are turned loose on lines, parabolas, ellipses, and hyperbolas.
Quick check
Mark section complete →
References
- Lang, S. (1971). Basic Mathematics. Springer. Chapter 11, §6, rotations derived from the addition formulas, leading into matrix notation.
- Apostol, T. M. (1969). Calculus, Volume 2: Multi-Variable Calculus and Linear Algebra (2nd ed.). Wiley. Chapter 5: rotations as orthogonal transformations.
- Strang, G. (2016). Introduction to Linear Algebra (5th ed.). Wellesley-Cambridge Press. Chapter 7: rotation matrices as the simplest orthogonal matrices.