StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
StarGenParticle Class Reference

Yet another particle class. More...

#include <StarGenParticle.h>

Inheritance diagram for StarGenParticle:

Public Types

enum  State {
  kNull, kFinal, kDecayed, kDocumentation,
  kIncident, kUnknown
}
 

Public Member Functions

void SetStatus (Int_t status)
 Set the status code of the particle according to the HEPEVT standard.
 
Int_t GetStatus ()
 Get the status code of the particle according to the HEPEVT standard.
 
void SetId (Int_t id)
 
Int_t GetId ()
 Get the id code of the particle according to the PDG standard.
 
void SetFirstMother (Int_t first)
 Set the first mother particle in the array of particles.
 
void SetFirstMother (StarGenParticle *p)
 
Int_t GetFirstMother ()
 Get the first mother particle.
 
void SetLastMother (Int_t last)
 Set the last mother particle in the array of particles.
 
void SetLastMother (StarGenParticle *p)
 
Int_t GetLastMother ()
 Get the last mother particle.
 
void SetFirstDaughter (Int_t first)
 Set the first daughter particle in the array of particles.
 
void SetFirstDaughter (StarGenParticle *p)
 
Int_t GetFirstDaughter ()
 Get the first daughter particle.
 
void SetLastDaughter (Int_t last)
 Set the last daughter particle in the array of particles.
 
void SetLastDaughter (StarGenParticle *p)
 
Int_t GetLastDaughter ()
 Get the last daughter particle.
 
void SetPx (Float_t px)
 Set the x-component of the momentum.
 
Float_t GetPx ()
 Get the x-component of the momentum.
 
void SetPy (Float_t py)
 Set the y-component of the momentum.
 
Float_t GetPy ()
 Get the y-component of the momentum.
 
void SetPz (Float_t pz)
 Set the z-component of the momentum.
 
Float_t GetPz ()
 Get the z-component of the momentum.
 
Float_t pt ()
 Returns the transverse momentum of the particle.
 
Float_t pt2 ()
 Returns the transverse momentum squared.
 
Float_t mt ()
 Returns the transverse mass of the particle.
 
Float_t mt2 ()
 Returns the transverse mass squared.
 
TLorentzVector momentum ()
 Return the 4-momentum of the particle.
 
void SetEnergy (Float_t energy)
 Set the energy.
 
Float_t GetEnergy ()
 Get the energy.
 
void SetMass (Float_t mass)
 Set the mass.
 
Float_t GetMass ()
 Get the mass.
 
void SetVx (Float_t vx)
 Set the x-component of the start vertex.
 
Float_t GetVx ()
 Get the x-component of the start vertex.
 
void SetVy (Float_t vy)
 Set the y-component of the start vertex.
 
Float_t GetVy ()
 Get the y-component of the start vertex.
 
void SetVz (Float_t vz)
 Set the z-component of the start vertex.
 
Float_t GetVz ()
 Get the z-component of the start vertex.
 
void SetTof (Float_t tof)
 Set the tof.
 
Float_t GetTof ()
 Get the tof.
 
void SetIndex (Int_t i)
 Set the line number in the event record.
 
Int_t GetIndex ()
 Get the line number in the event record.
 
void SetStack (Int_t i)
 Set the line number in the particle stack.
 
Int_t GetStack ()
 Get the line number in the particle stack.
 
void SetPrimaryKey (Int_t k)
 
Int_t GetPrimaryKey ()
 
void SetGeneratorId (Int_t id)
 
Int_t GetGeneratorId ()
 
void Print (const Option_t *opts="") const
 Print the particle.
 
Bool_t Simulate ()
 

Protected Member Functions

 ClassDef (StarGenParticle, 1)
 

Protected Attributes

Int_t mIndex
 
Int_t mStack
 
Int_t mPrimaryKey
 
Int_t mGeneratorId
 

Friends

class StarPrimaryMaker
 

Detailed Description

Yet another particle class.

The StarGenParticle class is the class which represents event-generator particles within the event record. It is based on the HEPEVT standard, developed many years ago when FORtran ruled the earth. It stores particle information in a "table" format, specifying

mId – the Particle Data Group ID of the particle mStatus – the status code of the particle, according to the HepMC standard noted below mMother[0] – the index of the first mother of this particle in the array of particles mMother[1] – the index of the last mother of this particle in the array of particles mDaughter[0] – the index of the first daughter of this particle in the array of particles mDaughter[1] – the index of the last daughter of this particle in the array of particles

mPx, mPy, mPz, mEnergy – Specifies the four-momentum of this particle mMass – the mass of the particle as specified by the event generator mVx, mVy, mVz, mTof – the four-position of this particle

It is the developer's responsability to set these variables, usually when calling StarGenEvent::AddParticle().

Additinal variables are provided for bookkeeping purposes.

mIndex – the position of the particle within the array of particles mPrimaryKey – the position of the particle within the primary event record's array of particles mStack – the position of the particle on the geant stack, which corresponds to the ID truth in the MuDst or the "primary key" in the g2t_track record

HEPEVT status codes (as defined in the HepMC manual)

After some discussion, the authors in MCnet [18] have agreed to a clarification of the HEPEVT status codes. The Fortran Monte Carlo generators will not change their behaviour, but Sherpa, Pythia8, and Herwig++ will go to the newer usage. These are the accepted status code definitions: o 0 : an empty entry with no meaningful information and therefore to be skipped unconditionally o 1 : a final-state particle, i.e. a particle that is not decayed further by the generator (may also include unstable particles that are to be decayed later, as part of the detector simulation). Such particles must always be labelled '1' o 2 : decayed Standard Model hadron or tau or mu lepton, excepting virtual intermediate states thereof (i.e. the particle must undergo a normal decay, not e.g. a shower branching). Such particles must always be labelled 2. No other particles can be labelled 2. o 3 : a documentation entry o 4 : an incoming beam particle

o 5-10 : undefined, reserved for future standards o 11-200: an intermediate (decayed/branched/...) particle that does not fullfil the criteria of status code 2, with a generator-dependent classification of its nature. o 201- : at the disposal of the user, in particular for event tracking in the detector

Author
Jason C. Webb

Definition at line 69 of file StarGenParticle.h.

Member Enumeration Documentation

Enumerator
kNull 

Null entry

kFinal 

Final state particle which will not be decayed further by the event generator

kDecayed 

Standard model hadron, muon or tau which has decayed. Code does not include intermediate-state hadrons.

kDocumentation 

Documentation line in the record

kIncident 

Incident beam particle

kUnknown 

Negative numbers will signify STAR event header information

Definition at line 76 of file StarGenParticle.h.

Member Function Documentation

void StarGenParticle::SetId ( Int_t  id)

Set the id code of the particle according to the PDG standard. The mass of the particle will be set according to the data tabulated in the PDG.

Definition at line 28 of file StarGenParticle.cxx.

References StarParticleData::GetParticle(), StarParticleData::instance(), and SetMass().

Referenced by StarKinematics::AddParticle(), and StarGenEvent::AddParticle().

Bool_t StarGenParticle::Simulate ( )

Returns true if the particle should be simulated (i.e. pushed out to the geant stack.

Definition at line 58 of file StarGenParticle.cxx.

References kFinal.

Referenced by StarGenEvent::Print(), and StarPrimaryMaker::Simulate().

Member Data Documentation

Int_t StarGenParticle::mIndex
protected
Todo:

Add user-defined weight (or optionally a parallel array of particle attributes users can populate)

Add polarization

Definition at line 218 of file StarGenParticle.h.

Referenced by GetIndex(), Print(), and SetIndex().


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