mherb/kalman

Is time-step fixed?

sume-cn opened this issue · 2 comments

When applied in real projects, the time-step (Δt) may vary according to different sensor setup.
In SystemModel.hpp, the f() function gives no time parameter, which implies the time-step is fixed.
Is there any way to modify dt, as it is in OpenCV's KalmanFilter?

mherb commented

The current recommended method to deal with arbitrary (including time varying) time steps is to model this in your SystemModel implementation. I.e. you could add a member variable "timestep" to your system model and set its value every time the timestep changes using e.g. sysModel.setTimestep(dt) and use that in your model transition and jacobian computation.

For future versions, it is planned that such additional parameters can be passed directly to the prediction step as suggested.

thanks a lot!