59 : R_(
R), r_(
r), v_(
v), t_(
t) {}
62 explicit Gal3(
const Matrix5& M);
67 OptionalJacobian<10, 3> H2 = {},
68 OptionalJacobian<10, 3> H3 = {},
69 OptionalJacobian<10, 1> H4 = {});
72 static Gal3 FromPoseVelocityTime(
const Pose3& pose,
const Velocity3& v,
73 double t, OptionalJacobian<10, 6> H1 = {},
74 OptionalJacobian<10, 3> H2 = {},
75 OptionalJacobian<10, 1> H3 = {});
82 const Rot3& rotation(OptionalJacobian<3, 10> H = {})
const;
85 const Point3& translation(OptionalJacobian<3, 10> H = {})
const;
88 const Velocity3& velocity(OptionalJacobian<3, 10> H = {})
const;
91 const double& time(OptionalJacobian<1, 10> H = {})
const;
94 const Rot3& attitude(OptionalJacobian<3, 10> H = {})
const {
97 const Point3& position(OptionalJacobian<3, 10> H = {})
const {
98 return translation(H);
106 Matrix3
R()
const {
return R_.matrix(); }
109 Vector3
r()
const {
return Vector3(r_); }
112 const Vector3&
v()
const {
return v_; }
115 const double&
t()
const {
return t_; }
123 OptionalJacobian<1, 3> Hpoint = {})
const;
130 Unit3 bearing(
const Point3& point, OptionalJacobian<2, 10> Hself = {},
131 OptionalJacobian<2, 3> Hpoint = {})
const;
139 friend std::ostream& operator<<(std::ostream& os,
const Gal3& state);
142 void print(
const std::string& s =
"")
const;
145 bool equals(
const Gal3& other,
double tol = 1e-9)
const;
155 Gal3 inverse()
const;
175 OptionalJacobian<4, 4> He = {})
const;
182 static Gal3 Expmap(
const TangentVector& xi,
183 OptionalJacobian<10, 10> Hxi = {});
186 static TangentVector
Logmap(
const Gal3& g, OptionalJacobian<10, 10> Hg = {});
189 Jacobian AdjointMap()
const;
192 static Jacobian adjointMap(
const TangentVector& xi);
195 static Jacobian ExpmapDerivative(
const TangentVector& xi);
198 static Jacobian LogmapDerivative(
const Gal3& g);
201 static Jacobian LogmapDerivative(
const TangentVector& xi);
205 static Gal3 Retract(
const TangentVector& xi, ChartJacobian Hxi = {});
206 static TangentVector Local(
const Gal3& g, ChartJacobian Hg = {});
213 using LieAlgebra = Matrix5;
214 using Vector25 = Eigen::Matrix<double, 25, 1>;
223 static LieAlgebra Hat(
const TangentVector& xi);
226 static TangentVector Vee(
const LieAlgebra& X);
233#if GTSAM_ENABLE_BOOST_SERIALIZATION
234 friend class boost::serialization::access;
235 template <
class ARCHIVE>
236 void serialize(ARCHIVE& ar,
const unsigned int ) {
237 ar& BOOST_SERIALIZATION_NVP(R_);
238 ar& BOOST_SERIALIZATION_NVP(r_);
239 ar& BOOST_SERIALIZATION_NVP(v_);
240 ar& BOOST_SERIALIZATION_NVP(t_);
Base class and basic functions for Matrix Lie groups.
3D Pose manifold SO(3) x R^3 and group SE(3)
Global functions in a separate testing namespace.
Definition chartTesting.h:28
Vector3 Point3
As of GTSAM 4, in order to make GTSAM more lean, it is now possible to just typedef Point3 to Vector3...
Definition Point3.h:38
void print(const Matrix &A, const string &s, ostream &stream)
print without optional string, must specify cout yourself
Definition Matrix.cpp:143
Point2 operator*(double s, const Point2 &p)
multiply with scalar
Definition Point2.h:52
Vector3 Velocity3
Velocity is currently typedef'd to Vector3.
Definition Gal3.h:33
@ Logmap
Use the SE_2(3) NavState Logmap for every backend.
Definition PreintegrationParams.h:32
A manifold defines a space in which there is a notion of a linear tangent space that can be centered ...
Definition Group.h:37
A CRTP helper class that implements Lie group methods Prerequisites: methods operator*,...
Definition Lie.h:114
A CRTP helper class that implements matrix Lie group methods.
Definition MatrixLieGroup.h:51
Both LieGroupTraits and Testable.
Definition MatrixLieGroup.h:350
OptionalJacobian is an Eigen::Ref like class that can take be constructed using either a fixed size o...
Definition OptionalJacobian.h:40
Definition BearingRange.h:36
Definition BearingRange.h:42
Definition BearingRange.h:182
Definition BearingRange.h:196
A space-time event models an event that happens at a certain 3D location, at a certain time.
Definition Event.h:35
Represents an element of the 3D Galilean group SGal(3).
Definition Gal3.h:39
const Vector3 & v() const
Return velocity as Vector3.
Definition Gal3.h:112
static Gal3 Identity()
Return the identity element.
Definition Gal3.h:152
Matrix5 matrix() const
Return 5x5 homogeneous matrix representation.
Definition Gal3.cpp:213
Gal3(const Rot3 &R, const Point3 &r, const Velocity3 &v, double t)
Construct from attitude, position, velocity, time.
Definition Gal3.h:58
const double & t() const
Return time scalar.
Definition Gal3.h:115
Vector3 r() const
Return position as Vector3.
Definition Gal3.h:109
Vector25 vec(OptionalJacobian< 25, 10 > H={}) const
Vectorize 5x5 matrix into a 25-dim vector.
Definition Gal3.cpp:226
Gal3()
Default constructor: Identity element.
Definition Gal3.h:51
Matrix3 R() const
Return rotation matrix (Matrix3).
Definition Gal3.h:106
Chart at origin, uses Expmap/Logmap for Retract/Local.
Definition Gal3.h:204
Rot3 is a 3D rotation represented as a rotation matrix if the preprocessor symbol GTSAM_USE_QUATERNIO...
Definition Rot3.h:65