sva Namespace Reference

Namespaces

 conversions
 Generic functions to convert to/from sva types.
 
 details
 
 sva_internal
 

Classes

class  ABInertia
 
class  AdmittanceVec
 
class  ForceVec
 
class  ImpedanceVec
 
class  MotionVec
 
class  PTransform
 
class  RBInertia
 

Typedefs

typedef MotionVec< double > MotionVecd
 
typedef ForceVec< double > ForceVecd
 
typedef ImpedanceVec< double > ImpedanceVecd
 
typedef AdmittanceVec< double > AdmittanceVecd
 
typedef RBInertia< double > RBInertiad
 
typedef ABInertia< double > ABInertiad
 
typedef PTransform< double > PTransformd
 

Functions

template<typename T , typename T2 >
ABInertia< T > operator* (T2 scalar, const ABInertia< T > &abI)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const ABInertia< T > &abI)
 
template<typename T , typename T2 >
AdmittanceVec< T > operator* (T2 scalar, const AdmittanceVec< T > &av)
 
template<typename T >
MotionVec< T > operator* (const AdmittanceVec< T > &av, const ForceVec< T > &fv)
 
template<typename T >
MotionVec< T > operator* (const ForceVec< T > &fv, const AdmittanceVec< T > &av)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const AdmittanceVec< T > &av)
 
template<typename T , typename T2 >
ForceVec< T > operator* (T2 scalar, const ForceVec< T > &fv)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const ForceVec< T > &fv)
 
template<typename T , typename T2 >
ImpedanceVec< T > operator* (T2 scalar, const ImpedanceVec< T > &iv)
 
template<typename T >
ForceVec< T > operator* (const ImpedanceVec< T > &iv, const MotionVec< T > &mv)
 
template<typename T >
ForceVec< T > operator* (const MotionVec< T > &mv, const ImpedanceVec< T > &iv)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const ImpedanceVec< T > &iv)
 
template<typename T >
sinc (const T x)
 
template<typename T >
sinc_inv (const T x)
 
template<typename T >
Eigen::Matrix3< T > SO3RightJacInv (const Eigen::Vector3< T > &u)
 
template<typename T >
Eigen::Matrix3< T > SO3RightJacInvDot (const Eigen::Vector3< T > &u, const Eigen::Vector3< T > &du)
 
template<typename T , typename T2 >
MotionVec< T > operator* (T2 scalar, const MotionVec< T > &mv)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const MotionVec< T > &mv)
 
template<typename Derived >
Eigen::Block< Derived, 3, Eigen::Dynamic > motionAngular (Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< const Derived, 3, Eigen::Dynamic > motionAngular (const Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< Derived, 3, Eigen::Dynamic > motionLinear (Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< const Derived, 3, Eigen::Dynamic > motionLinear (const Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< Derived, 3, Eigen::Dynamic > forceCouple (Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< const Derived, 3, Eigen::Dynamic > forceCouple (const Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< Derived, 3, Eigen::Dynamic > forceForce (Eigen::MatrixBase< Derived > &mv)
 
template<typename Derived >
Eigen::Block< const Derived, 3, Eigen::Dynamic > forceForce (const Eigen::MatrixBase< Derived > &mv)
 
template<typename T >
Eigen::Matrix3< T > RotX (T theta)
 
template<typename T >
Eigen::Matrix3< T > RotY (T theta)
 
template<typename T >
Eigen::Matrix3< T > RotZ (T theta)
 
template<typename T >
Eigen::Vector3< T > rotationError (const Eigen::Matrix3< T > &E_a_b, const Eigen::Matrix3< T > &E_a_c)
 
template<typename T >
Eigen::Vector3< T > rotationVelocity (const Eigen::Matrix3< T > &E_a_b)
 
template<typename T >
MotionVec< T > transformError (const PTransform< T > &X_a_b, const PTransform< T > &X_a_c)
 
template<typename T >
MotionVec< T > transformVelocity (const PTransform< T > &X_a_b)
 
template<typename T >
PTransform< T > interpolate (const PTransform< T > &from, const PTransform< T > &to, double t)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const PTransform< T > &pt)
 
template<typename T >
Eigen::Matrix3< T > inertiaToOrigin (const Eigen::Matrix3< T > &inertia, T mass, const Eigen::Vector3< T > &com, const Eigen::Matrix3< T > &rotation)
 
template<typename T , typename T2 >
RBInertia< T > operator* (T2 scalar, const RBInertia< T > &rbI)
 
template<typename T >
std::ostream & operator<< (std::ostream &out, const RBInertia< T > &rbI)
 

Typedef Documentation

◆ ABInertiad

typedef ABInertia<double> sva::ABInertiad

◆ AdmittanceVecd

◆ ForceVecd

typedef ForceVec<double> sva::ForceVecd

◆ ImpedanceVecd

◆ MotionVecd

typedef MotionVec<double> sva::MotionVecd

◆ PTransformd

typedef PTransform<double> sva::PTransformd

◆ RBInertiad

typedef RBInertia<double> sva::RBInertiad

Function Documentation

◆ forceCouple() [1/2]

template<typename Derived >
Eigen::Block<const Derived, 3, Eigen::Dynamic> sva::forceCouple ( const Eigen::MatrixBase< Derived > &  mv)
inline

◆ forceCouple() [2/2]

template<typename Derived >
Eigen::Block<Derived, 3, Eigen::Dynamic> sva::forceCouple ( Eigen::MatrixBase< Derived > &  mv)
inline

◆ forceForce() [1/2]

template<typename Derived >
Eigen::Block<const Derived, 3, Eigen::Dynamic> sva::forceForce ( const Eigen::MatrixBase< Derived > &  mv)
inline

◆ forceForce() [2/2]

template<typename Derived >
Eigen::Block<Derived, 3, Eigen::Dynamic> sva::forceForce ( Eigen::MatrixBase< Derived > &  mv)
inline

◆ inertiaToOrigin()

template<typename T >
Eigen::Matrix3< T > sva::inertiaToOrigin ( const Eigen::Matrix3< T > &  inertia,
mass,
const Eigen::Vector3< T > &  com,
const Eigen::Matrix3< T > &  rotation 
)

◆ interpolate()

template<typename T >
PTransform<T> sva::interpolate ( const PTransform< T > &  from,
const PTransform< T > &  to,
double  t 
)

◆ motionAngular() [1/2]

template<typename Derived >
Eigen::Block<const Derived, 3, Eigen::Dynamic> sva::motionAngular ( const Eigen::MatrixBase< Derived > &  mv)
inline

◆ motionAngular() [2/2]

template<typename Derived >
Eigen::Block<Derived, 3, Eigen::Dynamic> sva::motionAngular ( Eigen::MatrixBase< Derived > &  mv)
inline

◆ motionLinear() [1/2]

template<typename Derived >
Eigen::Block<const Derived, 3, Eigen::Dynamic> sva::motionLinear ( const Eigen::MatrixBase< Derived > &  mv)
inline

◆ motionLinear() [2/2]

template<typename Derived >
Eigen::Block<Derived, 3, Eigen::Dynamic> sva::motionLinear ( Eigen::MatrixBase< Derived > &  mv)
inline

◆ operator*() [1/10]

template<typename T >
MotionVec<T> sva::operator* ( const AdmittanceVec< T > &  av,
const ForceVec< T > &  fv 
)
inline

◆ operator*() [2/10]

template<typename T >
MotionVec<T> sva::operator* ( const ForceVec< T > &  fv,
const AdmittanceVec< T > &  av 
)
inline

◆ operator*() [3/10]

template<typename T >
ForceVec<T> sva::operator* ( const ImpedanceVec< T > &  iv,
const MotionVec< T > &  mv 
)
inline

◆ operator*() [4/10]

template<typename T >
ForceVec<T> sva::operator* ( const MotionVec< T > &  mv,
const ImpedanceVec< T > &  iv 
)
inline

◆ operator*() [5/10]

template<typename T , typename T2 >
ABInertia<T> sva::operator* ( T2  scalar,
const ABInertia< T > &  abI 
)
inline

◆ operator*() [6/10]

template<typename T , typename T2 >
AdmittanceVec<T> sva::operator* ( T2  scalar,
const AdmittanceVec< T > &  av 
)
inline

◆ operator*() [7/10]

template<typename T , typename T2 >
ForceVec<T> sva::operator* ( T2  scalar,
const ForceVec< T > &  fv 
)
inline

◆ operator*() [8/10]

template<typename T , typename T2 >
ImpedanceVec<T> sva::operator* ( T2  scalar,
const ImpedanceVec< T > &  iv 
)
inline

◆ operator*() [9/10]

template<typename T , typename T2 >
MotionVec<T> sva::operator* ( T2  scalar,
const MotionVec< T > &  mv 
)
inline

◆ operator*() [10/10]

template<typename T , typename T2 >
RBInertia<T> sva::operator* ( T2  scalar,
const RBInertia< T > &  rbI 
)
inline

◆ operator<<() [1/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const ABInertia< T > &  abI 
)
inline

◆ operator<<() [2/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const AdmittanceVec< T > &  av 
)
inline

◆ operator<<() [3/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const ForceVec< T > &  fv 
)
inline

◆ operator<<() [4/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const ImpedanceVec< T > &  iv 
)
inline

◆ operator<<() [5/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const MotionVec< T > &  mv 
)
inline

◆ operator<<() [6/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const PTransform< T > &  pt 
)
inline

◆ operator<<() [7/7]

template<typename T >
std::ostream& sva::operator<< ( std::ostream &  out,
const RBInertia< T > &  rbI 
)
inline

◆ rotationError()

template<typename T >
Eigen::Vector3< T > sva::rotationError ( const Eigen::Matrix3< T > &  E_a_b,
const Eigen::Matrix3< T > &  E_a_c 
)
inline

Compute the 3D rotation error between two matrix E_a_b and E_a_c in the 'a' frame. This method convert the 3D rotation matrix E_b_c into a rotation vector. The matrix E_b_c is computed as follow E_a_c = E_b_c*E_a_b. Then the error is computed with E_b_a*rotationVelocity(E_b_c).

Returns
XYZ rotation in radian.

◆ rotationVelocity()

template<typename T >
Eigen::Vector3< T > sva::rotationVelocity ( const Eigen::Matrix3< T > &  E_a_b)
inline

Compute the 3D rotation vector of the rotation matrix E_a_b in the 'a' frame. If we integrate this rotation vector for 1 second we must have the rotation matrix E_a_b. (see exponential matrix and logarithmic matrix).

◆ RotX()

template<typename T >
Eigen::Matrix3< T > sva::RotX ( theta)
inline

Create a rotation matrix about the X axis. The rotation is exprimed in successor frame.

Parameters
thetarotation in radian.

◆ RotY()

template<typename T >
Eigen::Matrix3< T > sva::RotY ( theta)
inline

Create a rotation matrix about the Y axis. The rotation is exprimed in successor frame.

Parameters
thetarotation in radian.

◆ RotZ()

template<typename T >
Eigen::Matrix3< T > sva::RotZ ( theta)
inline

Create a rotation matrix about the Z axis. The rotation is exprimed in successor frame.

Parameters
thetarotation in radian.

◆ sinc()

template<typename T >
T sva::sinc ( const T  x)

sinus cardinal: sin(x)/x Code adapted from boost::math::detail::sinc

◆ sinc_inv()

template<typename T >
T sva::sinc_inv ( const T  x)

Compute 1/sinc(x). This code is inspired by boost/math/special_functions/sinc.hpp.

◆ SO3RightJacInv()

template<typename T >
Eigen::Matrix3<T> sva::SO3RightJacInv ( const Eigen::Vector3< T > &  u)

Inverse of the right Jacobian of SO(3) as defined in "A micro Lie theory for state estimation in robotics" by SolĂ  et al. (see in particular eq. 144)

Inverse of left Jacobian is simply obtained by transposing (see eq. 147)

sva::rotationError(X,Y) is such that is derivative wrt X is $ J_r^{-1} $ as given by this function and its derivative wrt Y is $ -J_r^{-T} $.

Parameters
uPoint of so(3) at which to compute the matrix.

◆ SO3RightJacInvDot()

template<typename T >
Eigen::Matrix3<T> sva::SO3RightJacInvDot ( const Eigen::Vector3< T > &  u,
const Eigen::Vector3< T > &  du 
)

Derivative w.r.t. time of Inverse of the right Jacobian of SO(3)

Parameters
uPoint of so(3) at which to compute the matrix.
duDerivative w.r.t. time of u.

◆ transformError()

template<typename T >
MotionVec< T > sva::transformError ( const PTransform< T > &  X_a_b,
const PTransform< T > &  X_a_c 
)
inline

Compute the 6D error between two PTransform in the 'a' frame. This method convert the 6D transformation matrix X_b_c into a motion vector. The matrix X_b_c is computed as follow X_a_c = X_b_c*X_a_b. Then the error is computed with PTransform(E_b_a)*transformVelocity(X_b_c).

Returns
XYZ rotation in radian.

◆ transformVelocity()

template<typename T >
MotionVec< T > sva::transformVelocity ( const PTransform< T > &  X_a_b)
inline

Compute the motion vector of the matrix X_a_b in the 'a' frame. If we integrate this motion vector for 1 second we must have the transformation matrix X_a_b. This function can be see as an implementation of the function XtoV (see Featherstone appendix) but with the use of logarithmic matrix to compute the rotational error.