minimum_jerk_trajectory.h
Go to the documentation of this file.
1 /*******************************************************************************
2 * Copyright 2018 ROBOTIS CO., LTD.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *******************************************************************************/
16 
17 #ifndef ROBOTIS_MATH_MINIMUM_JERK_TRAJECTORY_H_
18 #define ROBOTIS_MATH_MINIMUM_JERK_TRAJECTORY_H_
19 
20 #define EIGEN_NO_DEBUG
21 #define EIGEN_NO_STATIC_ASSERT
22 
23 #include "robotis_linear_algebra.h"
24 #include "robotis_math_base.h"
25 
26 #include <ros/ros.h>
27 #include <stdint.h>
28 #include <vector>
29 
30 namespace robotis_framework
31 {
32 
34 {
35 public:
36  MinimumJerk(double ini_time, double fin_time,
37  std::vector<double_t> ini_pos, std::vector<double_t> ini_vel, std::vector<double_t> ini_acc,
38  std::vector<double_t> fin_pos, std::vector<double_t> fin_vel, std::vector<double_t> fin_acc);
39  virtual ~MinimumJerk();
40 
41  std::vector<double_t> getPosition(double time);
42  std::vector<double_t> getVelocity(double time);
43  std::vector<double_t> getAcceleration(double time);
44 
45  double cur_time_;
46  std::vector<double_t> cur_pos_;
47  std::vector<double_t> cur_vel_;
48  std::vector<double_t> cur_acc_;
49 
50  Eigen::MatrixXd position_coeff_;
51  Eigen::MatrixXd velocity_coeff_;
52  Eigen::MatrixXd acceleration_coeff_;
53  Eigen::MatrixXd time_variables_;
54 
55 private:
58  std::vector<double_t> ini_pos_, ini_vel_, ini_acc_;
59  std::vector<double_t> fin_pos_, fin_vel_, fin_acc_;
60 };
61 
62 }
63 
64 #endif /* ROBOTIS_MATH_MINIMUM_JERK_TRAJECTORY_H_ */
MinimumJerk(double ini_time, double fin_time, std::vector< double_t > ini_pos, std::vector< double_t > ini_vel, std::vector< double_t > ini_acc, std::vector< double_t > fin_pos, std::vector< double_t > fin_vel, std::vector< double_t > fin_acc)
std::vector< double_t > getAcceleration(double time)
std::vector< double_t > getPosition(double time)
std::vector< double_t > getVelocity(double time)


robotis_math
Author(s): SCH , Kayman , Jay Song
autogenerated on Fri Jul 17 2020 03:17:50