0.2.0
Loading...
Searching...
No Matches
BsplineKF.hpp
Go to the documentation of this file.
1// This file is part of INSTINCT, the INS Toolkit for Integrated
2// Navigation Concepts and Training by the Institute of Navigation of
3// the University of Stuttgart, Germany.
4//
5// This Source Code Form is subject to the terms of the Mozilla Public
6// License, v. 2.0. If a copy of the MPL was not distributed with this
7// file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
13
14#pragma once
15
16#include "util/Eigen.hpp"
17#include "../PinData.hpp"
19
20#include <vector>
21
22namespace NAV::BsplineKF
23{
29[[nodiscard]] Eigen::MatrixXd initialErrorCovarianceMatrix_P0(const std::vector<Eigen::VectorXd>& initCovariances, const uint8_t& numStates, const bool& imuCharacteristicsIdentical = false);
30
37void processNoiseMatrix_Q(Eigen::MatrixXd& Q, const double& dt, const std::vector<Eigen::VectorXd>& processNoiseVariances, const uint8_t& numStates, const bool& imuCharacteristicsIdentical = false);
38
41void rotateCoeffStates(Eigen::MatrixXd& x);
42
48void rotateErrorCovariances(Eigen::MatrixXd& P,
49 uint8_t& numStates,
50 const double& sigmaScalingFactorAngRate = 3.0,
51 const double& sigmaScalingFactorAccel = 3.0);
52
64[[nodiscard]] Eigen::MatrixXd designMatrix_H(const double& ti,
65 const double& splineSpacing,
66 const Eigen::Matrix3d& DCM_accel,
67 const Eigen::Matrix3d& DCM_gyro,
68 const size_t& pinIndex,
69 const uint8_t& numMeasurements,
70 const uint8_t& numStates,
71 const uint8_t& numStatesEst,
72 const uint8_t& numStatesPerPin);
73
86 const std::vector<PinData>& pinData,
87 const PinDataBsplineKF& pinDataBsplineKF,
88 const uint8_t& numStates,
89 const double& dtInit,
90 std::vector<Eigen::VectorXd>& processNoiseVariances,
91 KalmanFilter& kalmanFilter,
92 const bool& imuCharacteristicsIdentical,
93 const bool& imuBiasesIdentical);
94
95} // namespace NAV::BsplineKF
KalmanFilter initializeKalmanFilterManually(const size_t &numInputPins, const std::vector< PinData > &pinData, const PinDataBsplineKF &pinDataBsplineKF, const uint8_t &numStates, const double &dtInit, std::vector< Eigen::VectorXd > &processNoiseVariances, KalmanFilter &kalmanFilter, const bool &imuCharacteristicsIdentical, const bool &imuBiasesIdentical)
Initializes the BsplineKF manually (i.e. using GUI inputs instead of averaging)
void rotateErrorCovariances(Eigen::MatrixXd &P, uint8_t &numStates, const double &sigmaScalingFactorAngRate=3.0, const double &sigmaScalingFactorAccel=3.0)
Rotates the B-spline coefficient error covariances in P, once a new B-spline is introduced.
void processNoiseMatrix_Q(Eigen::MatrixXd &Q, const double &dt, const std::vector< Eigen::VectorXd > &processNoiseVariances, const uint8_t &numStates, const bool &imuCharacteristicsIdentical=false)
Calculates the process noise matrix Q.
void rotateCoeffStates(Eigen::MatrixXd &x)
Rotates the B-spline coefficient states in the state vector x, once a new B-spline is introduced.
Eigen::MatrixXd initialErrorCovarianceMatrix_P0(const std::vector< Eigen::VectorXd > &initCovariances, const uint8_t &numStates, const bool &imuCharacteristicsIdentical=false)
Initial error covariance matrix P_0.
Eigen::MatrixXd designMatrix_H(const double &ti, const double &splineSpacing, const Eigen::Matrix3d &DCM_accel, const Eigen::Matrix3d &DCM_gyro, const size_t &pinIndex, const uint8_t &numMeasurements, const uint8_t &numStates, const uint8_t &numStatesEst, const uint8_t &numStatesPerPin)
Calculates the design matrix H.
Vector space operations.
Generalized Kalman Filter class.
Information about a sensor which is connected to a certain pin.
Generalized Kalman Filter class.
Definition KalmanFilter.hpp:25
Sensor information specific to the Bspline-KF.
Definition PinData.hpp:179