# Using Kalman Filters with different dimensionality in an Interacting Multiple Model Algorithm

I am currently reading a lot about Kalman Filtering and am especially interested in the IMM - Interactive Multiple Model Algorithm. In the literature (e.g. here), IMM is used for Kalman Filters with state vectors of different dimensionality. For example, the paper linked above combines a constant velocity (6 dimensions) with an constant acceleration (9 dimensions) Model. When looking at the math of the IMM, this doesn't seem to make sense: mixing the state estimates consists of taking a weighted sum of the state vector of each Filter (weighted by the probability of that Filter). But if those state vectors have different dimensions, this operation doesn't make sense. The same goes for the calculation of the covariance matrix.

Does anyone here now more about IMMs and how these are implemented? Does an IMM only track the dimensions common to every Filter and does one "extract" only those when mixing state estimates?

• Why don't you inquire with the author? Then let us know what he says. Sep 12, 2018 at 23:14

The link to the provided document does not work.

Basically you need all models in IMM (Interactive Multiple Model) to have same dimensionality, otherwise the algorithm does not work. The problem is, that sometimes, you need to have more dimensions for one of the models. In your case there is a model with dimensionality 9 and the second has 6 dimensions.

The simple solution is, that you add 3 more dimensions into the smaller model and fix them on constant zeros. This way both models have same dimensions and still the smaller model has same behaviour.

Of what I observed on MATLAB :

• there is an IMM state vector that corresponds to the first model provided

• When mixing the other states are converted into the IMM state vector with the "switchimm" function

The switchimm function converts a state vector from one motion model to another by putting 0's when the dimension does not exist in the input model.

For the covariance matrix, it sets the variance to 100 when the dimension does not exist.

https://fr.mathworks.com/help/fusion/ref/switchimm.html

x = [1; 2; 3; 3]; %constvel = [x; vx; y; vy]; constturn = [x; vx; y; vy; w]
disp(switchimm("constvel", x, "constturn"))

>> test
1
2
3
3
0

There are other more elaborate ways that exist : https://ieeexplore.ieee.org/abstract/document/6324701 https://ieeexplore.ieee.org/document/7376231