Rank: 29538 based on 0 downloads (last 30 days) and 0 file submitted
photo

John D

E-mail

Personal Profile:

 

Watch this Author's files

 

Comments and Ratings by John D View all
Updated File Comments Rating
09 Jun 2010 Learning the Kalman Filter Basic Kalman filter, heavily commented, for beginners to Kalman filtering. Author: Michael Kleder

[continued from poste above]

As expected my matrices were wrong!

Thanks for the example!

09 Jun 2010 Learning the Kalman Filter Basic Kalman filter, heavily commented, for beginners to Kalman filtering. Author: Michael Kleder

[continued from poste above]

I have solved the problem by modifying the line to;

>> s.x = s.x + K' * (s.z-s.H*s.x); %added transpose of K

This was required as my observance vector (z) was a 2X1 matrix(and so is K and hence they couldn't be multiplied). Although the calculation now works I am still wondering why it doesnt work with the original code.

08 Jun 2010 Learning the Kalman Filter Basic Kalman filter, heavily commented, for beginners to Kalman filtering. Author: Michael Kleder

I get an error during the correction step.
>> s.x = s.x + K*(s.z-s.H*s.x);

Error using==>mtimes
Inner matrix dimensions must agree

The error makes sense given the size of my matrices but I don't see how they could be wrong. Is this code expected to not work for a system with two observer inputs (position and speed)?

Thanks for the help!
ps: let me know if you need more info - tried to keep it short.

Contact us