|
BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
|
CbmStack.h. More...
#include <CbmStack.h>
Public Member Functions | |
| CbmStack (Int_t size=100) | |
| Default constructor param size Estimated track number. | |
| virtual | ~CbmStack () |
| Destructor. | |
| virtual void | PushTrack (Int_t toBeDone, Int_t parentID, Int_t pdgCode, Double_t px, Double_t py, Double_t pz, Double_t e, Double_t vx, Double_t vy, Double_t vz, Double_t time, Double_t polx, Double_t poly, Double_t polz, TMCProcess proc, Int_t &ntr, Double_t weight, Int_t is) |
| Add a TParticle to the stack. | |
| virtual void | PushTrack (Int_t toBeDone, Int_t parentID, Int_t pdgCode, Double_t px, Double_t py, Double_t pz, Double_t e, Double_t vx, Double_t vy, Double_t vz, Double_t time, Double_t polx, Double_t poly, Double_t polz, TMCProcess proc, Int_t &ntr, Double_t weight, Int_t is, Int_t secondParentId) |
| virtual TParticle * | PopNextTrack (Int_t &iTrack) |
| Get next particle for tracking from the stack. | |
| virtual TParticle * | PopPrimaryForTracking (Int_t iPrim) |
| Get primary particle by index for tracking from stack Declared in TVirtualMCStack. | |
| virtual void | SetCurrentTrack (Int_t iTrack) |
| Set the current track number Declared in TVirtualMCStack. | |
| virtual Int_t | GetNtrack () const |
| Get total number of tracks Declared in TVirtualMCStack. | |
| virtual Int_t | GetNprimary () const |
| Get number of primary tracks Declared in TVirtualMCStack. | |
| virtual TParticle * | GetCurrentTrack () const |
| Get the current track's particle Declared in TVirtualMCStack. | |
| virtual Int_t | GetCurrentTrackNumber () const |
| Get the number of the current track Declared in TVirtualMCStack. | |
| virtual Int_t | GetCurrentParentTrackNumber () const |
| Get the track number of the parent of the current track Declared in TVirtualMCStack. | |
| virtual void | AddParticle (TParticle *part) |
| Add a TParticle to the fParticles array. | |
| virtual void | FillTrackArray () |
| Fill the MCTrack output array, applying filter criteria. | |
| virtual void | UpdateTrackIndex (TRefArray *detArray=0) |
| Update the track index in the MCTracks and MCPoints. | |
| virtual void | Reset () |
| Resets arrays and stack and deletes particles and tracks. | |
| virtual void | Register () |
| Register the MCTrack array to the Root Manager. | |
| virtual void | Print (Option_t *) const |
| Output to screen: the event summary, and the track info if the log level is debug1. | |
| void | StoreSecondaries (Bool_t choice=kTRUE) |
| Modifiers. | |
| void | SetMinPoints (Int_t min) |
| void | SetEnergyCut (Double_t eMin) |
| void | SetStartZCut (Double_t zMax) |
| void | StoreMothers (Bool_t choice=kTRUE) |
| void | AddPoint (DetectorId iDet) |
| Increment number of points for the current track in a given detector. | |
| void | AddPoint (DetectorId iDet, Int_t iTrack) |
| Increment number of points for an arbitrary track in a given detector. | |
| TParticle * | GetParticle (Int_t trackId) const |
| Accessors. | |
| TClonesArray * | GetListOfParticles () |
| void | SetParticleArray (TClonesArray *partArray) |
| void | SetParticleArray (TClonesArray *partArray, Int_t partFrom, Int_t partTo) |
| virtual FairGenericStack * | CloneStack () const |
| Clone this object (used in MT mode only). | |
| CbmStack (Int_t size=100) | |
| Default constructor param size Estimated track number. | |
| virtual | ~CbmStack () |
| Destructor. | |
| virtual void | PushTrack (Int_t toBeDone, Int_t parentID, Int_t pdgCode, Double_t px, Double_t py, Double_t pz, Double_t e, Double_t vx, Double_t vy, Double_t vz, Double_t time, Double_t polx, Double_t poly, Double_t polz, TMCProcess proc, Int_t &ntr, Double_t weight, Int_t is) |
| Add a TParticle to the stack. | |
| virtual void | PushTrack (Int_t toBeDone, Int_t parentID, Int_t pdgCode, Double_t px, Double_t py, Double_t pz, Double_t e, Double_t vx, Double_t vy, Double_t vz, Double_t time, Double_t polx, Double_t poly, Double_t polz, TMCProcess proc, Int_t &ntr, Double_t weight, Int_t is, Int_t secondParentId) |
| virtual TParticle * | PopNextTrack (Int_t &iTrack) |
| Get next particle for tracking from the stack. | |
| virtual TParticle * | PopPrimaryForTracking (Int_t iPrim) |
| Get primary particle by index for tracking from stack Declared in TVirtualMCStack. | |
| virtual void | SetCurrentTrack (Int_t iTrack) |
| Set the current track number Declared in TVirtualMCStack. | |
| virtual Int_t | GetNtrack () const |
| Get total number of tracks Declared in TVirtualMCStack. | |
| virtual Int_t | GetNprimary () const |
| Get number of primary tracks Declared in TVirtualMCStack. | |
| virtual TParticle * | GetCurrentTrack () const |
| Get the current track's particle Declared in TVirtualMCStack. | |
| virtual Int_t | GetCurrentTrackNumber () const |
| Get the number of the current track Declared in TVirtualMCStack. | |
| virtual Int_t | GetCurrentParentTrackNumber () const |
| Get the track number of the parent of the current track Declared in TVirtualMCStack. | |
| virtual void | AddParticle (TParticle *part) |
| Add a TParticle to the fParticles array. | |
| virtual void | FillTrackArray () |
| Fill the MCTrack output array, applying filter criteria. | |
| virtual void | UpdateTrackIndex (TRefArray *detArray=0) |
| Update the track index in the MCTracks and MCPoints. | |
| virtual void | Reset () |
| Resets arrays and stack and deletes particles and tracks. | |
| virtual void | Register () |
| Register the MCTrack array to the Root Manager. | |
| virtual void | Print (Option_t *) const |
| Output to screen: the event summary, and the track info if the log level is debug1. | |
| void | StoreSecondaries (Bool_t choice=kTRUE) |
| Modifiers. | |
| void | SetMinPoints (Int_t min) |
| void | SetEnergyCut (Double_t eMin) |
| void | SetStartZCut (Double_t zMax) |
| void | StoreMothers (Bool_t choice=kTRUE) |
| void | AddPoint (DetectorId iDet) |
| Increment number of points for the current track in a given detector. | |
| void | AddPoint (DetectorId iDet, Int_t iTrack) |
| Increment number of points for an arbitrary track in a given detector. | |
| TParticle * | GetParticle (Int_t trackId) const |
| Accessors. | |
| TClonesArray * | GetListOfParticles () |
| void | SetParticleArray (TClonesArray *partArray) |
| void | SetParticleArray (TClonesArray *partArray, Int_t partFrom, Int_t partTo) |
| virtual FairGenericStack * | CloneStack () const |
| Clone this object (used in MT mode only). | |
Private Member Functions | |
| void | SelectTracks () |
| Mark tracks for output using selection criteria. | |
| CbmStack (const CbmStack &) | |
| CbmStack & | operator= (const CbmStack &) |
| void | SelectTracks () |
| Mark tracks for output using selection criteria. | |
| CbmStack (const CbmStack &) | |
| CbmStack & | operator= (const CbmStack &) |
Private Attributes | |
| std::stack< TParticle * > | fStack |
| STL stack (FILO) used to handle the TParticles for tracking. | |
| TClonesArray * | fParticles |
| Array of TParticles (contains all TParticles put into or created by the transport. | |
| TClonesArray * | fTracks |
| Array of CbmMCTracks containg the tracks written to the output. | |
| std::map< Int_t, Bool_t > | fStoreMap |
| STL map from particle index to storage flag. | |
| std::map< Int_t, Bool_t >::iterator | fStoreIter |
| std::map< Int_t, Int_t > | fIndexMap |
| STL map from particle index to track index. | |
| std::map< Int_t, Int_t >::iterator | fIndexIter |
| std::map< std::pair< Int_t, Int_t >, Int_t > | fPointsMap |
| STL map from track index and detector ID to number of MCPoints. | |
| Int_t | fCurrentTrack |
| Some indizes and counters. | |
| Int_t | fNPrimaries |
| Index of current track. | |
| Int_t | fNParticles |
| Number of primary particles. | |
| Int_t | fNTracks |
| Number of entries in fParticles. | |
| Int_t | fIndex |
| Number of entries in fTracks. | |
| Bool_t | fStoreSecondaries |
| Used for merging. | |
| Int_t | fMinPoints |
| Double32_t | fEnergyCut |
| Double_t | fStartZCut |
| Bool_t | fStoreMothers |
Version 14/06/07 by V. Friese
This class handles the particle stack for the transport simulation. For the stack FILO functunality, it uses the STL stack. To store the tracks during transport, a TParticle arry is used. At the end of the event, tracks satisfying the filter criteria are copied to a CbmMCTrack array, which is stored in the output.
The filtering criteria for the output tracks are:
The storage of secondaries can be switched off. The storage of all mothers can be switched off. By default, the minimal number of points is 1 and the energy cut is 0.
Definition at line 42 of file CbmStack.h.
| CbmStack::CbmStack | ( | Int_t | size = 100 | ) |
Definition at line 22 of file CbmStack.cxx.
References fCurrentTrack, fEnergyCut, fIndex, fIndexIter, fIndexMap, fMinPoints, fNParticles, fNPrimaries, fNTracks, fParticles, fPointsMap, fStack, fStartZCut, fStoreIter, fStoreMap, fStoreMothers, fStoreSecondaries, and fTracks.
Referenced by CbmStack(), CloneStack(), and operator=().
|
virtual |
Definition at line 45 of file CbmStack.cxx.
References fParticles, and fTracks.
|
private |
| CbmStack::CbmStack | ( | Int_t | size = 100 | ) |
|
virtual |
|
private |
|
virtual |
Definition at line 188 of file CbmStack.cxx.
References fIndex, fParticles, TObject::GetUniqueID(), TParticle::GetWeight(), TObject::SetUniqueID(), and TParticle::SetWeight().
Referenced by SetParticleArray(), and SetParticleArray().
|
virtual |
| void CbmStack::AddPoint | ( | DetectorId | iDet | ) |
| iDet | Detector unique identifier |
Definition at line 351 of file CbmStack.cxx.
References fCurrentTrack, and fPointsMap.
Referenced by CbmSts::ProcessHits().
| void CbmStack::AddPoint | ( | DetectorId | iDet | ) |
| iDet | Detector unique identifier |
| void CbmStack::AddPoint | ( | DetectorId | iDet, |
| Int_t | iTrack ) |
| iDet | Detector unique identifier |
| iTrack | Track number |
Definition at line 364 of file CbmStack.cxx.
References fPointsMap.
| void CbmStack::AddPoint | ( | DetectorId | iDet, |
| Int_t | iTrack ) |
| iDet | Detector unique identifier |
| iTrack | Track number |
|
inlinevirtual |
Definition at line 217 of file CbmStack.h.
References CbmStack(), fEnergyCut, fMinPoints, fStoreMothers, fStoreSecondaries, SetEnergyCut(), SetMinPoints(), StoreMothers(), and StoreSecondaries().
|
inlinevirtual |
Definition at line 217 of file CbmStack.h.
References CbmStack(), fEnergyCut, fMinPoints, fStoreMothers, fStoreSecondaries, SetEnergyCut(), SetMinPoints(), StoreMothers(), and StoreSecondaries().
|
virtual |
Definition at line 198 of file CbmStack.cxx.
References fIndexMap, fNParticles, fNTracks, fPointsMap, fStoreIter, fStoreMap, GetParticle(), kNOFDETS, kREF, SelectTracks(), and CbmMCTrack::SetNPoints().
|
virtual |
|
virtual |
Definition at line 380 of file CbmStack.cxx.
References GetCurrentTrack(), and TParticle::GetFirstMother().
|
virtual |
|
virtual |
Definition at line 178 of file CbmStack.cxx.
References fCurrentTrack, and GetParticle().
Referenced by GetCurrentParentTrackNumber().
|
virtual |
|
inlinevirtual |
Definition at line 145 of file CbmStack.h.
References fCurrentTrack.
|
inlinevirtual |
Definition at line 145 of file CbmStack.h.
References fCurrentTrack.
|
inline |
Definition at line 191 of file CbmStack.h.
References fParticles.
Referenced by BmnParticleEqualizer1D::ReadEvent(), and BmnParticleEqualizer2D::ReadEvent().
|
inline |
Definition at line 191 of file CbmStack.h.
References fParticles.
|
inlinevirtual |
Definition at line 135 of file CbmStack.h.
References fNPrimaries.
|
inlinevirtual |
Definition at line 135 of file CbmStack.h.
References fNPrimaries.
|
inlinevirtual |
Definition at line 130 of file CbmStack.h.
References fNParticles.
|
inlinevirtual |
Definition at line 130 of file CbmStack.h.
References fNParticles.
Definition at line 391 of file CbmStack.cxx.
References fNParticles, and fParticles.
Referenced by FillTrackArray(), GetCurrentTrack(), SelectTracks(), and UpdateTrackIndex().
Declared in TVirtualMCStack
| iTrack | index of popped track (return) |
Definition at line 133 of file CbmStack.cxx.
References fCurrentTrack, fStack, and TParticle::GetStatusCode().
Declared in TVirtualMCStack
| iTrack | index of popped track (return) |
| iPrim | index of primary particle |
Definition at line 157 of file CbmStack.cxx.
References fNPrimaries, fParticles, and TParticle::GetMother().
| iPrim | index of primary particle |
|
virtual |
Definition at line 338 of file CbmStack.cxx.
References fNParticles, fNPrimaries, fNTracks, fTracks, and Print().
Referenced by Print().
|
virtual |
|
virtual |
Declared in TVirtualMCStack
| toBeDone | Flag for tracking |
| parentID | Index of mother particle |
| pdgCode | Particle type (PDG encoding) |
| px,py,pz | Momentum components at start vertex [GeV] |
| e | Total energy at start vertex [GeV] |
| vx,vy,vz | Coordinates of start vertex [cm] |
| time | Start time of track [s] |
| polx,poly,polz | Polarisation vector |
| proc | Production mechanism (VMC encoding) |
| ntr | Track number (filled by the stack) |
| weight | Particle weight |
| is | Generation status code (whatever that means) |
Definition at line 57 of file CbmStack.cxx.
References PushTrack().
Referenced by PushTrack().
|
virtual |
Declared in TVirtualMCStack
| toBeDone | Flag for tracking |
| parentID | Index of mother particle |
| pdgCode | Particle type (PDG encoding) |
| px,py,pz | Momentum components at start vertex [GeV] |
| e | Total energy at start vertex [GeV] |
| vx,vy,vz | Coordinates of start vertex [cm] |
| time | Start time of track [s] |
| polx,poly,polz | Polarisation vector |
| proc | Production mechanism (VMC encoding) |
| ntr | Track number (filled by the stack) |
| weight | Particle weight |
| is | Generation status code (whatever that means) |
|
virtual |
Definition at line 81 of file CbmStack.cxx.
References fNParticles, fNPrimaries, fParticles, fStack, TParticle::SetPolarisation(), TObject::SetUniqueID(), and TParticle::SetWeight().
|
virtual |
|
virtual |
Definition at line 328 of file CbmStack.cxx.
References fTracks.
|
virtual |
|
virtual |
Definition at line 314 of file CbmStack.cxx.
References fCurrentTrack, fIndex, fNParticles, fNPrimaries, fNTracks, fParticles, fPointsMap, fStack, and fTracks.
|
virtual |
|
private |
Definition at line 400 of file CbmStack.cxx.
References TLorentzVector::E(), fEnergyCut, fMinPoints, fNParticles, fPointsMap, fStartZCut, fStoreMap, fStoreMothers, fStoreSecondaries, TParticle::GetMother(), GetParticle(), TParticle::GetPDG(), TParticle::GetPdgCode(), i, kFHCAL, kNOFDETS, kREF, TLorentzVector::M(), TParticlePDG::Mass(), TParticle::Momentum(), TParticle::SetFirstMother(), and TParticle::Vz().
Referenced by FillTrackArray().
|
private |
|
inlinevirtual |
|
inlinevirtual |
|
inline |
Definition at line 174 of file CbmStack.h.
References fEnergyCut.
Referenced by CloneStack().
|
inline |
Definition at line 174 of file CbmStack.h.
References fEnergyCut.
|
inline |
Definition at line 173 of file CbmStack.h.
References fMinPoints, and min().
Referenced by CloneStack(), Config(), and BmnTrackDrawP::InitGeant3().
|
inline |
Definition at line 173 of file CbmStack.h.
References fMinPoints, and min().
|
inline |
Definition at line 193 of file CbmStack.h.
References AddParticle(), TObjArray::At(), fNParticles, fNPrimaries, fStack, and TObjArray::GetEntries().
|
inline |
Definition at line 193 of file CbmStack.h.
References AddParticle(), TObjArray::At(), fNParticles, fNPrimaries, fStack, and TObjArray::GetEntries().
|
inline |
Definition at line 204 of file CbmStack.h.
References AddParticle(), TObjArray::At(), fNParticles, fNPrimaries, and fStack.
|
inline |
Definition at line 204 of file CbmStack.h.
References AddParticle(), TObjArray::At(), fNParticles, fNPrimaries, and fStack.
|
inline |
Definition at line 175 of file CbmStack.h.
References fStartZCut, and zMax.
|
inline |
Definition at line 175 of file CbmStack.h.
References fStartZCut, and zMax.
Definition at line 176 of file CbmStack.h.
References fStoreMothers.
Referenced by CloneStack().
Definition at line 176 of file CbmStack.h.
References fStoreMothers.
Definition at line 172 of file CbmStack.h.
References fStoreSecondaries.
Referenced by CloneStack(), and Config().
Definition at line 172 of file CbmStack.h.
References fStoreSecondaries.
|
virtual |
Definition at line 243 of file CbmStack.cxx.
References TObjArray::At(), fIndexIter, fIndexMap, fNTracks, fTracks, TObjArray::GetEntriesFast(), TParticle::GetFirstMother(), CbmMCTrack::GetMotherId(), GetParticle(), i, TRefArray::MakeIterator(), TIterator::Reset(), and CbmMCTrack::SetMotherId().
|
virtual |
|
private |
Definition at line 251 of file CbmStack.h.
Referenced by CbmStack(), AddPoint(), GetCurrentTrack(), GetCurrentTrackNumber(), PopNextTrack(), Reset(), and SetCurrentTrack().
|
private |
Definition at line 260 of file CbmStack.h.
Referenced by CbmStack(), CloneStack(), SelectTracks(), and SetEnergyCut().
|
private |
Definition at line 255 of file CbmStack.h.
Referenced by CbmStack(), AddParticle(), and Reset().
Definition at line 245 of file CbmStack.h.
Referenced by CbmStack(), and UpdateTrackIndex().
Definition at line 244 of file CbmStack.h.
Referenced by CbmStack(), FillTrackArray(), and UpdateTrackIndex().
|
private |
Definition at line 259 of file CbmStack.h.
Referenced by CbmStack(), CloneStack(), SelectTracks(), and SetMinPoints().
|
private |
Definition at line 253 of file CbmStack.h.
Referenced by CbmStack(), FillTrackArray(), GetNtrack(), GetParticle(), Print(), PushTrack(), Reset(), SelectTracks(), SetParticleArray(), and SetParticleArray().
|
private |
Definition at line 252 of file CbmStack.h.
Referenced by CbmStack(), GetNprimary(), PopPrimaryForTracking(), Print(), PushTrack(), Reset(), SetParticleArray(), and SetParticleArray().
|
private |
Definition at line 254 of file CbmStack.h.
Referenced by CbmStack(), FillTrackArray(), Print(), Reset(), and UpdateTrackIndex().
|
private |
Definition at line 234 of file CbmStack.h.
Referenced by CbmStack(), ~CbmStack(), AddParticle(), GetListOfParticles(), GetParticle(), PopPrimaryForTracking(), PushTrack(), and Reset().
Definition at line 248 of file CbmStack.h.
Referenced by CbmStack(), AddPoint(), AddPoint(), FillTrackArray(), Reset(), and SelectTracks().
|
private |
Definition at line 229 of file CbmStack.h.
Referenced by CbmStack(), PopNextTrack(), PushTrack(), Reset(), SetParticleArray(), and SetParticleArray().
|
private |
Definition at line 261 of file CbmStack.h.
Referenced by CbmStack(), SelectTracks(), and SetStartZCut().
Definition at line 241 of file CbmStack.h.
Referenced by CbmStack(), and FillTrackArray().
Definition at line 240 of file CbmStack.h.
Referenced by CbmStack(), FillTrackArray(), and SelectTracks().
|
private |
Definition at line 262 of file CbmStack.h.
Referenced by CbmStack(), CloneStack(), SelectTracks(), and StoreMothers().
|
private |
Variables defining the criteria for output selection
Definition at line 258 of file CbmStack.h.
Referenced by CbmStack(), CloneStack(), SelectTracks(), and StoreSecondaries().
|
private |
Definition at line 237 of file CbmStack.h.
Referenced by CbmStack(), ~CbmStack(), Print(), Register(), Reset(), and UpdateTrackIndex().