HepLorentzVector is a Lorentz vector consisting of
Hep3Vector and HepDouble components.
Lorentz transformations (rotations and boosts)
of these vectors are perfomed by multiplying with objects of
HepLorentzRotation class.
Authors
Leif Lonnblad and Anders Nilsson.
Modified by Evgueni Tcherniaev.
See also
Hep3Vector,
HepRotation,
HepLorentzRotation.
Declaration
#include "CLHEP/Vector/LorentzVector.h"
class HepLorentzVector
Public Member Functions
- Constructor
- inline HepLorentzVector(HepDouble x = 0.0, HepDouble y = 0.0,
HepDouble z = 0.0, HepDouble t = 0.0)
- Constructor giving the components x, y, z, t.
- Constructor
- inline HepLorentzVector(const Hep3Vector &, HepDouble)
- Constructor giving a Hep3Vector and a time component.
- Copy constructor
- inline HepLorentzVector(const HepLorentzVector &)
- Destructor
- inline ~HepLorentzVector()
- Conversion operator
- inline operator Hep3Vector () const
- inline operator Hep3Vector & ()
- Conversion (cast) to Hep3Vector.
- =
- inline HepLorentzVector & operator =
(const HepLorentzVector &)
- Assignment.
- +
- inline HepLorentzVector operator +
(const HepLorentzVector &) const
- Addition of two HepLorentzVectors.
- +=
- inline HepLorentzVector & operator +=
(const HepLorentzVector &)
- Addition.
- -
- inline HepLorentzVector operator - () const
- Unary minus.
- inline HepLorentzVector operator -
(const HepLorentzVector &) const
- Subtractions of two HepLorentzVectors.
- -=
- inline HepLorentzVector & operator -=
(const HepLorentzVector &)
- Subtraction.
- *
- inline HepDouble operator * (const HepLorentzVector &)
const
- Scalar product.
- *=
- inline HepLorentzVector & operator *= (HepDouble)
- Scaling with real numbers.
- inline HepLorentzVector & operator *= (const HepRotation &)
- Transformation with HepRotation.
- HepLorentzVector & operator *= (const HepLorentzRotation &)
- Transformation with HepLorenzRotation.
- ==
- inline HepBoolean operator == (const HepLorentzVector &)
const
- Test for equality.
- !=
- inline HepBoolean operator != (const HepLorentzVector &)
const
- Test for inequality.
- ()
- HepDouble operator () (int) const
- Get components by index.
- HepDouble & operator () (int)
- Set components by index.
- []
- inline HepDouble operator [] (int) const
- Get components by index.
- inline HepDouble & operator [] (int)
- Set components by index.
- angle
- inline HepDouble angle(const Hep3Vector &) const
- Angle w.r.t. another vector.
- boost
- void boost(HepDouble, HepDouble, HepDouble)
- inline void boost(const Hep3Vector &)
- Lorentz boost.
- boostVector
- inline Hep3Vector boostVector() const
- Return the spatial component divided by the time component.
- cosTheta
- inline HepDouble cosTheta() const
- Return cosine of the polar angle of the spatial component.
- dot
- inline HepDouble dot(const HepLorentzVector &) const
- Scalar product.
- e
- inline HepDouble e() const
- Return energy component.
- m
- inline HepDouble m() const
- Invariant mass.
If mag2() is negative then -sqrt(-mag2()) is returned.
- m2
- inline HepDouble m2() const
- Invariant mass squared.
- mag
- inline HepDouble mag() const
- Invariant mass.
If mag2() is negative then -sqrt(-mag2()) is returned.
- mag2
- inline HepDouble mag2() const
- Invariant mass squared.
- minus
- inline HepDouble minus() const
- Returns the negative light-cone component (t - z).
- mt
- inline HepDouble mt() const
- Transverse mass.
- mt2
- inline HepDouble mt2() const
- Transverse mass squared.
- perp
- inline HepDouble perp() const
- Transverse component of the spatial vector.
- inline HepDouble perp(const Hep3Vector &) const
- Transverse component of the spatial vector w.r.t. given axis.
- perp2
- inline HepDouble perp2() const
- Transverse component of the spatial vector squared.
- inline HepDouble perp2(const Hep3Vector &) const
- Transverse component of the spatial vector w.r.t. given axis squared.
- phi
- inline HepDouble phi() const
- Return azimuth angle of the vector component.
- plus
- inline HepDouble plus() const
- Returns the positive light-cone component (t + z).
- pseudoRapidity
- inline HepDouble pseudoRapidity() const
- Returns the pseudo-rapidity, i.e. -ln(tan(theta/2))
- px
- inline HepDouble px() const
- Return x component of the momentum.
- py
- inline HepDouble py() const
- Return y component of the momentum.
- pz
- inline HepDouble pz() const
- Return z component of the momentum.
- rapidity
- HepDouble rapidity() const
- Returns the rapidity, i.e. 0.5*ln((E+pz)/(E-pz))
- rho
- inline HepDouble rho() const
- Return magnitude of the vector component.
- rotate
- inline void rotate(HepDouble, const Hep3Vector &)
- Rotate the spatial component around specified axis.
- rotateUz
- inline void rotateUz(Hep3Vector &)
- Rotates the reference frame from Uz to newUz
(unit vector).
- rotateX
- inline void rotateX(HepDouble)
- Rotate the spatial component around the x-axis.
- rotateY
- inline void rotateY(HepDouble)
- Rotate the spatial component around the y-axis.
- rotateZ
- inline void rotateZ(HepDouble)
- Rotate the spatial component around the z-axis.
- setE
- inline void setE(HepDouble)
- Set the energy component.
- setPerp
- inline void setPerp(HepDouble)
- Set the transverse component of the spatial vector.
- setPhi
- inline void setPhi(HepDouble)
- Set azimuth angle of the vector component.
- setPx
- inline void setPx(HepDouble)
- Set Px component.
- setPy
- inline void setPy(HepDouble)
- Set Py component.
- setPz
- inline void setPz(HepDouble)
- Set Pz component.
- setRho
- inline void setRho(HepDouble)
- Set magnitude of the vector component.
- setT
- inline void setT(HepDouble)
- Set time component.
- setTheta
- inline void setTheta(HepDouble)
- Set polar angle of the vector component.
- setVect
- inline void setVect(const Hep3Vector &)
- Set the vector component.
- setVectM
- inline void setVectM(const Hep3Vector & spatial,
HepDouble mass)
- Copy spatial coordinates, and set energy=sqrt(mass^2+spatial^2)
- setVectMag
- inline void setVectMag(const Hep3Vector & spatial,
HepDouble magnitude)
- Copy spatial coordinates, and set energy=sqrt(mass^2+spatial^2)
- setX
- inline void setX(HepDouble)
- Set x component.
- setY
- inline void setY(HepDouble)
- Set y component.
- setZ
- inline void setZ(HepDouble)
- Set z component.
- t
- inline HepDouble t() const
- Return time component.
- theta
- inline HepDouble theta() const
- Return polar angle of the vector component.
- transform
- inline HepLorentzVector & transform(const HepRotation &)
- Transformation with HepRotation.
- HepLorentzVector & transform(const HepLorentzRotation &)
- Transformation with HepLorenzRotation.
- vect
- inline Hep3Vector vect() const
- Return the vector component.
- x
- inline HepDouble x() const
- Return x component.
- y
- inline HepDouble y() const
- Return y component.
- z
- inline HepDouble z() const
- Return z component.
Non-Member Functions
- *
- inline HepLorentzVector operator * (const HepLorentzVector &,
HepDouble a)
- inline HepLorentzVector operator * (HepDouble a,
const HepLorentzVector &)
- Scaling LorentzVector with a real number
- <<
- std::ostream & operator << (std::ostream &,
const HepLorentzVector &)
- Output to a stream.
- >>
- std::istream & operator >> (std::istream &,
HepLorentzVector &)
- Input from a stream.
Example
CLHEP/test/testLorentzVector.cc
03 May 1999
EVC