Loose-GNSS-IMU/Loose-GNSS-IMU/MatrixUtils.cpp
// Transforms input vector using provided DCM
Transforms input vector using provided DCM
Transforms input vector using provided DCM
vector<double> Transformer(vector<double> v, MatrixXd DCM) {
	size_t n = v.size();
	VectorXd V = VectorXd::Zero(n);
	for (size_t i = 0; i < n; i++) {
		V(i) = v[i];
	}
	VectorXd W = VectorXd::Zero(n);
	W = DCM * V;
	vector<double> w;
	for (size_t i = 0; i < n; i++) {
		w.push_back(W(i));
	}
	return w;
}
vector < double > Transformer ( vector < double > v , MatrixXd DCM ) { size_t n = v . size ( ) ; VectorXd V = VectorXd :: Zero ( n ) ; for ( size_t i = 0 ; i < n ; i ++ ) { V ( i ) = v [ i ] ; } VectorXd W = VectorXd :: Zero ( n ) ; W = DCM * V ; vector < double > w ; for ( size_t i = 0 ; i < n ; i ++ ) { w . push_back ( W ( i ) ) ; } return w ; }
Transforms input vector using provided DCM
Transforms input vector using provided DCM