@@ -243,3 +243,44 @@ estimate the roll and pitch degrees of freedom of a moving body using the
243243 roll_pitch_est.append(vru.euler(degrees = False )[:2 ])
244244
245245 roll_pitch_est = np.array(roll_pitch_est)
246+
247+
248+ Smoothing
249+ ---------
250+ Smoothing refers to post-processing techniques that enhance the accuracy of a Kalman
251+ filter's state and covariance estimates by incorporating both past and future measurements.
252+ In contrast, standard forward filtering (as implemented in :class: `~smsfusion.AidedINS `)
253+ relies only on past and current measurements, leading to suboptimal estimates when
254+ future data is available.
255+
256+ Fixed-interval smoothing
257+ ........................
258+ The :class: `~smsfusion.FixedIntervalSmoother ` class implements fixed-interval smoothing
259+ for an :class: `~smsfusion.AidedINS ` instance or one of its subclasses (:class: `~smsfusion.AHRS `
260+ or :class: `~smsfusion.VRU `). After a complete forward pass using the AINS algorithm,
261+ a backward sweep with a smoothing algorithm is performed to refine the state
262+ and covariance estimates. Fixed-interval smoothing is particularly useful
263+ when the entire measurement sequence is available, as it allows for optimal state
264+ estimation by considering all measurements in the sequence.
265+
266+ The following example demonstrates how to refine a :class: `~smsfusion.VRU `'s roll
267+ and pitch estimates using :class: `~smsfusion.FixedIntervalSmoother `. The same
268+ workflow applies if the underlying AINS instance is an :class: `~smsfusion.AidedINS `
269+ or an :class: `~smsfusion.AHRS ` instead. However, note that the ``update() `` method may take
270+ additional aiding parameters depending on the type of AINS instance used.
271+
272+ .. code-block :: python
273+
274+ import smsfusion as sf
275+
276+
277+ vru_smoother = sf.FixedIntervalSmoother(vru)
278+
279+ for f_i, w_i in zip (acc_imu, gyro_imu):
280+ vru_smoother.update(
281+ f_i,
282+ w_i,
283+ degrees = False
284+ )
285+
286+ roll_pitch_est = vru_smoother.euler(degrees = False )[:, :2 ]
0 commit comments