Re: Kalman filter equation
- From: Thomas Arildsen <tha.es-aau-dk@xxxxxxxxxxxxxxx>
- Date: 30 Jul 2008 09:05:43 GMT
On Tue, 29 Jul 2008 19:21:12 +0200, Frank Neuhaus wrote:
Hi
I've got a question on one equation of the Kalman filter. First off, a
quick sync of the terminology (just like on Wikipedia)
x: System state estimate
P: System state estimation error covariance
F: Process Model
H: Measurement Model
z: Measurement
y: Innovation
S: Innovation covariance
K: Kalman Gain
Consider the first equations of the Kalman filter first (leaving out
subscripts etc):
x=Fx + w (leaving out control input u, w is the zero mean noise) P=F * P
* F^T + Q
The second Formula can be derived from the first using knowledge about
covariance matrices.
since P is just cov(x) we can compute P as: P=cov(x) = cov(Fx + w) =
cov(Fx) + cov(w) = F * cov(x) * F^T + Q = F * P * F^T + Q
The fact that cov(Fx)=F * cov(x) * F^T is just some identity that is
true for all covariance matrices.
So far so good... Now i tried to do the same thing on the last equation
of the Kalman Filter.
The Kalman gain is computed as K = P * H^T * S^-1
The update step looks like this:
x=x + K*y
Again we want P=cov(x)
So we write:
P = cov(x) = cov(x + K*y) = cov(x) + cov(K*y) = P + K * cov(y) * K^T
= P + K * S * K^T = P + (P * H^T * S^-1) * S * (P * H^T * S^-1)^T = P
+ P * H^T * S^-1 * S * S^-T * H * P^T
Now since P is symmetric, P^T=P, S is also symmetric, thus S*S^-T =
Identity
= P + P * H^T * S^-1 * H * P
= P + K * H * P
= (Identity + K*H)*P
So as you can see my result is P = (Identity + K*H)*P. When looking up
the formula in other sources, the result is (Identity !!-!! K*H)*P I
dont see where that - sign comes from though. Can anyone explain that?
Thanks alot :-)
Frank
I think your notation may be a little confusing since x and P in the
first half of your post are not the same as the x and P in the second
half. The Kalman filter equations are usually split into two steps; prior
and posterior. The first half of your post is the prior step and the
second half is the posterior step.
I would derive the equation you are looking for as follows:
x true state
x^ posterior state estimate
x^^ prior state estimate
P prior state error covariance
PP posterior state error covariance
I identity matrix
z measurement
H measurement matrix
v measurement noise
R measurement noise covariance
x~ = x - x^
x~~ = x - x^^
P = E{x~ * x~'} = E{(x - x^)(x - x^)'
= E{(x~~ - K(z - H'*x^^))(x~~ - K(z - H'*x^^))'}
= E{(x~~ - K(H'*x + v - H'*x^^))(x~~ - K(H'*x + v - H'*x^^))'}
= E{((I - K*H')*x~~ + K*v)((I - K*H')*x~~ + K*v)'}
= (I - K*H')*PP*(I - K*H')' + K*R*K'
= (I - K*H')*PP - (I - K*H')*PP*H*K' + K*R*K'
= (I - K*H')*PP - PP*H*K' + K*(H'*PP*H + R)*K'
= (I - K*H')*PP - PP*H*K' + PP*H*(H'*PP*H + R)^-1*(H'*PP*H + R)*K'
= (I - K*H')*PP - PP*H*K' + PP*H*K'
= (I - K*H')*PP
Best regards,
Thomas Arildsen
--
All email to sender address is lost.
My real adress is at es dot aau dot dk for user tha.
.
- Follow-Ups:
- Re: Kalman filter equation
- From: Frank Neuhaus
- Re: Kalman filter equation
- Prev by Date: extended Hamming code performance
- Next by Date: Re: Kalman filter equation
- Previous by thread: extended Hamming code performance
- Next by thread: Re: Kalman filter equation
- Index(es):