17 #ifndef ROOT_Math_GenVector_AxisAngle
18 #define ROOT_Math_GenVector_AxisAngle 1
62 template<
class AnyVector>
92 template <
class OtherRotation>
99 template <
class OtherRotation>
121 IT
a = begin; IT b = ++begin; IT
c = ++begin;
127 if (tot > 0)
fAxis /= tot;
140 IT
a = begin; IT b = ++begin; IT
c = ++begin;
163 template<
class AnyVector>
174 template<
class AnyVector>
201 template <
class CoordSystem,
class Tag>
207 vNew.
SetXYZ( rxyz.
X(), rxyz.
Y(), rxyz.
Z() );
214 template <
class CoordSystem,
class Tag>
225 template <
class CoordSystem>
240 template <
class ForeignVector>
245 return ForeignVector ( rxyz.
X(), rxyz.
Y(), rxyz.
Z() );
251 template <
class AVector>
314 static double Pi() {
return 3.14159265358979323; }
Scalar Distance(const R &r) const
Distance between two rotations.
Scalar E() const
return 4-th component (time, or energy for a 4-momentum vector)
Class describing a generic LorentzVector in the 4D space-time, using the specified coordinate system ...
double dist(Rotation3D const &r1, Rotation3D const &r2)
DisplacementVector3D< CoordSystem, Tag > & SetCoordinates(const Scalar src[])
Set internal data based on a C-style array of 3 Scalar numbers.
DisplacementVector3D< Cartesian3D< Scalar > > AxisVector
definition of vector axis
DisplacementVector3D< CoordSystem, Tag > & SetXYZ(Scalar a, Scalar b, Scalar c)
set the values of the vector from the cartesian components (x,y,z) (if the vector is held in polar or...
bool operator==(const AxisAngle &rhs) const
Equality/inequality operators.
XYZVector operator()(const XYZVector &v) const
Namespace for new ROOT classes and functions.
::ROOT::Math::DisplacementVector3D< Cartesian3D< Scalar > > Vect() const
get the spatial components of the Vector in a DisplacementVector based on Cartesian Coordinates ...
AxisAngle()
Default constructor (axis is z and angle is zero)
Rotation class representing a 3D rotation about the Z axis by the angle of rotation.
Scalar Y() const
Cartesian Y, converting if necessary from internal coordinate system.
void SetComponents(const AnyVector &v, Scalar angle)
Set components from a non-zero vector (x,y,z) and an angle.
Scalar R() const
Polar R, converting if necessary from internal coordinate system.
Class describing a generic position vector (point) in 3 dimensions.
DisplacementVector3D unit() const
Rotation class with the (3D) rotation represented by angles describing first a rotation of an angle p...
void GetCoordinates(Scalar &a, Scalar &b, Scalar &c) const
get internal data into 3 Scalar numbers
AxisVector Axis() const
accesss to rotation axis
AxisAngle(const OtherRotation &r)
Construct from another supported rotation type (see gv_detail::convert )
Rotation class with the (3D) rotation represented by a unit quaternion (u, i, j, k).
std::ostream & operator<<(std::ostream &os, const AxisAngle &a)
Stream Output and Input.
AxisAngle class describing rotation represented with direction axis (3D Vector) and an angle of rotat...
void GetComponents(IT begin) const
Get the axis and then the angle into data specified by an iterator begin.
Rotation class representing a 3D rotation about the Y axis by the angle of rotation.
AxisAngle(const AnyVector &v, Scalar angle)
Construct from a non-zero vector (x,y,z) and an angle.
void SetComponents(IT begin, IT end)
Set the axis and then the angle given a pair of pointers or iterators defining the beginning and end ...
Scalar X() const
Cartesian X, converting if necessary from internal coordinate system.
DisplacementVector3D< Cartesian3D< double >, DefaultCoordinateSystemTag > XYZVector
Rotation operation on a cartesian vector.
bool operator!=(const AxisAngle &rhs) const
AxisAngle & operator*=(const R &r)
Post-Multiply (on right) by another rotation : T = T*R.
Scalar Angle() const
access to rotation angle
AxisAngle Inverse() const
Return inverse of an AxisAngle rotation.
void Rectify()
Re-adjust components to eliminate small deviations from the axis being a unit vector and angles out o...
Class describing a generic displacement vector in 3 dimensions.
unsigned int r1[N_CITIES]
Rotation class representing a 3D rotation about the X axis by the angle of rotation.
void Invert()
Invert an AxisAngle rotation in place.
Rotation class with the (3D) rotation represented by a 3x3 orthogonal matrix.
AVector operator*(const AVector &v) const
Overload operator * for rotation on a vector.
void convert(R1 const &, R2 const)
Scalar Z() const
Cartesian Z, converting if necessary from internal coordinate system.
EulerAngles class describing rotation as three angles (Euler Angles).
void GetComponents(IT begin, IT end) const
Get the axis and then the angle into data specified by an iterator begin and another to the end of th...
AxisAngle(IT begin, IT end)
Construct given a pair of pointers or iterators defining the beginning and end of an array of four Sc...
Namespace for new Math classes and functions.
AxisAngle & operator=(OtherRotation const &r)
Assign from another supported rotation type (see gv_detail::convert )
void GetComponents(AnyVector &axis, Scalar &angle) const
Set components into a non-zero vector (x,y,z) and an angle.
DefaultCoordinateSystemTag Default tag for identifying any coordinate system.
unsigned int r2[N_CITIES]