smooth
A C++ library for Lie theory
|
Base class for Lie group types. More...
#include <lie_group_base.hpp>
Public Types | |
using | Scalar = typename traits::Scalar |
Scalar type. | |
using | Matrix = Eigen::Matrix< Scalar, Dim, Dim > |
Lie group matrix type. | |
using | Tangent = Eigen::Matrix< Scalar, Dof, 1 > |
Lie group parameterized tangent type. | |
using | TangentMap = Eigen::Matrix< Scalar, Dof, Dof > |
Matrix representing map between tangent elements. | |
using | Hessian = Eigen::Matrix< Scalar, Dof, Dof *Dof > |
Plain return type with different scalar. | |
template<typename NewScalar > | |
using | CastT = typename traits::template PlainObject< NewScalar > |
Plain return type with different scalar. | |
using | PlainObject = CastT< Scalar > |
Plain return type. | |
Public Member Functions | |
template<bool = true> requires (is_mutable) | |
auto & | coeffs () const |
Access underlying storages. | |
const auto & | coeffs () const |
Const access underlying storages. | |
template<bool = true> requires (is_mutable) | |
auto * | data () const |
Access raw pointer. | |
const auto * | data () const |
Const access raw pointer. | |
template<typename OtherDerived > requires (is_mutable && std::is_same_v<Impl, typename liebase_info<OtherDerived>::Impl>) | |
Derived & | operator= (const LieGroupBase< OtherDerived > &o) noexcept |
Eigen::Index | dof () const noexcept |
Dynamic size (degrees of freedom). | |
void | setIdentity () noexcept |
Set to group identity element. | |
void | setRandom () noexcept |
Set to a random element. | |
Matrix | matrix () const noexcept |
Return as matrix Lie group element in \( \mathbb{R}^{\mathtt{dim} \times \mathtt{dim}}
\). | |
template<typename OtherDerived > requires (std::is_same_v<Impl, typename liebase_info<OtherDerived>::Impl>) | |
bool | isApprox (const LieGroupBase< OtherDerived > &o, const Scalar &eps=Eigen::NumTraits< Scalar >::dummy_precision()) const noexcept |
Check if (approximately) equal to other element o . | |
template<typename NewScalar > | |
CastT< NewScalar > | cast () const noexcept |
Cast to different scalar type. | |
template<typename OtherDerived > requires (std::is_same_v<Impl, typename liebase_info<OtherDerived>::Impl>) | |
PlainObject | operator* (const LieGroupBase< OtherDerived > &o) const noexcept |
Group binary composition operation. | |
template<typename OtherDerived > requires (is_mutable && std::is_same_v<Impl, typename liebase_info<OtherDerived>::Impl>) | |
Derived & | operator*= (const LieGroupBase< OtherDerived > &o) noexcept |
Inplace group binary composition operation. | |
PlainObject | inverse () const noexcept |
Group inverse operation. | |
Tangent | log () const noexcept |
Lie group logarithm. | |
TangentMap | Ad () const noexcept |
Lie group adjoint. | |
template<typename TangentDerived > | |
PlainObject | operator+ (const Eigen::MatrixBase< TangentDerived > &a) const noexcept |
Right-plus. | |
template<typename TangentDerived > requires (is_mutable) | |
Derived & | operator+= (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Inplace right-plus: \( \mathbf{x} \leftarrow \mathbf{x} \circ \exp(\mathbf{a}) \). | |
template<typename OtherDerived > requires (std::is_same_v<Impl, typename liebase_info<OtherDerived>::Impl>) | |
Tangent | operator- (const LieGroupBase< OtherDerived > &xo) const noexcept |
Right-minus. | |
Static Public Member Functions | |
static PlainObject | Identity () noexcept |
Construct the identity element. | |
static PlainObject | Random () noexcept |
Construct a random element. | |
template<typename TangentDerived > | |
static PlainObject | exp (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Lie group exponential map. | |
template<typename TangentDerived > | |
static Matrix | hat (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Lie algebra hat map. | |
template<typename MatrixDerived > | |
static Tangent | vee (const Eigen::MatrixBase< MatrixDerived > &A) noexcept |
Lie alebra vee map. | |
template<typename TangentDerived > | |
static TangentMap | ad (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Lie algebra adjoint. | |
template<typename TangentDerived1 , typename TangentDerived2 > | |
static Tangent | lie_bracket (const Eigen::MatrixBase< TangentDerived1 > &a, const Eigen::MatrixBase< TangentDerived2 > &b) noexcept |
Lie algebra bracket. | |
template<typename TangentDerived > | |
static TangentMap | dr_exp (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Right jacobian of the exponential map. | |
template<typename TangentDerived > | |
static TangentMap | dr_expinv (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Inverse of right jacobian of the exponential map. | |
template<typename TangentDerived > | |
static TangentMap | dl_exp (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Left jacobian of the exponential map. | |
template<typename TangentDerived > | |
static TangentMap | dl_expinv (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Inverse of left jacobian of the exponential map. | |
template<typename TangentDerived > | |
static Hessian | d2r_exp (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Right Hessian of the exponential map. | |
template<typename TangentDerived > | |
static Hessian | d2r_expinv (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Right Hessian of the log map. | |
template<typename TangentDerived > | |
static Hessian | d2l_exp (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Left Hessian of the exponential map. | |
template<typename TangentDerived > | |
static Hessian | d2l_expinv (const Eigen::MatrixBase< TangentDerived > &a) noexcept |
Left Hessian of the log map. | |
Static Public Attributes | |
static constexpr int | RepSize = Impl::RepSize |
Number of scalars in internal representation. | |
static constexpr int | Dof = Impl::Dof |
Degrees of freedom of manifold (equal to tangent space dimension). | |
static constexpr int | Dim = Impl::Dim |
Side of Lie group matrix representation. | |
static constexpr bool | IsCommutative = Impl::IsCommutative |
Commutativity of group. A commutative group has a zero Lie bracket. | |
Protected Types | |
using | traits = liebase_info< Derived > |
CRTP traits. | |
using | Impl = typename traits::Impl |
Group-specific Lie group implementation. | |
Static Protected Attributes | |
static constexpr bool | is_mutable = traits::is_mutable |
True if underlying storage supports modification. | |
Base class for Lie group types.
Definition at line 27 of file lie_group_base.hpp.
using LieGroupBase< Derived >::CastT = typename traits::template PlainObject<NewScalar> |
Plain return type with different scalar.
Definition at line 67 of file lie_group_base.hpp.
Plain return type with different scalar.
Definition at line 64 of file lie_group_base.hpp.
Group-specific Lie group implementation.
Definition at line 40 of file lie_group_base.hpp.
Lie group matrix type.
Definition at line 58 of file lie_group_base.hpp.
Plain return type.
Definition at line 69 of file lie_group_base.hpp.
Scalar type.
Definition at line 56 of file lie_group_base.hpp.
Lie group parameterized tangent type.
Definition at line 60 of file lie_group_base.hpp.
using LieGroupBase< Derived >::TangentMap = Eigen::Matrix<Scalar, Dof, Dof> |
Matrix representing map between tangent elements.
Definition at line 62 of file lie_group_base.hpp.
|
protected |
CRTP traits.
Definition at line 37 of file lie_group_base.hpp.
|
inlinenoexcept |
Lie group adjoint.
Definition at line 227 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Lie algebra adjoint.
Definition at line 332 of file lie_group_base.hpp.
|
inlinenoexcept |
Cast to different scalar type.
Definition at line 169 of file lie_group_base.hpp.
|
inline |
Access underlying storages.
Definition at line 74 of file lie_group_base.hpp.
Const access underlying storages.
Definition at line 79 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Left Hessian of the exponential map.
Definition at line 458 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Left Hessian of the log map.
Definition at line 470 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Right Hessian of the exponential map.
Definition at line 423 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Right Hessian of the log map.
Definition at line 441 of file lie_group_base.hpp.
|
inline |
Access raw pointer.
Definition at line 84 of file lie_group_base.hpp.
Const access raw pointer.
Definition at line 89 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Left jacobian of the exponential map.
Definition at line 401 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Inverse of left jacobian of the exponential map.
Definition at line 412 of file lie_group_base.hpp.
|
inlinenoexcept |
Dynamic size (degrees of freedom).
Definition at line 107 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Right jacobian of the exponential map.
Definition at line 367 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Inverse of right jacobian of the exponential map.
Definition at line 384 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Lie group exponential map.
Definition at line 285 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Lie algebra hat map.
Maps a parameterization \( a \in \mathbb{R}^\mathtt{dof} \) a matrix Lie algebra element to the corresponding matrix Lie algebra element \( A \in \mathbb{R}^{\mathtt{dim} \times \mathtt{dim}} \).
Definition at line 302 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Construct the identity element.
Definition at line 124 of file lie_group_base.hpp.
|
inlinenoexcept |
Group inverse operation.
Definition at line 202 of file lie_group_base.hpp.
|
inlinenoexcept |
Check if (approximately) equal to other element o
.
Definition at line 159 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Lie algebra bracket.
\[ [ \mathbf{a}, \mathbf{b}] = \left( \mathbf{a}^\wedge \mathbf{b}^\wedge - \mathbf{b}^\wedge \mathbf{a}^\wedge \right)^\vee. \]
Definition at line 352 of file lie_group_base.hpp.
|
inlinenoexcept |
Lie group logarithm.
Definition at line 214 of file lie_group_base.hpp.
|
inlinenoexcept |
Return as matrix Lie group element in \( \mathbb{R}^{\mathtt{dim} \times \mathtt{dim}} \).
Definition at line 147 of file lie_group_base.hpp.
|
inlinenoexcept |
Group binary composition operation.
Definition at line 181 of file lie_group_base.hpp.
|
inlinenoexcept |
Inplace group binary composition operation.
Definition at line 193 of file lie_group_base.hpp.
|
inlinenoexcept |
Right-plus.
Definition at line 244 of file lie_group_base.hpp.
|
inlinenoexcept |
Inplace right-plus: \( \mathbf{x} \leftarrow \mathbf{x} \circ \exp(\mathbf{a}) \).
Definition at line 256 of file lie_group_base.hpp.
|
inlinenoexcept |
Right-minus.
\[ \mathbf{x}_1 \ominus \mathbf{x}_2 := \log(\mathbf{x}_2^{-1} \circ \mathbf{x}_1) \]
Definition at line 274 of file lie_group_base.hpp.
|
inlinenoexcept |
Assignment operation from other storage type.
Definition at line 96 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Construct a random element.
Set the seed with std::srand(unsigned)
.
Definition at line 136 of file lie_group_base.hpp.
|
inlinenoexcept |
Set to group identity element.
Definition at line 112 of file lie_group_base.hpp.
|
inlinenoexcept |
Set to a random element.
Set the seed with std::srand(unsigned)
.
Definition at line 119 of file lie_group_base.hpp.
|
inlinestaticnoexcept |
Side of Lie group matrix representation.
Definition at line 51 of file lie_group_base.hpp.
Degrees of freedom of manifold (equal to tangent space dimension).
Definition at line 49 of file lie_group_base.hpp.
|
staticconstexprprotected |
True if underlying storage supports modification.
Definition at line 43 of file lie_group_base.hpp.
|
staticconstexpr |
Commutativity of group. A commutative group has a zero Lie bracket.
Definition at line 53 of file lie_group_base.hpp.
|
staticconstexpr |
Number of scalars in internal representation.
Definition at line 47 of file lie_group_base.hpp.