Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:11:13

0001 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0002 
0003 //This class header
0004 #include "FastSimulation/CalorimeterProperties/interface/PreshowerLayer2Properties.h"
0005 #include <cmath>
0006 PreshowerLayer2Properties::PreshowerLayer2Properties(const edm::ParameterSet& fastDet) : PreshowerProperties() {
0007   // Preshower : mumber of Mips / GeV
0008   mips = fastDet.getParameter<double>("PreshowerLayer2_mipsPerGeV");
0009   thick = fastDet.getParameter<double>("PreshowerLayer2_thickness");
0010   pseeradLenIncm_ = fastDet.getUntrackedParameter<double>("PreshowerEEGapRadLenInCm", 63.);
0011   pseeInteractionLength_ = fastDet.getUntrackedParameter<double>("PreshowerEEGapIntLenInCm", 111.);
0012 }
0013 
0014 double PreshowerLayer2Properties::thickness(const double eta) const {
0015   // eta is the pseudorapidity
0016   double e = exp(-eta);
0017   double e2 = e * e;
0018   // 1 / cos theta
0019   double cinv = (1. + e2) / (1. - e2);
0020   //    double c  = (1.-e2)/(1.+e2);
0021   //    double s  = 2.*e/(1.+e2);
0022   //    double t  = 2.*e/(1.-e2);
0023   double feta = fabs(eta);
0024 
0025   if (1.637 < feta && feta < 2.625) {
0026     return thick * fabs(cinv);
0027   } else {
0028     return 0;
0029   }
0030 }