Strapdown Inertial Navigation: Discrete Quaternion and Finite-Increment Propagation
INS07 derived the continuous attitude kinematics. A real strapdown computer, however, does not
receive a continuous angular-rate function. It receives sampled gyroscope data at discrete times.
Depending on the IMU, the data may be reported as angular rate, integrated angle, or a
manufacturer-corrected delta angle over each sample interval.
The implementation problem is therefore not merely
The computer must convert finite sensor samples into a finite rotation, compose that
rotation with the existing attitude, preserve the unit-quaternion constraint, account for
navigation-frame motion, and detect numerical or convention errors before they corrupt the
velocity solution.
The central propagation chain is
Figure. A digital attitude mechanization converts sampled gyroscope information into a
finite angular increment, then into a unit quaternion increment, and finally composes that
increment with the previous attitude.
1 Learning objectives
After completing this entry, the reader should be able to:
- distinguish angular rate, delta angle, and finite quaternion increment;
- derive the exact quaternion increment associated with a constant angular rate over a
sample interval;
- propagate a body-to-navigation quaternion using right multiplication by a
body-resolved finite increment;
- derive a two-sided discrete update that accounts separately for body rotation and
navigation-frame rotation;
- derive stable small-angle approximations for the quaternion increment;
- explain why the first-order quaternion update is not exactly unit norm;
- normalize a quaternion without changing the represented attitude;
- explain the sign equivalence of q and −q;
- compare exact finite-increment propagation with forward-Euler integration of the
quaternion differential equation;
- identify when coning corrections are needed and when exact sequential sample
propagation already retains the finite-rotation information;
- formulate implementation invariants for quaternion norm, DCM orthogonality,
determinant, one-axis motion, and stationary-Earth tests;
- design a numerically robust discrete attitude update suitable for a strapdown
navigation loop.
2 From continuous gyro rate to sampled data
The ideal gyroscope measurement is the inertial angular rate of the body, resolved in body
coordinates,
A sampled digital IMU may provide this rate at times tk, or it may provide the integrated angular
increment over the interval
The ideal inertial body increment is
If the rate is approximately constant over the interval,
This distinction matters in software. If an IMU already reports Δ𝜃, multiplying by Δt again is a
serious scale error.
2.1 Three quantities that should never share one variable name
A robust implementation should distinguish
| ω | angular rate, units rad/s, | (7)
|
| Δ𝜃 | angular increment, units rad, | (8)
|
| δq | dimensionless unit quaternion increment. | (9) |
The units alone catch many integration mistakes.
3 Navigation-relative angular increment
For a local-level NED attitude, INS07 showed that the propagation rate is
where
For a sufficiently short sample interval, a midpoint approximation gives
The attitude used in Cnb should represent the interval reasonably well. Using the beginning-of-step
attitude is first order. A midpoint or predictor-corrector value is usually better when the interval or
angular rate is not extremely small.
4 Exact finite quaternion increment
Suppose the navigation-relative angular rate is constant over one interval. Define
Let
The exact finite rotation over the interval is an axis-angle rotation by α about u. With the
scalar-first Hamilton convention used throughout this series, its quaternion is
Equivalently, without explicitly constructing u,
The limit as α → 0 is well behaved because
Figure. The gyro increment is a finite rotation vector. Its magnitude is the rotation angle
α, its direction is the rotation axis u, and the equivalent quaternion uses the half angle α∕2.
5 Discrete quaternion propagation
The quaternion qbn represents the same body-to-navigation transformation as C
bn. If the increment
is body relative to navigation and is resolved in body coordinates, then the finite update
is
This right multiplication is the quaternion counterpart of
The multiplication order is not optional. Reversing it generally applies the same numerical
increment in a different frame.
5.1 Quaternion product used here
For
the Hamilton product is
This definition should appear explicitly in source code documentation because alternate quaternion
conventions can reverse signs or multiplication order.
6 A full two-sided discrete navigation-frame update
There is another useful way to implement the attitude step. Instead of first subtracting
navigation-frame rate from the gyro, propagate the two frame rotations separately.
Over one interval define the inertial body increment
and the inertial navigation-frame increment
Construct
and
Then, to the accuracy with which these finite increments represent the interval,
The left factor removes the inertial rotation of the navigation frame. The right factor applies the
inertial rotation of the body. This is the finite-increment analogue of the continuous
equation
For very small intervals, this two-sided update and the corrected-relative-rate update agree to
the expected order. The two-sided form is especially useful for reasoning about frame
bookkeeping.
7 Small-angle quaternion updates
For small α, expand the trigonometric functions:
| cos(α∕2) | = 1 − + + O(α6), | (28)
|
 | = − + + O(α6). | (29) |
Therefore
The simplest first-order approximation is
It is often adequate for very small increments, but it is not exactly unit norm.
7.1 Norm of the first-order increment
Its squared norm is
| ∥δqfirst∥2 | = 1 + Δ𝜃T Δ𝜃 | (32)
|
| = 1 + . | (33) |
Thus
for every nonzero increment.
8 What normalization fixes, and what it does not
If a numerically propagated quaternion is
a standard correction is
Normalization projects the four-component vector back onto the unit 3-sphere. It repairs norm
drift. It does not, in general, repair an incorrect rotation axis, an incorrect multiplication order, an
omitted Earth-rate correction, an incorrect sample interval, or a coning error.
For the normalized first-order increment
the represented rotation angle is
For small α,
So normalization removes the norm error, while a third-order attitude error remains.
Figure. After normalization, the first-order quaternion still represents a slightly smaller
rotation than the exact finite increment. The residual angle error scales approximately with
the cube of the increment magnitude.
9 A numerical finite-increment example
Take
Its magnitude is
The exact finite quaternion increment is
The first-order increment is
Its norm is slightly greater than one. Renormalizing it makes the result very close to the exact
increment, but not mathematically identical.
10 Exact finite increment versus forward Euler integration
A common alternative is to integrate the differential equation directly using forward
Euler,
Factor qk on the right-hand increment:
Thus forward Euler on the quaternion differential equation is exactly the same first-order
increment discussed above. Normalizing after the step repairs its norm but does not turn it into
the exact exponential-map solution.
For a constant angular rate over the interval, constructing the finite quaternion increment from
sine and cosine is inexpensive and gives the exact constant-rate rotation. There is little reason to
use plain forward Euler when the finite increment is available.
11 Numerically stable evaluation near zero angle
The expression
is mathematically regular at zero but can lose floating-point accuracy if evaluated carelessly for
very small α. Two practical approaches are common.
First, switch to the series
Second, use a numerically stable sinc implementation. If
then
The threshold between direct evaluation and series evaluation should be chosen based on the
floating-point type and implementation environment.
12 Quaternion normalization in a real mechanization
Exact multiplication of unit quaternions preserves unit norm algebraically. Floating-point
arithmetic introduces roundoff. Approximate integration can introduce additional drift. A practical
update therefore often ends with
Figure. Normalization projects a numerically perturbed quaternion back to the
unit-quaternion manifold. It fixes the constraint qT q = 1, but it does not correct a
physically wrong attitude update.
12.1 Do not hide gross failures with normalization
Normalization should not replace input validation. Before normalizing, an implementation should
reject or flag conditions such as
nonfinite components, impossible sample intervals, or unexpectedly large norm errors. A tiny norm
correction is Normal. A large correction is diagnostic information.
13 The sign ambiguity of a quaternion
The two quaternions
represent the same physical attitude. Therefore a perfectly correct algorithm may occasionally
change the sign of all four quaternion components without changing Cbn.
For continuous logging, interpolation, or plotting, it is often useful to enforce sign continuity.
If
replace
This does not change the attitude. It only chooses the closer of the two equivalent quaternion
representations.
14 Multiple gyro samples within one navigation update
Suppose a navigation update contains m gyro increments,
If each increment is propagated sequentially with its own exact finite quaternion,
then the noncommutativity of those finite sample rotations is retained.
If instead the software collapses the samples into one vector by
cross-axis information is lost. INS07E2 showed how coning corrections recover the leading
noncommutative terms.
Thus an important design distinction is:
Exact sequential propagation of each resolved sample is not the same as naive
vector summation followed by one update.
15 A robust discrete attitude-update sequence
A practical quaternion mechanization can be organized as follows.
- Read the IMU timestamp and gyro data.
- Determine whether the gyro quantity is rate or already-integrated delta angle.
- Convert all angular quantities to radians and seconds.
- Correct deterministic gyro errors available at this stage, such as estimated bias.
- Compute Earth rate and navigation-frame transport rate.
- Form either the navigation-relative increment or separate body and navigation
increments.
- Apply coning compensation if multiple subincrements are being collapsed into one
update.
- Construct the finite unit quaternion increment using the exact or stable small-angle
formula.
- Compose the increment with the previous quaternion in the documented multiplication
order.
- Normalize the result.
- Optionally enforce quaternion sign continuity for logs or interpolation.
- Convert to a DCM if the velocity mechanization requires Cbnfb.
- Run invariants and diagnostic checks.
16 Implementation checks
A strapdown attitude propagator should be surrounded by tests that are simple enough to verify
analytically.
16.1 Zero-increment test
If
then
and the attitude must remain unchanged.
16.2 Single-axis test
For a positive body z increment ψ,
The corresponding DCM should match the series sign convention for positive yaw.
16.3 Unit-norm test
Require
The tolerance should be appropriate to the floating-point precision and normalization
strategy.
16.4 DCM orthogonality test
After conversion from quaternion,
Both are useful. Determinant alone is not a sufficient DCM test.
16.5 Quaternion-DCM round trip
Test
The recovered quaternion should equal either q or −q to numerical precision.
16.6 Composition-order test
Apply a known x increment followed by a known y increment. Reverse the multiplication order and
confirm that the final attitudes differ. This prevents an accidental switch between body-resolved
and navigation-resolved increment conventions.
16.7 Stationary Earth-fixed test
For a body fixed to Earth and aligned with NED,
After Earth-rate subtraction, the relative increment should be approximately zero and the NED
attitude should remain fixed.
16.8 Rate versus delta-angle test
Feed the same physical rotation once as rate data and once as preintegrated angle data.
The two paths should produce the same result when the software handles their units
correctly.
Figure. A discrete attitude mechanization should be treated as a testable numerical
component. Quaternion norm, DCM orthogonality, one-axis motion, frame-rate
cancellation, and unit consistency expose different classes of implementation error.
17 Why time tagging matters
If the software uses rate data,
An error in Δt therefore directly scales the inferred angular increment. A timestamp slip, dropped
sample, or duplicated sample can become an attitude error even if the gyro measurement itself is
perfect.
If the IMU supplies delta angles integrated internally over its own sample interval, the navigation
computer should use those increments consistently with the associated timestamps. It should not
silently assume that every packet corresponds to an identical nominal Δt if the hardware
documentation says otherwise.
18 Small-angle threshold selection
There is no universal physical angle at which the small-angle formula suddenly becomes invalid.
The threshold is a numerical-design decision based on the required accuracy.
For a normalized first-order quaternion, the leading angle error is approximately
For example:
| Increment magnitude | Normalized first-order angle error |
|
|
| 1∘ | approximately 0.091 arcsec |
| 5∘ | approximately 11.4 arcsec |
| 10∘ | approximately 91.0 arcsec |
| 20∘ | approximately 718 arcsec |
This makes the engineering trade clear. At high-rate IMU sampling, individual increments are
usually small. During low-rate propagation or very rapid vehicle motion, exact finite increments are
preferable.
19 Connection to the velocity mechanization
The propagated attitude is used immediately to rotate accelerometer specific force,
The NED velocity equation is then
Thus a quaternion propagation error is not confined to the attitude output. It immediately rotates
the accelerometer vector incorrectly and becomes a velocity and position error.
20 Connection to coning and sculling
INS07E2 showed that finite rotations do not commute. When several gyro subincrements are
combined before an attitude update, coning corrections are required to recover the leading
cross-product terms.
The accelerometer analogue is sculling. If the body rotates while accelerometer delta velocity is
accumulated, the direction in which each increment acts changes during the interval. Later lessons
will derive the coupled angular-increment and delta-velocity corrections needed for a full
sampled-data strapdown mechanization.
21 Summary
A digital gyro may provide angular rate or integrated delta angle. The software must distinguish
them explicitly.
For a finite navigation-relative angular increment
the exact quaternion increment is
For the convention used here,
A useful two-sided inertial update is
The small-angle approximation
is not exactly unit norm. Normalization restores the constraint but does not remove every
finite-angle approximation error.
A robust implementation should verify quaternion norm, DCM orthogonality, determinant,
one-axis propagation, multiplication order, Earth-rate cancellation, timestamp handling, and
rate-versus-delta-angle units.
The discrete quaternion mechanization is therefore more than a formula. It is a finite-rotation
algorithm with explicit frame conventions, sampling assumptions, numerical constraints, and
testable physical invariants.
References
[1] David H. Titterton and John L. Weston, Strapdown Inertial Navigation Technology,
2nd ed., Institution of Electrical Engineers, 2004.
[2] Paul D. Groves, Principles of GNSS, Inertial, and Multisensor Integrated Navigation
Systems, 2nd ed., Artech House, 2013.
[3] Christopher Jekeli, Inertial Navigation Systems with Geodetic Applications, Walter
de Gruyter, 2001.
[4] Paul G. Savage, “Strapdown Inertial Navigation Integration Algorithm Design Part
1: Attitude Algorithms,” Journal of Guidance, Control, and Dynamics, vol. 21, no. 1,
pp. 19–28, 1998.
[5] John E. Bortz, “A New Mathematical Formulation for Strapdown Inertial
Navigation,” IEEE Transactions on Aerospace and Electronic Systems, vol. AES-7, no.
1, pp. 61–66, 1971.