ViSP
2.10.0
|
#include <vpThetaUVector.h>
Public Member Functions | |
vpThetaUVector () | |
vpThetaUVector (const vpThetaUVector &tu) | |
vpThetaUVector (const vpHomogeneousMatrix &M) | |
vpThetaUVector (const vpPoseVector &p) | |
vpThetaUVector (const vpRotationMatrix &R) | |
vpThetaUVector (const vpRzyxVector &rzyx) | |
vpThetaUVector (const vpRzyzVector &rzyz) | |
vpThetaUVector (const vpRxyzVector &rxyz) | |
vpThetaUVector (const double tux, const double tuy, const double tuz) | |
vpThetaUVector | buildFrom (const vpHomogeneousMatrix &M) |
vpThetaUVector | buildFrom (const vpPoseVector &p) |
vpThetaUVector | buildFrom (const vpRotationMatrix &R) |
vpThetaUVector | buildFrom (const vpRzyxVector &rzyx) |
vpThetaUVector | buildFrom (const vpRzyzVector &zyz) |
vpThetaUVector | buildFrom (const vpRxyzVector &xyz) |
vpThetaUVector & | operator= (double x) |
void | extract (double &theta, vpColVector &u) const |
double & | operator[] (unsigned int n) |
const double & | operator[] (unsigned int n) const |
unsigned int | size () const |
vpRowVector | t () const |
Protected Member Functions | |
void | init (const unsigned int size) |
Protected Attributes | |
double * | r |
unsigned int | _size |
Class that consider the case of the parameterization for the rotation.
The representation is one of the minimal representation of a rotation matrix, where is a unit vector representing the rotation axis and is the rotation angle.
From the representation it is possible to build the rotation matrix using the Rodrigues formula:
with the identity matrix of dimension and the skew matrix:
From the implementation point of view, it is nothing more than an array of three floats.
The code below shows first how to initialize a vector, than how to contruct a rotation matrix from a vpThetaUVector and finaly how to extract the theta U angles from the build rotation matrix.
Definition at line 140 of file vpThetaUVector.h.
|
inline |
Default constructor that initialize all the angles to zero.
Definition at line 152 of file vpThetaUVector.h.
|
inline |
Copy constructor.
Definition at line 154 of file vpThetaUVector.h.
vpThetaUVector::vpThetaUVector | ( | const vpHomogeneousMatrix & | M | ) |
Initialize a vector from an homogeneous matrix.
Definition at line 60 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector::vpThetaUVector | ( | const vpPoseVector & | p | ) |
Initialize a vector from a pose vector.
Definition at line 67 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector::vpThetaUVector | ( | const vpRotationMatrix & | R | ) |
Initialize a vector from a rotation matrix.
Definition at line 74 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector::vpThetaUVector | ( | const vpRzyxVector & | rzyx | ) |
Initialize a vector from an Euler z-y-x representation vector.
Definition at line 83 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector::vpThetaUVector | ( | const vpRzyzVector & | rzyz | ) |
Initialize a vector from an Euler z-y-z representation vector.
Definition at line 91 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector::vpThetaUVector | ( | const vpRxyzVector & | rxyz | ) |
Initialize a vector from an Euler x-y-z representation vector.
Definition at line 99 of file vpThetaUVector.cpp.
References buildFrom().
|
inline |
Build a vector from 3 angles in radian.
Definition at line 172 of file vpThetaUVector.h.
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpHomogeneousMatrix & | M | ) |
Converts an homogeneous matrix into a vector.
Definition at line 108 of file vpThetaUVector.cpp.
References vpHomogeneousMatrix::extract().
Referenced by vpPoseVector::buildFrom(), buildFrom(), vpHomogeneousMatrix::extract(), vpRobotAfma6::getVelocity(), vpRobotViper850::getVelocity(), vpRobotViper650::getVelocity(), vpExponentialMap::inverse(), vpSimulatorAfma6::setPosition(), and vpThetaUVector().
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpPoseVector & | p | ) |
Converts a pose vector into a vector.
Definition at line 121 of file vpThetaUVector.cpp.
References vpRotationVector::r.
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpRotationMatrix & | R | ) |
Converts a rotation matrix into a vector.
Definition at line 133 of file vpThetaUVector.cpp.
References vpRotationVector::r, and vpMath::sinc().
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpRzyxVector & | rzyx | ) |
Build a vector from an Euler z-y-x representation vector.
Definition at line 238 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpRzyzVector & | rzyz | ) |
Build a vector from an Euler z-y-z representation vector.
Definition at line 250 of file vpThetaUVector.cpp.
References buildFrom().
vpThetaUVector vpThetaUVector::buildFrom | ( | const vpRxyzVector & | rxyz | ) |
Build a vector from an Euler x-y-z representation vector.
Definition at line 262 of file vpThetaUVector.cpp.
References buildFrom().
void vpThetaUVector::extract | ( | double & | theta, |
vpColVector & | u | ||
) | const |
Extract the rotation angle and the unit vector from the representation.
theta | : Rotation angle . |
u | : Unit vector representing the rotation axis. |
Definition at line 311 of file vpThetaUVector.cpp.
References vpRotationVector::r, and vpColVector::resize().
Referenced by vpQuaternionVector::buildFrom().
|
protectedinherited |
Definition at line 117 of file vpRotationVector.cpp.
References vpRotationVector::_size, and vpRotationVector::r.
vpThetaUVector & vpThetaUVector::operator= | ( | double | v | ) |
Initialize each element of the vector to the same angle value v.
v | : Angle value to set for each element of the vector. |
Definition at line 291 of file vpThetaUVector.cpp.
References vpRotationVector::r.
|
inlineinherited |
Operator that allows to set the value of an element of the rotation vector: r[i] = value
Definition at line 130 of file vpRotationVector.h.
|
inlineinherited |
Operator that allows to get the value of an element of the rotation vector: value = r[i]
Definition at line 135 of file vpRotationVector.h.
|
inherited |
Returns the size of the rotation vector
Size of the rotation vector: number of double values describing the rotation. Common sizes are 4 for a quaternion and 3 for angle-based rotation vectors.
Definition at line 71 of file vpRotationVector.cpp.
References vpRotationVector::_size.
Referenced by vpRotationVector::operator=().
|
inherited |
Return the transpose of the rotation vector.
Definition at line 57 of file vpRotationVector.cpp.
References vpRotationVector::_size, and vpRotationVector::r.
|
protectedinherited |
Definition at line 99 of file vpRotationVector.h.
Referenced by vpRotationVector::init(), vpRotationVector::size(), vpRotationVector::t(), and vpColVector::vpColVector().
|
protectedinherited |
Definition at line 98 of file vpRotationVector.h.
Referenced by buildFrom(), vpRzyzVector::buildFrom(), vpRzyxVector::buildFrom(), vpRxyzVector::buildFrom(), extract(), vpRotationVector::init(), vpRotationVector::operator=(), operator=(), vpRzyzVector::operator=(), vpQuaternionVector::set(), vpRotationVector::t(), vpColVector::vpColVector(), vpRxyzVector::vpRxyzVector(), vpRzyxVector::vpRzyxVector(), vpRzyzVector::vpRzyzVector(), and vpRotationVector::~vpRotationVector().