MROB
nodePose3d.hpp
1 /* Copyright (c) 2022, Gonzalo Ferrer
2  *
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  *
15  *
16  * nodePose3d.hpp
17  *
18  * Created on: Feb 28, 2018
19  * Author: Gonzalo Ferrer
20  * g.ferrer@skoltech.ru
21  * Mobile Robotics Lab, Skoltech
22  */
23 
24 #ifndef NODEPOSE3D_HPP_
25 #define NODEPOSE3D_HPP_
26 
27 #include "mrob/matrix_base.hpp"
28 #include "mrob/SE3.hpp" //requires including and linking SE3 library
29 #include "mrob/node.hpp"
30 
31 namespace mrob{
32 
33 class NodePose3d : public Node
34 {
35  public:
42  NodePose3d(const Mat4 &initial_x, Node::nodeMode mode = STANDARD);
46  NodePose3d(const SE3 &initial_x, Node::nodeMode mode = STANDARD);
47  ~NodePose3d() override = default;
53  virtual void update(VectRefConst &dx);
54  virtual void update_from_auxiliary(VectRefConst &dx);
55  virtual void set_state(MatRefConst &x);
56  virtual void set_auxiliary_state(MatRefConst &x);
57  virtual MatRefConst get_state() const {return state_.T();};
58  virtual MatRefConst get_auxiliary_state() const {return auxiliaryState_.T();};
59  void print() const;
60 
61  protected:
62  SE3 state_;
63  SE3 auxiliaryState_; //an auxiliary vector for undoing updates
64 
65  public:
66  //EIGEN_MAKE_ALIGNED_OPERATOR_NEW // as proposed by Eigen
67 
68 
69 };
70 
71 
72 }
73 
74 
75 #endif /* NODEPOSE3D_HPP_ */
Definition: nodePose3d.hpp:33
const Eigen::Ref< const Mat4 > T() const
Definition: SE3.cpp:237
Definition: SE3.hpp:50
NodePose3d(const Mat4 &initial_x, Node::nodeMode mode=STANDARD)
Definition: nodePose3d.cpp:31
virtual MatRefConst get_auxiliary_state() const
Definition: nodePose3d.hpp:58
virtual void update_from_auxiliary(VectRefConst &dx)
Definition: nodePose3d.cpp:58
virtual void update(VectRefConst &dx)
Definition: nodePose3d.cpp:47
Definition: node.hpp:61
virtual void set_state(MatRefConst &x)
Definition: nodePose3d.cpp:65
virtual MatRefConst get_state() const
Definition: nodePose3d.hpp:57
Special Euclidean (group) in 3d Is the group representing rotations and translations, that is, rigid body transformations. SE3 = {T = [R t] | R SO3 , t Re^3 } [0 1] Associated to the groups of RBT, there is the Lie algebra se3 representing the same transformation in the tangent space around the identity. Particularly, xi =[w , v] Re^6, where w Re^3 represents the rotation and v the translation. We will preserve this order in this class.
Definition: matrix_base.hpp:36
virtual void set_auxiliary_state(MatRefConst &x)
Definition: nodePose3d.cpp:72