The toolbox provides multiple filters to estimate the pose and velocity of platforms by using onboard inertial sensors (including accelerometer, gyroscope, and altimeter), magnetometer, GPS, and visual odometry measurements. Each filter can process certain types of measurements from certain sensors. Each filter also makes assumptions and may have limitations that you should consider carefully before applying it. For example, many filters assume no sustained linear or angular acceleration other than the gravitational acceleration. Therefore, you should avoid using them during strong and constant acceleration, but these filters can perform reasonably well during short linear acceleration bursts. Also, some filters allow piecewise constant linear acceleration and angular velocity since they allow acceleration and angular velocity inputs during the prediction step.
The internal algorithms of these filters also vary greatly. For example, the ecompass
object uses the TRIAD method to determine the orientation of the
platform with very low computation cost. Many filters (such as ahrsfilter
and imufilter
) adopt the errorstate Kalman filter, in which the state deviation
from the reference state is estimated. Meanwhile, other filters (such as insfilterMARG
and insfilterAsync
) use the extended Kalman filter approach, in which the state is
estimated directly.
To achieve high estimation accuracy, it is important to tune the filter properties and
parameters properly. The toolbox offers the builtin tune
(Sensor Fusion and Tracking Toolbox) function to tune
parameters and sensor noise for the imufilter
, ahrsfilter
, and insfilterAsync
directly.
The table lists the inputs, outputs, assumptions, and algorithms for all the inertial sensor fusion filters.
Object  Sensors and Inputs  States and Outputs  Assumptions or Limitations  Algorithm Used 

ecompass

 Orientation  The filter assumes no sustained linear and angular acceleration other than gravitational acceleration.  TRIAD method 
ahrsfilter

 Orientation and angular velocity  The filter assumes no sustained linear and angular acceleration other than gravitational acceleration.  Errorstate Kalman filter 
ahrs10filter 
 Orientation, altitude, vertical velocity, delta angle bias, delta velocity bias, geomagnetic field vector, magnetometer bias  The filter assumes piecewise constant linear acceleration in the vertical direction, and no sustained linear and angular acceleration other than gravitational acceleration in other directions.  Discrete extended Kalman filter 
imufilter

 Orientation and angular velocity  The filter assumes no sustained linear and angular acceleration other than gravitational acceleration.  Errorstate Kalman filter 
complementaryFilter 
 Orientation and angular velocity  The filter assumes no sustained linear and angular acceleration other than gravitational acceleration.  NonKalman filter based approach:

insfilterMARG

 Orientation, position, velocity, delta angle bias, delta velocity bias, geomagnetic field vector, magnetometer bias  The prediction step takes the accelerometer and gyroscope inputs. Therefore, the filter assumes:
 Discrete extended Kalman filter 
insfilterAsync

 Orientation, angular velocity, position, velocity, acceleration, accelerometer bias, gyroscope bias, geomagnetic field vector, magnetometer bias  The filter assumes:
The filter does not require the sensors to be synchronous and each sensor can have sample dropping.  Continuous discrete extended Kalman Filter 
insfilterNonholonomic 
 Orientation, position, velocity, gyroscope bias, accelerometer bias  The prediction step takes the accelerometer and gyroscope inputs. Therefore, the filter assumes:
Also, the filter assumes the platform moves forward without side slip.  Discrete extended Kalman Filter 
insfilterErrorState 
 Orientation, position, velocity, gyroscope bias, accelerometer bias, and visual odometry scale  The prediction step takes the accelerometer and gyroscope inputs. Therefore, the filter assumes:
 Errorstate Kalman filter 