The Extended Kalman Filter: An Interactive Tutorial for Non-Experts

Part 3: Putting it Together

So now we have two equations describing the state of our airplane:

  altitudecurrent_time = 0.98 * altitudeprevious_time

  observed_altitudecurrent_time = altitudecurrent_time + noisecurrent_time

These equations are pretty easy to understand, but they aren't general enough to deal with systems other than our airplane-altitude example. To make the equations more general, engineers adopt the familiar mathematical convention of using names like $x$, $y$, and $z$ for variables and $a$ and $b$ for constants, and the subscript $k$ to represent time.[3] So our equations become: \[ \begin{aligned} x_k & = a x_{k-1} \\ z_k & = x_k + v_k \\ \end{aligned} \] where $x$ is the current state of our system, $x_{k-1}$ is its previous state, $a$ is some constant (0.98 in our example), $z_k$ is our current observation of the system, and $v_k$ is the current noise measurement. One reason the Kalman filter is so popular is that it allows us to get a very good estimation of the actual current state $x_k$ given the observation $z_k$, the constant $a$, and the overall amount of measurement noise $v$.

To complete the picture, we should also consider that that actual altitude of the airplane may not describe a perfectly smooth path. As anyone who has ever flown can tell you, airplanes typically experience a certain amount of turbulence as they descend for a landing. This turbulence is by definition noisy, and so can be treated as another noise signal:

  altitudecurrent_time = 0.98 * altitudeprevious_time + turbulencecurrent_time

More generally: \[ x_k = a x_{k-1} + w_k \] where $w_k$ is called the process noise, because, like turbulence, it is an inherent part of the process, and not an artifact of observation or measurement. We will ignore process noise for a while in order to focus on other topics, but we'll return to it in the section on Sensor Fusion.[4]

Previous:       Next:


[3] Why not t for time? Probably because time is being treated as a sequence of discrete steps, for which an index variable like k is conventional.

[4] I have also ignored the control-signal component of the state equation, because it is tangential to most of the Kalman Filter equations and can be easily added when needed.