Math Bridge: Why does gyroscope angle drift?

← Back to Mobile Sensing and Human Activity Recognition
Math BridgeAnalytics & MLStruggle-friendly runway

Why does gyroscope angle drift?

Build angle from rate samples, then watch a tiny bias accumulate faster than random walk over a long trial.

Data Dora, the guideData Dora guides
The one targetIntegrate angular rate and separate two different error growth laws.
The chapter case50 Hz, 2-second HAR windows, and a 60-second gait trial.
What it buys youA reason to fuse sensors and keep ground truth.

A field team faces an unresolved physical question: Why does gyroscope angle drift? They must answer it before changing trial duration on the real device. Predict the direction first.

See the relationship before changing it

The figure reads from left to right. The blue card is trial duration. The middle card applies this page's relationship. The green card is sample period. Walk the arrows once: set the input, apply the rule, then read the result with its unit.

The retained audit below checks several chapter fixtures. This added model holds every other chapter fixture fixed, so the numeric fixture does not switch without explanation.

Trial duration changes sample period An input card leads through the page relationship to the sample period result. SET INPUT ONE CONTROL APPLY RULE predict calculate check units READ RESULT
Walk the arrows. Short-window features can tolerate small absolute-angle errors, while joint tracking across a full trial needs accelerometer fusion, calibration, constraints, or independent reference motion.

Derive the baseline in four named moves

  1. 1

    Name the input. The chapter baseline for trial duration is 60.

  2. 2

    Name the relationship. fs=50 Hz → Δt=0.0200 s 2 s: bias=0.100°; ARW=0.0236° 60 s: bias=3.00°; ARW=0.129°; ratio=23.24x

  3. 3

    Substitute the chapter fixture. Set trial duration to 60. The page ledger gives sample period as 0.02 s.

  4. 4

    Read the result. Keep s beside the value. Use it only inside the technical boundary on this page.

Predict, then change trial duration

Try Predict the direction of sample period. Move one control, calculate, then check your prediction.

60
Chapter baseline
Sample period

Observe Short-window features can tolerate small absolute-angle errors, while joint tracking across a full trial needs accelerometer fusion, calibration, constraints, or independent reference motion. Reset the control to 60 and compare sample period.

Explain Only trial duration moves here. The other chapter fixtures remain fixed.

Check yourself

What should you do before trusting a moved-control result?
Answer: Predict its direction, apply the shown relationship, keep the units, and reset to the worked baseline.
What does this small model leave out?
Answer: Only trial duration moves. Field effects named in the page's technical boundary stay fixed.

1. Start with what a gyro measures

A gyroscope measures angular rate, such as degrees per second. Angle appears only after the pipeline adds each rate contribution over time.

Data Dora: Integration remembers every genuine turn—and every persistent error.

2. Name every algebra move

1

Invert sample rateΔt=1/fs.

2

Convert one sampleAngle contribution=ωiΔt.

3

Add contributionsθn=θ0+ΔtΣωi.

4

Integrate biasΔθbias=b×t.

5

Scale random walkσARW=ARW×√(t/3600).

3. Reproduce the chapter case

fs=50 Hz → Δt=0.0200 s
2 s: bias=0.100°; ARW=0.0236°
60 s: bias=3.00°; ARW=0.129°; ratio=23.24×

The small fixed offset wins over time because it grows with t while independent random walk grows only with √t.

4. Try the trial duration

TryLengthen the trial and watch linear bias pull away from square-root random walk.

Trial duration
Sample period
Sample count
2 s bias
2 s random walk
Trial bias
Trial random walk
Bias/random ratio

ObserveAt 60.00 s, 3,000 samples accumulate 3.000° bias and 0.129° random walk. Inside one 2-second window they are only 0.100° and 0.024°.

ExplainShort-window features can tolerate small absolute-angle errors, while joint tracking across a full trial needs accelerometer fusion, calibration, constraints, or independent reference motion.

Technical boundaries.

This compact engine isolates two error terms; it is not a complete IMU model.

Bias
The residual bias is held constant instead of changing with temperature and time
Noise
The ARW rule assumes the rating and independent sample behaviour apply
Fusion
Accelerometer, magnetometer, mounting, coordinate transforms, and filter tuning are omitted

Validate the complete pipeline against synchronized ground truth and placement changes.

5. Choose the correction evidence

Use a still calibration to estimate bias, gravity-referenced acceleration to bound tilt, legal HMM transitions to constrain phase order, and Vicon or another reference to test complete trial accuracy.

6. Keep the motion record

Record sample rate, clock alignment, sensor placement and axes, calibration, bias, ARW rating, window and overlap, fusion method, ground truth, tolerance, user group, owner, and retest trigger.

7. Check yourself

Why is each 50 Hz sample 0.0200 seconds?
Answer: Sample period is the reciprocal of sample rate: 1/50=0.0200 s.
Why does 0.0500°/s become 3.00° after one minute?
Answer: Constant bias integrates linearly: 0.0500×60=3.00°.
Does low error inside one window prove long-trial angle accuracy?
Answer: No. Bias keeps accumulating, and the complete fusion, mounting, timing, and ground-truth contract still needs validation.
Honesty boundary.

The sample rate and durations come from the chapter; sensor error values are labelled teaching assumptions.

50 Hz and 2 seconds
The chapter's windowed HAR example
60 seconds
A realistic trial length bounded in the original formula note
0.0500°/s and 1.00°/√hr
Catalog-typical residual bias and ARW teaching values

Correct, not complete: the actual sensor and validation protocol own the claim.