26#include "msceqf/system/system.hpp"
27#include "msceqf/options/msceqf_options.hpp"
28#include "msceqf/state/state_elements.hpp"
43 using MSCEqFStateMap = std::unordered_map<MSCEqFStateKey, MSCEqFStateElementSharedPtr>;
77 [[nodiscard]]
const SE23&
D()
const;
87 [[nodiscard]]
const SE3
B()
const;
97 [[nodiscard]]
const SE3
C()
const;
106 [[nodiscard]]
const Vector6&
delta()
const;
115 [[nodiscard]]
const SE3&
E()
const;
124 [[nodiscard]]
const In&
L()
const;
134 [[nodiscard]]
const SOT3&
Q(
const uint& feat_id)
const;
144 [[nodiscard]]
const SE3&
clone(
const fp& timestamp)
const;
167 [[nodiscard]]
inline size_t clonesSize()
const {
return clones_.size(); }
182 [[nodiscard]]
const MatrixX&
cov()
const;
201 [[nodiscard]]
const MatrixX
subCov(
const std::vector<MSCEqFKey>& keys)
const;
211 [[nodiscard]]
const MatrixX
subCovCols(
const std::vector<MSCEqFKey>& keys)
const;
291 [[nodiscard]]
bool insertStateElement(
const MSCEqFStateKey& key, MSCEqFStateElementUniquePtr ptr);
300 [[nodiscard]]
bool insertCloneElement(
const fp& timestamp, MSCEqFStateElementUniquePtr ptr);
308 [[nodiscard]]
const MSCEqFStateElementSharedPtr& getPtr(
const MSCEqFKey& key)
const;
const SE3 C() const
Get a copy of to the SE3 component of the Semi Direct Bias Group element of the MSCEqF state that inc...
std::variant< MSCEqFStateElementName, uint > MSCEqFStateKey
Key to access the msceqf state map.
Definition state.hpp:40
const MatrixX & cov() const
Get a reference to the covariance matrix.
std::unordered_map< MSCEqFStateKey, MSCEqFStateElementSharedPtr > MSCEqFStateMap
MSCEqF state map.
Definition state.hpp:43
const In & L() const
Get a reference to the In element of the MSCEqF state.
friend class Updater
Updater can access private members of MSCEqFState.
Definition state.hpp:312
const SE3 B() const
Get a copy of the SE3 component of the Semi Direct Bias Group element of the MSCEqF state that includ...
const MSCEqFState operator*(const MSCEqFState &other) const
operator* overloading for MSCEqFState. This function will perform the composition this * other for ea...
const uint & index(const MSCEqFKey &key) const
Get a reference to the index of the state element or the clone element corresponding to the given key...
const MSCEqFState Random() const
Return a random MSCEqF state without changing this. This method *WILL NOT change the actual values of...
void stochasticCloning(const fp ×tamp)
Augment the MSCEqF clones map with a new clone of the actual E element of the MSCEqF state....
friend class Symmetry
Symmetry can access private members of MSCEqFState.
Definition state.hpp:310
const MatrixX subCovCols(const std::vector< MSCEqFKey > &keys) const
Get a constant copy of the the covariance submatrix (including cross-correlations) constructed with c...
const SE3 & E() const
Get a reference to the SE3 element of the MSCEqF state.
MSCEqFState(const StateOptions &opts, const SystemState &xi0)
Construct the state of the MSCEqF given the options.
const StateOptions & opts() const
Get the state options.
Definition state.hpp:218
const uint & dof(const MSCEqFKey &key) const
Get a reference to the dof of the state element or the clone element corresponding to the given key.
std::variant< MSCEqFStateKey, fp > MSCEqFKey
Key to access the msceqf state and clones map.
Definition state.hpp:41
const SOT3 & Q(const uint &feat_id) const
Get a reference to the SOT3 element of the MSCEqF state that correspond to the given feature id.
const SE23 & D() const
Get a reference to the SE23 component of the Semi Direct Bias Group element of the MSCEqF state.
const MatrixX covBlock(const MSCEqFKey &key) const
get a constant copy of the covariance block relative to the elements (states or clones) corresponding...
const SE3 & clone(const fp ×tamp) const
Get a reference to the SE3 element of the MSCEqF clones that correspond to the given timestamp.
MSCEqFState(const MSCEqFState &other)
Rule of Five.
void initializeStateElement(const MSCEqFStateKey &key, const MatrixX &cov_block)
Initialize MSCEqF state element into the state map, and the relative covariance block.
friend class Propagator
Propagator can access private members of MSCEqFState.
Definition state.hpp:311
const Vector6 & delta() const
Get a reference to the R6 component of the Semi Direct Bias Group element of the MSCEqF state.
void marginalizeCloneAt(const fp ×tamp)
Marginalize out clone at a given timestamp.
std::map< fp, MSCEqFStateElementSharedPtr > MSCEqFClonesMap
MSCEqF clones map.
Definition state.hpp:44
const fp & cloneTimestampToMarginalize() const
Get the timestamp of the clone to marginalize. We implement our keyframing strategy here....
const MatrixX subCov(const std::vector< MSCEqFKey > &keys) const
Get a constant copy of the the covariance submatrix (including cross-correlations) constructed with c...
friend class ZeroVelocityUpdater
Zero velocity updater can access private members of MSCEqFState.
Definition state.hpp:313
size_t clonesSize() const
Get the amount of clones.
Definition state.hpp:167
static std::string toString(const MSCEqFStateKey &key)
Get a string describing the given MSCEqFStateKey.
MSCEqFState()=delete
Deleted default constructor.
The SystemState class represent the state of the system posed on the Homogenous space.
Definition system.hpp:37
Definition msceqf_options.hpp:106