Kalman filter - help me to set up a state equation

AI Thread Summary
The discussion focuses on setting up a Kalman filter to estimate the distance traveled by a vehicle using GPS, accelerometer, and barometer data. The user has converted GPS coordinates to a North, East, Down (NED) frame but faces challenges with accelerometer drift and accuracy of the magnetic heading. Suggestions include ensuring accelerometers are oriented correctly for better calibration and considering the integration of acceleration data with GPS corrections, despite inherent errors. The proposed Kalman filter model calculates distance based on sequential GPS position updates, but the user seeks feedback on its accuracy and potential improvements. Overall, the conversation emphasizes the complexities of sensor integration and the need for precise state estimation in vehicle tracking.
9988776655
Messages
46
Reaction score
0
I would like to find the distance that a vehicle travels using a Kalman filter. The vehicle is a car that travels the road between two positions. The vehicle has a GPS/barometer/accelerometer device that collects position data, which I converted from a longitude and latitude to a North, East, Down position in metres (This is a position coordinate of the starting coordinate is always 0,0,0). The velocity of the car is measured by this device in North, East, Down coordinates (m/s) (components of the velocity vector). I can access accelerometer measurements but this is in the device frame, not the North East Down frame. The device gives magnetic heading and euler angles roll pitch and yaw. The accelerometer has a problem with drift and the magnetic heading is not always accurate so I think that using the accelerometer for observations is not that important. Can anyone suggest a state matrix that helps me get a distance state? Thanks.
 
Engineering news on Phys.org
Some questions first:
  • How accurately are you trying to get the distance? AFAIK, the max GPS error box (not in altitude) is like 9m, so for a car traveling around a city you'd get pretty close to something actual.
  • Is there any reason you can't orient the accelerometers to give readings in the NED frame? That would help with calibration as well as not having to do 3D transformations.
  • Are you sure that the accelerometers drift? Because I know gyroscopes do, but in my experience accels are just noisy.
  • What device are you using to measure velocity? Accels measure acceleration, which is the derivative of velocity.
I don't think you need the magnetometer either. It's nice sometimes, but it's not really reliable or useful for your application.

You might be able to numerically integrate position from acceleration and correct it with your GPS readings, but that's kinda sketchy because there's error all over the place. If you had some way to measure the input to the wheels (like a u(t) function in the LTI equation xdot=Ax+Bu) and some knowledge about the car like the weight, you might be able to get something more accurate. The best way is if you had some sort of encoder on the car wheels. :)
 
The distance should just be the best estimation possible, given my observations. I know the GPS can have much error.
The accelerometers can't give readings in the NED frame without transformation using Euler angles. Euler angles are available from the system but I will use the magnitude of acceleration to get around this problem.
The accelerometers are noisy but you are right they don't drift.
The device uses the Doppler effect to measure velocity.
An encoder is not available for use.

I have decided on a Kalman filter model:
http://postimg.org/image/6h29p7e79/

Or for the word file version of this:
http://www.filedropper.com/kalmanfilter_1

The observation for the distance is:
temp(i) = sqrt((yEast(i)-yEast(i-1))^2 + (xNorth(i)-xNorth(i-1))^2+(zDown(i)-zDown(i-1))^2);
distance(i) =distance(i-1) + temp(i);

Where i is the index of a location given by the GPS coordinates in the North East Down frame and i = 0 ... N locations.

Units are metres, metres/sec, metres/sec^2

Can you please give me your thoughts and check if the model can be improved?
Thanks.
 
Last edited:
Thread 'I need a concave mirror with a focal length length of 150 feet'
I need to cut down a 3 year old dead tree from top down so tree causes no damage with small pieces falling. I need a mirror with a focal length of 150 ft. 12" diameter to 36" diameter will work good but I can't think of any easy way to build it. Nothing like this for sale on Ebay. I have a 30" Fresnel lens that I use to burn stumps it works great. Tree service wants $2000.
Hi all, i have some questions about the tesla turbine: is a tesla turbine more efficient than a steam engine or a stirling engine ? about the discs of the tesla turbine warping because of the high speed rotations; does running the engine on a lower speed solve that or will the discs warp anyway after time ? what is the difference in efficiency between the tesla turbine running at high speed and running it at a lower speed ( as fast as possible but low enough to not warp de discs) and: i...
Back
Top