16#include "wuzp/trafo/internal/rigid.hpp"
17#include "wuzp/trafo/internal/rotation.hpp"
18#include "wuzp/trafo/internal/rotation_parameterizations.hpp"
19#include "wuzp/trafo/internal/validity.hpp"
54 :
public PassiveTransformation<PassiveSpatialRotation<ValuesT_, ValueT_, FromT_, ToT_, DimensionV_>, FromT_, ToT_> {
55 using ParameterizationsT = internal::RotationParameterizationTypes<ValuesT_, ValueT_>;
56 using RequireParameterizableT = internal::RequireParameterizable<DimensionV_, ValueT_>;
57 using AngleUnitT =
typename ParameterizationsT::UnitsT::Angle;
58 using AngularVelocityUnitT =
typename ParameterizationsT::UnitsT::AngularVelocity;
74 using AngleT =
typename ParameterizationsT::AngleT;
97 template <
typename... Args>
100 internal::checkValidity(*
this,
"The matrix of a rotation must be orthogonal with determinant 1.");
105 template <
typename... Args>
114 template <
typename... Args>
123 auto inverse()
const {
return internal::WithFrames<PassiveSpatialRotation, ToT_, FromT_>::type::makeUnchecked(quantities_.transpose()); }
128 return internal::isRotation(quantities_.getValues(), tolerance);
133 template <
template <
typename,
int,
int>
typename ValuesOtherT_,
typename ValueOtherT_,
typename FromOtherT_,
typename ToOtherT_,
134 int DimensionOtherV_>
138 return quantities_.isApprox(other.
getQuantities(), precision);
150 template <AnyQuantities QuaternionOtherT_>
152 static_assert(RequireParameterizableT::value);
153 const auto elements = internal::checkedUnitQuaternion(internal::quaternionElements(
QuaternionT{quaternion}),
154 "The quaternion of a rotation must have unit length.");
155 return makeUnchecked(internal::matrixFromQuaternion<ValuesT>(elements));
160 static_assert(RequireParameterizableT::value);
161 return internal::fromElements<QuaternionT>(internal::quaternionFromMatrix(quantities_.getValues()));
168 template <AnyQuantities AngleOtherT_, AnyTensor AxisOtherT_>
170 static_assert(RequireParameterizableT::value);
171 const auto elements = internal::checkedUnitQuaternion(
172 internal::quaternionFromAngleAxis(
AngleT{angle}.getValue(), components<typename ParameterizationsT::UnitsT::Dimensionless>(axis)),
173 "The axis of a rotation must have unit length.");
174 return makeUnchecked(internal::matrixFromQuaternion<ValuesT>(elements));
179 static_assert(RequireParameterizableT::value);
180 const auto [angle, axis] = internal::angleAxisFromQuaternion(internal::quaternionFromMatrix(quantities_.getValues()));
181 return {
AngleT{angle}, internal::fromElements<AxisT>(axis)};
186 template <AnyTensor RotationVectorOtherT_>
188 static_assert(RequireParameterizableT::value);
189 return makeUnchecked(internal::matrixFromRotationVector<ValuesT>(components<AngleUnitT>(rotationVector)));
194 static_assert(RequireParameterizableT::value);
195 return internal::fromElements<RotationVectorT>(internal::rotationVectorFromMatrix(quantities_.getValues()));
200 template <AnyQuantities EulerAnglesOtherT_>
202 static_assert(RequireParameterizableT::value);
208 static_assert(RequireParameterizableT::value);
209 return internal::fromElements<EulerAnglesT>(internal::eulerAnglesZyxFromMatrix(quantities_.getValues()));
214 template <AnyQuantities EulerAnglesOtherT_>
216 static_assert(RequireParameterizableT::value);
222 static_assert(RequireParameterizableT::value);
223 return internal::fromElements<EulerAnglesT>(internal::eulerAnglesXyzFromMatrix(quantities_.getValues()));
233 template <AnyTensor FromVectorT_, AnyTensor ToVectorT_>
235 static_assert(RequireParameterizableT::value);
237 internal::directionElements<
typename ParameterizationsT::template
AxisT<FromT_>>(from), internal::directionElements<AxisT>(to)))};
245 template <AnyTensor RotationVectorOtherT_>
247 static_assert(RequireParameterizableT::value);
248 const ValuesT& matrix = quantities_.getValues();
249 return makeUnchecked(internal::boxPlus(matrix, componentsInTo<AngleUnitT>(matrix, rotationVector)));
254 template <
typename CoordinateSystemT_ = ToT_,
typename FromOtherT_,
typename ToOtherT_>
257 static_assert(RequireParameterizableT::value);
258 const ValuesT& matrix = quantities_.getValues();
259 return vectorFromTo<CoordinateSystemT_, AngleUnitT>(matrix, internal::boxMinus(matrix, other.
getQuantities().getValues()));
264 template <
typename FromOtherT_,
typename ToOtherT_>
267 static_assert(RequireParameterizableT::value);
268 return AngleT{internal::norm(internal::boxMinus(quantities_.getValues(), other.
getQuantities().getValues()))};
279 template <AnyTensor RotationVectorOtherT_>
281 static_assert(RequireParameterizableT::value);
283 constexpr bool inFrom = internal::IsInFrom<FromT_, ToT_, CoordinateSystemOtherT>::value;
286 return typename ParameterizationsT::template LinearMapT<CoordinateSystemOtherT>{
287 internal::TransposeIf<inFrom>::value(internal::exponentialMapJacobian<ValuesT>(components<AngleUnitT>(rotationVector)))};
295 template <AnyTensor AngularVelocityOtherT_>
297 static_assert(RequireParameterizableT::value);
298 const ValuesT& matrix = quantities_.getValues();
299 return MatrixDerivativeT{internal::matrixDerivative(matrix, componentsInTo<AngularVelocityUnitT>(matrix, angularVelocity))};
304 template <
typename CoordinateSystemT_ = ToT_, AnyQuantities MatrixDerivativeOtherT_>
306 static_assert(RequireParameterizableT::value);
307 const ValuesT& matrix = quantities_.getValues();
308 return vectorFromTo<CoordinateSystemT_, AngularVelocityUnitT>(
309 matrix, internal::angularVelocityFromMatrixDerivative(matrix,
MatrixDerivativeT{derivative}.getValues()));
314 template <AnyQuantities QuaternionOtherT_, AnyTensor AngularVelocityOtherT_>
316 static_assert(RequireParameterizableT::value);
317 const auto elements = internal::quaternionElements(
QuaternionT{quaternion});
318 return internal::fromElements<QuaternionDerivativeT>(internal::quaternionDerivative(
319 elements, componentsInTo<AngularVelocityUnitT>(internal::matrixFromQuaternion<ValuesT>(elements), angularVelocity)));
324 template <
typename CoordinateSystemT_ = ToT_, AnyQuantities QuaternionOtherT_, AnyQuantities QuaternionDerivativeOtherT_>
326 static_assert(RequireParameterizableT::value);
327 const auto elements = internal::quaternionElements(
QuaternionT{quaternion});
328 return vectorFromTo<CoordinateSystemT_, AngularVelocityUnitT>(
329 internal::matrixFromQuaternion<ValuesT>(elements),
330 internal::angularVelocityFromQuaternionDerivative(elements, internal::quaternionElements(
QuaternionDerivativeT{derivative})));
335 template <AnyQuantities EulerAnglesOtherT_, AnyTensor AngularVelocityOtherT_>
337 static_assert(RequireParameterizableT::value);
338 const auto elements = internal::elements3(
EulerAnglesT{angles});
339 return internal::fromElements<EulerAnglesDerivativeT>(internal::eulerAnglesZyxDerivative(
340 elements, componentsInTo<AngularVelocityUnitT>(internal::matrixFromEulerAngles<2, 1, 0, ValuesT>(elements), angularVelocity)));
345 template <
typename CoordinateSystemT_ = ToT_, AnyQuantities EulerAnglesOtherT_, AnyQuantities EulerAnglesDerivativeOtherT_>
347 const EulerAnglesDerivativeOtherT_& derivative) {
348 static_assert(RequireParameterizableT::value);
349 const auto elements = internal::elements3(
EulerAnglesT{angles});
350 return vectorFromTo<CoordinateSystemT_, AngularVelocityUnitT>(
351 internal::matrixFromEulerAngles<2, 1, 0, ValuesT>(elements),
352 internal::angularVelocityFromEulerAnglesZyxDerivative(elements, internal::elements3(
EulerAnglesDerivativeT{derivative})));
357 template <AnyQuantities EulerAnglesOtherT_, AnyTensor AngularVelocityOtherT_>
359 static_assert(RequireParameterizableT::value);
360 const auto elements = internal::elements3(
EulerAnglesT{angles});
361 return internal::fromElements<EulerAnglesDerivativeT>(internal::eulerAnglesXyzDerivative(
362 elements, componentsInTo<AngularVelocityUnitT>(internal::matrixFromEulerAngles<0, 1, 2, ValuesT>(elements), angularVelocity)));
367 template <
typename CoordinateSystemT_ = ToT_, AnyQuantities EulerAnglesOtherT_, AnyQuantities EulerAnglesDerivativeOtherT_>
369 const EulerAnglesDerivativeOtherT_& derivative) {
370 static_assert(RequireParameterizableT::value);
371 const auto elements = internal::elements3(
EulerAnglesT{angles});
372 return vectorFromTo<CoordinateSystemT_, AngularVelocityUnitT>(
373 internal::matrixFromEulerAngles<0, 1, 2, ValuesT>(elements),
374 internal::angularVelocityFromEulerAnglesXyzDerivative(elements, internal::elements3(
EulerAnglesDerivativeT{derivative})));
381 template <
typename UnitT_,
typename VectorT_>
382 static auto components(
const VectorT_& vector) {
385 static_cast<void>(internal::IsInFrom<FromT_, ToT_, CoordinateSystemOtherT>::value);
391 template <
typename UnitT_,
typename VectorT_>
392 static auto componentsInTo(
const ValuesT& matrix,
const VectorT_& vector) {
393 constexpr bool inFrom = internal::IsInFrom<FromT_, ToT_, typename GetCoordinateSystem<VectorT_>::type>::value;
394 return internal::TangentComponents<inFrom>::toTo(matrix, components<UnitT_>(vector));
399 template <
typename CoordinateSystemT_,
typename UnitT_>
400 static auto vectorFromTo(
const ValuesT& matrix,
const internal::Elements3<ValueT_>& elementsInTo) {
401 constexpr bool inFrom = internal::IsInFrom<FromT_, ToT_, CoordinateSystemT_>::value;
402 return internal::fromElements<HomogeneousVector<3, ValuesT_, ValueT_, UnitT_, CoordinateSystemT_>>(
403 internal::TangentComponents<inFrom>::fromTo(matrix, elementsInTo));
413template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_>
415template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_>
420template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_,
int DimensionV_>
421struct IsRotation<
PassiveSpatialRotation<ValuesT_, ValueT_, FromT_, ToT_, DimensionV_>> : std::true_type {};
423template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_,
int DimensionV_>
424struct IsChangeOfBasis<
PassiveSpatialRotation<ValuesT_, ValueT_, FromT_, ToT_, DimensionV_>> : std::true_type {};
426template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_,
int DimensionV_,
427 typename NewFromT_,
typename NewToT_>
428struct WithFrames<
PassiveSpatialRotation<ValuesT_, ValueT_, FromT_, ToT_, DimensionV_>, NewFromT_, NewToT_> {
436template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_,
int DimensionV_,
439 :
TransformationTraits<typename PassiveSpatialRotation<ValuesT_, ValueT_, FromT_, ToT_, DimensionV_>::LinearTransformationT, Object> {};
442template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
443 template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
int DimensionRhsV_>
454template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
455 template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
int DimensionRhsV_,
456 typename... UnitsRhsT_>
459 :
CompositionTraits<typename PassiveSpatialRotation<ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_>::LinearTransformationT,
460 PassiveLinearTransformation<ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_, UnitsRhsT_...>> {};
462template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
463 typename... UnitsLhsT_,
template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
464 typename ToRhsT_,
int DimensionRhsV_>
468 PassiveLinearTransformation<ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_, UnitsLhsT_...>,
469 typename PassiveSpatialRotation<ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_>::LinearTransformationT> {};
475template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
476 template <
typename,
int,
int>
typename ValuesRhsT_,
int DimensionRhsV_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
477 typename... UnitsRhsT_>
479 PassiveTranslation<ValuesRhsT_, DimensionRhsV_, ValueRhsT_, FromRhsT_, ToRhsT_, UnitsRhsT_...>> {
483 return internal::composeRotationAndTranslation<internal::PassiveRigidOf<LhsT, RhsT, FromRhsT_, ToLhsT_>>(lhs, rhs);
487template <
template <
typename,
int,
int>
typename ValuesLhsT_,
int DimensionLhsV_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
488 typename... UnitsLhsT_,
template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
489 typename ToRhsT_,
int DimensionRhsV_>
495 return internal::composeTranslationAndRotation<internal::PassiveRigidOf<RhsT, LhsT, FromRhsT_, ToLhsT_>>(lhs, rhs);
499template <
typename FromLhsT_,
typename ToLhsT_,
typename RotationLhsT_,
typename TranslationLhsT_,
500 template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
int DimensionRhsV_>
505 return internal::composeRigidAndRotation<internal::PassiveRigidWithFrames<LhsT, FromRhsT_, ToLhsT_>>(lhs, rhs);
509template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
510 typename FromRhsT_,
typename ToRhsT_,
typename RotationRhsT_,
typename TranslationRhsT_>
515 return internal::composeRotationAndRigid<internal::PassiveRigidWithFrames<RhsT, FromRhsT_, ToLhsT_>>(lhs, rhs);
519template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
520 template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
int DimensionRhsV_>
523 static_assert(internal::SameFrames<std::remove_cvref_t<
decltype(lhs)>, std::remove_cvref_t<
decltype(rhs)>>::value);
527template <
template <
typename,
int,
int>
typename ValuesLhsT_,
typename ValueLhsT_,
typename FromLhsT_,
typename ToLhsT_,
int DimensionLhsV_,
528 template <
typename,
int,
int>
typename ValuesRhsT_,
typename ValueRhsT_,
typename FromRhsT_,
typename ToRhsT_,
int DimensionRhsV_>
531 return !(lhs == rhs);
534template <
template <
typename,
int,
int>
typename ValuesT_,
typename ValueT_,
typename FromT_,
typename ToT_,
int DimensionV_>
A passive rotation from the coordinate system From to the coordinate system To, which have the same o...
EulerAnglesT toEulerAnglesZyx() const
The Euler angles ZYX of the matrix (see ActiveSpatialRotation::toEulerAnglesZyx()).
static EulerAnglesDerivativeT eulerAnglesXyzDerivative(const EulerAnglesOtherT_ &angles, const AngularVelocityOtherT_ &angularVelocity)
The derivatives of the Euler angles XYZ of the matrix for the angular velocity w, in To or in From,...
typename ParameterizationsT::AngleT AngleT
An angle, e.g. of a rotation around its axis, or between two rotations.
static PassiveSpatialRotation fromQuaternion(const QuaternionOtherT_ &quaternion)
The rotation of the unit quaternion q, whose matrix is that of ActiveSpatialRotation::fromQuaternion(...
typename ParameterizationsT::MatrixDerivativeT MatrixDerivativeT
The derivative dR/dt of the matrix of a rotation with respect to time.
static PassiveSpatialRotation fromEulerAnglesXyz(const EulerAnglesOtherT_ &angles)
The rotation whose matrix has the Euler angles XYZ (a0, a1, a2), R = R_x(a0) R_y(a1) R_z(a2) (see Act...
MatrixDerivativeT matrixDerivative(const AngularVelocityOtherT_ &angularVelocity) const
The derivative dR/dt = [w]x R of the matrix for the angular velocity w in To, which equals R [w]x for...
PassiveSpatialRotation()
The identity: From and To have the same axes.
static auto angularVelocityFromQuaternionDerivative(const QuaternionOtherT_ &quaternion, const QuaternionDerivativeOtherT_ &derivative)
The angular velocity of the derivative dq/dt of the unit quaternion q, expressed in To or,...
typename ParameterizationsT::EulerAnglesDerivativeT EulerAnglesDerivativeT
The derivatives of three Euler angles with respect to time.
typename ParameterizationsT::template RotationVectorT< ToT_ > RotationVectorT
A rotation vector angle * axis, expressed in To, e.g. the logarithm of a rotation or an increment of ...
RotationVectorT toRotationVector() const
The logarithmic map Log(R) of the matrix, the rotation vector of the rotation, with an angle in [0,...
typename LinearTransformationT::ValuesT ValuesT
AngleAxisT toAngleAxis() const
The angle in [0, pi] and the unit axis of the matrix (see ActiveSpatialRotation::toAngleAxis()).
AngleT angularDistance(const PassiveSpatialRotation< ValuesT_, ValueT_, FromOtherT_, ToOtherT_, DimensionV_ > &other) const
The angle in [0, pi] of the rotation between this and the other rotation, the norm of boxMinus(other)...
typename ParameterizationsT::template AxisT< ToT_ > AxisT
The unit axis of a rotation, expressed in To. The rotation leaves its axis unchanged,...
typename LinearTransformationT::UnitsT UnitsT
typename ParameterizationsT::QuaternionDerivativeT QuaternionDerivativeT
The derivative dq/dt of a quaternion with respect to time, in the unit of an angular velocity.
static PassiveSpatialRotation fromTwoVectors(const FromVectorT_ &from, const ToVectorT_ &to)
The rotation with the smallest angle under which the direction of the vector from,...
auto boxMinus(const PassiveSpatialRotation< ValuesT_, ValueT_, FromOtherT_, ToOtherT_, DimensionV_ > &other) const
The rotation vector Log(R S^T) of the matrices R of this rotation and S of the other one,...
static auto angularVelocityFromEulerAnglesZyxDerivative(const EulerAnglesOtherT_ &angles, const EulerAnglesDerivativeOtherT_ &derivative)
The angular velocity of the derivatives of the Euler angles ZYX of the matrix, expressed in To or,...
static PassiveSpatialRotation makeUnchecked(Args &&... args)
The rotation whose matrix is constructed from the arguments, without checking it, like Drake's Rotati...
PassiveLinearTransformation< ValuesT_, ValueT_, FromT_, ToT_, DimensionV_, typename AccessUnits< AccessImplementation< ValueT_ > >::Dimensionless > LinearTransformationT
The passive linear transformation with the matrix of the rotation, whose transformations the rotation...
EulerAnglesT toEulerAnglesXyz() const
The Euler angles XYZ of the matrix (see ActiveSpatialRotation::toEulerAnglesXyz()).
static auto exponentialMapJacobian(const RotationVectorOtherT_ &rotationVector)
The Jacobian J of the exponential map at the rotation vector v, a linear map in the coordinate system...
bool isApprox(const PassiveSpatialRotation< ValuesOtherT_, ValueOtherT_, FromOtherT_, ToOtherT_, DimensionOtherV_ > &other, const ValueT precision=Precision< ValueT >::value()) const
Whether both rotations, which must transform between the same coordinate systems, are approximately e...
static PassiveSpatialRotation projectToRotation(Args &&... args)
The rotation nearest to the matrix constructed from the arguments, e.g. to a rotation whose rounding ...
typename ParameterizationsT::EulerAnglesT EulerAnglesT
Three Euler angles, in the order of the axes in their name, e.g. (yaw, pitch, roll) for ZYX.
static EulerAnglesDerivativeT eulerAnglesZyxDerivative(const EulerAnglesOtherT_ &angles, const AngularVelocityOtherT_ &angularVelocity)
The derivatives of the Euler angles ZYX of the matrix for the angular velocity w, in To or in From,...
auto angularVelocityFromMatrixDerivative(const MatrixDerivativeOtherT_ &derivative) const
The angular velocity of the derivative dR/dt of the matrix, [w]x = dR/dt R^T in To,...
PassiveSpatialRotation boxPlus(const RotationVectorOtherT_ &rotationVector) const
The rotation whose matrix R is rotated further by the rotation vector v: Exp(v) R for v in To,...
static PassiveSpatialRotation fromEulerAnglesZyx(const EulerAnglesOtherT_ &angles)
The rotation whose matrix has the Euler angles ZYX (yaw, pitch, roll), R = R_z(yaw) R_y(pitch) R_x(ro...
typename LinearTransformationT::QuantitiesT QuantitiesT
static auto angularVelocityFromEulerAnglesXyzDerivative(const EulerAnglesOtherT_ &angles, const EulerAnglesDerivativeOtherT_ &derivative)
The angular velocity of the derivatives of the Euler angles XYZ of the matrix, expressed in To or,...
std::pair< AngleT, AxisT > AngleAxisT
The angle and the unit axis of a rotation.
static PassiveSpatialRotation fromAngleAxis(const AngleOtherT_ &angle, const AxisOtherT_ &axis)
The rotation whose matrix rotates by an angle around a unit axis, right-handed, which is expressed in...
QuaternionT toQuaternion() const
The unique unit quaternion of the matrix (see ActiveSpatialRotation::toQuaternion()).
PassiveSpatialRotation(Args &&... args)
The rotation whose matrix is constructed from the arguments, e.g. its elements row by row,...
static PassiveSpatialRotation fromRotationVector(const RotationVectorOtherT_ &rotationVector)
The rotation whose matrix is the exponential map Exp(v) of the rotation vector v, which is expressed ...
bool isValid(const ValueT tolerance=ValidityTolerance< ValueT >::value()) const
Whether the matrix is a rotation: max_ij |(R R^T - I)_ij| <= tolerance, and det(R) > 0 (see internal:...
const QuantitiesT & getQuantities() const
The matrix R, which transforms the components v of a vector in From into its components R v in To.
typename ParameterizationsT::template AngularVelocityT< ToT_ > AngularVelocityT
The angular velocity of From relative to To, expressed in To. It may also be expressed in From.
static QuaternionDerivativeT quaternionDerivative(const QuaternionOtherT_ &quaternion, const AngularVelocityOtherT_ &angularVelocity)
The derivative dq/dt = (0, w) q / 2 of the unit quaternion q for the angular velocity w in To,...
typename ParameterizationsT::QuaternionT QuaternionT
A unit quaternion (w, x, y, z) of the matrix (see ActiveSpatialRotation::QuaternionT),...
auto inverse() const
The inverse rotation, from To to From, whose matrix is the transpose R^T = R^-1: it needs no matrix i...
A passive translation from the coordinate system From to the coordinate system To,...
const ValuesT & getValues() const &
Get the values of the quantities.
The alias template ValueMatrix<ValueT_, RowsV_, ColsV_> of any value matrix backend,...
Whether constructing a Class from the arguments copies or moves it, i.e. whether they are a single Cl...
A coordinate system with the Euclidean metric, the default, e.g. CoordinateSystem<World>: the coordin...
bool operator!=(const Quantities< ValuesLhsT_, UnitsLhsT_ > &lhs, const Quantities< ValuesRhsT_, UnitsRhsT_ > &rhs)
std::ostream & operator<<(std::ostream &lhs, const Quantities< ValuesT_, UnitsT_ > &rhs)
auto innerProduct(const Quantities< ValuesLhsT_, UnitsLhsT_ > &lhs, const Quantities< ValuesRhsT_, UnitsRhsT_ > &rhs)
PassiveSpatialRotation< ValuesT_, ValueT_, FromT_, ToT_, 3 > PassiveSpatialRotation3
bool operator==(const Quantities< ValuesLhsT_, UnitsLhsT_ > &lhs, const Quantities< ValuesRhsT_, UnitsRhsT_ > &rhs)
PassiveSpatialRotation< ValuesT_, ValueT_, FromT_, ToT_, 2 > PassiveSpatialRotation2
Vector< Quantities< ValuesT_< ValueT_, DimensionV_, 1 >, TypeMatrix< DimensionV_, 1, UnitT_ > >, CoordinateSystemT_ > HomogeneousVector
The units for values of the arithmetic type ValueT_, e.g. double, specialized for AccessImplementatio...
PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ > LhsT
static auto compose(const LhsT &lhs, const PassiveSpatialRotation< ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_ > &rhs)
static auto compose(const PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ > &lhs, const RhsT &rhs)
PassiveProperRigidTransformationTemplate< FromRhsT_, ToRhsT_, RotationRhsT_, TranslationRhsT_ > RhsT
wuzp::CompositionTraits< PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ >, PassiveTranslation< ValuesRhsT_, DimensionRhsV_, ValueRhsT_, FromRhsT_, ToRhsT_, UnitsRhsT_... > >::compose static auto compose(const LhsT &lhs, const RhsT &rhs)
wuzp::CompositionTraits< PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ >, PassiveTranslation< ValuesRhsT_, DimensionRhsV_, ValueRhsT_, FromRhsT_, ToRhsT_, UnitsRhsT_... > >::LhsT PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ > LhsT
wuzp::CompositionTraits< PassiveSpatialRotation< ValuesLhsT_, ValueLhsT_, FromLhsT_, ToLhsT_, DimensionLhsV_ >, PassiveTranslation< ValuesRhsT_, DimensionRhsV_, ValueRhsT_, FromRhsT_, ToRhsT_, UnitsRhsT_... > >::RhsT PassiveTranslation< ValuesRhsT_, DimensionRhsV_, ValueRhsT_, FromRhsT_, ToRhsT_, UnitsRhsT_... > RhsT
wuzp::CompositionTraits< PassiveTranslation< ValuesLhsT_, DimensionLhsV_, ValueLhsT_, FromLhsT_, ToLhsT_, UnitsLhsT_... >, PassiveSpatialRotation< ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_ > >::compose static auto compose(const LhsT &lhs, const RhsT &rhs)
wuzp::CompositionTraits< PassiveTranslation< ValuesLhsT_, DimensionLhsV_, ValueLhsT_, FromLhsT_, ToLhsT_, UnitsLhsT_... >, PassiveSpatialRotation< ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_ > >::LhsT PassiveTranslation< ValuesLhsT_, DimensionLhsV_, ValueLhsT_, FromLhsT_, ToLhsT_, UnitsLhsT_... > LhsT
wuzp::CompositionTraits< PassiveTranslation< ValuesLhsT_, DimensionLhsV_, ValueLhsT_, FromLhsT_, ToLhsT_, UnitsLhsT_... >, PassiveSpatialRotation< ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_ > >::RhsT PassiveSpatialRotation< ValuesRhsT_, ValueRhsT_, FromRhsT_, ToRhsT_, DimensionRhsV_ > RhsT
The composition lhs * rhs of two transformations, which applies rhs first, then lhs: (lhs * rhs)....
static constexpr ValueT_ value()
static constexpr ValueT_ value()