CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Attributes | Private Attributes
HFRecalibration Class Reference

#include <HFRecalibration.h>

Public Member Functions

double getCorr (int ieta, int idepth, double lumi)
 
 HFRecalibration (const edm::ParameterSet &pset)
 
 ~HFRecalibration ()
 

Static Public Attributes

static const unsigned int loweriEtaBin = 30
 
static const unsigned int upperiEtaBin = 41
 

Private Attributes

std::vector< double > HFParsAB [2][2]
 
double reCalFactor = 1.0
 

Detailed Description

Definition at line 19 of file HFRecalibration.h.

Constructor & Destructor Documentation

◆ HFRecalibration()

HFRecalibration::HFRecalibration ( const edm::ParameterSet pset)

Definition at line 15 of file HFRecalibration.cc.

References muonDTDigis_cfi::pset.

15  {
16  //HFParsAB[Depth=0/1][A=0/B=1]
17  HFParsAB[0][0] = pset.getParameter<vecOfDoubles>("HFdepthOneParameterA");
18  HFParsAB[0][1] = pset.getParameter<vecOfDoubles>("HFdepthOneParameterB");
19  HFParsAB[1][0] = pset.getParameter<vecOfDoubles>("HFdepthTwoParameterA");
20  HFParsAB[1][1] = pset.getParameter<vecOfDoubles>("HFdepthTwoParameterB");
21 }
std::vector< double > vecOfDoubles
std::vector< double > HFParsAB[2][2]

◆ ~HFRecalibration()

HFRecalibration::~HFRecalibration ( )

Definition at line 23 of file HFRecalibration.cc.

23 {}

Member Function Documentation

◆ getCorr()

double HFRecalibration::getCorr ( int  ieta,
int  idepth,
double  lumi 
)

Definition at line 25 of file HFRecalibration.cc.

References funct::abs(), LEDCalibrationChannels::depth, LEDCalibrationChannels::ieta, BXlumiParameters_cfi::lumi, and mathSSE::sqrt().

25  {
26  // parameterizations provided by James Wetzel
27 
28  ieta = (abs(ieta) - loweriEtaBin);
29 
30  if (ieta < 0 || ieta > 11 || depth < 1 || depth > 2) {
31  return 1.0;
32  }
33 
34  switch (depth) {
35  case 1:
36  reCalFactor = (1 + HFParsAB[0][0][ieta] * sqrt(lumi) + HFParsAB[0][1][ieta] * lumi);
37  break;
38  case 2:
39  reCalFactor = (1 + HFParsAB[1][0][ieta] * sqrt(lumi) + HFParsAB[1][1][ieta] * lumi);
40  }
41 
42  return reCalFactor;
43 }
std::vector< double > HFParsAB[2][2]
T sqrt(T t)
Definition: SSEVec.h:19
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
static const unsigned int loweriEtaBin

Member Data Documentation

◆ HFParsAB

std::vector<double> HFRecalibration::HFParsAB[2][2]
private

Definition at line 31 of file HFRecalibration.h.

◆ loweriEtaBin

const unsigned int HFRecalibration::loweriEtaBin = 30
static

Definition at line 26 of file HFRecalibration.h.

◆ reCalFactor

double HFRecalibration::reCalFactor = 1.0
private

Definition at line 32 of file HFRecalibration.h.

◆ upperiEtaBin

const unsigned int HFRecalibration::upperiEtaBin = 41
static

Definition at line 27 of file HFRecalibration.h.