Changeset 409 in svn for trunk/Utilities/ExRootAnalysis/src
- Timestamp:
- May 20, 2009, 10:48:41 AM (16 years ago)
- Location:
- trunk/Utilities/ExRootAnalysis/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Utilities/ExRootAnalysis/src/BlockClasses.cc
r387 r409 36 36 37 37 TCompare *TRootGenParticle::fgCompare = 0; 38 TCompare *TRootGenFwdParticle::fgCompare = 0; 38 39 TCompare *TRootC::GenParticle::fgCompare = 0; 39 40 TCompare *TRootElectron::fgCompare = TComparePT<TRootElectron>::Instance(); … … 63 64 } 64 65 66 void TRootGenFwdParticle::Set(const TLorentzVector& momentum) { 67 genE = momentum.E(); 68 genPx = momentum.Px(); 69 genPy = momentum.Py(); 70 genPz = momentum.Pz(); 71 genPT = momentum.Pt(); 72 genEta = momentum.Eta(); 73 genPhi = momentum.Phi(); 74 } 75 76 65 77 void TRootTauJet::Set(const TLorentzVector& momentum) { 66 78 … … 87 99 } 88 100 101 void TRootGenFwdParticle::Set(const float px, const float py, const float pz, const float e) { 102 TLorentzVector toFill; 103 toFill.SetPxPyPzE(px,py,pz,e); 104 genE = e; 105 genPx = px; 106 genPy = py; 107 genPz = pz; 108 genPT = toFill.Pt(); 109 genEta = toFill.Eta(); 110 genPhi = toFill.Phi(); 111 } 112 113 89 114 void TRootParticle::SetEtaPhiEET(const float eta, const float phi, const float e, const float et) { 90 115 Eta = eta; Phi = phi; E = e; PT = et; 91 116 //float theta = 2* atan(exp(-Eta); 92 Px = PT*cos(Phi); 93 Py = PT*sin(Phi); 117 Px = PT*cos(Phi); Py = PT*sin(Phi); 118 } 119 120 void TRootGenFwdParticle::SetEtaPhiEET(const float eta, const float phi, const float e, const float et) { 121 genEta = eta; genPhi = phi; genE = e; genPT = et; 122 genPx = genPT*cos(genPhi); genPy = genPT*sin(genPhi); 123 } 124 125 126 TRootGenFwdParticle::TRootGenFwdParticle(const TRootGenFwdParticle& p): 127 genE(p.genE), genPx(p.genPx), genPy(p.genPy), genPz(p.genPz), genPT(p.genPT), genEta(p.genEta), genPhi(p.genPhi) {} 128 129 TRootGenFwdParticle& TRootGenFwdParticle::operator=(const TRootGenFwdParticle& p){ 130 genE=p.genE; genPx=p.genPx; genPy=p.genPy; genPz=p.genPz; 131 genPT=p.genPT; genEta=p.genEta; genPhi=p.genPhi; 94 132 } 95 133 … … 198 236 } 199 237 200 /*TRootZdcHits::TRootZdcHits(const float e, const float t, const int side, const bool had) : E(e), T(t), side(side), hadronic_hit(had) {}238 TRootZdcHits::TRootZdcHits(const float e, const float t, const int side, const bool had) : E(e), T(t), side(side), hadronic_hit(had) {} 201 239 TRootZdcHits::TRootZdcHits(const TRootZdcHits& zdc) : E(zdc.E), T(zdc.T), side(zdc.side), hadronic_hit(zdc.hadronic_hit) {} 202 TRootZdcHits::TRootZdcHits(const TRootZdcHits& zdc) : T(zdc.T), side(zdc.side) {}203 240 TRootZdcHits& TRootZdcHits::operator=(const TRootZdcHits& zdc) { 204 241 if(this==&zdc) return *this; 205 //E = zdc.E; T = zdc.T; side = zdc.side; hadronic_hit = zdc.hadronic_hit; 206 T = zdc.T; side = zdc.side; 242 E = zdc.E; T = zdc.T; side = zdc.side; hadronic_hit = zdc.hadronic_hit; 207 243 return *this; 208 244 } 209 */ 245 210 246 211 247 void TRootGenParticle:: print(){ -
trunk/Utilities/ExRootAnalysis/src/BlockClassesLinkDef.h
r370 r409 42 42 #pragma link C++ class TRootSelectorInfo; 43 43 #pragma link C++ class TRootGenParticle; 44 #pragma link C++ class TRootGenFwdParticle; 44 45 #pragma link C++ class TRootC::GenParticle; 45 46 #pragma link C++ class TRootElectron;
Note:
See TracChangeset
for help on using the changeset viewer.