3.5.6 · D3Guidance, Navigation & Control (GNC)

Worked examples — Quaternions — definition q = (q₀, q₁, q₂, q₃), unit quaternion constraint

2,197 words10 min readBack to topic

Before we start, one reminder of the tools we lean on (all built in the parent — we never use a symbol we did not earn there):

Recall The three tools we reuse
  • Encoding: — angle about unit axis .
  • Product: .
  • Sandwich rotation of a vector : treat as a pure quaternion , then , and for a unit , .

The scenario matrix

Every situation this topic can hand you falls into one of these cells. Each worked example below is tagged with the cell it kills.

Cell Scenario class What could trip you up
A Zero / degenerate: axis is undefined, must still give identity
B Positive angle, clean axis (Q-I style) half-angle, norm check
C Negative angle / opposite spin which sign flips, vs
D Limiting value: , scalar part vanishes
E Non-commutativity: vs the term
F Double cover: vs same rotation, different tuple
G Actually rotate a vector (sandwich) does the arrow really move?
H Drift & renormalize (numerical) project back to
I Real-world word problem (spacecraft) translate words → axis + angle
J Exam twist: recover from a given inverting cos/sin, arccos, unit axis

Cell A — the degenerate "no rotation" case


Cell B — clean positive rotation (+ figure)

Figure — Quaternions — definition q = (q₀, q₁, q₂, q₃), unit quaternion constraint

Look at the figure: the teal axis is , and the quaternion parks the angle (half of the real , in plum) into the scalar slot. The full physical turn (burnt orange arc) is what the sandwich will actually produce on a vector — we do that in Cell G.


Cell C — negative angle / the inverse


Cell D — the limiting case


Cell E — non-commutativity, the whole point


Cell F — double cover, and


Cell G — actually rotate a vector (sandwich) + figure

Figure — Quaternions — definition q = (q₀, q₁, q₂, q₃), unit quaternion constraint

The figure shows the input arrow (burnt orange, along ) swinging up to the output arrow (teal, along ), with the arc in plum. The sandwich did what geometry demanded.


Cell H — drift and renormalize


Cell I — real-world word problem


Cell J — exam twist: recover and from


Active Recall

Recall Cell D: what is special about the scalar part of a

rotation? , so — it's a pure quaternion.

Recall Cell J: how do you get

back from a quaternion? , then (watch the division-by-zero).

Recall Cell E: which term makes

? The cross product , which flips sign on swap.

Related build-outs: Axis-Angle Representation, Quaternion Kinematics — dq/dt, Rotation Matrices SO(3), Euler Angles and Gimbal Lock, Spacecraft Attitude Determination, Complex Numbers as 2D Rotations.

Flashcards

Recover angle from a unit quaternion.
.
Recover the axis from a unit quaternion.
(undefined when ).
Quaternion for about .
.
Why does mean a half-turn?
.