Changes in / [3b99510:cb46568] in git
- Files:
-
- 4 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
Makefile
r3b99510 rcb46568 316 316 modules/EnergySmearing.h \ 317 317 modules/MomentumSmearing.h \ 318 modules/TrackSmearing.h \ 318 319 modules/ImpactParameterSmearing.h \ 319 320 modules/TimeSmearing.h \ … … 338 339 modules/StatusPidFilter.h \ 339 340 modules/PdgCodeFilter.h \ 341 modules/BeamSpotFilter.h \ 340 342 modules/Cloner.h \ 341 343 modules/Weighter.h \ … … 546 548 classes/DelphesFactory.h \ 547 549 classes/DelphesFormula.h 550 tmp/modules/BeamSpotFilter.$(ObjSuf): \ 551 modules/BeamSpotFilter.$(SrcSuf) \ 552 modules/BeamSpotFilter.h \ 553 classes/DelphesClasses.h \ 554 classes/DelphesFactory.h \ 555 classes/DelphesFormula.h \ 556 external/ExRootAnalysis/ExRootResult.h \ 557 external/ExRootAnalysis/ExRootFilter.h \ 558 external/ExRootAnalysis/ExRootClassifier.h 548 559 tmp/modules/Calorimeter.$(ObjSuf): \ 549 560 modules/Calorimeter.$(SrcSuf) \ … … 830 841 modules/TrackPileUpSubtractor.$(SrcSuf) \ 831 842 modules/TrackPileUpSubtractor.h \ 843 classes/DelphesClasses.h \ 844 classes/DelphesFactory.h \ 845 classes/DelphesFormula.h \ 846 external/ExRootAnalysis/ExRootResult.h \ 847 external/ExRootAnalysis/ExRootFilter.h \ 848 external/ExRootAnalysis/ExRootClassifier.h 849 tmp/modules/TrackSmearing.$(ObjSuf): \ 850 modules/TrackSmearing.$(SrcSuf) \ 851 modules/TrackSmearing.h \ 832 852 classes/DelphesClasses.h \ 833 853 classes/DelphesFactory.h \ … … 915 935 tmp/modules/AngularSmearing.$(ObjSuf) \ 916 936 tmp/modules/BTagging.$(ObjSuf) \ 937 tmp/modules/BeamSpotFilter.$(ObjSuf) \ 917 938 tmp/modules/Calorimeter.$(ObjSuf) \ 918 939 tmp/modules/Cloner.$(ObjSuf) \ … … 946 967 tmp/modules/TrackCountingTauTagging.$(ObjSuf) \ 947 968 tmp/modules/TrackPileUpSubtractor.$(ObjSuf) \ 969 tmp/modules/TrackSmearing.$(ObjSuf) \ 948 970 tmp/modules/TreeWriter.$(ObjSuf) \ 949 971 tmp/modules/UniqueObjectFinder.$(ObjSuf) \ … … 1545 1567 tmp/external/tcl/tclVar.$(ObjSuf) 1546 1568 1569 modules/TrackSmearing.h: \ 1570 classes/DelphesModule.h 1571 @touch $@ 1572 1547 1573 external/fastjet/ClusterSequence.hh: \ 1548 1574 external/fastjet/PseudoJet.hh \ … … 1977 2003 1978 2004 modules/FastJetFinder.h: \ 2005 classes/DelphesModule.h 2006 @touch $@ 2007 2008 modules/BeamSpotFilter.h: \ 1979 2009 classes/DelphesModule.h 1980 2010 @touch $@ -
classes/DelphesClasses.cc
r3b99510 rcb46568 127 127 Momentum(0.0, 0.0, 0.0, 0.0), 128 128 Position(0.0, 0.0, 0.0, 0.0), 129 InitialPosition(0.0, 0.0, 0.0, 0.0), 129 130 Area(0.0, 0.0, 0.0, 0.0), 130 Dxy(0), SDxy(0), Xd(0), Yd(0), Zd(0), 131 L(0), 132 D0(0), ErrorD0(0), 133 DZ(0), ErrorDZ(0), 134 P(0), ErrorP(0), 135 PT(0), ErrorPT(0), 136 CtgTheta(0), ErrorCtgTheta(0), 137 Phi(0), ErrorPhi(0), 138 Xd(0), Yd(0), Zd(0), 131 139 TrackResolution(0), 132 140 NCharged(0), … … 262 270 object.Momentum = Momentum; 263 271 object.Position = Position; 272 object.InitialPosition = Position; 264 273 object.Area = Area; 265 object.Dxy = Dxy; 266 object.SDxy = SDxy; 274 object.L = L; 275 object.D0 = D0; 276 object.ErrorD0 = ErrorD0; 277 object.DZ = DZ; 278 object.ErrorDZ = ErrorDZ; 279 object.P = P; 280 object.ErrorP = ErrorP; 281 object.PT = PT; 282 object.ErrorPT = ErrorPT; 283 object.CtgTheta = CtgTheta ; 284 object.ErrorCtgTheta = ErrorCtgTheta; 285 object.Phi = Phi; 286 object.ErrorPhi = ErrorPhi; 267 287 object.Xd = Xd; 268 288 object.Yd = Yd; … … 363 383 Momentum.SetXYZT(0.0, 0.0, 0.0, 0.0); 364 384 Position.SetXYZT(0.0, 0.0, 0.0, 0.0); 385 InitialPosition.SetXYZT(0.0, 0.0, 0.0, 0.0); 365 386 Area.SetXYZT(0.0, 0.0, 0.0, 0.0); 366 Dxy = 0.0; 367 SDxy = 0.0; 387 L = 0.0; 388 D0 = 0.0; 389 ErrorD0 = 0.0; 390 DZ = 0.0; 391 ErrorDZ = 0.0; 392 P =0.0; 393 ErrorP =0.0; 394 PT = 0.0; 395 ErrorPT = 0.0; 396 CtgTheta = 0.0; 397 ErrorCtgTheta = 0.0; 398 Phi = 0.0; 399 ErrorPhi = 0.0; 368 400 Xd = 0.0; 369 401 Yd = 0.0; -
classes/DelphesClasses.h
r3b99510 rcb46568 415 415 Float_t TOuter; // track position (z component) at the tracker edge 416 416 417 Float_t D xy; // track signed transverse impact parameter418 Float_t SDxy; // signed error on the track signed transverse impact parameter417 Float_t D0; // track signed transverse impact parameter 418 Float_t ErrorD0; // signed error on the track signed transverse impact parameter 419 419 Float_t Xd; // X coordinate of point of closest approach to vertex 420 420 Float_t Yd; // Y coordinate of point of closest approach to vertex … … 526 526 Float_t DeltaPhi; 527 527 528 TLorentzVector Momentum, Position, Area; 529 530 Float_t Dxy; 531 Float_t SDxy; 528 TLorentzVector Momentum, Position, InitialPosition, Area; 529 530 Float_t L; // path length 531 Float_t D0; 532 Float_t ErrorD0; 533 Float_t DZ; 534 Float_t ErrorDZ; 535 Float_t P; 536 Float_t ErrorP; 537 Float_t PT; 538 Float_t ErrorPT; 539 Float_t CtgTheta; 540 Float_t ErrorCtgTheta; 541 Float_t Phi; 542 Float_t ErrorPhi; 543 532 544 Float_t Xd; 533 545 Float_t Yd; -
modules/ImpactParameterSmearing.cc
r3b99510 rcb46568 96 96 { 97 97 Candidate *candidate, *particle, *mother; 98 Double_t xd, yd, zd, d xy, sx, sy, sz, ddxy;98 Double_t xd, yd, zd, d0, sx, sy, sz, dd0; 99 99 Double_t pt, eta, px, py, phi, e; 100 100 … … 103 103 { 104 104 105 // take momentum before smearing (otherwise apply double smearing on d xy)105 // take momentum before smearing (otherwise apply double smearing on d0) 106 106 particle = static_cast<Candidate*>(candidate->GetCandidates()->At(0)); 107 107 … … 131 131 132 132 // calculate impact parameter (after-smearing) 133 d xy= (xd*py - yd*px)/pt;133 d0 = (xd*py - yd*px)/pt; 134 134 135 dd xy= gRandom->Gaus(0.0, fFormula->Eval(pt, eta, phi, e));135 dd0 = gRandom->Gaus(0.0, fFormula->Eval(pt, eta, phi, e)); 136 136 137 137 // fill smeared values in candidate … … 143 143 candidate->Zd = zd; 144 144 145 candidate->D xy = dxy;146 candidate-> SDxy = ddxy;145 candidate->D0 = d0; 146 candidate->ErrorD0 = dd0; 147 147 148 148 candidate->AddCandidate(mother); -
modules/ModulesLinkDef.h
r3b99510 rcb46568 35 35 #include "modules/EnergySmearing.h" 36 36 #include "modules/MomentumSmearing.h" 37 #include "modules/TrackSmearing.h" 37 38 #include "modules/ImpactParameterSmearing.h" 38 39 #include "modules/TimeSmearing.h" … … 57 58 #include "modules/StatusPidFilter.h" 58 59 #include "modules/PdgCodeFilter.h" 60 #include "modules/BeamSpotFilter.h" 59 61 #include "modules/Cloner.h" 60 62 #include "modules/Weighter.h" … … 79 81 #pragma link C++ class EnergySmearing+; 80 82 #pragma link C++ class MomentumSmearing+; 83 #pragma link C++ class TrackSmearing+; 81 84 #pragma link C++ class ImpactParameterSmearing+; 82 85 #pragma link C++ class TimeSmearing+; … … 101 104 #pragma link C++ class StatusPidFilter+; 102 105 #pragma link C++ class PdgCodeFilter+; 106 #pragma link C++ class BeamSpotFilter+; 103 107 #pragma link C++ class Cloner+; 104 108 #pragma link C++ class Weighter+; -
modules/ParticlePropagator.cc
r3b99510 rcb46568 66 66 { 67 67 } 68 68 69 69 70 //------------------------------------------------------------------------------ … … 91 92 fItInputArray = fInputArray->MakeIterator(); 92 93 94 // import beamspot 95 96 fBeamSpotInputArray = ImportArray(GetString("BeamSpotInputArray", "BeamSpotFilter/beamSpotParticle")); 97 93 98 // create output arrays 94 99 … … 111 116 { 112 117 Candidate *candidate, *mother; 113 TLorentzVector candidatePosition, candidateMomentum ;118 TLorentzVector candidatePosition, candidateMomentum, beamSpotPosition; 114 119 Double_t px, py, pz, pt, pt2, e, q; 115 120 Double_t x, y, z, t, r, phi; … … 120 125 Double_t tmp, discr, discr2; 121 126 Double_t delta, gammam, omega, asinrho; 122 Double_t rcu, rc2, dxy, xd, yd, zd; 123 127 Double_t rcu, rc2, xd, yd, zd; 128 Double_t l, d0, dz, p, ctgTheta, phip, etap, alpha; 129 Double_t bsx, bsy, bsz; 130 124 131 const Double_t c_light = 2.99792458E8; 125 132 133 if (!fBeamSpotInputArray->GetSize () || !fBeamSpotInputArray->At(0)) 134 beamSpotPosition.SetXYZT(0.0, 0.0, 0.0, 0.0); 135 else 136 { 137 Candidate &beamSpotCandidate = *((Candidate *) fBeamSpotInputArray->At(0)); 138 beamSpotPosition = beamSpotCandidate.Position; 139 } 140 126 141 fItInputArray->Reset(); 127 142 while((candidate = static_cast<Candidate*>(fItInputArray->Next()))) … … 132 147 y = candidatePosition.Y()*1.0E-3; 133 148 z = candidatePosition.Z()*1.0E-3; 149 150 bsx = beamSpotPosition.X()*1.0E-3; 151 bsy = beamSpotPosition.Y()*1.0E-3; 152 bsz = beamSpotPosition.Z()*1.0E-3; 153 134 154 q = candidate->Charge; 135 155 … … 181 201 y_t = y + py*t; 182 202 z_t = z + pz*t; 203 204 l = TMath::Sqrt( (x_t - x)*(x_t - x) + (y_t - y)*(y_t - y) + (z_t - z)*(z_t - z)); 183 205 184 206 mother = candidate; … … 186 208 187 209 candidate->Position.SetXYZT(x_t*1.0E3, y_t*1.0E3, z_t*1.0E3, candidatePosition.T() + t*e*1.0E3); 188 210 candidate->L = l*1.0E3; 211 189 212 candidate->Momentum = candidateMomentum; 190 213 candidate->AddCandidate(mother); … … 238 261 yd = (rc2 > 0.0) ? yd / rc2 : -999; 239 262 zd = z + (TMath::Sqrt(xd*xd + yd*yd) - TMath::Sqrt(x*x + y*y))*pz/pt; 240 241 // calculate impact paramater 242 dxy = (xd*py - yd*px)/pt; 243 263 264 // use perigee momentum rather than original particle 265 // momentum, since the orignal particle momentum isn't known 266 267 px = TMath::Sign(1.0,r) * pt * (-y_c / r_c); 268 py = TMath::Sign(1.0,r) * pt * (x_c / r_c); 269 etap = candidateMomentum.Eta(); 270 phip = TMath::ATan2(py, px); 271 272 candidateMomentum.SetPtEtaPhiE(pt, etap, phip, candidateMomentum.E()); 273 274 // calculate additional track parameters (correct for beamspot position) 275 276 d0 = ( (x - bsx) * py - (y - bsy) * px) / pt; 277 dz = z - ((x - bsx) * px + (py - bsy) * py) / pt * (pz / pt); 278 p = candidateMomentum.P(); 279 ctgTheta = 1.0 / TMath::Tan (candidateMomentum.Theta ()); 280 244 281 // 3. time evaluation t = TMath::Min(t_r, t_z) 245 282 // t_r : time to exit from the sides … … 287 324 r_t = TMath::Hypot(x_t, y_t); 288 325 326 327 // compute path length for an helix 328 329 alpha = pz*1.0E9 / c_light / gammam; 330 l = t * TMath::Sqrt(alpha*alpha + r*r*omega*omega); 331 289 332 if(r_t > 0.0) 290 333 { … … 295 338 296 339 candidate->Momentum = candidateMomentum; 297 candidate->Dxy = dxy*1.0E3; 298 candidate->Xd = xd*1.0E3; 340 341 candidate->L = l*1.0E3; 342 candidate->D0 = d0*1.0E3; 343 candidate->DZ = dz*1.0E3; 344 candidate->P = p; 345 candidate->PT = pt; 346 candidate->CtgTheta = ctgTheta; 347 candidate->Phi = phi; 348 349 candidate->Xd = xd*1.0E3; 299 350 candidate->Yd = yd*1.0E3; 300 351 candidate->Zd = zd*1.0E3; -
modules/ParticlePropagator.h
r3b99510 rcb46568 35 35 class TClonesArray; 36 36 class TIterator; 37 class TLorentzVector; 37 38 38 39 class ParticlePropagator: public DelphesModule … … 55 56 56 57 const TObjArray *fInputArray; //! 58 const TObjArray *fBeamSpotInputArray; //! 57 59 58 60 TObjArray *fOutputArray; //! -
modules/TrackCountingBTagging.cc
r3b99510 rcb46568 96 96 97 97 Double_t jpx, jpy; 98 Double_t dr, tp x, tpy, tpt;99 Double_t xd, yd, d xy, ddxy, ip, sip;98 Double_t dr, tpt; 99 Double_t xd, yd, d0, dd0, ip, sip; 100 100 101 101 Int_t sign; … … 117 117 { 118 118 const TLorentzVector &trkMomentum = track->Momentum; 119 119 120 120 dr = jetMomentum.DeltaR(trkMomentum); 121 122 121 tpt = trkMomentum.Pt(); 123 tpx = trkMomentum.Px();124 tpy = trkMomentum.Py();125 126 122 xd = track->Xd; 127 123 yd = track->Yd; 128 d xy= TMath::Hypot(xd, yd);129 dd xy = track->SDxy;124 d0 = TMath::Hypot(xd, yd); 125 dd0 = track->ErrorD0; 130 126 131 127 if(tpt < fPtMin) continue; 132 128 if(dr > fDeltaR) continue; 133 if(d xy> fIPmax) continue;129 if(d0 > fIPmax) continue; 134 130 135 131 sign = (jpx*xd + jpy*yd > 0.0) ? 1 : -1; 136 132 137 ip = sign*d xy;138 sip = ip / TMath::Abs(dd xy);133 ip = sign*d0; 134 sip = ip / TMath::Abs(dd0); 139 135 140 136 if(sip > fSigMin) count++; -
modules/TreeWriter.cc
r3b99510 rcb46568 292 292 entry->TOuter = position.T()*1.0E-3/c_light; 293 293 294 entry->D xy = candidate->Dxy;295 entry-> SDxy = candidate->SDxy;294 entry->D0 = candidate->D0; 295 entry->ErrorD0 = candidate->ErrorD0 ; 296 296 entry->Xd = candidate->Xd; 297 297 entry->Yd = candidate->Yd;
Note:
See TracChangeset
for help on using the changeset viewer.