From 6e0de4f0d4fac653dde826712e81cee95b470195 Mon Sep 17 00:00:00 2001 From: Martin Miller Date: Fri, 17 Mar 2017 21:31:12 -0500 Subject: Integration is implemented. But there are problems. The coordinates are not working correctly. When I run integration on a known dataset the body seems to turn in the opposite direction of reality. It's probably best to change it to NED and FRD. Currenty it is ENU and RFU. --- src/body.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 src/body.h (limited to 'src/body.h') diff --git a/src/body.h b/src/body.h new file mode 100644 index 0000000..d668957 --- /dev/null +++ b/src/body.h @@ -0,0 +1,42 @@ +#ifndef body_INC +#define body_INC +#include +#include +using Eigen::Matrix; +using Eigen::Vector3d; +using Eigen::Quaternion; + +/* + * ===================================================================================== + * Class: Body + * Description: State representation of body. + * ===================================================================================== + */ +class Body +{ + public: + /* ==================== LIFECYCLE ======================================= */ + Body (){}; /* constructor */ + + /* ==================== ACCESSORS ======================================= */ + + /* ==================== MUTATORS ======================================= */ + + /* ==================== OPERATORS ======================================= */ + void motionModel ( Matrix &X, const Vector3d &acc, const Vector3d &ang, const Quaternion &q, const double dt); + void skewSymmetric(const Vector3d &x, Matrix &y); + + protected: + /* ==================== METHODS ======================================= */ + + /* ==================== DATA MEMBERS ======================================= */ + + private: + /* ==================== METHODS ======================================= */ + + /* ==================== DATA MEMBERS ======================================= */ + +}; /* ----- end of class Body ----- */ + + +#endif /* ----- #ifndef body_INC ----- */ -- cgit v1.1