34 inline T
between_default(
const T& l1,
const T& l2) {
return l1.inverse().compose(l2);}
38 inline Vector
logmap_default(
const T& l0,
const T& lp) {
return T::Logmap(l0.between(lp));}
42 inline T
expmap_default(
const T& t,
const Vector& d) {
return t.compose(T::Expmap(d));}
81 static T concept_check(
const T& t) {
89 size_t dim_ret = t.dim();
92 T expmap_identity_ret = T::Expmap(
gtsam::zero(dim_ret));
95 Vector logmap_identity_ret = T::Logmap(t);
98 T between_ret = expmap_identity_ret.between(t2);
114 T
BCH(
const T& X,
const T& Y) {
115 static const double _2 = 1. / 2., _12 = 1. / 12., _24 = 1. / 24.;
116 T X_Y = bracket(X, Y);
117 return X + Y + _2 * X_Y + _12 * bracket(X - Y, X_Y) - _24 * bracket(Y,
125 template <
class T> Matrix
wedge(
const Vector& x);
134 T
expm(
const Vector& x,
int K=7) {
135 Matrix xhat = wedge<T>(x);
136 return T(
expm(xhat,K));
149 #define GTSAM_CONCEPT_LIE_INST(T) \
150 template class gtsam::ManifoldConcept<T>; \
151 template class gtsam::GroupConcept<T>; \
152 template class gtsam::LieConcept<T>;
154 #define GTSAM_CONCEPT_LIE_TYPE(T) \
155 typedef gtsam::ManifoldConcept<T> _gtsam_ManifoldConcept_##T; \
156 typedef gtsam::GroupConcept<T> _gtsam_GroupConcept_##T; \
157 typedef gtsam::LieConcept<T> _gtsam_LieConcept_##T;
T BCH(const T &X, const T &Y)
Three term approximation of the Baker�Campbell�Hausdorff formula In non-commutative Lie groups...
Definition: Lie.h:114
Vector logmap_default(const T &l0, const T &lp)
Log map centered at l0, s.t.
Definition: Lie.h:38
T expm(const Vector &x, int K=7)
Exponential map given exponential coordinates class T needs a wedge<> function and a constructor from...
Definition: Lie.h:134
Base class and basic functions for Manifold types.
bool zero(const Vector &v)
check if all zero
Definition: Vector.cpp:39
T between_default(const T &l1, const T &l2)
These core global functions can be specialized by new Lie types for better performance.
Definition: Lie.h:34
T expmap_default(const T &t, const Vector &d)
Exponential map centered at l0, s.t.
Definition: Lie.h:42
Concept check class for variable types with Group properties.
Concept check class for Lie group type.
Definition: Lie.h:78
Matrix wedge(const Vector &x)
Declaration of wedge (see Murray94book) used to convert from n exponential coordinates to n*n element...