Formula Student Autonomous Systems
The code for the main driverless system
Loading...
Searching...
No Matches
base_v2p_motion_model.cpp
Go to the documentation of this file.
2
4
6 const Eigen::Vector3d &previous_pose, const Eigen::VectorXd &motion_data,
7 const double delta_t) { // TODO: change to XD and create new acceleration model
8 Eigen::Vector3d next_pose =
9 previous_pose + this->get_pose_difference(previous_pose, motion_data, delta_t);
10 next_pose(2) = common_lib::maths::normalize_angle(next_pose(2));
11 return next_pose;
12}
virtual Eigen::Vector3d get_next_pose(const Eigen::Vector3d &previous_pose, const Eigen::VectorXd &motion_data, const double delta_t)
Predict the pose of the robot given the motion data.
virtual Eigen::Vector3d get_pose_difference(const Eigen::Vector3d &previous_pose, const Eigen::VectorXd &motion_data, const double delta_t)=0
Gives the increments to the pose instead of the next pose.
double normalize_angle(double angle)
Function to keep angle in [-Pi, Pi[ radians.