Struct bayes_estimate::estimators::ud::UDState [−][src]
pub struct UDState<N: RealField, D: Dim> where
DefaultAllocator: Allocator<N, D, D> + Allocator<N, D>, { pub x: OVector<N, D>, pub UD: OMatrix<N, D, D>, // some fields omitted }
Expand description
UD State representation.
Linear representation as a state vector and ‘square root’ factorisation of the state covariance matrix. Numerically the this ‘square root’ factorisation is advantageous as conditioning for inverting is improved by the square root.
The state covariance is represented as a U.d.U’ factorisation, where U is upper triangular matrix (0 diagonal) and d is a diagonal vector. U and d are packed into a single UD Matrix, the lower Triangle ist not part of state representation.
Fields
x: OVector<N, D>
State vector
UD: OMatrix<N, D, D>
UD matrix representation of state covariance
Implementations
Create a UDState for given state dimensions.
D is the size of states vector and rows in UD.
Create a UDState for given state dimensions.
d is the size of states vector and rows in UD.
pub fn predict<QD: Dim>(
&mut self,
fx: &OMatrix<N, D, D>,
x_pred: &OVector<N, D>,
noise: &CoupledNoise<N, D, QD>
) -> Result<N, &'static str> where
D: DimAdd<QD>,
DefaultAllocator: Allocator<N, DimSum<D, QD>, U1> + Allocator<N, D, QD> + Allocator<N, QD>,
pub fn observe_innovation<ZD: Dim>(
&mut self,
s: &OVector<N, ZD>,
hx: &OMatrix<N, ZD, D>,
noise: &UncorrelatedNoise<N, ZD>
) -> Result<N, &'static str> where
DefaultAllocator: Allocator<N, ZD, D> + Allocator<N, ZD>,
pub fn observe_innovation<ZD: Dim>(
&mut self,
s: &OVector<N, ZD>,
hx: &OMatrix<N, ZD, D>,
noise: &UncorrelatedNoise<N, ZD>
) -> Result<N, &'static str> where
DefaultAllocator: Allocator<N, ZD, D> + Allocator<N, ZD>,
Implement observe using sequential observation updates.
Uncorrelated observations are applied sequentially in the order they appear in z.
Special Linear ‘hx’ observe for correlated factorised noise.
Observation predictions are made with the linear ‘hx’. This allows the observation noise to be decorrelated. Observations can then be applied for each element in the order they appear in z.
Return: Minimum rcond of all sequential observations
pub fn new_predict_scratch<QD: Dim>(&self, qd: QD) -> PredictScratch<N, D, QD> where
D: DimAdd<QD>,
DefaultAllocator: Allocator<N, D, QD> + Allocator<N, DimSum<D, QD>, U1>,
pub fn predict_use_scratch<QD: Dim>(
&mut self,
scratch: &mut PredictScratch<N, D, QD>,
x_pred: &OVector<N, D>,
fx: &OMatrix<N, D, D>,
noise: &CoupledNoise<N, D, QD>
) -> Result<N, &'static str> where
D: DimAdd<QD>,
DefaultAllocator: Allocator<N, DimSum<D, QD>> + Allocator<N, D, QD> + Allocator<N, QD>,
pub fn observe_innovation_use_scratch<ZD: Dim>(
&mut self,
scratch: &mut ObserveScratch<N, D>,
s: &OVector<N, ZD>,
hx: &OMatrix<N, ZD, D>,
noise: &UncorrelatedNoise<N, ZD>
) -> Result<N, &'static str> where
DefaultAllocator: Allocator<N, ZD, D> + Allocator<N, ZD>,
Trait Implementations
impl<N: Copy + RealField, D: Dim> KalmanEstimator<N, D> for UDState<N, D> where
DefaultAllocator: Allocator<N, D, D> + Allocator<N, D>,
impl<N: Copy + RealField, D: Dim> KalmanEstimator<N, D> for UDState<N, D> where
DefaultAllocator: Allocator<N, D, D> + Allocator<N, D>,
Initialise the UDState with a KalmanState.
The covariance matrix X is factorised into a U.d.U’ as a UD matrix.
Derive the KalmanState from the UDState.
The covariance matrix X is recomposed from U.d.U’ in the UD matrix.
Auto Trait Implementations
impl<N, D> !RefUnwindSafe for UDState<N, D>
impl<N, D> !UnwindSafe for UDState<N, D>
Blanket Implementations
Mutably borrows from an owned value. Read more
type Output = T
type Output = T
Should always be Self
The inverse inclusion map: attempts to construct self
from the equivalent element of its
superset. Read more
pub fn is_in_subset(&self) -> bool
pub fn is_in_subset(&self) -> bool
Checks if self
is actually part of its subset T
(and can be converted to it).
pub fn to_subset_unchecked(&self) -> SS
pub fn to_subset_unchecked(&self) -> SS
Use with care! Same as self.to_subset
but without any property checks. Always succeeds.
pub fn from_subset(element: &SS) -> SP
pub fn from_subset(element: &SS) -> SP
The inclusion map: converts self
to the equivalent element of its superset.