CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
CalorimetryManager Class Reference

#include <CalorimetryManager.h>

Public Member Functions

 CalorimetryManager ()
 
 CalorimetryManager (FSimEvent *aSimEvent, const edm::ParameterSet &fastCalo, const edm::ParameterSet &MuonECALPars, const edm::ParameterSet &MuonHCALPars, const edm::ParameterSet &fastGflash, const RandomEngine *engine)
 
CaloGeometryHelpergetCalorimeter () const
 
void loadFromEcalBarrel (edm::PCaloHitContainer &c) const
 
void loadFromEcalEndcap (edm::PCaloHitContainer &c) const
 
void loadFromHcal (edm::PCaloHitContainer &c) const
 
void loadFromPreshower (edm::PCaloHitContainer &c) const
 
void loadMuonSimTracks (edm::SimTrackContainer &m) const
 
void reconstruct ()
 
 ~CalorimetryManager ()
 

Private Member Functions

void clean ()
 
void EMShowerSimulation (const FSimTrack &myTrack)
 
void HDShowerSimulation (const FSimTrack &myTrack)
 Hadronic Shower Simulation. More...
 
void MuonMipSimulation (const FSimTrack &myTrack)
 
void readParameters (const edm::ParameterSet &fastCalo)
 
void reconstructHCAL (const FSimTrack &myTrack)
 
void respCorr (double)
 
void updateECAL (const std::map< CaloHitID, float > &hitMap, int onEcal, int trackID=0, float corr=1.0)
 
void updateHCAL (const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
 
void updatePreshower (const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
 

Private Attributes

GammaFunctionGeneratoraGammaGenerator
 
const LandauFluctuationGeneratoraLandauGenerator
 
double aTerm
 
bool bFixedLength_
 
double bTerm
 
double crackPadSurvivalProbability_
 
DQMStoredbe
 
bool debug_
 
std::vector< std::pair
< CaloHitID, float > > 
EBMapping_
 
bool EcalDigitizer_
 
double ecorr
 
std::vector< std::pair
< CaloHitID, float > > 
EEMapping_
 
std::vector< std::pair
< CaloHitID, float > > 
ESMapping_
 
std::vector< unsigned int > evtsToDebug_
 
int gridSize_
 
bool HcalDigitizer_
 
double hcorr
 
int hdGridSize_
 
int hdSimMethod_
 
std::vector< std::pair
< CaloHitID, float > > 
HMapping_
 
int ietaShiftHB_
 
int ietaShiftHE_
 
int ietaShiftHF_
 
int ietaShiftHO_
 
bool initialized_
 
std::vector< double > k_e
 
std::vector< double > k_h
 
std::vector< double > mipValues_
 
std::vector< FSimTrackmuonSimTracks
 
CaloGeometryHelpermyCalorimeter_
 
RawParticle myElec
 A few pointers to save time. More...
 
HCALResponsemyHDResponse_
 
HistosmyHistos
 
HSParametersmyHSParameters_
 
RawParticle myPart
 
RawParticle myPosi
 
FSimEventmySimEvent
 
int optionHDSim_
 
std::vector< double > p_knots
 
double pulledPadSurvivalProbability_
 
double radiusFactorEB_
 
double radiusFactorEE_
 
std::vector< double > radiusPreshowerCorrections_
 
const RandomEnginerandom
 
double RCFactor_
 
std::vector< double > rsp
 
double RTFactor_
 
std::vector< double > samplingHBHE_
 
std::vector< double > samplingHF_
 
std::vector< double > samplingHO_
 
bool simulatePreshower_
 
double spotFraction_
 
GflashAntiProtonShowerProfiletheAntiProtonProfile
 
std::vector< double > theCoreIntervals_
 
MaterialEffectstheMuonEcalEffects
 
MaterialEffectstheMuonHcalEffects
 
GflashPiKShowerProfilethePiKProfile
 
GflashHadronShowerProfiletheProfile
 
GflashProtonShowerProfiletheProtonProfile
 
std::vector< double > theTailIntervals_
 
std::vector< double > timeShiftHB_
 
std::vector< double > timeShiftHE_
 
std::vector< double > timeShiftHF_
 
std::vector< double > timeShiftHO_
 
bool unfoldedMode_
 
bool useDQM_
 

Static Private Attributes

static std::vector< std::pair
< int, float > > 
myZero_
 

Detailed Description

Definition at line 44 of file CalorimetryManager.h.

Constructor & Destructor Documentation

CalorimetryManager::CalorimetryManager ( )

Definition at line 69 of file CalorimetryManager.cc.

69  :
70  myCalorimeter_(0),
71  // myHistos(0),
72  random(0),initialized_(false)
73 {;}
const RandomEngine * random
CaloGeometryHelper * myCalorimeter_
CalorimetryManager::CalorimetryManager ( FSimEvent aSimEvent,
const edm::ParameterSet fastCalo,
const edm::ParameterSet MuonECALPars,
const edm::ParameterSet MuonHCALPars,
const edm::ParameterSet fastGflash,
const RandomEngine engine 
)

Definition at line 75 of file CalorimetryManager.cc.

References aGammaGenerator, aLandauGenerator, DQMStore::book1D(), DQMStore::book2D(), dbe, edm::ParameterSet::getParameter(), myCalorimeter_, myHDResponse_, myHSParameters_, cppFunctionSkipper::operator, random, readParameters(), DQMStore::setCurrentFolder(), theAntiProtonProfile, theMuonEcalEffects, theMuonHcalEffects, thePiKProfile, theProfile, theProtonProfile, and useDQM_.

81  :
82  mySimEvent(aSimEvent),
83  random(engine), initialized_(false),
85 
86 {
87 
90 
91  //Gflash
92  theProfile = new GflashHadronShowerProfile(parGflash);
93  thePiKProfile = new GflashPiKShowerProfile(parGflash);
96 
97  readParameters(fastCalo);
98 
99  // myHistos = 0;
100 
102 
103  if (useDQM_){
104  TH1::SetDefaultSumw2(true); //turn on histo errors
105 
106  //ECAL histos
107  dbe->setCurrentFolder("EMShower");
108  // please keep the binning with fixed width and coherent between ShapeRhoZ and Tr/Lo shapes. Also check if you
109  // change the binning that the weight changes in the filling in EMShower.cc
110  dbe->book1D("TransverseShape","Transverse Shape; #rho / Moliere radius; 1/E dE/d#rho",70, 0., 7.);
111  dbe->book1D("LongitudinalShape","Longitudinal Shape; z / X0; 1/E dE/dz",40, 0.01, 40.01);
112  dbe->book1D("LongitudinalShapeLayers","Longitudinal Shape in number of layers; z / Layers; 1/E dE/dz", 26, 0.01, 26.01);
113  dbe->book2D("ShapeRhoZ","2D Shape; #rho / Moliere radius; z / X0", 70, 0., 7., 26, 0.01, 26.01);
114  dbe->book1D("NumberOfParticles","Number Of Particles entering the Shower; #Particles; #Events", 6, -0.5, 5.5);
115  dbe->book1D("ParticlesEnergy","Log Particles Energy; log10(E / GeV); #Particles", 30, 0, 3);
116 
117  //HCAL histos
118  dbe->setCurrentFolder("HDShower");
119 
120  dbe->book1D("TransverseShapeECAL","ECAL Transverse Shape; #rho / #lambda_{int}; 1/E dE/d#rho",70, 0., 7.);
121  dbe->book1D("LongitudinalShapeECAL","ECAL Longitudinal Shape; z / #lambda_{int}; 1/E dE/dz",20, 0., 2.);
122  dbe->book1D("TransverseShapeHCAL","HCAL Transverse Shape; #rho / #lambda_{int}; 1/E dE/d#rho",70, 0., 7.);
123  dbe->book1D("LongitudinalShapeHCAL","HCAL Longitudinal Shape; z / #lambda_{int}; 1/E dE/dz",120, 0., 12.);
124  dbe->book1D("ParticlesEnergy","Log Particles Energy; log10(E / GeV); #Particles", 30, 0, 3);
125 
126  }
127 
128 // myHistos = Histos::instance();
129 // myHistos->book("h10",140,-3.5,3.5,100,-0.5,99.5);
130 // myHistos->book("h20",150,0,150.,100,-0.5,99.5);
131 // myHistos->book("h100",140,-3.5,3.5,100,0,0.1);
132 // myHistos->book("h110",140,-3.5,3.5,100,0,10.);
133 // myHistos->book("h120",200,-5.,5.,100,0,0.5);
134 
135 // myHistos->book("h200",300,0,3.,100,0.,35.);
136 // myHistos->book("h210",720,-M_PI,M_PI,100,0,35.);
137 // myHistos->book("h212",720,-M_PI,M_PI,100,0,35.);
138 
139 // myHistos->bookByNumber("h30",0,7,300,-3.,3.,100,0.,35.);
140 // myHistos->book("h310",75,-3.,3.,"");
141 // myHistos->book("h400",100,-10.,10.,100,0.,35.);
142 // myHistos->book("h410",720,-M_PI,M_PI);
143 
144  myCalorimeter_ =
145  new CaloGeometryHelper(fastCalo);
146  myHDResponse_ =
147  new HCALResponse(fastCalo.getParameter<edm::ParameterSet>("HCALResponse"),
148  random);
149  myHSParameters_ =
150  new HSParameters(fastCalo.getParameter<edm::ParameterSet>("HSParameters"));
151 
152  // Material Effects for Muons in ECAL (only EnergyLoss implemented so far)
153 
154  if ( fastMuECAL.getParameter<bool>("PairProduction") ||
155  fastMuECAL.getParameter<bool>("Bremsstrahlung") ||
156  fastMuECAL.getParameter<bool>("MuonBremsstrahlung") ||
157  fastMuECAL.getParameter<bool>("EnergyLoss") ||
158  fastMuECAL.getParameter<bool>("MultipleScattering") )
159  theMuonEcalEffects = new MaterialEffects(fastMuECAL,random);
160 
161  // Material Effects for Muons in HCAL (only EnergyLoss implemented so far)
162 
163  if ( fastMuHCAL.getParameter<bool>("PairProduction") ||
164  fastMuHCAL.getParameter<bool>("Bremsstrahlung") ||
165  fastMuHCAL.getParameter<bool>("MuonBremsstrahlung") ||
166  fastMuHCAL.getParameter<bool>("EnergyLoss") ||
167  fastMuHCAL.getParameter<bool>("MultipleScattering") )
168  theMuonHcalEffects = new MaterialEffects(fastMuHCAL,random);
169 
170 
171 }
T getParameter(std::string const &) const
GflashPiKShowerProfile * thePiKProfile
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:722
MaterialEffects * theMuonEcalEffects
MaterialEffects * theMuonHcalEffects
GflashHadronShowerProfile * theProfile
void readParameters(const edm::ParameterSet &fastCalo)
const RandomEngine * random
const LandauFluctuationGenerator * aLandauGenerator
GflashAntiProtonShowerProfile * theAntiProtonProfile
GflashProtonShowerProfile * theProtonProfile
HCALResponse * myHDResponse_
CaloGeometryHelper * myCalorimeter_
GammaFunctionGenerator * aGammaGenerator
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:850
HSParameters * myHSParameters_
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:434
CalorimetryManager::~CalorimetryManager ( )

Definition at line 182 of file CalorimetryManager.cc.

References myCalorimeter_, myHDResponse_, theMuonEcalEffects, theMuonHcalEffects, and theProfile.

183 {
184  if(myCalorimeter_) delete myCalorimeter_;
185  if(myHDResponse_) delete myHDResponse_;
186 
189 
190  if ( theProfile ) delete theProfile;
191 }
MaterialEffects * theMuonEcalEffects
MaterialEffects * theMuonHcalEffects
GflashHadronShowerProfile * theProfile
HCALResponse * myHDResponse_
CaloGeometryHelper * myCalorimeter_

Member Function Documentation

void CalorimetryManager::clean ( )
private

Definition at line 173 of file CalorimetryManager.cc.

References EBMapping_, EEMapping_, ESMapping_, HMapping_, and muonSimTracks.

Referenced by reconstruct().

174 {
175  EBMapping_.clear();
176  EEMapping_.clear();
177  HMapping_.clear();
178  ESMapping_.clear();
179  muonSimTracks.clear();
180 }
std::vector< std::pair< CaloHitID, float > > ESMapping_
std::vector< std::pair< CaloHitID, float > > EBMapping_
std::vector< FSimTrack > muonSimTracks
std::vector< std::pair< CaloHitID, float > > EEMapping_
std::vector< std::pair< CaloHitID, float > > HMapping_
void CalorimetryManager::EMShowerSimulation ( const FSimTrack myTrack)
private

Definition at line 265 of file CalorimetryManager.cc.

References aGammaGenerator, aLandauGenerator, aTerm, bFixedLength_, bTerm, EMShower::compute(), crackPadSurvivalProbability_, dbe, debug_, alignCSCRings::e, FSimTrack::ecalEntrance(), Calorimeter::ecalProperties(), RandomEngine::flatShoot(), CaloGeometryHelper::getClosestCell(), PreshowerHitMaker::getHits(), HcalHitMaker::getHits(), EcalHitMaker::getHits(), EMShower::getMaximumOfShower(), gridSize_, FSimTrack::hcalEntrance(), Calorimeter::hcalProperties(), FSimTrack::id(), FSimTrack::layer1Entrance(), Calorimeter::layer1Properties(), FSimTrack::layer2Entrance(), Calorimeter::layer2Properties(), create_public_lumi_plots::log, mipValues_, myCalorimeter_, myElec, myPart, myPosi, NULL, FSimTrack::onEcal(), FSimTrack::onHcal(), FSimTrack::onLayer1(), FSimTrack::onLayer2(), pulledPadSurvivalProbability_, radiusFactorEB_, radiusFactorEE_, ECALProperties::radLenIncm(), random, RCFactor_, RTFactor_, EcalHitMaker::setCrackPadSurvivalProbability(), EMShower::setGrid(), EMShower::setHcal(), PreshowerHitMaker::setMipEnergy(), EMShower::setPreshower(), EcalHitMaker::setPreshowerPresent(), EcalHitMaker::setPulledPadSurvivalProbability(), EcalHitMaker::setRadiusFactor(), EcalHitMaker::setTrackParameters(), RawParticle::setVertex(), simulatePreshower_, findQualityFiles::size, theCoreIntervals_, theTailIntervals_, CoreSimTrack::type(), updateECAL(), updateHCAL(), updatePreshower(), RawParticle::vertex(), and histoStyle::weight.

Referenced by reconstruct().

265  {
266  std::vector<const RawParticle*> thePart;
267  double X0depth;
268 
269  if (debug_) {
270  LogInfo("FastCalorimetry") << " EMShowerSimulation " <<myTrack << std::endl;
271  }
272 
273  // std::cout << " Simulating " << myTrack << std::endl;
274 
275  // The Particle at ECAL entrance
276  // std::cout << " Before ecalEntrance " << std::endl;
277  myPart = myTrack.ecalEntrance();
278 
279  // protection against infinite loop.
280  if ( myTrack.type() == 22 && myPart.e()<0.055) return;
281 
282 
283  // Barrel or Endcap ?
284  int onEcal = myTrack.onEcal();
285  int onHcal = myTrack.onHcal();
286  int onLayer1 = myTrack.onLayer1();
287  int onLayer2 = myTrack.onLayer2();
288 
289  // The entrance in ECAL
290  XYZPoint ecalentrance = myPart.vertex().Vect();
291 
292  // std::cout << " Ecal entrance " << ecalentrance << std::endl;
293 
294  // The preshower
295  PreshowerHitMaker * myPreshower = NULL ;
296  if(simulatePreshower_ && (onLayer1 || onLayer2))
297  {
298  XYZPoint layer1entrance,layer2entrance;
299  XYZVector dir1,dir2;
300  if(onLayer1)
301  {
302  layer1entrance = XYZPoint(myTrack.layer1Entrance().vertex().Vect());
303  dir1 = XYZVector(myTrack.layer1Entrance().Vect().Unit());
304  }
305  if(onLayer2)
306  {
307  layer2entrance = XYZPoint(myTrack.layer2Entrance().vertex().Vect());
308  dir2 = XYZVector(myTrack.layer2Entrance().Vect().Unit());
309  }
310  // std::cout << " Layer1entrance " << layer1entrance << std::endl;
311  // std::cout << " Layer2entrance " << layer2entrance << std::endl;
312  myPreshower = new PreshowerHitMaker(myCalorimeter_,
313  layer1entrance,
314  dir1,
315  layer2entrance,
316  dir2,
318  myPreshower->setMipEnergy(mipValues_[0],mipValues_[1]);
319  }
320 
321  // The ECAL Properties
323  showerparam(myCalorimeter_->ecalProperties(onEcal),
324  myCalorimeter_->hcalProperties(onHcal),
325  myCalorimeter_->layer1Properties(onLayer1),
326  myCalorimeter_->layer2Properties(onLayer2),
329  RCFactor_,
330  RTFactor_);
331 
332  // Photons : create an e+e- pair
333  if ( myTrack.type() == 22 ) {
334 
335  // Depth for the first e+e- pair creation (in X0)
336  X0depth = -log(random->flatShoot()) * (9./7.);
337 
338  // Initialization
339  double eMass = 0.000510998902;
340  double xe=0;
341  double xm=eMass/myPart.e();
342  double weight = 0.;
343 
344  // Generate electron energy between emass and eGamma-emass
345  do {
346  xe = random->flatShoot()*(1.-2.*xm) + xm;
347  weight = 1. - 4./3.*xe*(1.-xe);
348  } while ( weight < random->flatShoot() );
349 
350  // Protection agains infinite loop in Famos Shower
351  if ( myPart.e()*xe < 0.055 || myPart.e()*(1.-xe) < 0.055 ) {
352 
353  if ( myPart.e() > 0.055 ) thePart.push_back(&myPart);
354 
355  } else {
356 
357  myElec = (myPart) * xe;
358  myPosi = (myPart) * (1.-xe);
361  thePart.push_back(&myElec);
362  thePart.push_back(&myPosi);
363  }
364  // Electrons
365  } else {
366 
367  X0depth = 0.;
368  if ( myPart.e() > 0.055 ) thePart.push_back(&myPart);
369 
370  }
371 
372  // After the different protections, this shouldn't happen.
373  if(thePart.size()==0)
374  {
375  if(myPreshower==NULL) return;
376  delete myPreshower;
377  return;
378  }
379 
380  // find the most energetic particle
381  double maxEnergy=-1.;
382  for(unsigned ip=0;ip < thePart.size();++ip)
383  if(thePart[ip]->e() > maxEnergy) maxEnergy = thePart[ip]->e();
384 
385  // Initialize the Grid in ECAL
386  int size = gridSize_;
387  if(maxEnergy>100) size=11;
388 // if ( maxEnergy < threshold5x5 ) size = 5;
389 // if ( maxEnergy < threshold3x3 ) size = 3;
390 
391 
392  EMShower theShower(random,aGammaGenerator,&showerparam,&thePart, dbe, NULL, NULL, bFixedLength_);
393 
394 
395  double maxShower = theShower.getMaximumOfShower();
396  if (maxShower > 20.) maxShower = 2.; // simple pivot-searching protection
397 
398  double depth((X0depth + maxShower) *
400  XYZPoint meanShower = ecalentrance + myPart.Vect().Unit()*depth;
401 
402  // if(onEcal!=1) return ;
403 
404  // The closest crystal
405  DetId pivot(myCalorimeter_->getClosestCell(meanShower, true, onEcal==1));
406 
407  if(pivot.subdetId() == 0) { // further protection against avbsence of pivot
408  edm::LogWarning("CalorimetryManager") << "Pivot for egamma e = " << myTrack.hcalEntrance().e() << " is not found at depth " << depth << " and meanShower coordinates = " << meanShower << std::endl;
409  if(myPreshower) delete myPreshower;
410  return;
411  }
412 
413  EcalHitMaker myGrid(myCalorimeter_,ecalentrance,pivot,onEcal,size,0,random);
414  // ^^^^
415  // for EM showers
416  myGrid.setPulledPadSurvivalProbability(pulledPadSurvivalProbability_);
417  myGrid.setCrackPadSurvivalProbability(crackPadSurvivalProbability_);
418 
419  //maximumdepth dependence of the radiusfactorbehindpreshower
420  //First tuning: Shilpi Jain (Mar-Apr 2010); changed after tuning - Feb-July - Shilpi Jain
421  /* **************
422  myGrid.setRadiusFactor(radiusFactor_);
423  if(onLayer1 || onLayer2)
424  {
425  float b = radiusPreshowerCorrections_[0];
426  float a = radiusFactor_*( 1.+radiusPreshowerCorrections_[1]*radiusPreshowerCorrections_[0] );
427  float maxdepth = X0depth+theShower.getMaximumOfShower();
428  float newRadiusFactor = radiusFactor_;
429  if(myPart.e()<=250.)
430  {
431  newRadiusFactor = a/(1.+b*maxdepth);
432  }
433  myGrid.setRadiusFactor(newRadiusFactor);
434  }
435  else // otherwise use the normal radius factor
436  {
437  myGrid.setRadiusFactor(radiusFactor_);
438  }
439  ************** */
440  if(myTrack.onEcal() == 2) // if on EE
441  {
442  if( (onLayer1 || onLayer2) && myPart.e()<=250.)
443  {
444  double maxdepth = X0depth+theShower.getMaximumOfShower();
445  double newRadiusFactor = radiusFactorEE_ * aTerm/(1.+bTerm*maxdepth);
446  myGrid.setRadiusFactor(newRadiusFactor);
447  }
448  else // otherwise use the normal radius factor
449  {
450  myGrid.setRadiusFactor(radiusFactorEE_);
451  }
452  }//if(myTrack.onEcal() == 2)
453  else // else if on EB
454  {
455  myGrid.setRadiusFactor(radiusFactorEB_);
456  }
457  //(end of) changed after tuning - Feb-July - Shilpi Jain
458 
459  myGrid.setPreshowerPresent(simulatePreshower_);
460 
461  // The shower simulation
462  myGrid.setTrackParameters(myPart.Vect().Unit(),X0depth,myTrack);
463 
464 // std::cout << " PS ECAL GAP HCAL X0 " << myGrid.ps1TotalX0()+myGrid.ps2TotalX0() << " " << myGrid.ecalTotalX0();
465 // std::cout << " " << myGrid.ecalHcalGapTotalX0() << " " << myGrid.hcalTotalX0() << std::endl;
466 // std::cout << " PS ECAL GAP HCAL L0 " << myGrid.ps1TotalL0()+myGrid.ps2TotalL0() << " " << myGrid.ecalTotalL0();
467 // std::cout << " " << myGrid.ecalHcalGapTotalL0() << " " << myGrid.hcalTotalL0() << std::endl;
468 // std::cout << "ECAL-HCAL " << myTrack.momentum().eta() << " " << myGrid.ecalHcalGapTotalL0() << std::endl;
469 //
470 // std::cout << " Grid created " << std::endl;
471  if(myPreshower) theShower.setPreshower(myPreshower);
472 
473  HcalHitMaker myHcalHitMaker(myGrid,(unsigned)0);
474 
475  theShower.setGrid(&myGrid);
476  theShower.setHcal(&myHcalHitMaker);
477  theShower.compute();
478  //myHistos->fill("h502", myPart->eta(),myGrid.totalX0());
479 
480  // Save the hits !
481  updateECAL(myGrid.getHits(),onEcal,myTrack.id());
482 
483  // Now fill the HCAL hits
484  updateHCAL(myHcalHitMaker.getHits(),myTrack.id());
485 
486  // delete the preshower
487  if(myPreshower!=0) {
488  updatePreshower(myPreshower->getHits(),myTrack.id());
489  delete myPreshower;
490  // std::cout << " Deleting myPreshower " << std::endl;
491  }
492 
493 }
RawParticle myElec
A few pointers to save time.
const ECALProperties * ecalProperties(int onEcal) const
ECAL properties.
Definition: Calorimeter.cc:73
void updateHCAL(const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
int onLayer2() const
Definition: FSimTrack.h:96
void updatePreshower(const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
double radLenIncm() const
Radiation length in cm.
const RawParticle & layer1Entrance() const
The particle at Preshower Layer 1.
Definition: FSimTrack.h:127
#define NULL
Definition: scimark2.h:8
void updateECAL(const std::map< CaloHitID, float > &hitMap, int onEcal, int trackID=0, float corr=1.0)
const std::map< CaloHitID, float > & getHits()
const PreshowerLayer1Properties * layer1Properties(int onLayer1) const
Preshower Layer1 properties.
Definition: Calorimeter.cc:100
int onEcal() const
Definition: FSimTrack.h:101
const RandomEngine * random
const LandauFluctuationGenerator * aLandauGenerator
math::XYZVector XYZVector
const PreshowerLayer2Properties * layer2Properties(int onLayer2) const
Preshower Layer2 properties.
Definition: Calorimeter.cc:108
const HCALProperties * hcalProperties(int onHcal) const
HCAL properties.
Definition: Calorimeter.cc:84
const RawParticle & ecalEntrance() const
The particle at ECAL entrance.
Definition: FSimTrack.h:133
std::vector< double > theTailIntervals_
CaloGeometryHelper * myCalorimeter_
std::vector< double > theCoreIntervals_
const XYZTLorentzVector & vertex() const
the vertex fourvector
Definition: RawParticle.h:284
Definition: DetId.h:20
GammaFunctionGenerator * aGammaGenerator
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
std::vector< double > mipValues_
double flatShoot(double xmin=0.0, double xmax=1.0) const
Definition: RandomEngine.h:30
math::XYZVector XYZPoint
int type() const
particle type (HEP PDT convension)
Definition: CoreSimTrack.h:40
int id() const
the index in FBaseSimEvent and other vectors
Definition: FSimTrack.h:86
const RawParticle & layer2Entrance() const
The particle at Preshower Layer 2.
Definition: FSimTrack.h:130
int onLayer1() const
Definition: FSimTrack.h:91
int onHcal() const
Definition: FSimTrack.h:106
const RawParticle & hcalEntrance() const
The particle at HCAL entrance.
Definition: FSimTrack.h:136
void setMipEnergy(double e1, double e2)
DetId getClosestCell(const XYZPoint &point, bool ecal, bool central) const
int weight
Definition: histoStyle.py:50
tuple size
Write out results.
void setVertex(const XYZTLorentzVector &vtx)
set the vertex
Definition: RawParticle.h:287
CaloGeometryHelper* CalorimetryManager::getCalorimeter ( ) const
inline

Definition at line 60 of file CalorimetryManager.h.

References myCalorimeter_.

Referenced by FamosManager::setupGeometryAndField().

60 {return myCalorimeter_;}
CaloGeometryHelper * myCalorimeter_
void CalorimetryManager::HDShowerSimulation ( const FSimTrack myTrack)
private

Hadronic Shower Simulation.

Definition at line 560 of file CalorimetryManager.cc.

References HcalHitMaker::addHit(), DeDxDiscriminatorTools::charge(), FSimTrack::charge(), HFShower::compute(), HDShower::compute(), HDRShower::computeShower(), dbe, debug_, FSimTrack::ecalEntrance(), Calorimeter::ecalProperties(), ecorr, Gflash::getCalorimeterNumber(), CaloGeometryHelper::getClosestCell(), CaloSubdetectorGeometry::getGeometry(), GflashHadronShowerProfile::getGflashHitList(), GflashHadronShowerProfile::getGflashShowino(), GflashTrajectory::getGflashTrajectoryPoint(), HCALResponse::getHCALEnergyResponse(), Calorimeter::getHcalGeometry(), GflashShowino::getHelix(), HcalHitMaker::getHits(), HDShower::getmip(), GflashShowino::getPathLengthAtShower(), GflashShowino::getPathLengthOnEcal(), CaloCellGeometry::getPosition(), GflashHadronShowerProfile::hadronicParameterization(), FSimTrack::hcalEntrance(), Calorimeter::hcalProperties(), hcorr, hdGridSize_, hdSimMethod_, FSimTrack::id(), GflashHadronShowerProfile::initialize(), Gflash::intLength, Gflash::kENCA, Gflash::kESPM, Gflash::kHB, Gflash::kHE, Gflash::kNULL, GflashHadronShowerProfile::loadParameters(), PV3DBase< T, PVType, FrameType >::mag(), max(), FSimTrack::momentum(), myCalorimeter_, myHDResponse_, myHSParameters_, myPart, DetId::null(), FSimTrack::onEcal(), FSimTrack::onHcal(), FSimTrack::onVFcal(), optionHDSim_, random, DetId::rawId(), respCorr(), HCALResponse::responseHCAL(), HcalHitMaker::setDepth(), HcalHitMaker::setSpotEnergy(), EcalHitMaker::setTrackParameters(), ntuplemaker::status, theAntiProtonProfile, thePiKProfile, theProfile, theProtonProfile, CoreSimTrack::type(), updateECAL(), updateHCAL(), RawParticle::vertex(), and FSimTrack::vfcalEntrance().

Referenced by reconstruct().

560  {//,
561  // const edm::ParameterSet& fastCalo){
562 
563  // TimeMe t(" FASTEnergyReconstructor::HDShower");
564  XYZTLorentzVector moment = myTrack.momentum();
565 
566  if(debug_)
567  LogInfo("FastCalorimetry")
568  << "CalorimetryManager::HDShowerSimulation - track param."
569  << std::endl
570  << " eta = " << moment.eta() << std::endl
571  << " phi = " << moment.phi() << std::endl
572  << " et = " << moment.Et() << std::endl
573  << " e = " << myTrack.hcalEntrance().e() << std::endl;
574 
575  if (debug_) {
576  LogInfo("FastCalorimetry") << " HDShowerSimulation " << myTrack << std::endl;
577  }
578 
579 
580  int hit;
581  // int pid = abs(myTrack.type());
582 
583  XYZTLorentzVector trackPosition;
584  if ( myTrack.onEcal() ) {
585  trackPosition=myTrack.ecalEntrance().vertex();
586  hit = myTrack.onEcal()-1; //
587  myPart = myTrack.ecalEntrance();
588  } else if ( myTrack.onVFcal()) {
589  trackPosition=myTrack.vfcalEntrance().vertex();
590  hit = 2;
591  myPart = myTrack.vfcalEntrance();
592  }
593  else
594  {
595  LogInfo("FastCalorimetry") << " The particle is not in the acceptance " << std::endl;
596  return;
597  }
598 
599  // int onHCAL = hit + 1; - specially for myCalorimeter->hcalProperties(onHCAL)
600  // (below) to get VFcal properties ...
601  int onHCAL = hit + 1;
602  int onECAL = myTrack.onEcal();
603 
604  double pathEta = trackPosition.eta();
605  double pathPhi = trackPosition.phi();
606  // double pathTheta = trackPosition.theta();
607 
608  double eint = moment.e();
609  double eGen = myTrack.hcalEntrance().e();
610 
611  double emeas = 0.;
612  //double emeas = -0.000001;
613 
614  //===========================================================================
615  if(eGen > 0.) {
616 
617  // ECAL and HCAL properties to get
619  theHDShowerparam(myCalorimeter_->ecalProperties(onECAL),
622 
623  //Making ECAL Grid (and segments calculation)
624  XYZPoint caloentrance;
625  XYZVector direction;
626  if(myTrack.onEcal())
627  {
628  caloentrance = myTrack.ecalEntrance().vertex().Vect();
629  direction = myTrack.ecalEntrance().Vect().Unit();
630  }
631  else if(myTrack.onHcal())
632  {
633  caloentrance = myTrack.hcalEntrance().vertex().Vect();
634  direction = myTrack.hcalEntrance().Vect().Unit();
635  }
636  else
637  {
638  caloentrance = myTrack.vfcalEntrance().vertex().Vect();
639  direction = myTrack.vfcalEntrance().Vect().Unit();
640  }
641 
642  if(debug_)
643  LogInfo("FastCalorimetry")
644  << "CalorimetryManager::HDShowerSimulation - on-calo 1 "
645  << std::endl
646  << " onEcal = " << myTrack.onEcal() << std::endl
647  << " onHcal = " << myTrack.onHcal() << std::endl
648  << " onVFcal = " << myTrack.onVFcal() << std::endl
649  << " position = " << caloentrance << std::endl;
650 
651 
652  DetId pivot;
653  if(myTrack.onEcal())
654  {
655  pivot=myCalorimeter_->getClosestCell(caloentrance,
656  true, myTrack.onEcal()==1);
657  }
658  else if(myTrack.onHcal())
659  {
660  // std::cout << " CalorimetryManager onHcal " << myTrack.onHcal() << " caloentrance" << caloentrance << std::endl;
661  pivot=myCalorimeter_->getClosestCell(caloentrance,
662  false, false);
663  }
664 
665  EcalHitMaker myGrid(myCalorimeter_,caloentrance,pivot,
666  pivot.null()? 0 : myTrack.onEcal(),hdGridSize_,1,
667  random);
668  // 1=HAD shower
669 
670  myGrid.setTrackParameters(direction,0,myTrack);
671  // Build the FAMOS HCAL
672  HcalHitMaker myHcalHitMaker(myGrid,(unsigned)1);
673 
674  // Shower simulation
675  bool status = false;
676  int mip = 2;
677  // Use HFShower for HF
678  if ( !myTrack.onEcal() && !myTrack.onHcal() ) {
679  // std::cout << "CalorimetryManager::HDShowerSimulation(): track entrance = "
680  // << myTrack.vfcalEntrance().vertex().X() << " "
681  // << myTrack.vfcalEntrance().vertex().Y() << " "
682  // << myTrack.vfcalEntrance().vertex().Z() << " "
683  // << " , Energy (Gen/Scale) = " << eGen << " " << e << std::endl;
684 
685  // Warning : We give here the particle energy with the response
686  // but without the resolution/gaussian smearing
687  // For HF, the resolution is due to the PE statistic
688 
689  HFShower theShower(random,
690  &theHDShowerparam,
691  &myGrid,
692  &myHcalHitMaker,
693  onECAL,
694  eGen);
695  // eGen);
696  // e); // PV Warning : temporarly set the energy to the generated E
697 
698  status = theShower.compute();
699  } else {
700  if(hdSimMethod_ == 0) {
701  HDShower theShower(random,
702  &theHDShowerparam,
703  &myGrid,
704  &myHcalHitMaker,
705  onECAL,
706  eGen,
707  dbe);
708  status = theShower.compute();
709  mip = theShower.getmip();
710  }
711  else if (hdSimMethod_ == 1) {
712  HDRShower theShower(random,
713  &theHDShowerparam,
714  &myGrid,
715  &myHcalHitMaker,
716  onECAL,
717  eGen);
718  status = theShower.computeShower();
719  mip = 2;
720  }
721  else if (hdSimMethod_ == 2 ) {
722  // std::cout << "Using GflashHadronShowerProfile hdSimMethod_ == 2" << std::endl;
723 
724  //dynamically loading a corresponding profile by the particle type
725  int particleType = myTrack.type();
727  if(particleType == -2212) theProfile = theAntiProtonProfile;
728  else if(particleType == 2212) theProfile = theProtonProfile;
729 
730  //input variables for GflashHadronShowerProfile
731  int showerType = 99 + myTrack.onEcal();
732  double globalTime = 150.0; // a temporary reference hit time in nanosecond
733  float charge = (float)(myTrack.charge());
734  Gflash3Vector gfpos(trackPosition.X(),trackPosition.Y(),trackPosition.Z());
735  Gflash3Vector gfmom(moment.X(),moment.Y(),moment.Z());
736 
737  theProfile->initialize(showerType,eGen,globalTime,charge,gfpos,gfmom);
740 
741  //make hits
742  std::vector<GflashHit>& gflashHitList = theProfile->getGflashHitList();
743  std::vector<GflashHit>::const_iterator spotIter = gflashHitList.begin();
744  std::vector<GflashHit>::const_iterator spotIterEnd = gflashHitList.end();
745 
747 
748  for( ; spotIter != spotIterEnd; spotIter++){
749 
750  double pathLength = theProfile->getGflashShowino()->getPathLengthAtShower()
751  + (30*100/eGen)*(spotIter->getTime() - globalTime);
752 
753  double currentDepth = std::max(0.0,pathLength - theProfile->getGflashShowino()->getPathLengthOnEcal());
754 
755  //find the the showino position at the currentDepth
756  GflashTrajectoryPoint trajectoryPoint;
757  theProfile->getGflashShowino()->getHelix()->getGflashTrajectoryPoint(trajectoryPoint,pathLength);
758  Gflash3Vector positionAtCurrentDepth = trajectoryPoint.getPosition();
759  //find radial distrance
760  Gflash3Vector lateralDisplacement = positionAtCurrentDepth - spotIter->getPosition()/CLHEP::cm;
761  double rShower = lateralDisplacement.r();
762  double azimuthalAngle = lateralDisplacement.phi();
763 
764  whichCalor = Gflash::getCalorimeterNumber(positionAtCurrentDepth);
765 
766  if(whichCalor==Gflash::kESPM || whichCalor==Gflash::kENCA) {
767  bool statusPad = myGrid.getPads(currentDepth,true);
768  if(!statusPad) continue;
769  myGrid.setSpotEnergy(1.2*spotIter->getEnergy()/CLHEP::GeV);
770  myGrid.addHit(rShower/Gflash::intLength[Gflash::kESPM],azimuthalAngle,0);
771  }
772  else if(whichCalor==Gflash::kHB || whichCalor==Gflash::kHE) {
773  bool setHDdepth = myHcalHitMaker.setDepth(currentDepth,true);
774  if(!setHDdepth) continue;
775  myHcalHitMaker.setSpotEnergy(1.4*spotIter->getEnergy()/CLHEP::GeV);
776  myHcalHitMaker.addHit(rShower/Gflash::intLength[Gflash::kHB],azimuthalAngle,0);
777  }
778  }
779  status = true;
780  }
781  else {
782  edm::LogInfo("FastSimulationCalorimetry") << " SimMethod " << hdSimMethod_ <<" is NOT available ";
783  }
784  }
785 
786 
787  if(status) {
788 
789  // Here to switch between simple formulae and parameterized response
790  if(optionHDSim_ == 1) {
791  emeas = myHDResponse_->getHCALEnergyResponse(eGen, hit);
792  }
793  else { // optionHDsim == 2
794  emeas = myHDResponse_->responseHCAL(mip, eGen, pathEta, 1); // 1=hadron
795  }
796 
797  double correction = emeas / eGen;
798 
799  // RespCorrP factors (ECAL and HCAL separately) calculation
800  respCorr(eint);
801 
802  if(debug_)
803  LogInfo("FastCalorimetry")
804  << "CalorimetryManager::HDShowerSimulation - on-calo 2" << std::endl
805  << " eta = " << pathEta << std::endl
806  << " phi = " << pathPhi << std::endl
807  << " Egen = " << eGen << std::endl
808  << " Emeas = " << emeas << std::endl
809  << " corr = " << correction << std::endl
810  << " mip = " << mip << std::endl;
811 
812  if(myTrack.onEcal() > 0) {
813  // Save ECAL hits
814  updateECAL(myGrid.getHits(),onECAL,myTrack.id(),correction*ecorr);
815  }
816 
817  // Save HCAL hits
818  updateHCAL(myHcalHitMaker.getHits(),myTrack.id(),correction*hcorr);
819 
820  }
821  else { // shower simulation failed
822 // std::cout << " Shower simulation failed " << trackPosition.Vect() << std::endl;
823 // std::cout << " The FSimTrack " << myTrack << std::endl;
824 // std::cout << " HF entrance on VFcal" << myTrack.onVFcal() << std::endl;
825 // std::cout << " trackPosition.eta() " << trackPosition.eta() << std::endl;
826  if(myTrack.onHcal() || myTrack.onVFcal())
827  {
828  DetId cell = myCalorimeter_->getClosestCell(trackPosition.Vect(),false,false);
829  double tof = (myCalorimeter_->getHcalGeometry()->getGeometry(cell)->getPosition().mag())/29.98;//speed of light
830  CaloHitID current_id(cell.rawId(),tof,myTrack.id());
831  std::map<CaloHitID,float> hitMap;
832  hitMap[current_id] = emeas;
833  updateHCAL(hitMap,myTrack.id());
834  if(debug_)
835  LogInfo("FastCalorimetry") << " HCAL simple cell "
836  << cell.rawId() << " added E = "
837  << emeas << std::endl;
838  }
839  }
840 
841  } // e > 0. ...
842 
843  if(debug_)
844  LogInfo("FastCalorimetry") << std::endl << " FASTEnergyReconstructor::HDShowerSimulation finished "
845  << std::endl;
846 }
double getHCALEnergyResponse(double e, int hit)
float charge() const
charge
Definition: FSimTrack.h:47
const ECALProperties * ecalProperties(int onEcal) const
ECAL properties.
Definition: Calorimeter.cc:73
const RawParticle & vfcalEntrance() const
The particle at VFCAL entrance.
Definition: FSimTrack.h:139
void updateHCAL(const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
GflashPiKShowerProfile * thePiKProfile
GflashTrajectory * getHelix()
Definition: GflashShowino.h:30
const XYZTLorentzVector & momentum() const
Temporary (until move of SimTrack to Mathcore) - No! Actually very useful.
Definition: FSimTrack.h:190
GflashHadronShowerProfile * theProfile
void updateECAL(const std::map< CaloHitID, float > &hitMap, int onEcal, int trackID=0, float corr=1.0)
const CaloSubdetectorGeometry * getHcalGeometry() const
Definition: Calorimeter.h:57
double charge(const std::vector< uint8_t > &Ampls)
virtual const CaloCellGeometry * getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
int onEcal() const
Definition: FSimTrack.h:101
uint32_t rawId() const
get the raw id
Definition: DetId.h:45
const RandomEngine * random
T mag() const
Definition: PV3DBase.h:67
GflashAntiProtonShowerProfile * theAntiProtonProfile
math::XYZVector XYZVector
GflashProtonShowerProfile * theProtonProfile
const T & max(const T &a, const T &b)
double getPathLengthAtShower()
Definition: GflashShowino.h:26
void setTrackParameters(const XYZNormal &normal, double X0depthoffset, const FSimTrack &theTrack)
const HCALProperties * hcalProperties(int onHcal) const
HCAL properties.
Definition: Calorimeter.cc:84
const RawParticle & ecalEntrance() const
The particle at ECAL entrance.
Definition: FSimTrack.h:133
int onVFcal() const
Definition: FSimTrack.h:111
HCALResponse * myHDResponse_
CaloGeometryHelper * myCalorimeter_
const double intLength[kNumberCalorimeter]
void getGflashTrajectoryPoint(GflashTrajectoryPoint &point, double s) const
const XYZTLorentzVector & vertex() const
the vertex fourvector
Definition: RawParticle.h:284
Definition: DetId.h:20
CLHEP::Hep3Vector Gflash3Vector
Definition: Gflash3Vector.h:6
bool null() const
is this a null id ?
Definition: DetId.h:47
CalorimeterNumber getCalorimeterNumber(const Gflash3Vector position)
double getPathLengthOnEcal()
Definition: GflashShowino.h:25
math::XYZVector XYZPoint
int type() const
particle type (HEP PDT convension)
Definition: CoreSimTrack.h:40
int id() const
the index in FBaseSimEvent and other vectors
Definition: FSimTrack.h:86
double responseHCAL(int _mip, double energy, double eta, int partype)
std::vector< GflashHit > & getGflashHitList()
int onHcal() const
Definition: FSimTrack.h:106
const RawParticle & hcalEntrance() const
The particle at HCAL entrance.
Definition: FSimTrack.h:136
DetId getClosestCell(const XYZPoint &point, bool ecal, bool central) const
tuple status
Definition: ntuplemaker.py:245
const GlobalPoint & getPosition() const
Returns the position of reference for this cell.
HSParameters * myHSParameters_
void initialize(int showerType, double energy, double globalTime, double charge, Gflash3Vector &position, Gflash3Vector &momentum)
math::XYZTLorentzVector XYZTLorentzVector
Definition: RawParticle.h:15
void CalorimetryManager::loadFromEcalBarrel ( edm::PCaloHitContainer c) const

Definition at line 1339 of file CalorimetryManager.cc.

References EBMapping_, first, i, edm::second(), and EBDetId::unhashIndex().

1340 {
1341  c.reserve(c.size()+EBMapping_.size());
1342  for(unsigned i=0; i<EBMapping_.size(); i++) {
1343  c.push_back(PCaloHit(EBDetId::unhashIndex(EBMapping_[i].first.unitID()),EBMapping_[i].second,EBMapping_[i].first.timeSlice(),EBMapping_[i].first.trackID()));
1344  }
1345 }
int i
Definition: DBlmapReader.cc:9
std::vector< std::pair< CaloHitID, float > > EBMapping_
U second(std::pair< T, U > const &p)
bool first
Definition: L1TdeRCT.cc:94
static EBDetId unhashIndex(int hi)
get a DetId from a compact index for arrays
Definition: EBDetId.h:115
void CalorimetryManager::loadFromEcalEndcap ( edm::PCaloHitContainer c) const

Definition at line 1347 of file CalorimetryManager.cc.

References EEMapping_, first, i, edm::second(), and EEDetId::unhashIndex().

1348 {
1349  c.reserve(c.size()+EEMapping_.size());
1350  for(unsigned i=0; i<EEMapping_.size(); i++) {
1351  c.push_back(PCaloHit(EEDetId::unhashIndex(EEMapping_[i].first.unitID()),EEMapping_[i].second,EEMapping_[i].first.timeSlice(),EEMapping_[i].first.trackID()));
1352  }
1353 }
int i
Definition: DBlmapReader.cc:9
static EEDetId unhashIndex(int hi)
Definition: EEDetId.cc:99
U second(std::pair< T, U > const &p)
bool first
Definition: L1TdeRCT.cc:94
std::vector< std::pair< CaloHitID, float > > EEMapping_
void CalorimetryManager::loadFromHcal ( edm::PCaloHitContainer c) const

Definition at line 1355 of file CalorimetryManager.cc.

References first, HMapping_, i, and edm::second().

1356 {
1357  c.reserve(c.size()+HMapping_.size());
1358  for(unsigned i=0; i<HMapping_.size(); i++) {
1359  c.push_back(PCaloHit(DetId(HMapping_[i].first.unitID()),HMapping_[i].second,HMapping_[i].first.timeSlice(),HMapping_[i].first.trackID()));
1360  }
1361 }
int i
Definition: DBlmapReader.cc:9
U second(std::pair< T, U > const &p)
bool first
Definition: L1TdeRCT.cc:94
Definition: DetId.h:20
std::vector< std::pair< CaloHitID, float > > HMapping_
void CalorimetryManager::loadFromPreshower ( edm::PCaloHitContainer c) const

Definition at line 1364 of file CalorimetryManager.cc.

References ESMapping_, first, and i.

1365 {
1366  c.reserve(c.size()+ESMapping_.size());
1367  for(unsigned i=0; i<ESMapping_.size(); i++) {
1368  c.push_back(PCaloHit(ESMapping_[i].first.unitID(),ESMapping_[i].second,ESMapping_[i].first.timeSlice(),ESMapping_[i].first.trackID()));
1369  }
1370 }
int i
Definition: DBlmapReader.cc:9
std::vector< std::pair< CaloHitID, float > > ESMapping_
bool first
Definition: L1TdeRCT.cc:94
void CalorimetryManager::loadMuonSimTracks ( edm::SimTrackContainer m) const

Definition at line 1374 of file CalorimetryManager.cc.

References abs, i, muonSimTracks, and findQualityFiles::size.

1375 {
1376  unsigned size=muons.size();
1377  for(unsigned i=0; i<size;++i)
1378  {
1379  int id=muons[i].trackId();
1380  if(abs(muons[i].type())!=13) continue;
1381  // identify the corresponding muon in the local collection
1382 
1383  std::vector<FSimTrack>::const_iterator itcheck=find_if(muonSimTracks.begin(),muonSimTracks.end(),FSimTrackEqual(id));
1384  if(itcheck!=muonSimTracks.end())
1385  {
1386  muons[i].setTkPosition(itcheck->trackerSurfacePosition());
1387  muons[i].setTkMomentum(itcheck->trackerSurfaceMomentum());
1388 // std::cout << " Found the SimTrack " << std::endl;
1389 // std::cout << *itcheck << std::endl;
1390 // std::cout << "SimTrack Id "<< id << " " << muons[i] << " " << std::endl;
1391  }
1392 // else
1393 // {
1394 // std::cout << " Calorimetery Manager : this should really not happen " << std::endl;
1395 // std::cout << " Was looking for " << id << " " << muons[i] << std::endl;
1396 // for(unsigned i=0;i<muonSimTracks.size();++i)
1397 // std::cout << muonSimTracks[i] << std::endl;
1398 // }
1399  }
1400 
1401 }
type
Definition: HCALResponse.h:21
int i
Definition: DBlmapReader.cc:9
#define abs(x)
Definition: mlp_lapack.h:159
std::vector< FSimTrack > muonSimTracks
tuple muons
Definition: patZpeak.py:38
tuple size
Write out results.
void CalorimetryManager::MuonMipSimulation ( const FSimTrack myTrack)
private

// /// TEMPORARY First attempt to include HCAL (with straight-line extrapolation):

Definition at line 849 of file CalorimetryManager.cc.

References HcalHitMaker::addHit(), DeDxDiscriminatorTools::charge(), FSimTrack::charge(), debug_, EnergyLossSimulator::deltaMom(), FSimTrack::ecalEntrance(), relval_parameters_module::energy, MaterialEffects::energyLossSimulator(), CaloGeometryHelper::getClosestCell(), HcalHitMaker::getHits(), CaloSegment::HCAL, FSimTrack::hcalEntrance(), hdGridSize_, FSimTrack::id(), FSimTrack::momentum(), muonSimTracks, myCalorimeter_, myPart, DetId::null(), FSimTrack::onEcal(), FSimTrack::onHcal(), FSimTrack::onVFcal(), CaloSegment::PbWO4, random, reconstructHCAL(), RawParticle::setID(), HcalHitMaker::setSpotEnergy(), SimTrack::setTkMomentum(), SimTrack::setTkPosition(), EcalHitMaker::setTrackParameters(), theMuonEcalEffects, theMuonHcalEffects, updateECAL(), updateHCAL(), MaterialEffectsSimulator::updateState(), RawParticle::vertex(), and FSimTrack::vfcalEntrance().

Referenced by reconstruct().

850 {
851  // TimeMe t(" FASTEnergyReconstructor::HDShower");
852  XYZTLorentzVector moment = myTrack.momentum();
853 
854  // Backward compatibility behaviour
855  if(!theMuonHcalEffects)
856  {
857  if(myTrack.onHcal() || myTrack.onVFcal() )
858  reconstructHCAL(myTrack);
859 
860  return;
861  }
862 
863  if(debug_)
864  LogInfo("FastCalorimetry") << "CalorimetryManager::MuonMipSimulation - track param."
865  << std::endl
866  << " eta = " << moment.eta() << std::endl
867  << " phi = " << moment.phi() << std::endl
868  << " et = " << moment.Et() << std::endl;
869 
870  // int hit;
871  // int pid = abs(myTrack.type());
872 
873  XYZTLorentzVector trackPosition;
874  if ( myTrack.onEcal() ) {
875  trackPosition=myTrack.ecalEntrance().vertex();
876  // hit = myTrack.onEcal()-1; //
877  myPart = myTrack.ecalEntrance();
878  } else if ( myTrack.onVFcal()) {
879  trackPosition=myTrack.vfcalEntrance().vertex();
880  // hit = 2;
881  myPart = myTrack.vfcalEntrance();
882  }
883  else
884  {
885  LogInfo("FastCalorimetry") << " The particle is not in the acceptance " << std::endl;
886  return;
887  }
888 
889  // int onHCAL = hit + 1; - specially for myCalorimeter->hcalProperties(onHCAL)
890  // (below) to get VFcal properties ...
891  // not needed ?
892  // int onHCAL = hit + 1;
893  int onECAL = myTrack.onEcal();
894 
895  // double pathEta = trackPosition.eta();
896  // double pathPhi = trackPosition.phi();
897  // double pathTheta = trackPosition.theta();
898 
899  //===========================================================================
900 
901  // ECAL and HCAL properties to get
902 
903  //Making ECAL Grid (and segments calculation)
904  XYZPoint caloentrance;
905  XYZVector direction;
906  if(myTrack.onEcal())
907  {
908  caloentrance = myTrack.ecalEntrance().vertex().Vect();
909  direction = myTrack.ecalEntrance().Vect().Unit();
910  }
911  else if(myTrack.onHcal())
912  {
913  caloentrance = myTrack.hcalEntrance().vertex().Vect();
914  direction = myTrack.hcalEntrance().Vect().Unit();
915  }
916  else
917  {
918  caloentrance = myTrack.vfcalEntrance().vertex().Vect();
919  direction = myTrack.vfcalEntrance().Vect().Unit();
920  }
921 
922  DetId pivot;
923  if(myTrack.onEcal())
924  {
925  pivot=myCalorimeter_->getClosestCell(caloentrance,
926  true, myTrack.onEcal()==1);
927  }
928  else if(myTrack.onHcal())
929  {
930  // std::cout << " CalorimetryManager onHcal " << myTrack.onHcal() << " caloentrance" << caloentrance << std::endl;
931  pivot=myCalorimeter_->getClosestCell(caloentrance,
932  false, false);
933  }
934 
935  EcalHitMaker myGrid(myCalorimeter_,caloentrance,pivot,
936  pivot.null()? 0 : myTrack.onEcal(),hdGridSize_,0,
937  random);
938  // 0 =EM shower -> Unit = X0
939 
940  myGrid.setTrackParameters(direction,0,myTrack);
941 
942  // Now get the path in the Preshower, ECAL and HCAL along a straight line extrapolation
943  // but only those in the ECAL are used
944 
945  const std::vector<CaloSegment>& segments=myGrid.getSegments();
946  unsigned nsegments=segments.size();
947 
948  int ifirstHcal=-1;
949  int ilastEcal=-1;
950 
951  EnergyLossSimulator* energyLossECAL = 0;
953  // // Muon brem in ECAL
954  // MuonBremsstrahlungSimulator* muonBremECAL = 0;
955  // if (theMuonEcalEffects) muonBremECAL = theMuonEcalEffects->muonBremsstrahlungSimulator();
956 
957  for(unsigned iseg=0;iseg<nsegments&&ifirstHcal<0;++iseg)
958  {
959 
960  // in the ECAL, there are two types of segments: PbWO4 and GAP
961  float segmentSizeinX0=segments[iseg].X0length();
962 
963  // Martijn - insert your computations here
964  float energy=0.0;
965  if (segmentSizeinX0>0.001 && segments[iseg].material()==CaloSegment::PbWO4 ) {
966  // The energy loss simulator
967  float charge = (float)(myTrack.charge());
968  ParticlePropagator theMuon(moment,trackPosition,charge,0);
969  theMuon.setID(-(int)charge*13);
970  if ( energyLossECAL ) {
971  energyLossECAL->updateState(theMuon, segmentSizeinX0);
972  energy = energyLossECAL->deltaMom().E();
973  moment -= energyLossECAL->deltaMom();
974  }
975  }
976  // that's all for ECAL, Florian
977  // Save the hit only if it is a crystal
978  if(segments[iseg].material()==CaloSegment::PbWO4)
979  {
980  myGrid.getPads(segments[iseg].sX0Entrance()+segmentSizeinX0*0.5);
981  myGrid.setSpotEnergy(energy);
982  myGrid.addHit(0.,0.);
983  ilastEcal=iseg;
984  }
985  // Check for end of loop:
986  if(segments[iseg].material()==CaloSegment::HCAL)
987  {
988  ifirstHcal=iseg;
989  }
990  }
991 
992 
993  // Build the FAMOS HCAL
994  HcalHitMaker myHcalHitMaker(myGrid,(unsigned)2);
995  // float mipenergy=0.1;
996  // Create the helix with the stepping helix propagator
997  // to add a hit, just do
998  // myHcalHitMaker.setSpotEnergy(mipenergy);
999  // math::XYZVector hcalEntrance;
1000  // if(ifirstHcal>=0) hcalEntrance=segments[ifirstHcal].entrance();
1001  // myHcalHitMaker.addHit(hcalEntrance);
1005  int ilastHcal=-1;
1006  float mipenergy=0.0;
1007 
1008  EnergyLossSimulator* energyLossHCAL = 0;
1010  // // Muon Brem effect
1011  // MuonBremsstrahlungSimulator* muonBremHCAL = 0;
1012  // if (theMuonHcalEffects) muonBremHCAL = theMuonHcalEffects->muonBremsstrahlungSimulator();
1013 
1014  if(ifirstHcal>0 && energyLossHCAL){
1015  for(unsigned iseg=ifirstHcal;iseg<nsegments;++iseg)
1016  {
1017  float segmentSizeinX0=segments[iseg].X0length();
1018  if(segments[iseg].material()==CaloSegment::HCAL) {
1019  ilastHcal=iseg;
1020  if (segmentSizeinX0>0.001) {
1021  // The energy loss simulator
1022  float charge = (float)(myTrack.charge());
1023  ParticlePropagator theMuon(moment,trackPosition,charge,0);
1024  theMuon.setID(-(int)charge*13);
1025  energyLossHCAL->updateState(theMuon, segmentSizeinX0);
1026  mipenergy = energyLossHCAL->deltaMom().E();
1027  moment -= energyLossHCAL->deltaMom();
1028  myHcalHitMaker.setSpotEnergy(mipenergy);
1029  myHcalHitMaker.addHit(segments[iseg].entrance());
1030  }
1031  }
1032  }
1033  }
1034 
1039  //
1040 
1041 
1042 
1043  // Copy the muon SimTrack (Only for Energy loss)
1044  FSimTrack muonTrack(myTrack);
1045  if(energyLossHCAL && ilastHcal>=0) {
1046  math::XYZVector hcalExit=segments[ilastHcal].exit();
1047  muonTrack.setTkPosition(hcalExit);
1048  muonTrack.setTkMomentum(moment);
1049  } else if(energyLossECAL && ilastEcal>=0) {
1050  math::XYZVector ecalExit=segments[ilastEcal].exit();
1051  muonTrack.setTkPosition(ecalExit);
1052  muonTrack.setTkMomentum(moment);
1053  } // else just leave tracker surface position and momentum...
1054 
1055  muonSimTracks.push_back(muonTrack);
1056 
1057 
1058  // no need to change below this line
1059  std::map<CaloHitID,float>::const_iterator mapitr;
1060  std::map<CaloHitID,float>::const_iterator endmapitr;
1061  if(myTrack.onEcal() > 0) {
1062  // Save ECAL hits
1063  updateECAL(myGrid.getHits(),onECAL,myTrack.id());
1064  }
1065 
1066  // Save HCAL hits
1067  updateHCAL(myHcalHitMaker.getHits(),myTrack.id());
1068 
1069  if(debug_)
1070  LogInfo("FastCalorimetry") << std::endl << " FASTEnergyReconstructor::MipShowerSimulation finished "
1071  << std::endl;
1072 }
float charge() const
charge
Definition: FSimTrack.h:47
const RawParticle & vfcalEntrance() const
The particle at VFCAL entrance.
Definition: FSimTrack.h:139
void updateHCAL(const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
MaterialEffects * theMuonEcalEffects
MaterialEffects * theMuonHcalEffects
const XYZTLorentzVector & momentum() const
Temporary (until move of SimTrack to Mathcore) - No! Actually very useful.
Definition: FSimTrack.h:190
void updateECAL(const std::map< CaloHitID, float > &hitMap, int onEcal, int trackID=0, float corr=1.0)
double charge(const std::vector< uint8_t > &Ampls)
int onEcal() const
Definition: FSimTrack.h:101
std::vector< FSimTrack > muonSimTracks
const RandomEngine * random
math::XYZVector XYZVector
void setTrackParameters(const XYZNormal &normal, double X0depthoffset, const FSimTrack &theTrack)
const XYZTLorentzVector & deltaMom() const
Returns the actual energy lost.
const RawParticle & ecalEntrance() const
The particle at ECAL entrance.
Definition: FSimTrack.h:133
int onVFcal() const
Definition: FSimTrack.h:111
CaloGeometryHelper * myCalorimeter_
const XYZTLorentzVector & vertex() const
the vertex fourvector
Definition: RawParticle.h:284
Definition: DetId.h:20
void updateState(ParticlePropagator &myTrack, double radlen)
Compute the material effect (calls the sub class)
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
bool null() const
is this a null id ?
Definition: DetId.h:47
math::XYZVector XYZPoint
int id() const
the index in FBaseSimEvent and other vectors
Definition: FSimTrack.h:86
int onHcal() const
Definition: FSimTrack.h:106
const RawParticle & hcalEntrance() const
The particle at HCAL entrance.
Definition: FSimTrack.h:136
DetId getClosestCell(const XYZPoint &point, bool ecal, bool central) const
EnergyLossSimulator * energyLossSimulator() const
Return the Energy Loss engine.
void reconstructHCAL(const FSimTrack &myTrack)
math::XYZTLorentzVector XYZTLorentzVector
Definition: RawParticle.h:15
void CalorimetryManager::readParameters ( const edm::ParameterSet fastCalo)
private

Definition at line 1075 of file CalorimetryManager.cc.

References aTerm, bFixedLength_, bTerm, crackPadSurvivalProbability_, debug_, EcalDigitizer_, evtsToDebug_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), gridSize_, HcalDigitizer_, hdGridSize_, hdSimMethod_, i, ietaShiftHB_, ietaShiftHE_, ietaShiftHF_, ietaShiftHO_, k_e, k_h, mipValues_, optionHDSim_, p_knots, pulledPadSurvivalProbability_, radiusFactorEB_, radiusFactorEE_, radiusPreshowerCorrections_, RCFactor_, rsp, RTFactor_, samplingHBHE_, samplingHF_, samplingHO_, simulatePreshower_, spotFraction_, theCoreIntervals_, theTailIntervals_, timeShiftHB_, timeShiftHE_, timeShiftHF_, timeShiftHO_, and useDQM_.

Referenced by CalorimetryManager().

1075  {
1076 
1077  edm::ParameterSet ECALparameters = fastCalo.getParameter<edm::ParameterSet>("ECAL");
1078 
1079  evtsToDebug_ = fastCalo.getUntrackedParameter<std::vector<unsigned int> >("EvtsToDebug",std::vector<unsigned>());
1080  debug_ = fastCalo.getUntrackedParameter<bool>("Debug");
1081  useDQM_ = fastCalo.getUntrackedParameter<bool>("useDQM");
1082 
1083  bFixedLength_ = ECALparameters.getParameter<bool>("bFixedLength");
1084  // std::cout << "bFixedLength_ = " << bFixedLength_ << std::endl;
1085 
1086  gridSize_ = ECALparameters.getParameter<int>("GridSize");
1087  spotFraction_ = ECALparameters.getParameter<double>("SpotFraction");
1088  pulledPadSurvivalProbability_ = ECALparameters.getParameter<double>("FrontLeakageProbability");
1089  crackPadSurvivalProbability_ = ECALparameters.getParameter<double>("GapLossProbability");
1090  theCoreIntervals_ = ECALparameters.getParameter<std::vector<double> >("CoreIntervals");
1091  theTailIntervals_ = ECALparameters.getParameter<std::vector<double> >("TailIntervals");
1092 
1093  RCFactor_ = ECALparameters.getParameter<double>("RCFactor");
1094  RTFactor_ = ECALparameters.getParameter<double>("RTFactor");
1095  //changed after tuning - Feb-July - Shilpi Jain
1096  // radiusFactor_ = ECALparameters.getParameter<double>("RadiusFactor");
1097  radiusFactorEE_ = ECALparameters.getParameter<double>("RadiusFactorEE");
1098  radiusFactorEB_ = ECALparameters.getParameter<double>("RadiusFactorEB");
1099  //(end of) changed after tuning - Feb-July - Shilpi Jain
1100  radiusPreshowerCorrections_ = ECALparameters.getParameter<std::vector<double> >("RadiusPreshowerCorrections");
1103  mipValues_ = ECALparameters.getParameter<std::vector<double> >("MipsinGeV");
1104  simulatePreshower_ = ECALparameters.getParameter<bool>("SimulatePreshower");
1105 
1106  if(gridSize_ <1) gridSize_= 7;
1107  if(pulledPadSurvivalProbability_ <0. || pulledPadSurvivalProbability_>1 ) pulledPadSurvivalProbability_= 1.;
1108  if(crackPadSurvivalProbability_ <0. || crackPadSurvivalProbability_>1 ) crackPadSurvivalProbability_= 0.9;
1109 
1110  LogInfo("FastCalorimetry") << " Fast ECAL simulation parameters " << std::endl;
1111  LogInfo("FastCalorimetry") << " =============================== " << std::endl;
1112  if(simulatePreshower_)
1113  LogInfo("FastCalorimetry") << " The preshower is present " << std::endl;
1114  else
1115  LogInfo("FastCalorimetry") << " The preshower is NOT present " << std::endl;
1116  LogInfo("FastCalorimetry") << " Grid Size : " << gridSize_ << std::endl;
1117  if(spotFraction_>0.)
1118  LogInfo("FastCalorimetry") << " Spot Fraction : " << spotFraction_ << std::endl;
1119  else
1120  {
1121  LogInfo("FastCalorimetry") << " Core of the shower " << std::endl;
1122  for(unsigned ir=0; ir < theCoreIntervals_.size()/2;++ir)
1123  {
1124  LogInfo("FastCalorimetry") << " r < " << theCoreIntervals_[ir*2] << " R_M : " << theCoreIntervals_[ir*2+1] << " ";
1125  }
1126  LogInfo("FastCalorimetry") << std::endl;
1127 
1128  LogInfo("FastCalorimetry") << " Tail of the shower " << std::endl;
1129  for(unsigned ir=0; ir < theTailIntervals_.size()/2;++ir)
1130  {
1131  LogInfo("FastCalorimetry") << " r < " << theTailIntervals_[ir*2] << " R_M : " << theTailIntervals_[ir*2+1] << " ";
1132  }
1133  //changed after tuning - Feb-July - Shilpi Jain
1134  // LogInfo("FastCalorimetry") << "Radius correction factor " << radiusFactor_ << std::endl;
1135  LogInfo("FastCalorimetry") << "Radius correction factors: EB & EE " << radiusFactorEB_ << " : "<< radiusFactorEE_ << std::endl;
1136  //(end of) changed after tuning - Feb-July - Shilpi Jain
1137  LogInfo("FastCalorimetry") << std::endl;
1138  if(mipValues_.size()>2) {
1139  LogInfo("FastCalorimetry") << "Improper number of parameters for the preshower ; using 95keV" << std::endl;
1140  mipValues_.clear();
1141  mipValues_.resize(2,0.000095);
1142  }
1143  }
1144 
1145  LogInfo("FastCalorimetry") << " FrontLeakageProbability : " << pulledPadSurvivalProbability_ << std::endl;
1146  LogInfo("FastCalorimetry") << " GapLossProbability : " << crackPadSurvivalProbability_ << std::endl;
1147 
1148 
1149  // RespCorrP: p (momentum), ECAL and HCAL corrections = f(p)
1150  edm::ParameterSet CalorimeterParam = fastCalo.getParameter<edm::ParameterSet>("CalorimeterProperties");
1151 
1152  rsp = CalorimeterParam.getParameter<std::vector<double> >("RespCorrP");
1153  LogInfo("FastCalorimetry") << " RespCorrP (rsp) size " << rsp.size() << std::endl;
1154 
1155  if( rsp.size()%3 !=0 ) {
1156  LogInfo("FastCalorimetry")
1157  << " RespCorrP size is wrong -> no corrections applied !!!"
1158  << std::endl;
1159 
1160  p_knots.push_back(14000.);
1161  k_e.push_back (1.);
1162  k_h.push_back (1.);
1163  }
1164  else {
1165  for(unsigned i = 0; i < rsp.size(); i += 3) {
1166  LogInfo("FastCalorimetry") << "i = " << i/3 << " p = " << rsp [i]
1167  << " k_e(p) = " << rsp[i+1]
1168  << " k_e(p) = " << rsp[i+2] << std::endl;
1169 
1170  p_knots.push_back(rsp[i]);
1171  k_e.push_back (rsp[i+1]);
1172  k_h.push_back (rsp[i+2]);
1173  }
1174  }
1175 
1176 
1177  //FR
1178  edm::ParameterSet HCALparameters = fastCalo.getParameter<edm::ParameterSet>("HCAL");
1179  optionHDSim_ = HCALparameters.getParameter<int>("SimOption");
1180  hdGridSize_ = HCALparameters.getParameter<int>("GridSize");
1181  hdSimMethod_ = HCALparameters.getParameter<int>("SimMethod");
1182  //RF
1183 
1184  EcalDigitizer_ = ECALparameters.getUntrackedParameter<bool>("Digitizer",false);
1185  HcalDigitizer_ = HCALparameters.getUntrackedParameter<bool>("Digitizer",false);
1186  samplingHBHE_ = HCALparameters.getParameter< std::vector<double> >("samplingHBHE");
1187  samplingHF_ = HCALparameters.getParameter< std::vector<double> >("samplingHF");
1188  samplingHO_ = HCALparameters.getParameter< std::vector<double> >("samplingHO");
1189  ietaShiftHB_ = HCALparameters.getParameter< int >("ietaShiftHB");
1190  ietaShiftHE_ = HCALparameters.getParameter< int >("ietaShiftHE");
1191  ietaShiftHF_ = HCALparameters.getParameter< int >("ietaShiftHF");
1192  ietaShiftHO_ = HCALparameters.getParameter< int >("ietaShiftHO");
1193  timeShiftHB_ = HCALparameters.getParameter< std::vector<double> >("timeShiftHB");
1194  timeShiftHE_ = HCALparameters.getParameter< std::vector<double> >("timeShiftHE");
1195  timeShiftHF_ = HCALparameters.getParameter< std::vector<double> >("timeShiftHF");
1196  timeShiftHO_ = HCALparameters.getParameter< std::vector<double> >("timeShiftHO");
1197 
1198 }
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
int i
Definition: DBlmapReader.cc:9
std::vector< double > rsp
std::vector< double > k_h
std::vector< double > timeShiftHO_
std::vector< double > timeShiftHF_
std::vector< double > p_knots
std::vector< double > samplingHF_
std::vector< double > radiusPreshowerCorrections_
std::vector< double > theTailIntervals_
std::vector< double > samplingHBHE_
std::vector< double > timeShiftHB_
std::vector< double > theCoreIntervals_
std::vector< double > mipValues_
std::vector< unsigned int > evtsToDebug_
std::vector< double > k_e
std::vector< double > samplingHO_
std::vector< double > timeShiftHE_
void CalorimetryManager::reconstruct ( )

Definition at line 193 of file CalorimetryManager.cc.

References abs, clean(), gather_cfg::cout, debug_, EMShowerSimulation(), edm::EventID::event(), evtsToDebug_, spr::find(), HDShowerSimulation(), FSimEvent::id(), initialized_, MuonMipSimulation(), myCalorimeter_, mySimEvent, FSimTrack::noEndVertex(), FSimEvent::nTracks(), FSimTrack::onEcal(), FSimTrack::onHcal(), FSimTrack::onVFcal(), optionHDSim_, evf::utils::pid, CaloGeometryHelper::preshowerPresent(), FBaseSimEvent::print(), reconstructHCAL(), simulatePreshower_, FBaseSimEvent::track(), and CoreSimTrack::type().

Referenced by FamosManager::reconstruct().

194 {
195 
196  if(evtsToDebug_.size())
197  {
198  std::vector<unsigned int>::const_iterator itcheck=find(evtsToDebug_.begin(),evtsToDebug_.end(),mySimEvent->id().event());
199  debug_=(itcheck!=evtsToDebug_.end());
200  if(debug_)
201  mySimEvent->print();
202  }
203  // Clear the content of the calorimeters
204  if(!initialized_)
205  {
206 
207  // Check if the preshower is really available
209  {
210  std::cout << " WARNING " << std::endl;
211  std::cout << " The preshower simulation has been turned on; but no preshower geometry is available " << std::endl;
212  std::cout << " Disabling the preshower simulation " << std::endl;
213  simulatePreshower_ = false;
214  }
215 
216  initialized_=true;
217  }
218  clean();
219 
220  LogInfo("FastCalorimetry") << "Reconstructing " << (int) mySimEvent->nTracks() << " tracks." << std::endl;
221  for( int fsimi=0; fsimi < (int) mySimEvent->nTracks() ; ++fsimi) {
222 
223  FSimTrack& myTrack = mySimEvent->track(fsimi);
224 
225  int pid = abs(myTrack.type());
226 
227  if (debug_) {
228  LogInfo("FastCalorimetry") << " ===> pid = " << pid << std::endl;
229  }
230 
231 
232  // Check that the particle hasn't decayed
233  if(myTrack.noEndVertex()) {
234  // Simulate energy smearing for photon and electrons
235  if ( pid == 11 || pid == 22 ) {
236 
237  if ( myTrack.onEcal() )
238  EMShowerSimulation(myTrack);
239  else if ( myTrack.onVFcal() )
240  reconstructHCAL(myTrack);
241 
242  } // electron or photon
243  else if (pid==13)
244  {
245  MuonMipSimulation(myTrack);
246  }
247  // Simulate energy smearing for hadrons (i.e., everything
248  // but muons... and SUSY particles that deserve a special
249  // treatment.
250  else if ( pid < 1000000 ) {
251  if ( myTrack.onHcal() || myTrack.onVFcal() ) {
252  if(optionHDSim_ == 0 ) reconstructHCAL(myTrack);
253  else HDShowerSimulation(myTrack);
254  }
255  } // pid < 1000000
256  } // myTrack.noEndVertex()
257  } // particle loop
258  // LogInfo("FastCalorimetry") << " Number of hits (barrel)" << EBMapping_.size() << std::endl;
259  // LogInfo("FastCalorimetry") << " Number of hits (Hcal)" << HMapping_.size() << std::endl;
260  // std::cout << " Nombre de hit (endcap)" << EEMapping_.size() << std::endl;
261 
262 } // reconstruct
EventNumber_t event() const
Definition: EventID.h:44
bool noEndVertex() const
no end vertex
#define abs(x)
Definition: mlp_lapack.h:159
void HDShowerSimulation(const FSimTrack &myTrack)
Hadronic Shower Simulation.
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
void MuonMipSimulation(const FSimTrack &myTrack)
int onEcal() const
Definition: FSimTrack.h:101
int onVFcal() const
Definition: FSimTrack.h:111
unsigned int nTracks() const
Number of tracks.
Definition: FSimEvent.cc:48
CaloGeometryHelper * myCalorimeter_
edm::EventID id() const
Method to return the EventId.
Definition: FSimEvent.cc:39
void EMShowerSimulation(const FSimTrack &myTrack)
int type() const
particle type (HEP PDT convension)
Definition: CoreSimTrack.h:40
std::vector< unsigned int > evtsToDebug_
bool preshowerPresent() const
int onHcal() const
Definition: FSimTrack.h:106
tuple cout
Definition: gather_cfg.py:121
void reconstructHCAL(const FSimTrack &myTrack)
void print() const
print the FBaseSimEvent in an intelligible way
FSimTrack & track(int id) const
Return track with given Id.
void CalorimetryManager::reconstructHCAL ( const FSimTrack myTrack)
private

Definition at line 497 of file CalorimetryManager.cc.

References abs, debug_, CaloGeometryHelper::getClosestCell(), CaloSubdetectorGeometry::getGeometry(), HCALResponse::getHCALEnergyResponse(), Calorimeter::getHcalGeometry(), CaloCellGeometry::getPosition(), FSimTrack::hcalEntrance(), FSimTrack::id(), PV3DBase< T, PVType, FrameType >::mag(), myCalorimeter_, myHDResponse_, FSimTrack::onHcal(), evf::utils::pid, DetId::rawId(), HCALResponse::responseHCAL(), CoreSimTrack::type(), updateHCAL(), RawParticle::vertex(), and FSimTrack::vfcalEntrance().

Referenced by MuonMipSimulation(), and reconstruct().

498 {
499  int hit;
500  int pid = abs(myTrack.type());
501  if (debug_) {
502  LogInfo("FastCalorimetry") << " reconstructHCAL " << myTrack << std::endl;
503  }
504 
505  // FSimTrack myTrack = mySimEvent.track(fsimi);
506 
507  // int pid=abs(myTrack.type());
508  // std::cout << "reconstructHCAL " << std::endl;
509 
510  XYZTLorentzVector trackPosition;
511  if (myTrack.onHcal()) {
512  trackPosition=myTrack.hcalEntrance().vertex();
513  hit = myTrack.onHcal()-1;
514  } else {
515  trackPosition=myTrack.vfcalEntrance().vertex();
516  hit = 2;
517  }
518 
519  double pathEta = trackPosition.eta();
520  double pathPhi = trackPosition.phi();
521  // double pathTheta = trackPosition.theta();
522 
523  double EGen = myTrack.hcalEntrance().e();
524  double emeas = 0.;
525  //double emeas = -0.0001;
526 
527  if(pid == 13) {
528  // std::cout << " We should not be here " << std::endl;
529  emeas = myHDResponse_->responseHCAL(0, EGen, pathEta, 2); // 2=muon
530  if(debug_)
531  LogInfo("FastCalorimetry") << "CalorimetryManager::reconstructHCAL - MUON !!!" << std::endl;
532  }
533  else if( pid == 22 || pid == 11) {
534  emeas = myHDResponse_->responseHCAL(0, EGen, pathEta, 0); // last par. = 0 = e/gamma
535  // cout << "CalorimetryManager::reconstructHCAL - e/gamma !!!" << std::endl;
536  if(debug_)
537  LogInfo("FastCalorimetry") << "CalorimetryManager::reconstructHCAL - e/gamma !!!" << std::endl;
538  }
539  else {
540  emeas = myHDResponse_->getHCALEnergyResponse(EGen,hit);
541  }
542 
543  if(debug_)
544  LogInfo("FastCalorimetry") << "CalorimetryManager::reconstructHCAL - on-calo "
545  << " eta = " << pathEta
546  << " phi = " << pathPhi
547  << " Egen = " << EGen
548  << " Emeas = " << emeas << std::endl;
549 
550  if(emeas > 0.) {
551  DetId cell = myCalorimeter_->getClosestCell(trackPosition.Vect(),false,false);
552  double tof = (myCalorimeter_->getHcalGeometry()->getGeometry(cell)->getPosition().mag())/29.98;//speed of light
553  CaloHitID current_id(cell.rawId(),tof,myTrack.id());
554  std::map<CaloHitID,float> hitMap;
555  hitMap[current_id] = emeas;
556  updateHCAL(hitMap,myTrack.id());
557  }
558 }
double getHCALEnergyResponse(double e, int hit)
const RawParticle & vfcalEntrance() const
The particle at VFCAL entrance.
Definition: FSimTrack.h:139
void updateHCAL(const std::map< CaloHitID, float > &hitMap, int trackID=0, float corr=1.0)
#define abs(x)
Definition: mlp_lapack.h:159
const CaloSubdetectorGeometry * getHcalGeometry() const
Definition: Calorimeter.h:57
virtual const CaloCellGeometry * getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
uint32_t rawId() const
get the raw id
Definition: DetId.h:45
T mag() const
Definition: PV3DBase.h:67
HCALResponse * myHDResponse_
CaloGeometryHelper * myCalorimeter_
const XYZTLorentzVector & vertex() const
the vertex fourvector
Definition: RawParticle.h:284
Definition: DetId.h:20
int type() const
particle type (HEP PDT convension)
Definition: CoreSimTrack.h:40
int id() const
the index in FBaseSimEvent and other vectors
Definition: FSimTrack.h:86
double responseHCAL(int _mip, double energy, double eta, int partype)
int onHcal() const
Definition: FSimTrack.h:106
const RawParticle & hcalEntrance() const
The particle at HCAL entrance.
Definition: FSimTrack.h:136
DetId getClosestCell(const XYZPoint &point, bool ecal, bool central) const
const GlobalPoint & getPosition() const
Returns the position of reference for this cell.
math::XYZTLorentzVector XYZTLorentzVector
Definition: RawParticle.h:15
void CalorimetryManager::respCorr ( double  p)
private

Definition at line 1200 of file CalorimetryManager.cc.

References debug_, ecorr, hcorr, i, k_e, k_h, and p_knots.

Referenced by HDShowerSimulation().

1200  {
1201 
1202  int sizeP = p_knots.size();
1203 
1204  if(sizeP <= 1) {
1205  ecorr = 1.;
1206  hcorr = 1.;
1207  }
1208  else {
1209  int ip = -1;
1210  for (int i = 0; i < sizeP; i++) {
1211  if (p < p_knots[i]) { ip = i; break;}
1212  }
1213  if (ip == 0) {
1214  ecorr = k_e[0];
1215  hcorr = k_h[0];
1216  }
1217  else {
1218  if(ip == -1) {
1219  ecorr = k_e[sizeP-1];
1220  hcorr = k_h[sizeP-1];
1221  }
1222  else {
1223  double x1 = p_knots[ip-1];
1224  double x2 = p_knots[ip];
1225  double y1 = k_e[ip-1];
1226  double y2 = k_e[ip];
1227 
1228  if(x1 == x2) {
1229  // std::cout << " equal p_knots values!!! " << std::endl;
1230  }
1231 
1232  ecorr = (y1 + (y2 - y1) * (p - x1)/(x2 - x1));
1233 
1234  y1 = k_h[ip-1];
1235  y2 = k_h[ip];
1236  hcorr = (y1 + (y2 - y1) * (p - x1)/(x2 - x1));
1237 
1238  }
1239  }
1240  }
1241 
1242  if(debug_)
1243  LogInfo("FastCalorimetry") << " p, ecorr, hcorr = " << p << " "
1244  << ecorr << " " << hcorr << std::endl;
1245 
1246 }
int i
Definition: DBlmapReader.cc:9
std::vector< double > k_h
std::vector< double > p_knots
std::vector< double > k_e
void CalorimetryManager::updateECAL ( const std::map< CaloHitID, float > &  hitMap,
int  onEcal,
int  trackID = 0,
float  corr = 1.0 
)
private

Definition at line 1248 of file CalorimetryManager.cc.

References corr, EBMapping_, EEMapping_, and relval_parameters_module::energy.

Referenced by EMShowerSimulation(), HDShowerSimulation(), and MuonMipSimulation().

1249 {
1250  std::map<CaloHitID,float>::const_iterator mapitr;
1251  std::map<CaloHitID,float>::const_iterator endmapitr=hitMap.end();
1252  if(onEcal==1) {
1253  EBMapping_.reserve(EBMapping_.size()+hitMap.size());
1254  endmapitr=hitMap.end();
1255  for(mapitr=hitMap.begin();mapitr!=endmapitr;++mapitr) {
1256  //correct energy
1257  float energy = mapitr->second;
1258  energy *= corr;
1259 
1260  //make finalized CaloHitID
1261  CaloHitID current_id(mapitr->first.unitID(),mapitr->first.timeSlice(),trackID);
1262 
1263  EBMapping_.push_back(std::pair<CaloHitID,float>(current_id,energy));
1264  }
1265  }
1266  else if(onEcal==2) {
1267  EEMapping_.reserve(EEMapping_.size()+hitMap.size());
1268  endmapitr=hitMap.end();
1269  for(mapitr=hitMap.begin();mapitr!=endmapitr;++mapitr) {
1270  //correct energy
1271  float energy = mapitr->second;
1272  energy *= corr;
1273 
1274  //make finalized CaloHitID
1275  CaloHitID current_id(mapitr->first.unitID(),mapitr->first.timeSlice(),trackID);
1276 
1277  EEMapping_.push_back(std::pair<CaloHitID,float>(current_id,energy));
1278  }
1279  }
1280 
1281 }
std::vector< std::pair< CaloHitID, float > > EBMapping_
JetCorrectorParameters corr
Definition: classes.h:11
std::vector< std::pair< CaloHitID, float > > EEMapping_
void CalorimetryManager::updateHCAL ( const std::map< CaloHitID, float > &  hitMap,
int  trackID = 0,
float  corr = 1.0 
)
private

Definition at line 1283 of file CalorimetryManager.cc.

References corr, HcalDetId::depth(), relval_parameters_module::energy, HcalBarrel, HcalDigitizer_, HcalEndcap, HcalForward, HcalOuter, HMapping_, HcalDetId::ietaAbs(), ietaShiftHB_, ietaShiftHE_, ietaShiftHF_, ietaShiftHO_, samplingHBHE_, samplingHF_, samplingHO_, DetId::subdetId(), cond::rpcobgas::time, timeShiftHB_, timeShiftHE_, timeShiftHF_, and timeShiftHO_.

Referenced by EMShowerSimulation(), HDShowerSimulation(), MuonMipSimulation(), and reconstructHCAL().

1284 {
1285  std::map<CaloHitID,float>::const_iterator mapitr;
1286  std::map<CaloHitID,float>::const_iterator endmapitr=hitMap.end();
1287  HMapping_.reserve(HMapping_.size()+hitMap.size());
1288  for(mapitr=hitMap.begin(); mapitr!=endmapitr; ++mapitr) {
1289  //correct energy
1290  float energy = mapitr->second;
1291  energy *= corr;
1292 
1293  float time = mapitr->first.timeSlice();
1294  //put energy into uncalibrated state for digitizer && correct timing
1295  if(HcalDigitizer_){
1296  HcalDetId hdetid = HcalDetId(mapitr->first.unitID());
1297  if (hdetid.subdetId()== HcalBarrel){
1298  energy /= samplingHBHE_[hdetid.ietaAbs()-1]; //re-convert to GeV
1299  time = timeShiftHB_[hdetid.ietaAbs()-ietaShiftHB_];
1300  }
1301  else if (hdetid.subdetId()== HcalEndcap){
1302  energy /= samplingHBHE_[hdetid.ietaAbs()-1]; //re-convert to GeV
1303  time = timeShiftHE_[hdetid.ietaAbs()-ietaShiftHE_];
1304  }
1305  else if (hdetid.subdetId()== HcalForward){
1306  if(hdetid.depth()== 1) energy *= samplingHF_[0];
1307  if(hdetid.depth()== 2) energy *= samplingHF_[1];
1308  time = timeShiftHF_[hdetid.ietaAbs()-ietaShiftHF_];
1309  }
1310  else if (hdetid.subdetId()== HcalOuter){
1311  energy /= samplingHO_[hdetid.ietaAbs()-1];
1312  time = timeShiftHO_[hdetid.ietaAbs()-ietaShiftHO_];
1313  }
1314  }
1315 
1316  //make finalized CaloHitID
1317  CaloHitID current_id(mapitr->first.unitID(),time,trackID);
1318  HMapping_.push_back(std::pair<CaloHitID,float>(current_id,energy));
1319  }
1320 }
std::vector< double > timeShiftHO_
std::vector< double > timeShiftHF_
std::vector< double > samplingHF_
int depth() const
get the tower depth
Definition: HcalDetId.h:42
std::vector< double > samplingHBHE_
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
JetCorrectorParameters corr
Definition: classes.h:11
std::vector< double > timeShiftHB_
int ietaAbs() const
get the absolute value of the cell ieta
Definition: HcalDetId.h:36
std::vector< std::pair< CaloHitID, float > > HMapping_
std::vector< double > samplingHO_
std::vector< double > timeShiftHE_
void CalorimetryManager::updatePreshower ( const std::map< CaloHitID, float > &  hitMap,
int  trackID = 0,
float  corr = 1.0 
)
private

Definition at line 1322 of file CalorimetryManager.cc.

References corr, relval_parameters_module::energy, and ESMapping_.

Referenced by EMShowerSimulation().

1323 {
1324  std::map<CaloHitID,float>::const_iterator mapitr;
1325  std::map<CaloHitID,float>::const_iterator endmapitr=hitMap.end();
1326  ESMapping_.reserve(ESMapping_.size()+hitMap.size());
1327  for(mapitr=hitMap.begin();mapitr!=endmapitr;++mapitr) {
1328  //correct energy
1329  float energy = mapitr->second;
1330  energy *= corr;
1331 
1332  //make finalized CaloHitID
1333  CaloHitID current_id(mapitr->first.unitID(),mapitr->first.timeSlice(),trackID);
1334 
1335  ESMapping_.push_back(std::pair<CaloHitID,float>(current_id,energy));
1336  }
1337 }
std::vector< std::pair< CaloHitID, float > > ESMapping_
JetCorrectorParameters corr
Definition: classes.h:11

Member Data Documentation

GammaFunctionGenerator* CalorimetryManager::aGammaGenerator
private

Definition at line 155 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and EMShowerSimulation().

const LandauFluctuationGenerator* CalorimetryManager::aLandauGenerator
private

Definition at line 154 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and EMShowerSimulation().

double CalorimetryManager::aTerm
private

Definition at line 142 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

bool CalorimetryManager::bFixedLength_
private

Definition at line 180 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

double CalorimetryManager::bTerm
private

Definition at line 142 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

double CalorimetryManager::crackPadSurvivalProbability_
private

Definition at line 137 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

DQMStore* CalorimetryManager::dbe
private
bool CalorimetryManager::debug_
private
std::vector<std::pair<CaloHitID,float> > CalorimetryManager::EBMapping_
private

Definition at line 107 of file CalorimetryManager.h.

Referenced by clean(), loadFromEcalBarrel(), and updateECAL().

bool CalorimetryManager::EcalDigitizer_
private

Definition at line 119 of file CalorimetryManager.h.

Referenced by readParameters().

double CalorimetryManager::ecorr
private

Definition at line 165 of file CalorimetryManager.h.

Referenced by HDShowerSimulation(), and respCorr().

std::vector<std::pair<CaloHitID,float> > CalorimetryManager::EEMapping_
private

Definition at line 108 of file CalorimetryManager.h.

Referenced by clean(), loadFromEcalEndcap(), and updateECAL().

std::vector<std::pair<CaloHitID,float> > CalorimetryManager::ESMapping_
private

Definition at line 110 of file CalorimetryManager.h.

Referenced by clean(), loadFromPreshower(), and updatePreshower().

std::vector<unsigned int> CalorimetryManager::evtsToDebug_
private

Definition at line 114 of file CalorimetryManager.h.

Referenced by readParameters(), and reconstruct().

int CalorimetryManager::gridSize_
private

Definition at line 144 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

bool CalorimetryManager::HcalDigitizer_
private

Definition at line 120 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

double CalorimetryManager::hcorr
private

Definition at line 166 of file CalorimetryManager.h.

Referenced by HDShowerSimulation(), and respCorr().

int CalorimetryManager::hdGridSize_
private

Definition at line 148 of file CalorimetryManager.h.

Referenced by HDShowerSimulation(), MuonMipSimulation(), and readParameters().

int CalorimetryManager::hdSimMethod_
private

Definition at line 148 of file CalorimetryManager.h.

Referenced by HDShowerSimulation(), and readParameters().

std::vector<std::pair<CaloHitID,float> > CalorimetryManager::HMapping_
private

Definition at line 109 of file CalorimetryManager.h.

Referenced by clean(), loadFromHcal(), and updateHCAL().

int CalorimetryManager::ietaShiftHB_
private

Definition at line 124 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

int CalorimetryManager::ietaShiftHE_
private

Definition at line 124 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

int CalorimetryManager::ietaShiftHF_
private

Definition at line 124 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

int CalorimetryManager::ietaShiftHO_
private

Definition at line 124 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

bool CalorimetryManager::initialized_
private

Definition at line 169 of file CalorimetryManager.h.

Referenced by reconstruct().

std::vector<double> CalorimetryManager::k_e
private

Definition at line 163 of file CalorimetryManager.h.

Referenced by readParameters(), and respCorr().

std::vector<double> CalorimetryManager::k_h
private

Definition at line 164 of file CalorimetryManager.h.

Referenced by readParameters(), and respCorr().

std::vector<double> CalorimetryManager::mipValues_
private

Definition at line 143 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

std::vector<FSimTrack> CalorimetryManager::muonSimTracks
private

Definition at line 171 of file CalorimetryManager.h.

Referenced by clean(), loadMuonSimTracks(), and MuonMipSimulation().

CaloGeometryHelper* CalorimetryManager::myCalorimeter_
private
RawParticle CalorimetryManager::myElec
private

A few pointers to save time.

Definition at line 131 of file CalorimetryManager.h.

Referenced by EMShowerSimulation().

HCALResponse* CalorimetryManager::myHDResponse_
private
Histos* CalorimetryManager::myHistos
private

Definition at line 100 of file CalorimetryManager.h.

HSParameters* CalorimetryManager::myHSParameters_
private

Definition at line 105 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and HDShowerSimulation().

RawParticle CalorimetryManager::myPart
private

Definition at line 133 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), HDShowerSimulation(), and MuonMipSimulation().

RawParticle CalorimetryManager::myPosi
private

Definition at line 132 of file CalorimetryManager.h.

Referenced by EMShowerSimulation().

FSimEvent* CalorimetryManager::mySimEvent
private

Definition at line 97 of file CalorimetryManager.h.

Referenced by reconstruct().

std::vector< std::pair< int, float > > CalorimetryManager::myZero_
staticprivate
Initial value:
= std::vector<std::pair<int,float> >
(1,std::pair<int,float>(0,0.))

Definition at line 157 of file CalorimetryManager.h.

int CalorimetryManager::optionHDSim_
private

Definition at line 148 of file CalorimetryManager.h.

Referenced by HDShowerSimulation(), readParameters(), and reconstruct().

std::vector<double> CalorimetryManager::p_knots
private

Definition at line 162 of file CalorimetryManager.h.

Referenced by readParameters(), and respCorr().

double CalorimetryManager::pulledPadSurvivalProbability_
private

Definition at line 136 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

double CalorimetryManager::radiusFactorEB_
private

Definition at line 140 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

double CalorimetryManager::radiusFactorEE_
private

Definition at line 140 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

std::vector<double> CalorimetryManager::radiusPreshowerCorrections_
private

Definition at line 141 of file CalorimetryManager.h.

Referenced by readParameters().

const RandomEngine* CalorimetryManager::random
private
double CalorimetryManager::RCFactor_
private

Definition at line 146 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

std::vector<double> CalorimetryManager::rsp
private

Definition at line 161 of file CalorimetryManager.h.

Referenced by readParameters().

double CalorimetryManager::RTFactor_
private

Definition at line 146 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

std::vector<double> CalorimetryManager::samplingHBHE_
private

Definition at line 121 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

std::vector<double> CalorimetryManager::samplingHF_
private

Definition at line 122 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

std::vector<double> CalorimetryManager::samplingHO_
private

Definition at line 123 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

bool CalorimetryManager::simulatePreshower_
private

Definition at line 149 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), readParameters(), and reconstruct().

double CalorimetryManager::spotFraction_
private

Definition at line 138 of file CalorimetryManager.h.

Referenced by readParameters().

GflashAntiProtonShowerProfile* CalorimetryManager::theAntiProtonProfile
private

Definition at line 186 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and HDShowerSimulation().

std::vector<double> CalorimetryManager::theCoreIntervals_
private

Definition at line 145 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

MaterialEffects* CalorimetryManager::theMuonEcalEffects
private
MaterialEffects* CalorimetryManager::theMuonHcalEffects
private
GflashPiKShowerProfile* CalorimetryManager::thePiKProfile
private

Definition at line 184 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and HDShowerSimulation().

GflashHadronShowerProfile* CalorimetryManager::theProfile
private
GflashProtonShowerProfile* CalorimetryManager::theProtonProfile
private

Definition at line 185 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and HDShowerSimulation().

std::vector<double> CalorimetryManager::theTailIntervals_
private

Definition at line 145 of file CalorimetryManager.h.

Referenced by EMShowerSimulation(), and readParameters().

std::vector<double> CalorimetryManager::timeShiftHB_
private

Definition at line 125 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

std::vector<double> CalorimetryManager::timeShiftHE_
private

Definition at line 126 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

std::vector<double> CalorimetryManager::timeShiftHF_
private

Definition at line 127 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

std::vector<double> CalorimetryManager::timeShiftHO_
private

Definition at line 128 of file CalorimetryManager.h.

Referenced by readParameters(), and updateHCAL().

bool CalorimetryManager::unfoldedMode_
private

Definition at line 116 of file CalorimetryManager.h.

bool CalorimetryManager::useDQM_
private

Definition at line 113 of file CalorimetryManager.h.

Referenced by CalorimetryManager(), and readParameters().