dstl / Stone-Soup

A software project to provide the target tracking community with a framework for the development and testing of tracking algorithms.
https://stonesoup.rtfd.io
MIT License
384 stars 126 forks source link

Fix non linear constant turn transition model #844

Closed orosoman-dstl closed 10 months ago

orosoman-dstl commented 10 months ago

I found a few bugs in the ConstantTurn transition model, which this PR aims to fix.

  1. As detailed in #841, the documentation for Q_t did not match the implementation.
  2. The bottom right term in the Q_t array was erroneously divided by the change in time, which would result in the noise of the turn rate being smaller for a larger change in time. I'm not really sure personally why this value is not instead multiplied by dt, but this seems to be a misunderstanding on my part and not a mistake.
  3. There was an issue where if you put in an integer turn rate of zero, you would get an error for division by zero. This is a little bit academic as it's not really the intended use for this transition model, but I thought it was worth fixing for consistency.

I have also raised up a misbehaving comma in the first tutorial as it looked slightly messy.