21#include <gtsam/dllexport.h>
37 typedef Rot2 Rotation;
38 typedef Point2 Translation;
60 Similarity2(
const Matrix2& R,
const Vector2& t,
double s);
76 void print(
const std::string& s =
"")
const;
78 GTSAM_EXPORT
friend std::ostream& operator<<(std::ostream& os,
141 using LieAlgebra = Matrix3;
144 static Matrix2
GetV(
double theta,
double lambda);
171 static Matrix3
Hat(
const Vector4& xi);
174 static Vector4
Vee(
const Matrix3& X);
194 #if GTSAM_ENABLE_BOOST_SERIALIZATION
196 friend class boost::serialization::access;
197 template<
class Archive>
198 void serialize(Archive & ar,
const unsigned int ) {
199 ar & BOOST_SERIALIZATION_NVP(R_);
200 ar & BOOST_SERIALIZATION_NVP(t_);
201 ar & BOOST_SERIALIZATION_NVP(s_);
Base class and basic functions for Matrix Lie groups.
Global functions in a separate testing namespace.
Definition chartTesting.h:28
Vector2 Point2
As of GTSAM 4, in order to make GTSAM more lean, it is now possible to just typedef Point2 to Vector2...
Definition Point2.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
A 2D pose (Point2,Rot2).
Definition Pose2.h:39
Rotation matrix NOTE: the angle theta is in radians unless explicitly stated.
Definition Rot2.h:40
2D similarity transform
Definition Similarity2.h:34
Point2 translation() const
Return a GTSAM translation.
Definition Similarity2.h:187
Point2 transformFrom(const Point2 &p) const
Action on a point p is s*(R*p+t).
Definition Similarity2.cpp:148
static Similarity2 Align(const Point2Pairs &abPointPairs)
Create Similarity2 by aligning at least two point pairs.
Definition Similarity2.cpp:163
double scale() const
Return the scale.
Definition Similarity2.h:190
bool operator==(const Similarity2 &other) const
Exact equality.
Definition Similarity2.cpp:124
static Matrix2 GetV(double theta, double lambda)
Calculate expmap and logmap coefficients.
Definition Similarity2.cpp:198
static Matrix3 Hat(const Vector4 &xi)
Hat maps from tangent vector to Lie algebra.
Definition Similarity2.cpp:280
static Similarity2 Expmap(const Vector4 &v)
Exponential map at the identity.
Definition Similarity2.cpp:250
Matrix4 AdjointMap() const
Project from one tangent space to another.
Definition Similarity2.cpp:258
Similarity2 inverse() const
Return the inverse.
Definition Similarity2.cpp:142
static Vector4 Logmap(const Similarity2 &S)
Log map at the identity .
Definition Similarity2.cpp:241
static Similarity2 Identity()
Return an identity transform.
Definition Similarity2.cpp:136
bool equals(const Similarity2 &sim, double tol) const
Compare with tolerance.
Definition Similarity2.cpp:118
void print(const std::string &s="") const
Print with optional string.
Definition Similarity2.cpp:128
Matrix3 matrix() const
Calculate 3*3 matrix group equivalent.
Definition Similarity2.cpp:303
Rot2 rotation() const
Return a GTSAM rotation.
Definition Similarity2.h:184
Similarity2 operator*(const Similarity2 &S) const
Composition.
Definition Similarity2.cpp:138
Similarity2()
Default constructor.
Definition Similarity2.cpp:103
static Vector4 Vee(const Matrix3 &X)
Vee maps from Lie algebra to tangent vector.
Definition Similarity2.cpp:289
Chart at the origin.
Definition Similarity2.h:156