1 #include "StMuDSTMaker/COMMON/StMuTrack.h"
2 #include "StGammaPythiaEvent.h"
4 #include "StGammaEvent.h"
11 StGammaEvent::StGammaEvent()
16 , mMagneticField(1956)
20 , mSpin4(kUnknownSpin4)
21 , mBunchCrossing7bit(255)
22 , mBunchCrossing48bit(255)
23 , mBunchCrossingStar(255)
24 , mPolarizationType(kUnknownPol)
42 StGammaEvent::~StGammaEvent()
44 delete mTracks; mTracks = 0;
45 delete mTowers; mTowers = 0;
46 delete mPreshower1; mPreshower1 = 0;
47 delete mPreshower2; mPreshower2 = 0;
48 delete mPostshower; mPostshower = 0;
49 delete mStrips; mStrips = 0;
50 delete mCandidates; mCandidates = 0;
56 void StGammaEvent::Clear(Option_t *opts)
75 mSpin4 = kUnknownSpin4;
76 mBunchCrossing7bit = 255;
77 mBunchCrossing48bit = 255;
78 mBunchCrossingStar = 255;
79 mPolarizationType = kUnknownPol;
89 Int_t StGammaEvent::InitArrays()
91 if (!mTracks) mTracks =
new TClonesArray(
"StGammaTrack", 1000);
92 if (!mTowers) mTowers =
new TClonesArray(
"StGammaTower", 4800 + 720);
93 if (!mPreshower1)mPreshower1 =
new TClonesArray(
"StGammaTower", 4800 + 720);
94 if (!mPreshower2)mPreshower2 =
new TClonesArray(
"StGammaTower", 720);
95 if (!mPostshower)mPostshower =
new TClonesArray(
"StGammaTower", 720);
96 if (!mStrips) mStrips =
new TClonesArray(
"StGammaStrip", 10000);
97 if (!mCandidates)mCandidates =
new TClonesArray(
"StGammaCandidate", 10);
108 TClonesArray &tracks = *mTracks;
111 if(mutr) track =
new( tracks[tracks.GetEntriesFast()] )
StGammaTrack(mutr);
112 else track =
new( tracks[tracks.GetEntriesFast()] )
StGammaTrack;
120 TClonesArray &towers = *mTowers;
148 TClonesArray &strips = *mStrips;
155 TClonesArray &candidates = *mCandidates;
164 Float_t StGammaEvent::sumPt(Float_t eta_min, Float_t eta_max)
const
177 for(Int_t i = 0; i < numberOfTracks(); i++)
180 if(t->
eta() < eta_min || t->
eta() > eta_max)
continue;
199 if(t->fail)
continue;
200 if(t->eta < eta_min || t->eta > eta_max)
continue;
Float_t sumTrackPt(Float_t eta_min=-2.5, Float_t eta_max=+2.5) const
Returns track+tower pT in eta range.
StGammaPythiaEvent * mPythia
Magnetic field (kG)
Float_t sumTowerPt(Float_t eta_min=-2.5, Float_t eta_max=+2.5) const
Returns track pT in eta range.
StGammaTower * newPostshower()
Add a new preshower2 element.
StGammaTower * tower(Int_t i) const
Return ith track.
StGammaTower * preshower1(Int_t i) const
Return ith tower.
StGammaTower * newPreshower1()
Add a new tower.
StGammaTower * newTower()
Add a new track.
StGammaStrip * strip(Int_t i) const
Return ith post.
StGammaTower * newPreshower2()
Add a new preshower1 (bprs) element.
StGammaTrack * newTrack(StMuTrack *mutr=0)
Returns tower pT in eta range.
StGammaCandidate * newCandidate()
Add a new SMD strip.
StGammaStrip * newStrip()
Add a new postshower element.
set< int > mSimuTriggerIds
Trigger ID's.
set< int > mTriggerIds
Event number.
StGammaTrack * track(Int_t i) const
Return number of candidates.
Float_t pt() const
Referencing candidates.
TVector3 mVertex
File from which StGammaEvent originatedt.
StGammaTower * preshower2(Int_t i) const
Return ith pre1.
StGammaTower * postshower(Int_t i) const
Return ith pre2.
Int_t mEventNumber
Run number.
Int_t numberOfTowers() const
Return number of tracks.
StGammaCandidate * candidate(Int_t i) const
Return ith strip.
Float_t eta() const
pz at vertex