Extended Kalman Filter

The Extended Kalman Filter (EKF) is a nonlinear version of the Kalman filter used when the evolution or observation of the system state is nonlinear.

A discrete-time nonlinear system, consisting of state evolution and observation, can be expressed in a generalized form as

\begin{displaymath}
\left\{
\begin{array}{rl}
\mathbf{x}_{k+1} & = f (\mathbf{x}...
..._k & = h (\mathbf{x}_{k}, \mathbf{v}_k) \\
\end{array}\right.
\end{displaymath} (2.112)

where, in addition to the state $\mathbf{x}_{k}$ and the inputs $\mathbf{u}_{k}$, the process errors $\mathbf{w}_{k}$ and the observation errors $\mathbf{v}_k$ can also non-linearly affect the evolution of the state $f$ and the observation $h$, thereby generalizing the concept of additive noise used previously.

In order to be applied, EKF requires the computation of the Jacobians of both $f$ and $h$. By applying the theory presented in section 2.6 regarding the propagation of uncertainty in nonlinear functions, it is possible to leverage the same mathematical formulations used for the linear Kalman case on nonlinear functions by utilizing the matrices

\begin{displaymath}
\begin{array}{ll}
\mathbf{A}_k = \left. \frac{\partial f(\ma...
...\partial \mathbf{v}}\right\vert _{\bar{\mathbf{x}}}
\end{array}\end{displaymath} (2.113)

and employing the update equation
\begin{displaymath}
\hat{\mathbf{x}}_{k} = \hat{\mathbf{x}}^{-}_{k} + \mathbf{K}_k( \mathbf{z}_k - h(\hat{\mathbf{x}}^{-}_{k}) )
\end{displaymath} (2.114)

. It is also worth noting that the computation of the residual $\mathbf{z}_k - h(\hat{\mathbf{x}}^{-}_{k})$ can be a nonlinear function (for example, when comparing angles, where there exists a periodicity of the error).

Compared to the linear Kalman filter, the Extended Kalman Filter (EKF) is considered a sub-optimal choice as an estimator, yet it remains widely accepted and utilized in practical applications. The Extended Kalman Filter, by its very design, achieves only first-order accuracy but still allows for results that are close to optimal in scenarios where the second derivatives are negligible.

Paolo medici
2025-10-22