mc_rtc  2.16.0
RobotFrame.h
Go to the documentation of this file.
1 /*
2  * Copyright 2015-2022 CNRS-UM LIRMM, CNRS-AIST JRL
3  */
4 
5 #pragma once
6 
7 #include <mc_tvm/Frame.h>
8 
9 #include <mc_rbdyn/RobotFrame.h>
10 
11 namespace mc_tvm
12 {
13 
28 {
29  SET_OUTPUTS(RobotFrame, Jacobian, NormalAcceleration, JDot)
30  SET_UPDATES(RobotFrame, Jacobian, NormalAcceleration, JDot)
31 
32  friend struct mc_rbdyn::RobotFrame;
33 
34 protected:
36  {
37  };
38 
39 public:
41 
43  inline const tvm::internal::MatrixWithProperties & jacobian() const noexcept { return jacobian_; }
44 
46  inline const sva::MotionVecd & normalAcceleration() const noexcept { return normalAcceleration_; }
47 
49  inline const tvm::internal::MatrixWithProperties & JDot() const noexcept { return jacDot_; }
50 
59  inline const rbd::Jacobian & rbdJacobian() const noexcept { return jac_; }
60 
62  inline const mc_rbdyn::RobotFrame & frame() const noexcept
63  { return static_cast<const mc_rbdyn::RobotFrame &>(frame_); }
64 
65 protected:
66  Eigen::Matrix3d h_ = Eigen::Matrix3d::Zero();
67 
70 
71  Eigen::MatrixXd jacTmp_;
72 
75 
78 
80  void updateJDot();
81 };
82 
83 } // namespace mc_tvm
#define SET_UPDATES(SelfT,...)
#define SET_OUTPUTS(SelfT,...)
#define MC_TVM_DLLAPI
Definition: api.h:47
Definition: generic_gripper.h:15
Definition: CollisionFunction.h:16
std::vector< Block > Blocks
Definition: RobotFrame.h:22
Definition: Frame.h:42
Definition: Frame.h:34
Definition: RobotFrame.h:36
Definition: RobotFrame.h:28
const tvm::internal::MatrixWithProperties & jacobian() const noexcept
Definition: RobotFrame.h:43
rbd::Jacobian jac_
Definition: RobotFrame.h:68
const rbd::Jacobian & rbdJacobian() const noexcept
Definition: RobotFrame.h:59
RobotFrame(NewRobotFrameToken, const mc_rbdyn::RobotFrame &frame)
rbd::Blocks blocks_
Definition: RobotFrame.h:69
const mc_rbdyn::RobotFrame & frame() const noexcept
Definition: RobotFrame.h:62
void updateNormalAcceleration()
Eigen::MatrixXd jacTmp_
Definition: RobotFrame.h:71
const sva::MotionVecd & normalAcceleration() const noexcept
Definition: RobotFrame.h:46
const tvm::internal::MatrixWithProperties & JDot() const noexcept
Definition: RobotFrame.h:49
tvm::internal::MatrixWithProperties jacDot_
Definition: RobotFrame.h:79
sva::MotionVecd normalAcceleration_
Definition: RobotFrame.h:76
tvm::internal::MatrixWithProperties jacobian_
Definition: RobotFrame.h:73