![]() |
0.4.1
|
The Spp Kalman Filter related options. More...
Public Member Functions | |
void | addInterFrequencyBias (const Frequency &freq) |
Adds the frequency as inter-frequency bias state. | |
void | deinitialize () |
Deinitialize the KF (can be used to reinitialize the Filter when results seem strange) | |
const KeyedMatrixXd< States::StateKeyType, States::StateKeyType > & | getErrorCovarianceMatrix () const |
Returns the Error covariance matrix 𝐏 | |
const KeyedVectorXd< States::StateKeyType > & | getState () const |
Returns the State vector x̂ | |
const std::vector< SPP::States::StateKeyType > & | getStateKeys () const |
Get the States in the Kalman Filter. | |
void | initialize (const KeyedVectorXd< States::StateKeyType > &states, const KeyedMatrixXd< States::StateKeyType, States::StateKeyType > &variance) |
Initialize the filter. | |
bool | isInitialized () const |
Checks wether the Kalman filter is initialized. | |
void | predict (const double &dt, const Eigen::Vector3d &lla_pos, const std::string &nameId) |
Does the Kalman Filter prediction. | |
void | reset (const std::vector< SatelliteSystem > &satelliteSystems) |
Resets the filter. | |
void | setClockBiasErrorCovariance (double clkPhaseDrift) |
Set the P matrix entry for the covariance of the clock phase drift. | |
bool | ShowGuiWidgets (const char *id, bool useDoppler, bool multiConstellation, bool estimateInterFrequencyBiases, float itemWidth, float unitWidth) |
Shows the GUI input to select the options. | |
void | update (const std::vector< Meas::MeasKeyTypes > &measKeys, const KeyedMatrixXd< Meas::MeasKeyTypes, States::StateKeyType > &H, const KeyedMatrixXd< Meas::MeasKeyTypes, Meas::MeasKeyTypes > &R, const KeyedVectorXd< Meas::MeasKeyTypes > &dz, const std::string &nameId) |
Does the Kalman Filter update. | |
Private Types | |
enum class | InitCovarianceClockDriftUnits : uint8_t { m_s , s_s , m2_s2 , s2_s2 } |
Possible Units for the P matrix initialization clock drift uncertainty. More... | |
enum class | InitCovarianceVelocityUnits : uint8_t { m_s , m2_s2 } |
Possible Units for the P matrix initialization velocity uncertainty. More... | |
Private Attributes | |
double | _gui_initCovarianceClockDrift |
GUI selection for the P matrix initialization clock drift uncertainty. | |
InitCovarianceClockDriftUnits | _gui_initCovarianceClockDriftUnit |
Gui selection for the Unit of the P matrix initialization clock drift uncertainty. | |
double | _gui_initCovarianceInterSysClockDrift |
GUI selection for the P matrix initialization inter system clock drift uncertainty. | |
InitCovarianceClockDriftUnits | _gui_initCovarianceInterSysClockDriftUnit |
Gui selection for the Unit of the P matrix initialization inter system clock drift uncertainty. | |
double | _gui_initCovarianceVelocity |
GUI selection for the P matrix initialization velocity uncertainty. | |
InitCovarianceVelocityUnits | _gui_initCovarianceVelocityUnit |
Gui selection for the Unit of the P matrix initialization velocity uncertainty. | |
double | _initCovarianceClockDrift |
Covariance of the P matrix initialization clock drift uncertainty [m²/s²]. | |
double | _initCovarianceInterSysClockDrift |
Covariance of the P matrix initialization inter system clock drift uncertainty [m²/s²]. | |
double | _initCovarianceVelocity |
Covariance of the P matrix initialization velocity uncertainty [m²/s²]. | |
bool | _initialized |
Boolean that determines, if Kalman Filter is initialized (from weighted LSE solution) | |
InterFrequencyBiasModel< SPP::States::StateKeyType > | _interFrequencyBiasModel |
Inter-frequency bias Model. | |
KeyedKalmanFilterD< SPP::States::StateKeyType, SPP::Meas::MeasKeyTypes > | _kalmanFilter |
Kalman Filter representation. | |
MotionModel< SPP::States::StateKeyType > | _motionModel |
Motion Model. | |
ReceiverClockModel< SPP::States::StateKeyType > | _receiverClockModel |
Receiver clock Model. | |
SystemModelCalcAlgorithm | _systemModelCalcAlgorithm |
Algorithm to calculate the system models with. | |
const std::array< SPP::States::StateKeyType, 6 > & | PosVelKey |
All position and velocity keys. | |
const std::array< SPP::States::StateKeyType, 3 > & | VelKey |
All velocity keys. | |
Friends | |
void | from_json (const json &j, KalmanFilter &data) |
Converts the provided json object into the data object. | |
void | to_json (json &j, const KalmanFilter &data) |
Converts the provided data into a json object. | |
The Spp Kalman Filter related options.
Definition at line 37 of file KalmanFilter.hpp.
|
strongprivate |
Possible Units for the P matrix initialization clock drift uncertainty.
Enumerator | |
---|---|
m_s | [ m / s ] |
s_s | [ s / s ] |
m2_s2 | [ m^2 / s^2 ] |
s2_s2 | [ s^2 / s^2 ] |
Definition at line 139 of file KalmanFilter.hpp.
|
strongprivate |
Possible Units for the P matrix initialization velocity uncertainty.
Enumerator | |
---|---|
m_s | [ m / s ] |
m2_s2 | [ m^2 / s^2 ] |
Definition at line 123 of file KalmanFilter.hpp.
void NAV::SPP::KalmanFilter::addInterFrequencyBias | ( | const Frequency & | freq | ) |
Adds the frequency as inter-frequency bias state.
[in] | freq | Frequency to estimate the inter-frequency bias for |
Definition at line 185 of file KalmanFilter.cpp.
void NAV::SPP::KalmanFilter::deinitialize | ( | ) |
Deinitialize the KF (can be used to reinitialize the Filter when results seem strange)
Definition at line 123 of file KalmanFilter.cpp.
|
nodiscard |
Returns the Error covariance matrix 𝐏
Definition at line 299 of file KalmanFilter.cpp.
|
nodiscard |
Returns the State vector x̂
Definition at line 294 of file KalmanFilter.cpp.
|
nodiscard |
Get the States in the Kalman Filter.
Definition at line 289 of file KalmanFilter.cpp.
void NAV::SPP::KalmanFilter::initialize | ( | const KeyedVectorXd< States::StateKeyType > & | states, |
const KeyedMatrixXd< States::StateKeyType, States::StateKeyType > & | variance ) |
Initialize the filter.
states | States to initialize with |
variance | Variance of the state |
Definition at line 101 of file KalmanFilter.cpp.
|
inlinenodiscard |
Checks wether the Kalman filter is initialized.
Definition at line 53 of file KalmanFilter.hpp.
void NAV::SPP::KalmanFilter::predict | ( | const double & | dt, |
const Eigen::Vector3d & | lla_pos, | ||
const std::string & | nameId ) |
Does the Kalman Filter prediction.
[in] | dt | Time step [s] |
[in] | lla_pos | Position in Latitude, Longitude, Altitude [rad, rad, m] |
[in] | nameId | Name and id of the node calling this (only used for logging purposes) |
Definition at line 128 of file KalmanFilter.cpp.
void NAV::SPP::KalmanFilter::reset | ( | const std::vector< SatelliteSystem > & | satelliteSystems | ) |
Resets the filter.
satelliteSystems | Satellite systems to consider |
Definition at line 33 of file KalmanFilter.cpp.
void NAV::SPP::KalmanFilter::setClockBiasErrorCovariance | ( | double | clkPhaseDrift | ) |
Set the P matrix entry for the covariance of the clock phase drift.
clkPhaseDrift | Clock phase drift variance in [m^2 / s] |
Definition at line 278 of file KalmanFilter.cpp.
bool NAV::SPP::KalmanFilter::ShowGuiWidgets | ( | const char * | id, |
bool | useDoppler, | ||
bool | multiConstellation, | ||
bool | estimateInterFrequencyBiases, | ||
float | itemWidth, | ||
float | unitWidth ) |
Shows the GUI input to select the options.
[in] | id | Unique id for ImGui. |
[in] | useDoppler | Whether to use doppler measurements |
[in] | multiConstellation | Whether to use multiple constellations |
[in] | estimateInterFrequencyBiases | Whether to use estimate inter frequency biases |
[in] | itemWidth | Width of the widgets |
[in] | unitWidth | Width on unit inputs |
Definition at line 197 of file KalmanFilter.cpp.
void NAV::SPP::KalmanFilter::update | ( | const std::vector< Meas::MeasKeyTypes > & | measKeys, |
const KeyedMatrixXd< Meas::MeasKeyTypes, States::StateKeyType > & | H, | ||
const KeyedMatrixXd< Meas::MeasKeyTypes, Meas::MeasKeyTypes > & | R, | ||
const KeyedVectorXd< Meas::MeasKeyTypes > & | dz, | ||
const std::string & | nameId ) |
Does the Kalman Filter update.
[in] | measKeys | Measurement keys |
[in] | H | Measurement sensitivity matrix 𝐇 |
[in] | R | Measurement noise covariance matrix 𝐑 |
[in] | dz | Measurement innovation 𝜹𝐳 |
[in] | nameId | Name and id of the node calling this (only used for logging purposes) |
Definition at line 168 of file KalmanFilter.cpp.
|
friend |
Converts the provided json object into the data object.
[in] | j | Json object with the needed values |
[out] | data | Object to fill from the json |
Definition at line 314 of file KalmanFilter.cpp.
|
friend |
Converts the provided data into a json object.
[out] | j | Json object which gets filled with the info |
[in] | data | Data to convert into json |
Definition at line 304 of file KalmanFilter.cpp.
|
private |
GUI selection for the P matrix initialization clock drift uncertainty.
Definition at line 150 of file KalmanFilter.hpp.
|
private |
Gui selection for the Unit of the P matrix initialization clock drift uncertainty.
Definition at line 147 of file KalmanFilter.hpp.
|
private |
GUI selection for the P matrix initialization inter system clock drift uncertainty.
Definition at line 160 of file KalmanFilter.hpp.
|
private |
Gui selection for the Unit of the P matrix initialization inter system clock drift uncertainty.
Definition at line 157 of file KalmanFilter.hpp.
|
private |
GUI selection for the P matrix initialization velocity uncertainty.
Definition at line 132 of file KalmanFilter.hpp.
|
private |
Gui selection for the Unit of the P matrix initialization velocity uncertainty.
Definition at line 129 of file KalmanFilter.hpp.
|
private |
Covariance of the P matrix initialization clock drift uncertainty [m²/s²].
Definition at line 152 of file KalmanFilter.hpp.
|
private |
Covariance of the P matrix initialization inter system clock drift uncertainty [m²/s²].
Definition at line 162 of file KalmanFilter.hpp.
|
private |
Covariance of the P matrix initialization velocity uncertainty [m²/s²].
Definition at line 134 of file KalmanFilter.hpp.
|
private |
Boolean that determines, if Kalman Filter is initialized (from weighted LSE solution)
Definition at line 113 of file KalmanFilter.hpp.
|
private |
Inter-frequency bias Model.
Definition at line 118 of file KalmanFilter.hpp.
|
private |
Kalman Filter representation.
Definition at line 110 of file KalmanFilter.hpp.
|
private |
Motion Model.
Definition at line 116 of file KalmanFilter.hpp.
|
private |
Receiver clock Model.
Definition at line 117 of file KalmanFilter.hpp.
|
private |
Algorithm to calculate the system models with.
Definition at line 115 of file KalmanFilter.hpp.
|
private |
All position and velocity keys.
Definition at line 107 of file KalmanFilter.hpp.
|
private |
All velocity keys.
Definition at line 105 of file KalmanFilter.hpp.