Logo ROOT   6.12/07
Reference Guide
List of all members | Classes | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
TLorentzRotation Class Reference

The TLorentzRotation class describes Lorentz transformations including Lorentz boosts and rotations (see TRotation)

| xx xy xz xt |
| |
| yx yy yz yt |
lambda = | |
| zx zy zz zt |
| |
| tx ty tz tt |

Declaration

By default it is initialized to the identity matrix, but it may also be intialized by an other TLorentzRotation, by a pure TRotation or by a boost:

TLorentzRotation l; // l is initialized as identity TLorentzRotation m(l); // m = l TRotation r; TLorentzRotation lr(r); TLorentzRotation lb1(bx,by,bz); TVector3 b; TLorentzRotation lb2(b);

The Matrix for a Lorentz boosts is:

| 1+gamma'*bx*bx gamma'*bx*by gamma'*bx*bz gamma*bx |
| gamma'*by*bx 1+gamma'*by*by gamma'*by*bz gamma*by |
| gamma'*bz*bx gamma'*bz*by 1+gamma'*bz*bz gamma*bz |
| gamma*bx gamma*by gamma*bz gamma |

with the boost vector b=(bx,by,bz) and gamma=1/Sqrt(1-beta*beta) and gamma'=(gamma-1)/beta*beta.

Access to the matrix components/Comparisons

Access to the matrix components is possible through the member functions XX(), XY() .. TT(), through the operator (int,int):

xx = l.XX(); // gets the xx component
xx = l(0,0); // gets the xx component
if (l==m) {...} // test for equality
if (l !=m) {...} // test for inequality
if (l.IsIdentity()) {...} // test for identity

Transformations of a LorentzRotation

Compound transformations

There are four possibilities to find the product of two TLorentzRotation transformations:

c = b*a;// product
c = a.MatrixMultiplication(b); // a is unchanged
a *= b;// Attention: a=a*b
c = a.Transform(b)// a=b*a then c=a

Lorentz boosts

Double_t bx, by, bz;
TVector3 v(bx,by,bz);
l.Boost(v);
l.Boost(bx,by,bz);

Rotations

TVector3 axis;
l.RotateX(TMath::Pi()); // rotation around x-axis
l.Rotate(.5,axis);// rotation around specified vector

Inverse transformation

The matrix for the inverse transformation of a TLorentzRotation is as follows:

| xx yx zx -tx |
| |
| xy yy zy -ty |
| |
| xz yz zz -tz |
| |
|-xt -yt -zt tt |

To return the inverse transformation keeping the current unchanged use the member function Inverse(). Invert() inverts the current TLorentzRotation:

l1 = l2.Inverse(); // l1 is inverse of l2, l2 unchanged
l1 = l2.Invert(); // invert l2, then l1=l2

Transformation of a TLorentzVector

To apply TLorentzRotation to TLorentzVector you can use either the VectorMultiplication() member function or the * operator. You can also use the Transform() function and the *= operator of the TLorentzVector class.:

...
v = l * v;
v.Transform(l);
v *= l; // Attention v = l*v

Definition at line 20 of file TLorentzRotation.h.

Classes

class  TLorentzRotationRow
 

Public Member Functions

 TLorentzRotation ()
 
 TLorentzRotation (const TRotation &)
 
 TLorentzRotation (const TLorentzRotation &)
 
 TLorentzRotation (Double_t, Double_t, Double_t)
 
 TLorentzRotation (const TVector3 &)
 
TLorentzRotationBoost (Double_t, Double_t, Double_t)
 
TLorentzRotationBoost (const TVector3 &)
 
TLorentzRotation Inverse () const
 
TLorentzRotationInvert ()
 
Bool_t IsIdentity () const
 
TLorentzRotation MatrixMultiplication (const TLorentzRotation &) const
 
Bool_t operator!= (const TLorentzRotation &) const
 
Double_t operator() (int, int) const
 
TLorentzVector operator* (const TLorentzVector &) const
 
TLorentzRotation operator* (const TLorentzRotation &) const
 
TLorentzRotationoperator*= (const TLorentzRotation &)
 
TLorentzRotationoperator= (const TLorentzRotation &)
 
TLorentzRotationoperator= (const TRotation &)
 
Bool_t operator== (const TLorentzRotation &) const
 
TLorentzRotationRow operator[] (int) const
 
TLorentzRotationRotate (Double_t, const TVector3 &)
 
TLorentzRotationRotate (Double_t, const TVector3 *)
 
TLorentzRotationRotateX (Double_t)
 
TLorentzRotationRotateY (Double_t)
 
TLorentzRotationRotateZ (Double_t)
 
TLorentzRotationTransform (const TLorentzRotation &)
 
TLorentzRotationTransform (const TRotation &)
 
Double_t TT () const
 
Double_t TX () const
 
Double_t TY () const
 
Double_t TZ () const
 
TLorentzVector VectorMultiplication (const TLorentzVector &) const
 
Double_t XT () const
 
Double_t XX () const
 
Double_t XY () const
 
Double_t XZ () const
 
Double_t YT () const
 
Double_t YX () const
 
Double_t YY () const
 
Double_t YZ () const
 
Double_t ZT () const
 
Double_t ZX () const
 
Double_t ZY () const
 
Double_t ZZ () const
 
- Public Member Functions inherited from TObject
 TObject ()
 TObject constructor. More...
 
 TObject (const TObject &object)
 TObject copy ctor. More...
 
virtual ~TObject ()
 TObject destructor. More...
 
void AbstractMethod (const char *method) const
 Use this method to implement an "abstract" method that you don't want to leave purely abstract. More...
 
virtual void AppendPad (Option_t *option="")
 Append graphics object to current pad. More...
 
virtual void Browse (TBrowser *b)
 Browse object. May be overridden for another default action. More...
 
ULong_t CheckedHash ()
 Checked and record whether for this class has a consistent Hash/RecursiveRemove setup (*) and then return the regular Hash value for this object. More...
 
virtual const char * ClassName () const
 Returns name of class to which the object belongs. More...
 
virtual void Clear (Option_t *="")
 
virtual TObjectClone (const char *newname="") const
 Make a clone of an object using the Streamer facility. More...
 
virtual Int_t Compare (const TObject *obj) const
 Compare abstract method. More...
 
virtual void Copy (TObject &object) const
 Copy this to obj. More...
 
virtual void Delete (Option_t *option="")
 Delete this object. More...
 
virtual Int_t DistancetoPrimitive (Int_t px, Int_t py)
 Computes distance from point (px,py) to the object. More...
 
virtual void Draw (Option_t *option="")
 Default Draw method for all objects. More...
 
virtual void DrawClass () const
 Draw class inheritance tree of the class to which this object belongs. More...
 
virtual TObjectDrawClone (Option_t *option="") const
 Draw a clone of this object in the current selected pad for instance with: gROOT->SetSelectedPad(gPad). More...
 
virtual void Dump () const
 Dump contents of object on stdout. More...
 
virtual void Error (const char *method, const char *msgfmt,...) const
 Issue error message. More...
 
virtual void Execute (const char *method, const char *params, Int_t *error=0)
 Execute method on this object with the given parameter string, e.g. More...
 
virtual void Execute (TMethod *method, TObjArray *params, Int_t *error=0)
 Execute method on this object with parameters stored in the TObjArray. More...
 
virtual void ExecuteEvent (Int_t event, Int_t px, Int_t py)
 Execute action corresponding to an event at (px,py). More...
 
virtual void Fatal (const char *method, const char *msgfmt,...) const
 Issue fatal error message. More...
 
virtual TObjectFindObject (const char *name) const
 Must be redefined in derived classes. More...
 
virtual TObjectFindObject (const TObject *obj) const
 Must be redefined in derived classes. More...
 
virtual Option_tGetDrawOption () const
 Get option used by the graphics system to draw this object. More...
 
virtual const char * GetIconName () const
 Returns mime type name of object. More...
 
virtual const char * GetName () const
 Returns name of object. More...
 
virtual char * GetObjectInfo (Int_t px, Int_t py) const
 Returns string containing info about the object at position (px,py). More...
 
virtual Option_tGetOption () const
 
virtual const char * GetTitle () const
 Returns title of object. More...
 
virtual UInt_t GetUniqueID () const
 Return the unique object id. More...
 
virtual Bool_t HandleTimer (TTimer *timer)
 Execute action in response of a timer timing out. More...
 
virtual ULong_t Hash () const
 Return hash value for this object. More...
 
Bool_t HasInconsistentHash () const
 Return true is the type of this object is known to have an inconsistent setup for Hash and RecursiveRemove (i.e. More...
 
virtual void Info (const char *method, const char *msgfmt,...) const
 Issue info message. More...
 
virtual Bool_t InheritsFrom (const char *classname) const
 Returns kTRUE if object inherits from class "classname". More...
 
virtual Bool_t InheritsFrom (const TClass *cl) const
 Returns kTRUE if object inherits from TClass cl. More...
 
virtual void Inspect () const
 Dump contents of this object in a graphics canvas. More...
 
void InvertBit (UInt_t f)
 
virtual Bool_t IsEqual (const TObject *obj) const
 Default equal comparison (objects are equal if they have the same address in memory). More...
 
virtual Bool_t IsFolder () const
 Returns kTRUE in case object contains browsable objects (like containers or lists of other objects). More...
 
R__ALWAYS_INLINE Bool_t IsOnHeap () const
 
virtual Bool_t IsSortable () const
 
R__ALWAYS_INLINE Bool_t IsZombie () const
 
virtual void ls (Option_t *option="") const
 The ls function lists the contents of a class on stdout. More...
 
void MayNotUse (const char *method) const
 Use this method to signal that a method (defined in a base class) may not be called in a derived class (in principle against good design since a child class should not provide less functionality than its parent, however, sometimes it is necessary). More...
 
virtual Bool_t Notify ()
 This method must be overridden to handle object notification. More...
 
void Obsolete (const char *method, const char *asOfVers, const char *removedFromVers) const
 Use this method to declare a method obsolete. More...
 
void operator delete (void *ptr)
 Operator delete. More...
 
void operator delete[] (void *ptr)
 Operator delete []. More...
 
voidoperator new (size_t sz)
 
voidoperator new (size_t sz, void *vp)
 
voidoperator new[] (size_t sz)
 
voidoperator new[] (size_t sz, void *vp)
 
TObjectoperator= (const TObject &rhs)
 TObject assignment operator. More...
 
virtual void Paint (Option_t *option="")
 This method must be overridden if a class wants to paint itself. More...
 
virtual void Pop ()
 Pop on object drawn in a pad to the top of the display list. More...
 
virtual void Print (Option_t *option="") const
 This method must be overridden when a class wants to print itself. More...
 
virtual Int_t Read (const char *name)
 Read contents of object with specified name from the current directory. More...
 
virtual void RecursiveRemove (TObject *obj)
 Recursively remove this object from a list. More...
 
void ResetBit (UInt_t f)
 
virtual void SaveAs (const char *filename="", Option_t *option="") const
 Save this object in the file specified by filename. More...
 
virtual void SavePrimitive (std::ostream &out, Option_t *option="")
 Save a primitive as a C++ statement(s) on output stream "out". More...
 
void SetBit (UInt_t f, Bool_t set)
 Set or unset the user status bits as specified in f. More...
 
void SetBit (UInt_t f)
 
virtual void SetDrawOption (Option_t *option="")
 Set drawing option for object. More...
 
virtual void SetUniqueID (UInt_t uid)
 Set the unique object id. More...
 
virtual void SysError (const char *method, const char *msgfmt,...) const
 Issue system error message. More...
 
R__ALWAYS_INLINE Bool_t TestBit (UInt_t f) const
 
Int_t TestBits (UInt_t f) const
 
virtual void UseCurrentStyle ()
 Set current style settings in this object This function is called when either TCanvas::UseCurrentStyle or TROOT::ForceStyle have been invoked. More...
 
virtual void Warning (const char *method, const char *msgfmt,...) const
 Issue warning message. More...
 
virtual Int_t Write (const char *name=0, Int_t option=0, Int_t bufsize=0)
 Write this object to the current directory. More...
 
virtual Int_t Write (const char *name=0, Int_t option=0, Int_t bufsize=0) const
 Write this object to the current directory. More...
 

Protected Member Functions

 TLorentzRotation (Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t, Double_t)
 
void SetBoost (Double_t, Double_t, Double_t)
 
- Protected Member Functions inherited from TObject
virtual void DoError (int level, const char *location, const char *fmt, va_list va) const
 Interface to ErrorHandler (protected). More...
 
void MakeZombie ()
 

Protected Attributes

Double_t ftt
 
Double_t ftx
 
Double_t fty
 
Double_t ftz
 
Double_t fxt
 
Double_t fxx
 
Double_t fxy
 
Double_t fxz
 
Double_t fyt
 
Double_t fyx
 
Double_t fyy
 
Double_t fyz
 
Double_t fzt
 
Double_t fzx
 
Double_t fzy
 
Double_t fzz
 

Additional Inherited Members

- Public Types inherited from TObject
enum  {
  kIsOnHeap = 0x01000000, kNotDeleted = 0x02000000, kZombie = 0x04000000, kInconsistent = 0x08000000,
  kBitMask = 0x00ffffff
}
 
enum  { kSingleKey = BIT(0), kOverwrite = BIT(1), kWriteDelete = BIT(2) }
 
enum  EDeprecatedStatusBits { kObjInCanvas = BIT(3) }
 
enum  EStatusBits {
  kCanDelete = BIT(0), kMustCleanup = BIT(3), kIsReferenced = BIT(4), kHasUUID = BIT(5),
  kCannotPick = BIT(6), kNoContextMenu = BIT(8), kInvalidObject = BIT(13)
}
 
- Static Public Member Functions inherited from TObject
static Long_t GetDtorOnly ()
 Return destructor only flag. More...
 
static Bool_t GetObjectStat ()
 Get status of object stat flag. More...
 
static void SetDtorOnly (void *obj)
 Set destructor only flag. More...
 
static void SetObjectStat (Bool_t stat)
 Turn on/off tracking of objects in the TObjectTable. More...
 

#include <TLorentzRotation.h>

Inheritance diagram for TLorentzRotation:
[legend]

Constructor & Destructor Documentation

◆ TLorentzRotation() [1/6]

TLorentzRotation::TLorentzRotation ( )

Definition at line 136 of file TLorentzRotation.cxx.

◆ TLorentzRotation() [2/6]

TLorentzRotation::TLorentzRotation ( const TRotation r)

Definition at line 142 of file TLorentzRotation.cxx.

◆ TLorentzRotation() [3/6]

TLorentzRotation::TLorentzRotation ( const TLorentzRotation r)

Definition at line 148 of file TLorentzRotation.cxx.

◆ TLorentzRotation() [4/6]

TLorentzRotation::TLorentzRotation ( Double_t  bx,
Double_t  by,
Double_t  bz 
)

Definition at line 164 of file TLorentzRotation.cxx.

◆ TLorentzRotation() [5/6]

TLorentzRotation::TLorentzRotation ( const TVector3 p)

Definition at line 172 of file TLorentzRotation.cxx.

◆ TLorentzRotation() [6/6]

TLorentzRotation::TLorentzRotation ( Double_t  rxx,
Double_t  rxy,
Double_t  rxz,
Double_t  rxt,
Double_t  ryx,
Double_t  ryy,
Double_t  ryz,
Double_t  ryt,
Double_t  rzx,
Double_t  rzy,
Double_t  rzz,
Double_t  rzt,
Double_t  rtx,
Double_t  rty,
Double_t  rtz,
Double_t  rtt 
)
protected

Definition at line 154 of file TLorentzRotation.cxx.

Member Function Documentation

◆ Boost() [1/2]

TLorentzRotation & TLorentzRotation::Boost ( Double_t  bx,
Double_t  by,
Double_t  bz 
)
inline

Definition at line 278 of file TLorentzRotation.h.

◆ Boost() [2/2]

TLorentzRotation & TLorentzRotation::Boost ( const TVector3 b)
inline

Definition at line 282 of file TLorentzRotation.h.

◆ Inverse()

TLorentzRotation TLorentzRotation::Inverse ( ) const
inline

Definition at line 267 of file TLorentzRotation.h.

◆ Invert()

TLorentzRotation & TLorentzRotation::Invert ( )
inline

Definition at line 274 of file TLorentzRotation.h.

◆ IsIdentity()

Bool_t TLorentzRotation::IsIdentity ( ) const
inline

Definition at line 231 of file TLorentzRotation.h.

◆ MatrixMultiplication()

TLorentzRotation TLorentzRotation::MatrixMultiplication ( const TLorentzRotation b) const

Definition at line 221 of file TLorentzRotation.cxx.

◆ operator!=()

Bool_t TLorentzRotation::operator!= ( const TLorentzRotation r) const
inline

Definition at line 223 of file TLorentzRotation.h.

◆ operator()()

Double_t TLorentzRotation::operator() ( int  i,
int  j 
) const

Definition at line 177 of file TLorentzRotation.cxx.

◆ operator*() [1/2]

TLorentzVector TLorentzRotation::operator* ( const TLorentzVector p) const
inline

Definition at line 247 of file TLorentzRotation.h.

◆ operator*() [2/2]

TLorentzRotation TLorentzRotation::operator* ( const TLorentzRotation m) const
inline

Definition at line 251 of file TLorentzRotation.h.

◆ operator*=()

TLorentzRotation & TLorentzRotation::operator*= ( const TLorentzRotation m)
inline

Definition at line 255 of file TLorentzRotation.h.

◆ operator=() [1/2]

TLorentzRotation & TLorentzRotation::operator= ( const TLorentzRotation r)
inline

Definition at line 171 of file TLorentzRotation.h.

◆ operator=() [2/2]

TLorentzRotation & TLorentzRotation::operator= ( const TRotation r)
inline

Definition at line 188 of file TLorentzRotation.h.

◆ operator==()

Bool_t TLorentzRotation::operator== ( const TLorentzRotation r) const
inline

Definition at line 206 of file TLorentzRotation.h.

◆ operator[]()

TLorentzRotation::TLorentzRotationRow TLorentzRotation::operator[] ( int  i) const
inline

Definition at line 167 of file TLorentzRotation.h.

◆ Rotate() [1/2]

TLorentzRotation & TLorentzRotation::Rotate ( Double_t  angle,
const TVector3 axis 
)
inline

Definition at line 298 of file TLorentzRotation.h.

◆ Rotate() [2/2]

TLorentzRotation & TLorentzRotation::Rotate ( Double_t  angle,
const TVector3 axis 
)
inline

Definition at line 302 of file TLorentzRotation.h.

◆ RotateX()

TLorentzRotation & TLorentzRotation::RotateX ( Double_t  angle)
inline

Definition at line 286 of file TLorentzRotation.h.

◆ RotateY()

TLorentzRotation & TLorentzRotation::RotateY ( Double_t  angle)
inline

Definition at line 290 of file TLorentzRotation.h.

◆ RotateZ()

TLorentzRotation & TLorentzRotation::RotateZ ( Double_t  angle)
inline

Definition at line 294 of file TLorentzRotation.h.

◆ SetBoost()

void TLorentzRotation::SetBoost ( Double_t  bx,
Double_t  by,
Double_t  bz 
)
protected

Definition at line 204 of file TLorentzRotation.cxx.

◆ Transform() [1/2]

TLorentzRotation & TLorentzRotation::Transform ( const TLorentzRotation m)
inline

Definition at line 259 of file TLorentzRotation.h.

◆ Transform() [2/2]

TLorentzRotation & TLorentzRotation::Transform ( const TRotation m)
inline

Definition at line 263 of file TLorentzRotation.h.

◆ TT()

Double_t TLorentzRotation::TT ( ) const
inline

Definition at line 158 of file TLorentzRotation.h.

◆ TX()

Double_t TLorentzRotation::TX ( ) const
inline

Definition at line 155 of file TLorentzRotation.h.

◆ TY()

Double_t TLorentzRotation::TY ( ) const
inline

Definition at line 156 of file TLorentzRotation.h.

◆ TZ()

Double_t TLorentzRotation::TZ ( ) const
inline

Definition at line 157 of file TLorentzRotation.h.

◆ VectorMultiplication()

TLorentzVector TLorentzRotation::VectorMultiplication ( const TLorentzVector p) const
inline

Definition at line 240 of file TLorentzRotation.h.

◆ XT()

Double_t TLorentzRotation::XT ( ) const
inline

Definition at line 146 of file TLorentzRotation.h.

◆ XX()

Double_t TLorentzRotation::XX ( ) const
inline

Definition at line 143 of file TLorentzRotation.h.

◆ XY()

Double_t TLorentzRotation::XY ( ) const
inline

Definition at line 144 of file TLorentzRotation.h.

◆ XZ()

Double_t TLorentzRotation::XZ ( ) const
inline

Definition at line 145 of file TLorentzRotation.h.

◆ YT()

Double_t TLorentzRotation::YT ( ) const
inline

Definition at line 150 of file TLorentzRotation.h.

◆ YX()

Double_t TLorentzRotation::YX ( ) const
inline

Definition at line 147 of file TLorentzRotation.h.

◆ YY()

Double_t TLorentzRotation::YY ( ) const
inline

Definition at line 148 of file TLorentzRotation.h.

◆ YZ()

Double_t TLorentzRotation::YZ ( ) const
inline

Definition at line 149 of file TLorentzRotation.h.

◆ ZT()

Double_t TLorentzRotation::ZT ( ) const
inline

Definition at line 154 of file TLorentzRotation.h.

◆ ZX()

Double_t TLorentzRotation::ZX ( ) const
inline

Definition at line 151 of file TLorentzRotation.h.

◆ ZY()

Double_t TLorentzRotation::ZY ( ) const
inline

Definition at line 152 of file TLorentzRotation.h.

◆ ZZ()

Double_t TLorentzRotation::ZZ ( ) const
inline

Definition at line 153 of file TLorentzRotation.h.

Member Data Documentation

◆ ftt

Double_t TLorentzRotation::ftt
protected

Definition at line 122 of file TLorentzRotation.h.

◆ ftx

Double_t TLorentzRotation::ftx
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fty

Double_t TLorentzRotation::fty
protected

Definition at line 122 of file TLorentzRotation.h.

◆ ftz

Double_t TLorentzRotation::ftz
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fxt

Double_t TLorentzRotation::fxt
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fxx

Double_t TLorentzRotation::fxx
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fxy

Double_t TLorentzRotation::fxy
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fxz

Double_t TLorentzRotation::fxz
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fyt

Double_t TLorentzRotation::fyt
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fyx

Double_t TLorentzRotation::fyx
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fyy

Double_t TLorentzRotation::fyy
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fyz

Double_t TLorentzRotation::fyz
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fzt

Double_t TLorentzRotation::fzt
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fzx

Double_t TLorentzRotation::fzx
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fzy

Double_t TLorentzRotation::fzy
protected

Definition at line 122 of file TLorentzRotation.h.

◆ fzz

Double_t TLorentzRotation::fzz
protected

Definition at line 122 of file TLorentzRotation.h.

Libraries for TLorentzRotation:
[legend]

The documentation for this class was generated from the following files: