#include <state-observation/tools/rigid-body-kinematics.hpp>
Public Member Functions | |
Orientation (bool initialize=true) | |
Orientation (const Vector3 &v) | |
this is the rotation vector and NOT Euler angles More... | |
Orientation (const Quaternion &q) | |
Orientation (const Matrix3 &m) | |
Orientation (const AngleAxis &aa) | |
Orientation (const Quaternion &q, const Matrix3 &m) | |
Orientation (const double &roll, const double &pitch, const double &yaw) | |
Orientation (const Orientation &multiplier1, const Orientation &multiplier2) | |
Orientation & | operator= (const Vector3 &v) |
Orientation & | operator= (const Quaternion &q) |
Orientation & | operator= (const Matrix3 &m) |
Orientation & | operator= (const AngleAxis &aa) |
Orientation & | setValue (const Quaternion &q, const Matrix3 &m) |
Orientation & | fromVector4 (const Vector4 &v) |
Orientation & | setRandom () |
template<typename t = Quaternion> | |
Orientation & | setZeroRotation () |
const Matrix3 & | toMatrix3 () const |
get a const reference on the matrix or the quaternion More... | |
const Quaternion & | toQuaternion () const |
operator const Matrix3 & () const | |
operator const Quaternion & () const | |
Vector4 | toVector4 () const |
Vector3 | toRotationVector () const |
Vector3 | toRollPitchYaw () const |
AngleAxis | toAngleAxis () const |
Orientation | operator* (const Orientation &R2) const |
const Orientation & | setToProductNoAlias (const Orientation &R1, const Orientation &R2) |
Noalias versions of the operator*. More... | |
Orientation | inverse () const |
const Orientation & | integrate (Vector3 dt_x_omega) |
const Orientation & | integrateRightSide (Vector3 dt_x_omega) |
Vector3 | differentiate (Orientation R_k1) const |
gives the log (rotation vector) of the "left-side" difference of orientation: log of R_k1*(*this).inverse(). More... | |
Vector3 | differentiateRightSide (Orientation R_k1) const |
gives the log (rotation vector) of the "right-side" difference of orientation: log of (*this).inverse() * R_k1. More... | |
Vector3 | operator* (const Vector3 &v) const |
Rotate a vector. More... | |
bool | isSet () const |
checks that the orientation has been assigned a value. More... | |
void | reset () |
resets the Orientation object. More... | |
bool | isMatrixSet () const |
checks that the matrix representation of the orientation has been assigned a value. More... | |
bool | isQuaternionSet () const |
checks that the quaternion representation of the orientation has been assigned a value. More... | |
void | setMatrix (bool b=true) |
void | setQuaternion (bool b=true) |
CheckedMatrix3 & | getMatrixRefUnsafe () |
no checks are performed for these functions, use with caution More... | |
CheckedQuaternion & | getQuaternionRefUnsafe () |
get a reference to the quaternion representation of the orientation without calling the check functions. More... | |
void | synchronize () |
synchronizes the representations (quaternion and rotation matrix) More... | |
Static Public Member Functions | |
static Orientation | zeroRotation () |
retruns a zero rotation More... | |
static Orientation | randomRotation () |
Returns a uniformly distributed random rotation. More... | |
Protected Member Functions | |
void | check_ () const |
const Matrix3 & | quaternionToMatrix_ () const |
const Quaternion & | matrixToQuaternion_ () const |
Protected Attributes | |
CheckedQuaternion | q_ |
CheckedMatrix3 | m_ |
|
explicit |
The parameter initialize should be set to true except when it is certain that the initial value will not be used And that the first operation would be to set its value
|
explicit |
this is the rotation vector and NOT Euler angles
|
explicit |
|
explicit |
|
explicit |
stateObservation::kine::Orientation::Orientation | ( | const Quaternion & | q, |
const Matrix3 & | m | ||
) |
stateObservation::kine::Orientation::Orientation | ( | const double & | roll, |
const double & | pitch, | ||
const double & | yaw | ||
) |
stateObservation::kine::Orientation::Orientation | ( | const Orientation & | multiplier1, |
const Orientation & | multiplier2 | ||
) |
|
protected |
|
inline |
gives the log (rotation vector) of the "left-side" difference of orientation: log of R_k1*(*this).inverse().
This function is also used to differentiate two Orientations expressed in the same frame at the same time k, even for the LocalKinematics (the integration of the orientation is different and therefore the associated differentiation also is, but the difference remains the same)
R_k1 | the other orientation with which we compute the difference. |
|
inline |
gives the log (rotation vector) of the "right-side" difference of orientation: log of (*this).inverse() * R_k1.
This function is also used to differentiate two Orientations expressed in the same frame at the same time k, even for the LocalKinematics (the integration of the orientation is different and therefore the associated differentiation also is, but the difference remains the same)
R_k1 | the other orientation with which we compute the difference. |
|
inline |
|
inline |
no checks are performed for these functions, use with caution
get a reference to the matrix representation of the orientation without calling the check functions.
Has to be used with care as this function doesn't check that the matrix has been assigned values.
|
inline |
get a reference to the quaternion representation of the orientation without calling the check functions.
Has to be used with care as this function doesn't check that the quaternion has been assigned values.
|
inline |
uses the vector dt_x_omega as the increment of rotation expressed in the world frame. Which gives R_{k+1}=\exp(S(dtxomega))R_k. This function is also used to sum two Orientations expressed in the same frame at the same time k, even for the LocalKinematics (the integration of the orientation is different but not the sum)
|
inline |
use the vector dt_x_omega as the increment of rotation expressed in the local frame. Which gives R_{k+1}=R_k*exp(S(dtxomega))
|
inline |
|
inline |
checks that the matrix representation of the orientation has been assigned a value.
|
inline |
checks that the quaternion representation of the orientation has been assigned a value.
|
inline |
checks that the orientation has been assigned a value.
|
inlineprotected |
|
inline |
|
inline |
|
inline |
Multiply the rotation (orientation) by another rotation R2 the non const versions allow to use more optimized methods
Rotate a vector.
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineprotected |
|
inlinestatic |
Returns a uniformly distributed random rotation.
|
inline |
resets the Orientation object.
The orientation is then considered as outdated and cannot be used until it is assigned a value.
|
inline |
switch the state of the Matrix or quaternion to set or not this can be used for forward initialization
|
inline |
|
inline |
|
inline |
Noalias versions of the operator*.
|
inline |
|
inline |
|
inline |
synchronizes the representations (quaternion and rotation matrix)
|
inline |
|
inline |
get a const reference on the matrix or the quaternion
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinestatic |
retruns a zero rotation
|
mutableprotected |
|
mutableprotected |