3.5.22 · D1Guidance, Navigation & Control (GNC)

Foundations — Kalman gain — minimizes trace of covariance

3,068 words14 min readBack to topic

This page assumes nothing. Before you can read the parent note Kalman gain, you must be able to read every symbol it throws at you: , , , , , , , , , , , and the little superscripts , , . We build them one at a time, each anchored to a picture.


0. The stage: "state" and "estimate"

Figure s01 (below): a horizontal number line with a green dot marking the true state on the right and a blue dot marking our estimate to its left; a red arrow runs from the blue dot to the green dot, labelled — the error we're about to define.

Figure — Kalman gain — minimizes trace of covariance

1. Error — measuring "how wrong"


2. Expectation — the "average over all luck" machine


3. The zero-mean assumption — why matters

So far we only have the estimation error ; the sensor and its noise arrive later in §7. So for now the zero-mean idea is stated for alone (we'll repeat it for the sensor noise once that noise is defined).


4. Variance and covariance — the "blur" of a guess

When the state has several components (position and velocity), one variance per component isn't enough — errors in different components can be linked. We collect all of them into a matrix. (The "transpose" symbol used just below is defined fully in §6; for now read as "the column of errors times the same errors laid out as a row," which builds a square table.)

Figure s02 (below): a wide blue ellipse and a small green ellipse, both centred on a white dot marked , drawn over axes "state component 1" and "state component 2". The wide ellipse is labelled "big blur = big (unsure)"; the tight one "small blur (sure)" — showing that the size of the ellipse is the amount of uncertainty encodes.

Figure — Kalman gain — minimizes trace of covariance

5. The Euclidean norm and the trace

Before the trace, one small piece of notation the parent note leans on:


6. The transpose and matrices — reshaping and mapping

Figure s03 (below): a blue box on the left labelled "state-space" containing (position and velocity), a yellow arrow labelled " (convert)" pointing rightward, and a green box on the right labelled "measurement-space" containing " = position only" — illustrating that drops/mixes state components down into what the sensor can actually read.

Figure — Kalman gain — minimizes trace of covariance

7. Measurement , sensor noise , noise covariance


8. The superscripts and — before vs after


9. The gain — the slider that ties it all together


Prerequisite map

Zero-mean assumption - E of e and v are 0

Covariance P - the blur ellipse

Expectation - average over luck

Error e = x minus x-hat

Euclidean norm - straight-line length

Trace - total blur as one number

Transpose - flip rows and columns

H - state to sensor map

Measurement z = Hx + v

R - sensor noise size

Noise v inside each reading

Minimize trace of P-plus

Gain K - the trust slider

Kalman gain - minimizes trace of covariance


Equipment checklist

Test yourself — you're ready for the parent note only if you can answer each without peeking.

What does a hat, as in , always mean?
"Our best estimate / guess of" — never the true value.
Write the estimation error and say what it points to.
; the gap/arrow from our guess back to the truth.
What does compute and why do we need it?
The average over infinitely many random repetitions; noise is random so we compare strategies by average behaviour.
Why do we square the error before averaging?
So positive and negative errors don't cancel — can be 0 while the guess is still wrong; captures true spread.
What zero-mean assumptions does the filter make, and why?
and (unbiased); only then are and true covariances rather than raw second moments.
What does mean?
The Euclidean (straight-line) length ; and .
What is in words, and what picture goes with it?
The error covariance ; an uncertainty ellipse around the guess — its size is our blur.
What two properties does always have, and why do they matter?
Symmetric () and positive semidefinite (); these are exactly what let be drawn as a sensible uncertainty ellipse.
Show why .
.
What does the matrix do?
Maps state-space into measurement-space; is "what we'd expect the sensor to read."
What are and ?
is the random sensor noise inside each reading; is its size (the sensor's own uncertainty).
Distinguish the superscripts and .
= prior, before using the measurement; = posterior, after using it.
Under what assumptions is the posterior ellipse never bigger than the prior?
The linear-Gaussian setting with the optimal gain; it can fail for nonlinear models, bad gains, or non-Gaussian noise.
In one sentence, what is the Kalman gain ?
The 0-to-1 slider setting how much of the sensor's surprise we fold into our guess, chosen to minimize the after-blur.