https://github.com/jdranczewski/optical-levitation-raytracin... for my repo, and https://onlinelibrary.wiley.com/doi/abs/10.1002/nme.5165 for the rotational dynamics with quaternions.
Visualizing quaternions (2018) - https://news.ycombinator.com/item?id=38043644 - Oct 2023 (42 comments)
Visualizing quaternions: an explorable video series (2018) - https://news.ycombinator.com/item?id=31083042 - April 2022 (15 comments)
Visualizing quaternions: An explorable video series - https://news.ycombinator.com/item?id=18310788 - Oct 2018 (32 comments)
https://www.olliw.eu/2013/imu-data-fusing/#chapter23
Best of luck =3
Edit: I get fusion is regarding multiple sensors
gyroscope: fast over-sampled low-pass filter, but slowly drifts compounding heading errors
accelerometer: relatively stable, but dead-reckoning errors compound quickly
magnetometer: best stability, but low-sample rate and vulnerable to metal/magnets fooling/blinding the sensors
The fusion algorithms usually weights which data is consistent with the motion path, and attenuates the estimated pose errors.
Notably, not all sensors are equal quality, but there are probably better options now. =3