#include <SimpleVector.h>
Public Member Functions | |
FourVector (double xin, double yin, double zin, double tin=0) | |
constructor requiring at least x, y, and z | |
FourVector (double t) | |
constructor requiring only t | |
FourVector () | |
template<class T> | |
FourVector (const T &v, typename detail::disable_if< detail::is_arithmetic< T >::value, void >::type *=0) | |
templated constructor this is used ONLY if T is not arithmetic | |
FourVector (const FourVector &v) | |
copy constructor | |
void | swap (FourVector &other) |
swap | |
double | px () const |
return px | |
double | py () const |
return py | |
double | pz () const |
return pz | |
double | e () const |
return E | |
double | x () const |
return x | |
double | y () const |
return y | |
double | z () const |
return z | |
double | t () const |
return t | |
double | m2 () const |
Invariant mass squared. | |
double | m () const |
Invariant mass. If m2() is negative then -sqrt(-m2()) is returned. | |
double | perp2 () const |
Transverse component of the spatial vector squared. | |
double | perp () const |
Transverse component of the spatial vector (R in cylindrical system). | |
double | mag () const |
Magnitude of the spatial vector. | |
double | theta () const |
The polar angle. | |
double | phi () const |
The azimuth angle. | |
double | rho () const |
spatial vector component magnitude | |
FourVector & | operator= (const FourVector &) |
make a copy | |
bool | operator== (const FourVector &) const |
equality | |
bool | operator!= (const FourVector &) const |
inequality | |
double | pseudoRapidity () const |
Returns the pseudo-rapidity, i.e. -ln(tan(theta/2)). | |
double | eta () const |
Pseudorapidity (of the space part). | |
void | set (double x, double y, double z, double t) |
set x, y, z, and t | |
void | setX (double x) |
set x | |
void | setY (double y) |
set y | |
void | setZ (double z) |
set z | |
void | setT (double t) |
set t | |
void | setPx (double x) |
set px | |
void | setPy (double y) |
set py | |
void | setPz (double z) |
set pz | |
void | setE (double t) |
set E | |
Private Attributes | |
double | m_x |
double | m_y |
double | m_z |
double | m_t |
Also, there is a templated constructor that will take another vector (HepLorentzVector, GenVector, ...) which must have the following methods: x(), y(), z(), t().
Definition at line 42 of file SimpleVector.h.
HepMC::FourVector::FourVector | ( | double | xin, | |
double | yin, | |||
double | zin, | |||
double | tin = 0 | |||
) | [inline] |
HepMC::FourVector::FourVector | ( | double | t | ) | [inline] |
HepMC::FourVector::FourVector | ( | ) | [inline] |
HepMC::FourVector::FourVector | ( | const T & | v, | |
typename detail::disable_if< detail::is_arithmetic< T >::value, void >::type * | = 0 | |||
) | [inline] |
HepMC::FourVector::FourVector | ( | const FourVector & | v | ) | [inline] |
void HepMC::FourVector::swap | ( | FourVector & | other | ) | [inline] |
double HepMC::FourVector::px | ( | ) | const [inline] |
double HepMC::FourVector::py | ( | ) | const [inline] |
double HepMC::FourVector::pz | ( | ) | const [inline] |
double HepMC::FourVector::e | ( | ) | const [inline] |
double HepMC::FourVector::x | ( | ) | const [inline] |
double HepMC::FourVector::y | ( | ) | const [inline] |
double HepMC::FourVector::z | ( | ) | const [inline] |
double HepMC::FourVector::t | ( | ) | const [inline] |
double HepMC::FourVector::m2 | ( | ) | const [inline] |
double HepMC::FourVector::m | ( | ) | const [inline] |
Invariant mass. If m2() is negative then -sqrt(-m2()) is returned.
Definition at line 46 of file SimpleVector.icc.
00046 { 00047 double mm = m2(); 00048 return mm < 0.0 ? -std::sqrt(-mm) : std::sqrt(mm); 00049 }
double HepMC::FourVector::perp2 | ( | ) | const [inline] |
double HepMC::FourVector::perp | ( | ) | const [inline] |
Transverse component of the spatial vector (R in cylindrical system).
Definition at line 57 of file SimpleVector.icc.
00057 { return std::sqrt(perp2()); }
double HepMC::FourVector::mag | ( | ) | const [inline] |
double HepMC::FourVector::theta | ( | ) | const [inline] |
double HepMC::FourVector::phi | ( | ) | const [inline] |
double HepMC::FourVector::rho | ( | ) | const [inline] |
FourVector & HepMC::FourVector::operator= | ( | const FourVector & | ) | [inline] |
bool HepMC::FourVector::operator== | ( | const FourVector & | ) | const [inline] |
bool HepMC::FourVector::operator!= | ( | const FourVector & | ) | const [inline] |
double HepMC::FourVector::pseudoRapidity | ( | ) | const [inline] |
double HepMC::FourVector::eta | ( | ) | const [inline] |
Pseudorapidity (of the space part).
Definition at line 87 of file SimpleVector.icc.
00087 { return pseudoRapidity();}
void HepMC::FourVector::set | ( | double | x, | |
double | y, | |||
double | z, | |||
double | t | |||
) | [inline] |
void HepMC::FourVector::setX | ( | double | x | ) | [inline] |
void HepMC::FourVector::setY | ( | double | y | ) | [inline] |
void HepMC::FourVector::setZ | ( | double | z | ) | [inline] |
void HepMC::FourVector::setT | ( | double | t | ) | [inline] |
void HepMC::FourVector::setPx | ( | double | x | ) | [inline] |
void HepMC::FourVector::setPy | ( | double | y | ) | [inline] |
void HepMC::FourVector::setPz | ( | double | z | ) | [inline] |
void HepMC::FourVector::setE | ( | double | t | ) | [inline] |
double HepMC::FourVector::m_x [private] |
Definition at line 115 of file SimpleVector.h.
double HepMC::FourVector::m_y [private] |
Definition at line 116 of file SimpleVector.h.
double HepMC::FourVector::m_z [private] |
Definition at line 117 of file SimpleVector.h.
double HepMC::FourVector::m_t [private] |
Definition at line 118 of file SimpleVector.h.