20#ifndef ROOT_Math_GenVector_CylindricalEta3D
21#define ROOT_Math_GenVector_CylindricalEta3D 1
70 template <
class CoordSystem >
75 static Scalar bigEta =
Scalar(-0.3) * log(std::numeric_limits<Scalar>::epsilon());
76 if (std::fabs(
fEta) > bigEta) {
141 T
X()
const {
using std::cos;
return fRho * cos(
fPhi); }
142 T
Y()
const {
using std::sin;
return fRho * sin(
fPhi); }
152 :
fEta > etaMax<T>() ?
fEta - etaMax<T>() :
fEta < -etaMax<T>() ? -
fEta - etaMax<T>() : 0;
205 }
else if (
fEta > etaMax<T>() ) {
206 fEta = (
fEta-etaMax<T>())*
a + etaMax<T>();
207 }
else if (
fEta < -etaMax<T>() ) {
208 fEta = (
fEta+etaMax<T>())*
a - etaMax<T>();
225 template <
class CoordSystem >
249 T
x()
const {
return X();}
250 T
y()
const {
return Y();}
251 T
z()
const {
return Z(); }
257#if defined(__MAKECINT__) || defined(G__DICTIONARY)
269 void SetTheta(
Scalar theta);
291#if defined(__MAKECINT__) || defined(G__DICTIONARY)
305#if defined(__MAKECINT__) || defined(G__DICTIONARY)
319void CylindricalEta3D<T>::SetY(
Scalar yy) {
320 GenVector_exception
e(
"CylindricalEta3D::SetY() is not supposed to be called");
322 Cartesian3D<Scalar>
v(*
this);
v.SetY(yy);
323 *
this = CylindricalEta3D<Scalar>(
v);
326void CylindricalEta3D<T>::SetZ(
Scalar zz) {
327 GenVector_exception
e(
"CylindricalEta3D::SetZ() is not supposed to be called");
329 Cartesian3D<Scalar>
v(*
this);
v.SetZ(zz);
330 *
this = CylindricalEta3D<Scalar>(
v);
333void CylindricalEta3D<T>::SetR(
Scalar r) {
334 GenVector_exception
e(
"CylindricalEta3D::SetR() is not supposed to be called");
336 Polar3D<Scalar>
v(*
this);
v.SetR(
r);
337 *
this = CylindricalEta3D<Scalar>(
v);
340void CylindricalEta3D<T>::SetTheta(
Scalar theta) {
341 GenVector_exception
e(
"CylindricalEta3D::SetTheta() is not supposed to be called");
343 Polar3D<Scalar>
v(*
this);
v.SetTheta(theta);
344 *
this = CylindricalEta3D<Scalar>(
v);
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t dest
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t r
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t src
Class describing a 3D cartesian coordinate system (x, y, z coordinates)
Class describing a cylindrical coordinate system based on eta (pseudorapidity) instead of z.
void SetEta(T eta)
set the eta coordinate value keeping rho and phi constant
CylindricalEta3D()
Default constructor with rho=eta=phi=0.
void SetXYZ(Scalar x, Scalar y, Scalar z)
set all values using cartesian coordinates
void SetCoordinates(const Scalar src[])
Set internal data based on an array of 3 Scalar numbers.
void SetCoordinates(Scalar rho, Scalar eta, Scalar phi)
Set internal data based on 3 Scalar numbers.
void GetCoordinates(Scalar dest[]) const
get internal data into an array of 3 Scalar numbers
void Negate()
negate the vector
CylindricalEta3D(const CoordSystem &v)
Construct from any Vector or coordinate system implementing Rho(), Eta() and Phi()
void Scale(T a)
scale by a scalar quantity a – for cylindrical eta coords, as long as a >= 0, only rho changes!
void GetCoordinates(Scalar &rho, Scalar &eta, Scalar &phi) const
get internal data into 3 Scalar numbers
void SetPhi(T phi)
set the phi coordinate value keeping rho and eta constant
CylindricalEta3D & operator=(const CylindricalEta3D &v)
assignment operator
CylindricalEta3D(const CylindricalEta3D &v)
copy constructor
void SetRho(T rho)
set the rho coordinate value keeping eta and phi constant
CylindricalEta3D(Scalar rho, Scalar eta, Scalar phi)
Construct from rho eta and phi values.
static constexpr unsigned int Dimension
bool operator==(const CylindricalEta3D &rhs) const
Exact component-by-component equality Note: Peculiar representations of the zero vector such as (0,...
bool operator!=(const CylindricalEta3D &rhs) const
Namespace for new Math classes and functions.
Rotation3D::Scalar Scalar
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...