Package org.hipparchus.filtering.kalman
Class KalmanSmoother
java.lang.Object
org.hipparchus.filtering.kalman.KalmanSmoother
- All Implemented Interfaces:
KalmanObserver
Kalman smoother for linear, extended or unscented filters.
This implementation is attached to a filter using the observer mechanism. Once all measurements have been processed by the filter, the smoothing method can be called.
For example
// Kalman filter
final KalmanFilter<SimpleMeasurement> filter = new LinearKalmanFilter<>(decomposer, process, initialState);
// Smoother observer
final KalmanSmoother smoother = new KalmanSmoother(decomposer);
filter.setObserver(smoother);
// Process measurements with filter (forwards pass)
measurements.forEach(filter::estimationStep);
// Smooth backwards
List<ProcessEstimate> smoothedStates = smoother.backwardsSmooth();
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionBackwards smooth.void
init
(KalmanEstimate estimate) Callback for initialisation of observer.void
updatePerformed
(KalmanEstimate estimate) Notification callback after each Kalman filter measurement update.
-
Constructor Details
-
Method Details
-
init
Description copied from interface:KalmanObserver
Callback for initialisation of observer.- Specified by:
init
in interfaceKalmanObserver
- Parameters:
estimate
- estimate calculated by a Kalman filter
-
updatePerformed
Description copied from interface:KalmanObserver
Notification callback after each Kalman filter measurement update.- Specified by:
updatePerformed
in interfaceKalmanObserver
- Parameters:
estimate
- estimate calculated by a Kalman filter
-
backwardsSmooth
Backwards smooth. This is a backward pass over the filtered data, recursively calculating smoothed states, using the Rauch-Tung-Striebel (RTS) formulation. Note that the list result is a `LinkedList`, not an `ArrayList`.- Returns:
- list of smoothed states
-