Skip to content

Commit

Permalink
Update readme.md
Browse files Browse the repository at this point in the history
  • Loading branch information
e-pet authored Dec 25, 2021
1 parent 2f8232d commit 72ecfda
Showing 1 changed file with 18 additions and 13 deletions.
31 changes: 18 additions & 13 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
### KFS-suite
## KFS-suite

This is a collection of three Kalman filter and smoother implementations in Matlab:
1) A linear Kalman filter and Rauch-Tung-Striebel smoother
Expand All @@ -12,31 +12,36 @@ All three filters/smoothers can correctly treat the following:
- state constraints (a simple projection-based approach is implemented).

All three filters/smoothers return various quantities that might be of interest for further diagnostics or analyses.
In particular, all three functions return the innovation signals, and the two linear filters return the negative log data likelihood, also known as the *energy*.
Both innovation and energy can be used as optimization targets for *estimating any of the state-space model parameters*, such as the noise covariances.
In particular, all three functions return the innovation signals, and the two linear filters return the negative log data likelihood, also known as the **energy**.

Both innovation and energy can be used as optimization targets for **estimating any of the state-space model parameters**, such as the noise covariances.
(Some of the tests/demo cases show how to do this.)
Various tests and demos are included to *verify the correctness* of various aspects of the implementation, and to showcase its utility.
Significant effort has been invested into ensuring the *numerical robustness* and accuracy of the implementation, whereas execution speed was *not* a major concern.
As a rather unusual feature, the two linear filters/smoothers implement the *sample weighting* approach described in Petersen (2022).

Various tests and demos are included to **verify the correctness** of various aspects of the implementation, and to showcase its utility.
Significant effort has been invested into ensuring the **numerical robustness** and accuracy of the implementation, whereas execution speed was *not* a major concern.

As a rather unusual feature, the two linear filters/smoothers implement the **sample weighting** approach described in Petersen (2022).
This can be used to perform importance-weighted estimation in the face of model mismatch, covariate shift, and time-varying systems, as described in Petersen (2022) and illustrated in `test_wkfs.m`.
Finally, as a limitation, currently, only the first filter/smoother (linear KF + RTS) supports inputs, although the other two could be quite trivially extended to also support this.

Concerning the nonlinear filter and smoother, a *general iterative sigma-point quadrature filter and smoother* have been implemented.
Turning off iterations and choosing the unscented transform as a quadrature scheme, this is equivalent to the classical unscented Rauch-Tung-Striebel smoother.
Finally, as a limitation, currently, only the first filter/smoother (linear KF + RTS) supports **inputs** ("+B u(k)"), although the other two could be quite trivially extended to also support this.

Concerning the nonlinear filter and smoother, a **general iterative sigma-point quadrature filter and smoother** has been implemented.
Turning off iterations and choosing the unscented transform as a quadrature scheme, this is equivalent to the classical **unscented Rauch-Tung-Striebel smoother**.
As an alternative quadrature scheme, the general (also multivariate) Gauss-Hermite quadrature rule is provided for use.
Since the implementation is modular, alternative quadrature schemes could easily be integrated.
Concerning the iterative aspect of the implementation, it has been shown in a number of studies that approximative nonlinear (e.g., extended, unscented, or Gauss-Hermite) filters and smoothers can greatly benefit from performing iterative filter/smoother runs.

Concerning the **iterative aspect** of the implementation, it has been shown in a number of studies that approximative nonlinear (e.g., extended, unscented, or Gauss-Hermite) filters and smoothers can greatly benefit from performing iterative filter/smoother runs.
The included demo case demonstrates this effect very clearly.
By default, iterations are performed both within individual samples and across whole filter/smoother runs.
Dampening is implemented to speed up convergence across iterations.

As the documentation is likely far from complete and clear, *please don't hesitate to ask away in case of any questions.*
As the documentation is likely far from complete and clear, **please don't hesitate to ask away in case of any questions.**
My wish is for this toolbox to be useful to as many people as possible.
(If there is sufficient demand, I might be willing to put together a dedicated PDF documentation in the future.)
Also, please do not hesitate to contact me in case of any bugs or problems with the code.


##### Third-party content
#### Third-party content
The following files (in the directory `3rd party code`) have been written by other authors:
- the `block-matrix-inverse-tools` have been written by **Richard Lange**, see https://github.com/wrongu/block-matrix-inverse-tools
- `vline2.m` has been written by **K. Stahl**, see https://www.mathworks.com/matlabcentral/fileexchange/29578-improved-vline
Expand All @@ -48,7 +53,7 @@ Copyright remains with the original authors, of course.
Check the original sources (provided above) if in doubt about licensing.


##### References
#### References
- Arasaratnam and Haykin (2007), Discrete-Time Nonlinear Filtering Algorithms Using Gauss-Hermite Quadrature, Proceedings of the IEEE.
- Dan Simon (2006), Optimal State Estimation, John Wiley & Sons, Inc.
- Dan Simon (2009), Kalman filtering with state constraints: a survey of linear and nonlinear algorithms, IET Control Theory and Applications.
Expand Down

0 comments on commit 72ecfda

Please sign in to comment.