EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
EicEventGenerator Class Reference

#include <EicRoot/blob/master/eic/event/EicEventGenerator.h>

+ Inheritance diagram for EicEventGenerator:
+ Collaboration diagram for EicEventGenerator:

Public Member Functions

 EicEventGenerator (TString fileName="")
 
virtual ~EicEventGenerator ()
 
int SkipFewEvents (unsigned eventsToSkip)
 
void RestrictEventChunkSize (unsigned nEvents)
 
void SelectPdgCode (int pdg)
 
void SelectLeadingParticle (double pmin=0.0)
 
void BuildEnergyFlowPlot (int etaBinNum, double etaMin, double etaMax)
 
void AddEnergyFlowPdgCode (int pdg)
 
virtual Bool_t ReadEvent (FairPrimaryGenerator *primGen)
 
const TChain * GetInputTree () const
 
- Public Member Functions inherited from EicProtoGenerator
 EicProtoGenerator (const char *name)
 
 ~EicProtoGenerator ()
 
void SetNaiveVerticalBeamDivergence (double value)
 
void SetNaiveHorizontalBeamDivergence (double value)
 
void SetNaiveHorizontalBeamRotation (double value)
 
void SetVertex (double x, double y, double z=0.0)
 
double GetVx () const
 
double GetVy () const
 
double GetVz () const
 
void SetVertexSmearing (double sx, double sy, double sz=0.0)
 
void SetVertexRange (double rx, double ry, double rz=0.0)
 
double GetVxSmearing () const
 
double GetVySmearing () const
 
double GetVzSmearing () const
 
TVector3 GetSimulatedPrimaryVertex (void)
 
TVector3 GetModifiedTrack (const TVector3 track)
 
 ClassDef (EicProtoGenerator, 1)
 
- Public Member Functions inherited from FairGenerator
 FairGenerator ()
 
 FairGenerator (const char *name, const char *title="FAIR Generator")
 
virtual ~FairGenerator ()
 
virtual Bool_t Init ()
 
 ClassDef (FairGenerator, 1)
 

Static Public Member Functions

static EicEventGeneratorInstance ()
 

Private Member Functions

void ResetVars ()
 
 ClassDef (EicEventGenerator, 22)
 

Private Attributes

PoachermPoacher
 singelton instance
 
TChain * mInputTree
 
unsigned mInputTreeNextEventId
 
erhic::VirtualEventmGeneratorEvent
 
ParticleMappingTablemMappingTable
 
Bool_t mSelectLeadingParticle
 
Double_t mSelectedLeadingParticlePmin
 
std::set< Int_t > mSelectedPdgCodes
 
UInt_t mEventChunkSize
 
UInt_t mEventCounter
 
double mEtaBinWidth
 
TH1D * mEnergyFlowHist
 
TH1D * mParticleCountHist
 
std::set< Int_t > mEnergyFlowPdgCodes
 

Static Private Attributes

static EicEventGeneratormInstance = 0
 

Friends

class EicEventGeneratorTask
 

Additional Inherited Members

- Public Attributes inherited from EicProtoGenerator
double mVerticalBeamDivergence
 
double mHorizontalBeamDivergence
 
double mHorizontalBeamRotation
 
Double_t mCoord [3]
 
Double_t mCoordSigma [3]
 
Double_t mCoordRange [3]
 
Bool_t mGaussianCoordinateSmearing
 

Detailed Description

Definition at line 142 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 142 of file EicEventGenerator.h

Constructor & Destructor Documentation

EicEventGenerator::EicEventGenerator ( TString  fileName = "")

Default constructor without arguments should not be used. Standard constructor.

Parameters
fileNameThe input file name

Definition at line 195 of file EicEventGenerator.cxx.

View newest version in sPHENIX GitHub at line 195 of file EicEventGenerator.cxx

References _EIC_GENERATOR_EVENT_BRANCH_, _EIC_GENERATOR_TREE_, mGeneratorEvent, mInputTree, mInstance, mMappingTable, mPoacher, and ResetVars().

+ Here is the call graph for this function:

virtual EicEventGenerator::~EicEventGenerator ( )
inlinevirtual

Destructor.

Definition at line 156 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 156 of file EicEventGenerator.h

Member Function Documentation

void EicEventGenerator::AddEnergyFlowPdgCode ( int  pdg)
inline

Definition at line 187 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 187 of file EicEventGenerator.h

References mEnergyFlowPdgCodes.

void EicEventGenerator::BuildEnergyFlowPlot ( int  etaBinNum,
double  etaMin,
double  etaMax 
)
inline

Definition at line 175 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 175 of file EicEventGenerator.h

References mEnergyFlowHist, mEtaBinWidth, and mParticleCountHist.

EicEventGenerator::ClassDef ( EicEventGenerator  ,
22   
)
private
const TChain* EicEventGenerator::GetInputTree ( ) const
inline

Definition at line 195 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 195 of file EicEventGenerator.h

Referenced by FluxMonitorGrid::FillOutHistograms().

+ Here is the caller graph for this function:

static EicEventGenerator* EicEventGenerator::Instance ( )
inlinestatic

Definition at line 159 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 159 of file EicEventGenerator.h

References mInstance.

Referenced by FluxMonitorGrid::FillOutHistograms(), and EicEventGeneratorTask::FinishTask().

+ Here is the caller graph for this function:

Bool_t EicEventGenerator::ReadEvent ( FairPrimaryGenerator primGen)
virtual

Reads on event from the input file and pushes the tracks onto the stack. Abstract method in base class.

Parameters
primGenpointer to the FairPrimaryGenerator

Implements FairGenerator.

Definition at line 259 of file EicEventGenerator.cxx.

View newest version in sPHENIX GitHub at line 259 of file EicEventGenerator.cxx

References _EIC_GENERATOR_EVENT_BRANCH_, _EIC_GENERATOR_TREE_, _EIC_MAPPING_BRANCH_, FairRun::AddTask(), FairPrimaryGenerator::AddTrack(), EicEventGeneratorTask, Poacher::EventName(), erhic::VirtualParticle::GetE(), erhic::VirtualParticle::GetEta(), erhic::VirtualParticle::GetM(), EicProtoGenerator::GetModifiedTrack(), Poacher::GetNextEvent(), erhic::VirtualEvent::GetNTracks(), erhic::VirtualParticle::GetP(), erhic::VirtualParticle::GetParentIndex(), erhic::VirtualParticle::GetPx(), erhic::VirtualParticle::GetPy(), erhic::VirtualParticle::GetPz(), EicProtoGenerator::GetSimulatedPrimaryVertex(), erhic::VirtualParticle::GetStatus(), erhic::VirtualEvent::GetTrack(), erhic::VirtualParticle::GetVertex(), erhic::VirtualParticle::Id(), FairRunSim::Instance(), ParticleMappingTable::mData, mEnergyFlowHist, mEnergyFlowPdgCodes, mEventChunkSize, mEventCounter, mGeneratorEvent, mInputTree, mInputTreeNextEventId, mMappingTable, mParticleCountHist, mPoacher, mSelectedLeadingParticlePmin, mSelectedPdgCodes, mSelectLeadingParticle, printf(), and vtx().

+ Here is the call graph for this function:

void EicEventGenerator::ResetVars ( )
inlineprivate

Definition at line 227 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 227 of file EicEventGenerator.h

References mEnergyFlowHist, mEtaBinWidth, mEventChunkSize, mEventCounter, mGeneratorEvent, mInputTree, mInputTreeNextEventId, mMappingTable, mParticleCountHist, mPoacher, mSelectedLeadingParticlePmin, and mSelectLeadingParticle.

Referenced by EicEventGenerator().

+ Here is the caller graph for this function:

void EicEventGenerator::RestrictEventChunkSize ( unsigned  nEvents)
inline

Definition at line 165 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 165 of file EicEventGenerator.h

References mEventChunkSize, and nEvents.

Referenced by simulation().

+ Here is the caller graph for this function:

void EicEventGenerator::SelectLeadingParticle ( double  pmin = 0.0)
inline

Definition at line 170 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 170 of file EicEventGenerator.h

References mSelectedLeadingParticlePmin, and mSelectLeadingParticle.

Referenced by simulation().

+ Here is the caller graph for this function:

void EicEventGenerator::SelectPdgCode ( int  pdg)
inline

Definition at line 169 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 169 of file EicEventGenerator.h

References mSelectedPdgCodes.

Referenced by simulation().

+ Here is the caller graph for this function:

int EicEventGenerator::SkipFewEvents ( unsigned  eventsToSkip)

Definition at line 238 of file EicEventGenerator.cxx.

View newest version in sPHENIX GitHub at line 238 of file EicEventGenerator.cxx

References Poacher::GetNextEvent(), mInputTree, mInputTreeNextEventId, and mPoacher.

Referenced by simulation().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Friends And Related Function Documentation

friend class EicEventGeneratorTask
friend

Definition at line 144 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 144 of file EicEventGenerator.h

Referenced by ReadEvent().

Member Data Documentation

TH1D* EicEventGenerator::mEnergyFlowHist
private

Definition at line 223 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 223 of file EicEventGenerator.h

Referenced by BuildEnergyFlowPlot(), EicEventGeneratorTask::FinishTask(), ReadEvent(), and ResetVars().

std::set<Int_t> EicEventGenerator::mEnergyFlowPdgCodes
private

Definition at line 225 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 225 of file EicEventGenerator.h

Referenced by AddEnergyFlowPdgCode(), and ReadEvent().

double EicEventGenerator::mEtaBinWidth
private

Definition at line 222 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 222 of file EicEventGenerator.h

Referenced by BuildEnergyFlowPlot(), EicEventGeneratorTask::FinishTask(), and ResetVars().

UInt_t EicEventGenerator::mEventChunkSize
private

Definition at line 219 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 219 of file EicEventGenerator.h

Referenced by ReadEvent(), ResetVars(), and RestrictEventChunkSize().

UInt_t EicEventGenerator::mEventCounter
private

Definition at line 220 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 220 of file EicEventGenerator.h

Referenced by EicEventGeneratorTask::FinishTask(), ReadEvent(), and ResetVars().

erhic::VirtualEvent* EicEventGenerator::mGeneratorEvent
private

Definition at line 203 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 203 of file EicEventGenerator.h

Referenced by EicEventGenerator(), ReadEvent(), and ResetVars().

TChain* EicEventGenerator::mInputTree
private

Definition at line 201 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 201 of file EicEventGenerator.h

Referenced by EicEventGenerator(), ReadEvent(), ResetVars(), and SkipFewEvents().

unsigned EicEventGenerator::mInputTreeNextEventId
private

Definition at line 202 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 202 of file EicEventGenerator.h

Referenced by ReadEvent(), ResetVars(), and SkipFewEvents().

EicEventGenerator * EicEventGenerator::mInstance = 0
staticprivate

Definition at line 195 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 195 of file EicEventGenerator.h

Referenced by EicEventGenerator(), and Instance().

ParticleMappingTable* EicEventGenerator::mMappingTable
private

Definition at line 208 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 208 of file EicEventGenerator.h

Referenced by EicEventGenerator(), ReadEvent(), and ResetVars().

TH1D* EicEventGenerator::mParticleCountHist
private

Definition at line 224 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 224 of file EicEventGenerator.h

Referenced by BuildEnergyFlowPlot(), EicEventGeneratorTask::FinishTask(), ReadEvent(), and ResetVars().

Poacher* EicEventGenerator::mPoacher
private

singelton instance

Definition at line 200 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 200 of file EicEventGenerator.h

Referenced by EicEventGenerator(), ReadEvent(), ResetVars(), and SkipFewEvents().

Double_t EicEventGenerator::mSelectedLeadingParticlePmin
private

Definition at line 211 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 211 of file EicEventGenerator.h

Referenced by ReadEvent(), ResetVars(), and SelectLeadingParticle().

std::set<Int_t> EicEventGenerator::mSelectedPdgCodes
private

Definition at line 212 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 212 of file EicEventGenerator.h

Referenced by ReadEvent(), and SelectPdgCode().

Bool_t EicEventGenerator::mSelectLeadingParticle
private

Definition at line 210 of file EicEventGenerator.h.

View newest version in sPHENIX GitHub at line 210 of file EicEventGenerator.h

Referenced by ReadEvent(), ResetVars(), and SelectLeadingParticle().


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