2

I'm trying to implement a Kalman filter in a computationally efficient way. The main issue is the inversion of the innovation residual:

  S=HPH^t+R

  K=PH^t*inv(S)

My question is, can one assume that the S matrix in positive definite? This would make inverting it more computationally efficient....

Ali
  • 56,466
  • 29
  • 168
  • 265
staple
  • 125
  • 3

2 Answers2

1

Yes, S is symmetric positive definite as mentioned here, and also how it can be automatically recognized:

I find that presentation fascinating!


EDIT: I have done a little research and it turns out one has to be very careful when implementing the Kalman-Filter in order to retain the symmetric positive definiteness. Keywords: "stabilized Kalman filter" and "Josepf form". See for example Linear-Optimal Estimation for Discrete-Time Systems, page 7 or Understanding and Applying Kalman Filtering, page 28.

To address bits_international's comment, see Under what circumstance will a covariance matrix be positive semi-definite rather than positive definite? or page 7 in Understanding and Applying Kalman Filtering. In short, it is positive definite unless there is a linear dependence among the components.

Community
  • 1
  • 1
Ali
  • 56,466
  • 29
  • 168
  • 265
1

Another way to reduce the cost of inverting S is to use serial updates. In a nutshell: Predict, then repeat the update step for each row of H. In this case, HPH', R, and therefore S are all scalar, so inverting S is trivial. If R is diagonal (as is often the case) this doesn't require any extra work. If there are off-diagonal terms, you can orthogonalize your measurements. Most of the effort there can be pre-computed.

Several square root KF formulations rely on serial updates, so look at those for more ideas.

Ben Jackson
  • 90,079
  • 9
  • 98
  • 150