- Timestamp:
- Jul 23, 2013, 1:14:48 AM (11 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- 0d5f77c
- Parents:
- 703d39c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
modules/Calorimeter.cc
r703d39c r9c6410e 431 431 Double_t energy, pt, eta, phi; 432 432 Double_t ecalEnergy, hcalEnergy; 433 TIterator *it erator;433 TIterator *itTowerTrackArray, *itTowerArray; 434 434 435 435 if(!fTower) return; … … 486 486 } 487 487 else if(fTowerTrackAllHits > 0 && 488 fTowerECalHits + fTowerHCalHits == fTowerAllHits && 489 (fTowerECalHits == fTowerECalTrackHits || fTowerHCalHits == fTowerHCalTrackHits)) 490 { 491 if(fTowerECalHits == fTowerECalTrackHits) 492 { 493 fItTowerECalTrackArray->Reset(); 494 while((track = static_cast<Candidate*>(fItTowerECalTrackArray->Next()))) 488 fTowerECalHits + fTowerHCalHits == fTowerAllHits) 489 { 490 if(fTowerECalHits == fTowerECalTrackHits && 491 fTowerHCalHits == fTowerHCalTrackHits) 492 { 493 itTowerTrackArray = fItTowerTrackArray; 494 itTowerArray = 0; 495 energy = 0.0; 496 } 497 else if(fTowerECalHits == fTowerECalTrackHits) 498 { 499 itTowerTrackArray = fItTowerECalTrackArray; 500 itTowerArray = fItTowerHCalArray; 501 energy = hcalEnergy; 502 } 503 else if(fTowerHCalHits == fTowerHCalTrackHits) 504 { 505 itTowerTrackArray = fItTowerHCalTrackArray; 506 itTowerArray = fItTowerECalArray; 507 energy = ecalEnergy; 508 } 509 else 510 { 511 itTowerTrackArray = 0; 512 itTowerArray = 0; 513 energy = 0.0; 514 fEFlowTowerOutputArray->Add(fTower); 515 } 516 517 if(itTowerTrackArray) 518 { 519 itTowerTrackArray->Reset(); 520 while((track = static_cast<Candidate*>(itTowerTrackArray->Next()))) 495 521 { 496 522 fEFlowTrackOutputArray->Add(track); 497 523 } 498 energy = hcalEnergy; 499 iterator = fItTowerHCalArray; 500 } 501 502 if(fTowerHCalHits == fTowerHCalTrackHits) 503 { 504 fItTowerHCalTrackArray->Reset(); 505 while((track = static_cast<Candidate*>(fItTowerHCalTrackArray->Next()))) 506 { 507 fEFlowTrackOutputArray->Add(track); 508 } 509 energy = ecalEnergy; 510 iterator = fItTowerECalArray; 511 } 512 513 if(fTowerECalHits == fTowerECalTrackHits && 514 fTowerHCalHits == fTowerHCalTrackHits) 515 { 516 energy = 0.0; 517 iterator = 0; 518 } 519 520 if(energy > 0.0 && iterator) 524 } 525 526 if(itTowerArray && energy > 0.0) 521 527 { 522 528 DelphesFactory *factory = GetFactory(); … … 525 531 tower = factory->NewCandidate(); 526 532 527 it erator->Reset();528 while((particle = static_cast<Candidate*>(it erator->Next())))533 itTowerArray->Reset(); 534 while((particle = static_cast<Candidate*>(itTowerArray->Next()))) 529 535 { 530 536 tower->AddCandidate(particle);
Note:
See TracChangeset
for help on using the changeset viewer.