R3BROOT
R3B analysis software
Loading...
Searching...
No Matches
R3BStack Class Reference

R3BStack.h. More...

#include <R3BMCStack.h>

Public Member Functions

 R3BStack (Int_t size=100)
 Default constructor param size Estimated track number.
 
virtual ~R3BStack ()
 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)
 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 PrintStack (Int_t iVerbose) const
 Output to screen.
 
void StoreSecondaries (Bool_t choice=kTRUE)
 Modifiers.
 
void SetMinPoints (Int_t min)
 
void SetEnergyCut (Double_t eMin)
 
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 SetDebug (Bool_t t)
 

Detailed Description

Author
D.Bertini d.ber.nosp@m.tini.nosp@m.@gsi..nosp@m.de
V.Friese v.fri.nosp@m.ese@.nosp@m.gsi.d.nosp@m.e

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 R3BMCTrack array, which is stored in the output.

The filtering criteria for the output tracks are:

  • primary tracks are stored in any case.
  • secondary tracks are stored if they have a minimal number of points (sum of all detectors) and a minimal energy, or are the

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 54 of file R3BMCStack.h.

Constructor & Destructor Documentation

◆ R3BStack()

R3BStack::R3BStack ( Int_t size = 100)

Definition at line 41 of file R3BMCStack.cxx.

◆ ~R3BStack()

R3BStack::~R3BStack ( )
virtual

Definition at line 76 of file R3BMCStack.cxx.

Member Function Documentation

◆ AddParticle()

void R3BStack::AddParticle ( TParticle * part)
virtual

Definition at line 231 of file R3BMCStack.cxx.

◆ AddPoint() [1/2]

void R3BStack::AddPoint ( DetectorId iDet)
Parameters
iDetDetector unique identifier

Definition at line 403 of file R3BMCStack.cxx.

◆ AddPoint() [2/2]

void R3BStack::AddPoint ( DetectorId iDet,
Int_t iTrack )
Parameters
iDetDetector unique identifier
iTrackTrack number

Definition at line 413 of file R3BMCStack.cxx.

◆ FillTrackArray()

void R3BStack::FillTrackArray ( )
virtual

Definition at line 242 of file R3BMCStack.cxx.

◆ GetCurrentParentTrackNumber()

Int_t R3BStack::GetCurrentParentTrackNumber ( ) const
virtual

Definition at line 425 of file R3BMCStack.cxx.

◆ GetCurrentTrack()

TParticle * R3BStack::GetCurrentTrack ( ) const
virtual

Definition at line 219 of file R3BMCStack.cxx.

◆ GetCurrentTrackNumber()

virtual Int_t R3BStack::GetCurrentTrackNumber ( ) const
inlinevirtual

Definition at line 158 of file R3BMCStack.h.

◆ GetListOfParticles()

TClonesArray * R3BStack::GetListOfParticles ( )
inline

Definition at line 204 of file R3BMCStack.h.

◆ GetNprimary()

virtual Int_t R3BStack::GetNprimary ( ) const
inlinevirtual

Definition at line 148 of file R3BMCStack.h.

◆ GetNtrack()

virtual Int_t R3BStack::GetNtrack ( ) const
inlinevirtual

Definition at line 143 of file R3BMCStack.h.

◆ GetParticle()

TParticle * R3BStack::GetParticle ( Int_t trackId) const

Definition at line 436 of file R3BMCStack.cxx.

◆ PopNextTrack()

TParticle * R3BStack::PopNextTrack ( Int_t & iTrack)
virtual

Declared in TVirtualMCStack

Parameters
iTrackindex of popped track (return)
Returns
Pointer to the TParticle of the track

Definition at line 166 of file R3BMCStack.cxx.

◆ PopPrimaryForTracking()

TParticle * R3BStack::PopPrimaryForTracking ( Int_t iPrim)
virtual
Parameters
iPrimindex of primary particle
Returns
Pointer to the TParticle of the track

Definition at line 194 of file R3BMCStack.cxx.

◆ PrintStack()

void R3BStack::PrintStack ( Int_t iVerbose) const
virtual
Parameters
iVerbose0=events summary, 1=track info

Definition at line 385 of file R3BMCStack.cxx.

◆ PushTrack() [1/2]

void R3BStack::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 )
virtual

Declared in TVirtualMCStack

Parameters
toBeDoneFlag for tracking
parentIDIndex of mother particle
pdgCodeParticle type (PDG encoding)
px,py,pzMomentum components at start vertex [GeV]
eTotal energy at start vertex [GeV]
vx,vy,vzCoordinates of start vertex [cm]
timeStart time of track [s]
polx,poly,polzPolarisation vector
procProduction mechanism (VMC encoding)
ntrTrack number (filled by the stack)
weightParticle weight
isGeneration status code (whatever that means)

Definition at line 92 of file R3BMCStack.cxx.

◆ PushTrack() [2/2]

void R3BStack::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

Definition at line 117 of file R3BMCStack.cxx.

◆ Register()

void R3BStack::Register ( )
virtual

Definition at line 381 of file R3BMCStack.cxx.

◆ Reset()

void R3BStack::Reset ( )
virtual

Definition at line 367 of file R3BMCStack.cxx.

◆ SetCurrentTrack()

virtual void R3BStack::SetCurrentTrack ( Int_t iTrack)
inlinevirtual
Parameters
iTracktrack number

Definition at line 138 of file R3BMCStack.h.

◆ SetDebug()

void R3BStack::SetDebug ( Bool_t t)
inline

Definition at line 206 of file R3BMCStack.h.

◆ SetEnergyCut()

void R3BStack::SetEnergyCut ( Double_t eMin)
inline

Definition at line 188 of file R3BMCStack.h.

◆ SetMinPoints()

void R3BStack::SetMinPoints ( Int_t min)
inline

Definition at line 187 of file R3BMCStack.h.

◆ StoreMothers()

void R3BStack::StoreMothers ( Bool_t choice = kTRUE)
inline

Definition at line 189 of file R3BMCStack.h.

◆ StoreSecondaries()

void R3BStack::StoreSecondaries ( Bool_t choice = kTRUE)
inline

Definition at line 186 of file R3BMCStack.h.

◆ UpdateTrackIndex()

void R3BStack::UpdateTrackIndex ( TRefArray * detArray)
virtual

Definition at line 303 of file R3BMCStack.cxx.


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