Changes in / [7967061:0852ba95] in git
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
classes/DelphesClasses.cc
r7967061 r0852ba95 108 108 //------------------------------------------------------------------------------ 109 109 110 TMatrixDSym Track::CovarianceMatrix() const 111 { 112 TMatrixDSym Cv; 113 Cv.ResizeTo(5, 5); 114 115 // convert diagonal term to original units 116 Cv(0, 0)=TMath::Power(ErrorD0*1.0E-3, 2.); 117 Cv(1, 1)=TMath::Power(ErrorPhi, 2.); 118 Cv(2, 2)=TMath::Power(ErrorC*1.0E-3, 2.); 119 Cv(3, 3)=TMath::Power(ErrorDZ*1.0E-3, 2.); 120 Cv(4, 4)=TMath::Power(ErrorCtgTheta, 2.); 121 122 // off diagonal terms 123 Cv(0, 1)=ErrorD0Phi; 124 Cv(0, 2)=ErrorD0C; 125 Cv(0, 3)=ErrorD0DZ; 126 Cv(0, 4)=ErrorD0CtgTheta; 127 Cv(1, 2)=ErrorPhiC; 128 Cv(1, 3)=ErrorPhiDZ; 129 Cv(1, 4)=ErrorPhiCtgTheta; 130 Cv(2, 3)=ErrorCDZ; 131 Cv(2, 4)=ErrorCCtgTheta; 132 Cv(3, 4)=ErrorDZCtgTheta; 133 134 Cv(1, 0)=Cv(0, 1); 135 Cv(2, 0)=Cv(0, 2); 136 Cv(3, 0)=Cv(0, 3); 137 Cv(4, 0)=Cv(0, 4); 138 Cv(2, 1)=Cv(1, 2); 139 Cv(3, 1)=Cv(1, 3); 140 Cv(4, 1)=Cv(1, 4); 141 Cv(3, 2)=Cv(2, 3); 142 Cv(4, 2)=Cv(2, 4); 143 Cv(4, 3)=Cv(3, 4); 144 145 return Cv; 146 } 147 148 149 //------------------------------------------------------------------------------ 150 110 151 TLorentzVector Tower::P4() const 111 152 { … … 122 163 vec.SetPtEtaPhiM(PT, Eta, Phi, 0.0); 123 164 return vec; 165 } 166 167 //------------------------------------------------------------------------------ 168 169 TMatrixDSym ParticleFlowCandidate::CovarianceMatrix() const 170 { 171 TMatrixDSym Cv; 172 Cv.ResizeTo(5, 5); 173 174 // convert diagonal term to original units 175 Cv(0, 0)=TMath::Power(ErrorD0*1.0E-3, 2.); 176 Cv(1, 1)=TMath::Power(ErrorPhi, 2.); 177 Cv(2, 2)=TMath::Power(ErrorC*1.0E-3, 2.); 178 Cv(3, 3)=TMath::Power(ErrorDZ*1.0E-3, 2.); 179 Cv(4, 4)=TMath::Power(ErrorCtgTheta, 2.); 180 181 // off diagonal terms 182 Cv(0, 1)=ErrorD0Phi; 183 Cv(0, 2)=ErrorD0C; 184 Cv(0, 3)=ErrorD0DZ; 185 Cv(0, 4)=ErrorD0CtgTheta; 186 Cv(1, 2)=ErrorPhiC; 187 Cv(1, 3)=ErrorPhiDZ; 188 Cv(1, 4)=ErrorPhiCtgTheta; 189 Cv(2, 3)=ErrorCDZ; 190 Cv(2, 4)=ErrorCCtgTheta; 191 Cv(3, 4)=ErrorDZCtgTheta; 192 193 Cv(1, 0)=Cv(0, 1); 194 Cv(2, 0)=Cv(0, 2); 195 Cv(3, 0)=Cv(0, 3); 196 Cv(4, 0)=Cv(0, 4); 197 Cv(2, 1)=Cv(1, 2); 198 Cv(3, 1)=Cv(1, 3); 199 Cv(4, 1)=Cv(1, 4); 200 Cv(3, 2)=Cv(2, 3); 201 Cv(4, 2)=Cv(2, 4); 202 Cv(4, 3)=Cv(3, 4); 203 204 return Cv; 124 205 } 125 206 -
classes/DelphesClasses.h
r7967061 r0852ba95 473 473 Float_t ErrorD0; // track transverse impact parameter error 474 474 Float_t ErrorDZ; // track longitudinal impact parameter error 475 Float_t ErrorC; // track curvature error 476 477 // track covariance off-diagonal terms 478 Float_t ErrorD0Phi; 479 Float_t ErrorD0C; 480 Float_t ErrorD0DZ; 481 Float_t ErrorD0CtgTheta; 482 Float_t ErrorPhiC; 483 Float_t ErrorPhiDZ; 484 Float_t ErrorPhiCtgTheta ; 485 Float_t ErrorCDZ; 486 Float_t ErrorCCtgTheta; 487 Float_t ErrorDZCtgTheta; 475 488 476 489 TRef Particle; // reference to generated particle … … 482 495 483 496 TLorentzVector P4() const; 497 TMatrixDSym CovarianceMatrix() const; 484 498 485 499 ClassDef(Track, 3) … … 561 575 Float_t ErrorD0; // track transverse impact parameter error 562 576 Float_t ErrorDZ; // track longitudinal impact parameter error 577 Float_t ErrorC; // track curvature error 578 579 // track covariance off-diagonal terms 580 Float_t ErrorD0Phi; 581 Float_t ErrorD0C; 582 Float_t ErrorD0DZ; 583 Float_t ErrorD0CtgTheta; 584 Float_t ErrorPhiC; 585 Float_t ErrorPhiDZ; 586 Float_t ErrorPhiCtgTheta ; 587 Float_t ErrorCDZ; 588 Float_t ErrorCCtgTheta; 589 Float_t ErrorDZCtgTheta; 563 590 564 591 Int_t VertexIndex; // reference to vertex … … 568 595 569 596 TLorentzVector P4() const; 597 TMatrixDSym CovarianceMatrix() const; 570 598 571 599 Int_t NTimeHits; // number of hits contributing to time measurement … … 578 606 TRefArray Particles; // references to generated particles 579 607 580 ClassDef(ParticleFlowCandidate, 1)608 ClassDef(ParticleFlowCandidate, 2) 581 609 582 610 }; -
modules/TreeWriter.cc
r7967061 r0852ba95 348 348 349 349 entry->D0 = candidate->D0; 350 entry->ErrorD0 = candidate->ErrorD0;351 350 entry->DZ = candidate->DZ; 352 entry->ErrorDZ = candidate->ErrorDZ;353 351 354 352 entry->ErrorP = candidate->ErrorP; 355 353 entry->ErrorPT = candidate->ErrorPT; 354 355 // diagonal covariance matrix terms 356 entry->ErrorD0 = candidate->ErrorD0; 357 entry->ErrorC = candidate->ErrorC; 358 entry->ErrorPhi = candidate->ErrorPhi; 359 entry->ErrorDZ = candidate->ErrorDZ; 356 360 entry->ErrorCtgTheta = candidate->ErrorCtgTheta; 357 entry->ErrorPhi = candidate->ErrorPhi; 361 362 // add some offdiagonal covariance matrix elements 363 entry->ErrorD0Phi = candidate->TrackCovariance(0,1); 364 entry->ErrorD0C = candidate->TrackCovariance(0,2); 365 entry->ErrorD0DZ = candidate->TrackCovariance(0,3); 366 entry->ErrorD0CtgTheta = candidate->TrackCovariance(0,4); 367 entry->ErrorPhiC = candidate->TrackCovariance(1,2); 368 entry->ErrorPhiDZ = candidate->TrackCovariance(1,3); 369 entry->ErrorPhiCtgTheta = candidate->TrackCovariance(1,4); 370 entry->ErrorCDZ = candidate->TrackCovariance(2,3); 371 entry->ErrorCCtgTheta = candidate->TrackCovariance(2,4); 372 entry->ErrorDZCtgTheta = candidate->TrackCovariance(3,4); 358 373 359 374 entry->Xd = candidate->Xd; … … 482 497 483 498 entry->D0 = candidate->D0; 484 entry->ErrorD0 = candidate->ErrorD0;485 499 entry->DZ = candidate->DZ; 486 entry->ErrorDZ = candidate->ErrorDZ;487 500 488 501 entry->ErrorP = candidate->ErrorP; 489 502 entry->ErrorPT = candidate->ErrorPT; 490 503 entry->ErrorCtgTheta = candidate->ErrorCtgTheta; 504 505 506 // diagonal covariance matrix terms 507 508 entry->ErrorD0 = candidate->ErrorD0; 509 entry->ErrorC = candidate->ErrorC; 491 510 entry->ErrorPhi = candidate->ErrorPhi; 511 entry->ErrorDZ = candidate->ErrorDZ; 512 entry->ErrorCtgTheta = candidate->ErrorCtgTheta; 513 514 // add some offdiagonal covariance matrix elements 515 entry->ErrorD0Phi = candidate->TrackCovariance(0,1); 516 entry->ErrorD0C = candidate->TrackCovariance(0,2); 517 entry->ErrorD0DZ = candidate->TrackCovariance(0,3); 518 entry->ErrorD0CtgTheta = candidate->TrackCovariance(0,4); 519 entry->ErrorPhiC = candidate->TrackCovariance(1,2); 520 entry->ErrorPhiDZ = candidate->TrackCovariance(1,3); 521 entry->ErrorPhiCtgTheta = candidate->TrackCovariance(1,4); 522 entry->ErrorCDZ = candidate->TrackCovariance(2,3); 523 entry->ErrorCCtgTheta = candidate->TrackCovariance(2,4); 524 entry->ErrorDZCtgTheta = candidate->TrackCovariance(3,4); 525 526 cout<<entry->ErrorPhiC<<endl; 492 527 493 528 entry->Xd = candidate->Xd;
Note:
See TracChangeset
for help on using the changeset viewer.