Fork me on GitHub

Changeset 1356 in svn for trunk


Ignore:
Timestamp:
Mar 9, 2014, 12:09:46 PM (11 years ago)
Author:
Michele Selvaggi
Message:

separated Photon and Neutral Hadron components in particle algorithm

Location:
trunk/modules
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/modules/Calorimeter.cc

    r1345 r1356  
    33 *
    44 *  Fills calorimeter towers, performs calorimeter resolution smearing,
    5  *  preselects towers hit by photons and creates energy flow objects.
     5 *  and creates energy flow objects (tracks, photons, and neutral hadrons).
    66 *
    77 *  $Date$
     
    149149  fTowerOutputArray = ExportArray(GetString("TowerOutputArray", "towers"));
    150150  fPhotonOutputArray = ExportArray(GetString("PhotonOutputArray", "photons"));
    151 
     151 
    152152  fEFlowTrackOutputArray = ExportArray(GetString("EFlowTrackOutputArray", "eflowTracks"));
    153   fEFlowTowerOutputArray = ExportArray(GetString("EFlowTowerOutputArray", "eflowTowers"));
     153  fEFlowPhotonOutputArray = ExportArray(GetString("EFlowPhotonOutputArray", "eflowPhotons"));
     154  fEFlowNeutralHadronOutputArray = ExportArray(GetString("EFlowNeutralHadronOutputArray", "eflowNeutralHadrons"));
     155
     156
    154157}
    155158
     
    341344      fTowerTrackHits = 0;
    342345      fTowerPhotonHits = 0;
    343 
     346     
    344347      fTowerTrackArray->Clear();
    345348    }
     
    371374      continue;
    372375    }
    373 
     376   
    374377    // check for photon and electron hits in current tower
    375378    if(flags & 2) ++fTowerPhotonHits;
    376 
     379   
    377380    particle = static_cast<Candidate*>(fParticleInputArray->At(number));
    378381    momentum = particle->Momentum;
     
    451454
    452455
    453   // fill calorimeter towers and photon candidates
     456  // fill calorimeter towers
    454457  if(energy > 0.0)
    455458  {
     
    458461      fPhotonOutputArray->Add(fTower);
    459462    }
    460 
     463   
    461464    fTowerOutputArray->Add(fTower);
    462465  }
     
    479482  energy = ecalEnergy + hcalEnergy;
    480483
     484 
    481485  // save ECAL and/or HCAL energy excess as an energy flow tower
    482   if(energy > 0.0)
    483   {
    484     // create new tower
     486  if(ecalEnergy > 0.0)
     487  {
     488    // create new photon tower
    485489    tower = static_cast<Candidate*>(fTower->Clone());
    486490
    487     pt = energy / TMath::CosH(eta);
    488 
    489     tower->Momentum.SetPtEtaPhiE(pt, eta, phi, energy);
     491    pt = ecalEnergy / TMath::CosH(eta);
     492
     493    tower->Momentum.SetPtEtaPhiE(pt, eta, phi, ecalEnergy);
    490494    tower->Eem = ecalEnergy;
     495    tower->Ehad = 0;
     496
     497    fEFlowPhotonOutputArray->Add(tower);
     498  }
     499
     500  if(hcalEnergy > 0.0)
     501  {
     502    // create new neutral hadron tower
     503    tower = static_cast<Candidate*>(fTower->Clone());
     504
     505    pt = hcalEnergy / TMath::CosH(eta);
     506
     507    tower->Momentum.SetPtEtaPhiE(pt, eta, phi, hcalEnergy);
     508    tower->Eem = 0;
    491509    tower->Ehad = hcalEnergy;
    492510
    493     fEFlowTowerOutputArray->Add(tower);
    494   }
     511    fEFlowNeutralHadronOutputArray->Add(tower);
     512  }
     513
     514
     515
     516
    495517}
    496518
  • trunk/modules/Calorimeter.h

    r1345 r1356  
    55 *
    66 *  Fills calorimeter towers, performs calorimeter resolution smearing,
    7  *  preselects towers hit by photons and creates energy flow objects.
     7 *  and creates energy flow objects (tracks, photons, and neutral hadrons).
    88 *
    99 *  $Date$
     
    7979  TObjArray *fTowerOutputArray; //!
    8080  TObjArray *fPhotonOutputArray; //!
    81 
     81 
    8282  TObjArray *fEFlowTrackOutputArray; //!
    83   TObjArray *fEFlowTowerOutputArray; //!
     83  TObjArray *fEFlowPhotonOutputArray; //!
     84  TObjArray *fEFlowNeutralHadronOutputArray; //!
    8485
    8586  TObjArray *fTowerTrackArray; //!
Note: See TracChangeset for help on using the changeset viewer.