Kalman Filters Keep Measurements on Track

Published By

The Kalman filter is used to continually improve a system’s estimate of factors such as distance, velocity and direction. It is applicable in situations where there is more than one way of measuring something, as perhaps a robot’s new position as a result of a movement. After each move, and each set of measurements, more weight in subsequent measurements of movement and position is given to those predictors that have been judged by the Kalman filter to be better estimators.

Kalman filters deal with problems caused by random, Gaussian noise. It minimizes, or filters their effect, which is why the construct is called a filter. It is not a discrete product as such, but rather a set of coded equations that is part of the structure of a measurement and control system.

A Simple Block Diagram Representation

As a starting point, consider this block diagram:

0715_Kalman Filters Keep Measurements on Track_inarticle1 

Figure 1: The starting point for a Kalman filter. (Source: Swarthmore College)

In the diagram above, u might represent a moving or a braking force, applied through a factor b, and x might be position. A is the effect the previous value of x has on the present value of x. The inner loop of the block diagram is a system where the value of x is equal to the previous value of x (that is, xj-1), multiplied by the value a, plus an input of u multiplied by a factor b. Wj, or noise, must also be factored in. The loop with the “T” inserted means that this is a recursive process. Another way of saying the same thing for the inner loop is:

xj = axj-1 + buj + wj

The final part of the loop describes measuring xj by multiplying by h. Of course, noise associated with the measuring system, Vj, is also introduced. That, in equation form, is:

Zj  = hxj  + vj

Looking at it Graphically

Now, we come to the fundamental purpose of the Kalman filter, which is how to eliminate the noise associated with the movement and the measurement. This is done by predicting and correcting. The Kalman filter predicts the next value of x based on the previous value of x. Then, that estimate is corrected by comparing it to another estimate (a.k.a. a measurement of the value). Thanks to the loop, the system has the “memory” of the previous estimates and it can be shown the Kalman filter minimizes the error of the estimate. This is represented in Figure 3.

A graphical representation of the process, applied to the prediction of the initial location of a train is as below:

0715_Kalman Filters Keep Measurements on Track_inarticle2 

Figure 2: Possible initial positions. (Source: University of Cambridge, Lecture Notes from Ramsey Faragher)

The red envelope represents a Gaussian distribution of the possible initial positions of a train. One iteration later, after the train is forced forward, the picture changes to that seen below.

0715_Kalman Filters Keep Measurements on Track_inarticle3 

Figure 3: Making better estimates. (Source: University of Cambridge, Lecture Notes from Ramsey Faragher)

After the train is forced forward, the pink area represents the Gaussian envelope of predictions for the new position; the blue is a distribution of the position’s measurement. The green is the new estimate of position, based on prediction and measurement. Thus, with each iteration, more knowledge is gained, thanks to the Kalman filter.

The end result is that with Kalman filters, system designers can get the most out of noisy, uncertain estimates. The process is recursive, and over time, the system is improved for tighter control and better results.

Related news articles

Latest News

Sorry, your filter selection returned no results.

We've updated our privacy policy. Please take a moment to review these changes. By clicking I Agree to Arrow Electronics Terms Of Use  and have read and understand the Privacy Policy and Cookie Policy.

Our website places cookies on your device to improve your experience and to improve our site. Read more about the cookies we use and how to disable them here. Cookies and tracking technologies may be used for marketing purposes.
By clicking “Accept”, you are consenting to placement of cookies on your device and to our use of tracking technologies. Click “Read More” below for more information and instructions on how to disable cookies and tracking technologies. While acceptance of cookies and tracking technologies is voluntary, disabling them may result in the website not working properly, and certain advertisements may be less relevant to you.
We respect your privacy. Read our privacy policy here