19 #ifndef ROOT_Math_GenVector_PtEtaPhiE4D 20 #define ROOT_Math_GenVector_PtEtaPhiE4D 1 51 template <
class ScalarType>
75 template <
class CoordSystem >
110 { dest[0] =
fPt; dest[1] =
fEta; dest[2] =
fPhi; dest[3] =
fE; }
132 Scalar
E()
const {
return fE; }
136 Scalar
T()
const {
return E(); }
141 Scalar
X ()
const {
return Px(); }
143 Scalar
Y ()
const {
return Py(); }
147 Scalar
Z ()
const {
return Pz(); }
154 :
fEta > etaMax<Scalar>() ?
fEta - etaMax<Scalar>()
155 :
fEta < -etaMax<Scalar>() ? -
fEta - etaMax<Scalar>() : 0;
157 Scalar
R()
const {
return P(); }
164 const Scalar p =
P();
173 const Scalar p =
P();
174 return fE *
fE - p * p;
182 const Scalar mm =
M2();
187 " Pt and Eta give P such that P^2 > E^2, so the mass would be imaginary");
191 Scalar
Mag()
const {
return M(); }
202 Scalar
Mt2()
const { Scalar pz =
Pz();
return fE*
fE - pz*pz; }
208 const Scalar mm =
Mt2();
213 " Pt and Eta give Pz such that Pz^2 > E^2, so the mass would be imaginary");
233 const Scalar et =
Et();
238 inline static Scalar
pi() {
return M_PI; }
280 void SetPxPyPzE(Scalar px, Scalar py, Scalar pz, Scalar
e);
309 template <
class CoordSystem >
331 Scalar
x()
const {
return X(); }
332 Scalar
y()
const {
return Y(); }
333 Scalar
z()
const {
return Z(); }
334 Scalar
t()
const {
return E(); }
338 #if defined(__MAKECINT__) || defined(G__DICTIONARY) 342 void SetPx(Scalar px);
344 void SetPy(Scalar py);
346 void SetPz(Scalar pz);
370 #if defined(__MAKECINT__) || defined(G__DICTIONARY) 378 template <
class ScalarType>
384 #if defined(__MAKECINT__) || defined(G__DICTIONARY) 388 template <
class ScalarType>
394 template <
class ScalarType>
400 template <
class ScalarType>
406 template <
class ScalarType>
414 #endif // endif __MAKE__CINT || G__DICTIONARY 423 #endif // ROOT_Math_GenVector_PtEtaPhiE4D Class describing a 4D cylindrical coordinate system using Pt , Phi, Eta and E (or rho...
void SetPhi(Scalar phi)
set phi value
Class describing a 4D cylindrical coordinate system using Pt , Phi, Eta and M (mass) The metric used ...
void SetPxPyPzE(Scalar px, Scalar py, Scalar pz, Scalar e)
set values using cartesian coordinate system
Namespace for new ROOT classes and functions.
PtEtaPhiE4D()
Default constructor gives zero 4-vector.
Scalar Et2() const
transverse energy squared
Scalar Theta() const
polar angle
void Scale(Scalar a)
Scale coordinate values by a scalar quantity a.
VecExpr< UnaryOp< Sqrt< T >, VecExpr< A, T, D >, T >, T, D > sqrt(const VecExpr< A, T, D > &rhs)
void SetPx(Scalar px)
set X value
void GetCoordinates(Scalar &pt, Scalar &eta, Scalar &phi, Scalar &e) const
get internal data into 4 Scalar numbers
Class describing a 4D cartesian coordinate system (x, y, z, t coordinates) or momentum-energy vectors...
Scalar Mt() const
transverse mass
void Negate()
negate the 4-vector
void SetM(Scalar mass)
set M value
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t Double_t Int_t m
bool operator!=(const PtEtaPhiE4D &rhs) const
void SetPt(Scalar pt)
set Pt value
void Throw(const char *)
function throwing exception, by creating internally a GenVector_exception only when needed ...
void SetCoordinates(Scalar pt, Scalar eta, Scalar phi, Scalar e)
Set internal data based on 4 Scalar numbers.
void SetPz(Scalar pz)
set Z value
void SetPy(Scalar py)
set Y value
void SetEta(Scalar eta)
set eta value
Scalar M2() const
vector magnitude squared (or mass squared)
void SetCoordinates(const Scalar src[])
Set internal data based on an array of 4 Scalar numbers.
Scalar P() const
magnitude of momentum
Scalar Mt2() const
transverse mass squared
you should not use this method at all Int_t Int_t Double_t Double_t Double_t e
void SetE(Scalar e)
set E value
PtEtaPhiE4D(Scalar pt, Scalar eta, Scalar phi, Scalar e)
Constructor from pt, eta, phi, e values.
Scalar P2() const
squared magnitude of spatial components (momentum squared)
Namespace for new Math classes and functions.
Scalar M() const
invariant mass
bool operator==(const PtEtaPhiE4D &rhs) const
Exact equality.
#define dest(otri, vertexptr)
void GetCoordinates(Scalar dest[]) const
get internal data into an array of 4 Scalar numbers
PtEtaPhiE4D & operator=(const PtEtaPhiE4D &v)
assignment operator
Scalar Et() const
transverse energy
PtEtaPhiE4D(const CoordSystem &c)
Generic constructor from any 4D coordinate system implementing Pt(), Eta(), Phi() and E() ...
Scalar Pt2() const
transverse spatial component squared
PtEtaPhiE4D(const PtEtaPhiE4D &v)
copy constructor