CMS 3D CMS Logo

/afs/cern.ch/work/a/aaltunda/public/www/CMSSW_5_3_13_patch3/src/FastSimulation/CalorimeterProperties/src/ECALBarrelProperties.cc

Go to the documentation of this file.
00001 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00002 
00003 //This class header
00004 #include "FastSimulation/CalorimeterProperties/interface/ECALBarrelProperties.h"
00005 #include "TMath.h"
00006 #include <iostream>
00007 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00008 
00009 ECALBarrelProperties::ECALBarrelProperties(const edm::ParameterSet& fastDet)
00010 {
00011 
00012   using namespace std;
00013 
00014   edm::ParameterSet fastDetBarrel = fastDet.getParameter<edm::ParameterSet>("BarrelCalorimeterProperties");
00015 
00016   lightColl_ =  fastDetBarrel.getParameter<double>("lightColl");  
00017   lightCollUnif_ = fastDetBarrel.getParameter<double>("lightCollUnif");
00018   photoStatistics_ = fastDetBarrel.getParameter<double>("photoStatistics");
00019   thickness_ = fastDetBarrel.getParameter<double>("thickness");
00020   interactionLength_ = fastDetBarrel.getParameter<double>("interactionLength");
00021 
00022   Aeff_ = fastDetBarrel.getParameter<double>("Aeff");
00023   Zeff_ = fastDetBarrel.getParameter<double>("Zeff");
00024   rho_ = fastDetBarrel.getParameter<double>("rho");
00025   radLenIngcm2_ = fastDetBarrel.getParameter<double>("radLenIngcm2");
00026 
00027   radLenIncm_ = fastDetBarrel.getParameter<double>("radLenIncm");
00028   radLenIncm_ = (radLenIncm_ < 0) ? radLenIngcm2_/rho_ : radLenIncm_;
00029 
00030   criticalEnergy_ = fastDetBarrel.getParameter<double>("criticalEnergy");
00031   criticalEnergy_ = (criticalEnergy_ < 0) ? 2.66E-3*TMath::Power((radLenIngcm2_*Zeff_/Aeff_),1.1) : criticalEnergy_;
00032 
00033   moliereRadius_  = fastDetBarrel.getParameter<double>("moliereRadius");
00034   moliereRadius_  = (moliereRadius_ < 0) ? scaleEnergy_/criticalEnergy_*radLenIncm_ : moliereRadius_;
00035 
00036   Fs_ = fastDetBarrel.getParameter<double>("Fs");
00037   ehat_ = fastDetBarrel.getParameter<double>("ehat");
00038   resE_ = fastDetBarrel.getParameter<double>("resE");
00039 
00040   bHom_ = fastDetBarrel.getParameter<bool>("bHom");
00041 
00042   bool debug = fastDetBarrel.getParameter<bool>("debug");
00043 
00044   if (debug)
00045     LogDebug("ECALEndcapProperties")  <<" ========== Barrel ========= " << endl
00046          <<" \t\t isHom ? " << bHom_ << endl
00047          <<" lightColl = " << lightColl_ << endl
00048          <<" lightCollUnif_ = " <<  lightCollUnif_  << endl
00049          <<" photoStatistics_ = " << photoStatistics_ << endl
00050          <<" thickness_ = " << thickness_ << endl
00051          <<" interactionLength_ = " << interactionLength_ << endl
00052          <<" Aeff_ = " << Aeff_ << endl
00053          <<" Zeff_ = " << Zeff_ << endl
00054          <<" rho_ = " << rho_ << endl
00055          <<" radLenIngcm2_ = " << radLenIngcm2_ << endl
00056          <<" radLenIncm_ = " << radLenIncm_ << endl
00057          <<" moliereRadius_ = " << moliereRadius_ << endl
00058          <<" criticalEnergy_ = " << criticalEnergy_ << endl
00059          <<" scaleEnergy_ = " << scaleEnergy_ << endl
00060          <<" Fs = " << Fs_ << " ehat = " << ehat_ << " resE = " << resE_ << endl;
00061 
00062   
00063   
00064 
00065 
00066 }