CMS 3D CMS Logo

List of all members | Public Member Functions
EvolutionECAL Class Reference

#include <EvolutionECAL.h>

Public Member Functions

double AgingVPT (double instLumi, double integralLumi, double eta)
 
double ChargeVPTCathode (double instLumi, double eta, double integralLumi)
 
double DamageProfileEta (double eta)
 
double DamageProfileEtaAPD (double eta)
 
double DegradationMeanEM50GeV (double mu)
 
double DegradationNonLinearityEM50GeV (double mu, double ene)
 
double DoseLongitudinalProfile (double z)
 
Double_t EquilibriumFractionColorCentersEM (double *x, double *par)
 
 EvolutionECAL ()
 
double InducedAbsorptionEM (double lumi, double eta)
 
double InducedAbsorptionHadronic (double lumi, double eta)
 
double LightCollectionEfficiency (double z, double mu)
 
double LightCollectionEfficiencyWeighted (double z, double mu_ind)
 
double NoiseFactorFE (double lumi, double eta)
 
double ResolutionConstantTermEM50GeV (double mu)
 
virtual ~EvolutionECAL ()
 

Detailed Description

Definition at line 23 of file EvolutionECAL.h.

Constructor & Destructor Documentation

EvolutionECAL::EvolutionECAL ( )

Definition at line 8 of file EvolutionECAL.cc.

8 {}
EvolutionECAL::~EvolutionECAL ( )
virtual

Definition at line 5 of file EvolutionECAL.cc.

5 {}

Member Function Documentation

double EvolutionECAL::AgingVPT ( double  instLumi,
double  integralLumi,
double  eta 
)

Definition at line 360 of file EvolutionECAL.cc.

References ChargeVPTCathode(), MillePedeFileConverter_cfg::e, JetChargeProducer_cfi::exp, class-composition::Q, and mps_fire::result.

Referenced by EnergyResolutionVsLumi::calcampDropPhotoDetector(), and EnergyResolutionVsLumi::CalculateDegradation().

360  {
361  if (fabs(eta) < 1.497)
362  return 1.0;
363  double Q = ChargeVPTCathode(instLumi, eta, integralLumi);
364  double result = 0.772 + 0.228 * (3.94304e-01 * exp(-Q / 5.99232e-04) + (1 - 3.94304e-01) * exp(-Q / 1.58243e-02));
365  return result;
366 }
double ChargeVPTCathode(double instLumi, double eta, double integralLumi)
double EvolutionECAL::ChargeVPTCathode ( double  instLumi,
double  eta,
double  integralLumi 
)

Definition at line 345 of file EvolutionECAL.cc.

References ALCARECOTkAlJpsiMuMu_cff::charge, DamageProfileEta(), DegradationMeanEM50GeV(), InducedAbsorptionEM(), and InducedAbsorptionHadronic().

Referenced by AgingVPT().

345  {
346  double charge = 0.0;
347  double tmpLumi = 0.0;
348  double stepLumi = 1.0;
349  double muEM = InducedAbsorptionEM(instLumi, eta);
350  while (tmpLumi < integralLumi) {
351  tmpLumi += stepLumi;
352  double muHD = InducedAbsorptionHadronic(tmpLumi, eta);
353  double SS0 = DegradationMeanEM50GeV(muEM + muHD);
354  charge += SS0 * 0.26e-3 * DamageProfileEta(eta) * stepLumi;
355  }
356  return charge;
357 }
double DegradationMeanEM50GeV(double mu)
double InducedAbsorptionHadronic(double lumi, double eta)
double InducedAbsorptionEM(double lumi, double eta)
double DamageProfileEta(double eta)
double EvolutionECAL::DamageProfileEta ( double  eta)

Definition at line 175 of file EvolutionECAL.cc.

References JetChargeProducer_cfi::exp, and x.

Referenced by ChargeVPTCathode(), EquilibriumFractionColorCentersEM(), and InducedAbsorptionHadronic().

175  {
176  double x = fabs(eta);
177  if (x < 1.497) {
178  return exp(-4.11065 + 0.258478 * x);
179  } else {
180  return exp(-13.5112 + 7.913860 * x - 0.998649 * x * x);
181  }
182 }
double EvolutionECAL::DamageProfileEtaAPD ( double  eta)

Definition at line 185 of file EvolutionECAL.cc.

References stringResolutionProvider_cfi::et, and x.

Referenced by NoiseFactorFE().

185  {
186  double x = fabs(eta);
187  if (x < 1.497) {
188  double et = x / 1.48 * 34.0;
189  double etaprof = (9.54827 + et * 0.0379222 + et * et * (-0.00257047) + et * et * et * 0.00073546 +
190  et * et * et * et * (-1.49683e-05)) /
191  9.54827;
192  return etaprof;
193  } else {
194  return 1.0;
195  }
196 }
et
define resolution functions of each parameter
double EvolutionECAL::DegradationMeanEM50GeV ( double  mu)

Definition at line 253 of file EvolutionECAL.cc.

References alpha, MillePedeFileConverter_cfg::e, JetChargeProducer_cfi::exp, connectstrParser::f1, connectstrParser::f2, mps_fire::i, cmsBatch::log, RPCpg::mu, and x.

Referenced by EnergyResolutionVsLumi::calcampDropTransparency(), EnergyResolutionVsLumi::CalculateDegradation(), and ChargeVPTCathode().

253  {
254  double retval = 1.0;
255  double x = mu;
256  if (x < 1e-4)
257  return retval;
258  if (x >= 200.0)
259  x = 200.0; // parameterization is not valid for large mu
260 
261  double par[11] = {1.00000e+01,
262  -4.41441e-01,
263  7.08607e-02,
264  -3.75572e-01,
265  -3.60410e-01,
266  1.30130e-01,
267  -4.72350e-01,
268  3.36315e-01,
269  -1.19872e-01,
270  1.99574e-02,
271  -1.22910e-03};
272 
273  double alpha = par[0];
274 
275  double f1 = par[1] * x + par[2] * x * x;
276  double u = log(x);
277  double f2 = par[10];
278  for (int i = 9; i >= 3; i--)
279  f2 = par[i] + f2 * u;
280 
281  retval = f1 / (1.0 + exp(alpha * u)) + f2 / (1.0 + exp(-alpha * u));
282  retval = exp(retval);
283  return retval;
284 }
float alpha
Definition: AMPTWrapper.h:95
const int mu
Definition: Constants.h:22
double EvolutionECAL::DegradationNonLinearityEM50GeV ( double  mu,
double  ene 
)

Definition at line 287 of file EvolutionECAL.cc.

References MillePedeFileConverter_cfg::e, mps_fire::i, RPCpg::mu, slope, and x.

287  {
288  if (ene <= 1e-3)
289  return 0.0;
290 
291  double x = mu;
292  if (mu <= 0.06)
293  x = 0.06;
294  if (mu >= 150.0)
295  x = 150.0;
296 
297  double par[9] = {5.17712e-03,
298  1.97597e-02,
299  3.36596e-02,
300  2.84505e-02,
301  1.38480e-02,
302  1.11498e-02,
303  7.73634e-03,
304  -1.30767e-03,
305  -2.20628e-03};
306 
307  double u = log10(x);
308  double slope = par[8];
309  for (int i = 7; i >= 0; i--)
310  slope = par[i] + slope * u;
311 
312  double retval = 1.0 + slope * log10(ene / 50.0);
313  if (retval <= 0.0)
314  retval = 0.0;
315  return retval;
316 }
static const double slope[3]
const int mu
Definition: Constants.h:22
double EvolutionECAL::DoseLongitudinalProfile ( double  z)

Definition at line 206 of file EvolutionECAL.cc.

References alpha, pfBoostedDoubleSVAK8TagInfos_cfi::beta, JetChargeProducer_cfi::exp, Gamma, PFRecoTauDiscriminationByIsolation_cfi::offset, and funct::pow().

Referenced by EquilibriumFractionColorCentersEM().

206  {
207  double alpha = 4.72877e+00;
208  double beta = 5.91296e-01;
209  double amp1 = 6.24495e+02;
210  double amp2 = 1.84367e-01;
211  double offset = 2.00705e+01;
212  if (z >= 0.0 && z <= 22.0) {
213  double term1 = (amp1 / TMath::Gamma(alpha)) * pow((beta * z), (alpha - 1)) * exp(-beta * z);
214  double term2 = amp2 * (z - 11.0) * (z - 11.0) + offset;
215  return (term1 + term2) / 150.44;
216  } else {
217  return 0;
218  }
219 }
float alpha
Definition: AMPTWrapper.h:95
dbl * Gamma
Definition: mlp_gen.cc:38
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
Double_t EvolutionECAL::EquilibriumFractionColorCentersEM ( double *  x,
double *  par 
)

Definition at line 222 of file EvolutionECAL.cc.

References alpha, DamageProfileEta(), DoseLongitudinalProfile(), MillePedeFileConverter_cfg::e, PVValHelper::eta, and RPCpg::rate().

Referenced by InducedAbsorptionEM().

222  {
223  double instantLumi = par[0];
224  double eta = par[1];
225  double rate = DoseLongitudinalProfile(x[0]) * 5.0 * DamageProfileEta(eta) * instantLumi / 1e+34;
226  if (rate <= 0.0)
227  rate = 0.0;
228  double alpha = par[2];
229  return rate / (alpha + rate);
230 }
float alpha
Definition: AMPTWrapper.h:95
double DoseLongitudinalProfile(double z)
double rate(double x)
Definition: Constants.cc:3
double DamageProfileEta(double eta)
double EvolutionECAL::InducedAbsorptionEM ( double  lumi,
double  eta 
)

Definition at line 233 of file EvolutionECAL.cc.

References EquilibriumFractionColorCentersEM().

Referenced by EnergyResolutionVsLumi::calcmuEM(), EnergyResolutionVsLumi::calcmuTot(), EnergyResolutionVsLumi::CalculateDegradation(), and ChargeVPTCathode().

233  {
234  double mu_max = 2.0;
235  double alpha1 = 3.41488e+00;
236 
237  TF1 *ftmp1 = new TF1("ftmp1",
238  this,
240  0.0,
241  22.0,
242  3,
243  "EvolutionECAL",
244  "EquilibriumFractionColorCentersEM");
245  ftmp1->SetParameters(lumi, eta, alpha1);
246  double muEM = mu_max * ftmp1->Integral(0.0, 22.0) / 22.0;
247 
248  delete ftmp1;
249  return muEM;
250 }
Double_t EquilibriumFractionColorCentersEM(double *x, double *par)
double EvolutionECAL::InducedAbsorptionHadronic ( double  lumi,
double  eta 
)

Definition at line 199 of file EvolutionECAL.cc.

References DamageProfileEta(), csvLumiCalc::lumi, RPCpg::mu, and funct::pow().

Referenced by EnergyResolutionVsLumi::calcmuHD(), EnergyResolutionVsLumi::calcmuTot(), EnergyResolutionVsLumi::CalculateDegradation(), and ChargeVPTCathode().

199  {
200  double fluence = DamageProfileEta(eta) * 2.7e+13 / 500.0 * lumi;
201  double mu = 2.08E-13 * pow(fluence, 1.0049);
202  return mu;
203 }
const int mu
Definition: Constants.h:22
double DamageProfileEta(double eta)
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
double EvolutionECAL::LightCollectionEfficiency ( double  z,
double  mu 
)

Definition at line 11 of file EvolutionECAL.cc.

References patCaloMETCorrections_cff::A, TtFullHadDaughter::B, patCaloMETCorrections_cff::C, fftjetpileupestimator_calo_uncalib_cfi::c0, alignmentValidation::c1, allConversions_cfi::d0, JetChargeProducer_cfi::exp, f, RPCpg::mu, funct::pow(), dttmaxenums::R, and z.

11  {
12  double f = 0;
13  if (z <= 0)
14  return f;
15  if (z >= 0.22)
16  return f;
17 
18  double e0 = 6.91563e-02;
19  double e1 = 1.64406e+00;
20  double e2 = 6.42509e-01;
21  double E = e0 / (1 + exp(e1 * (log10(mu) - e2)));
22 
23  double d0 = 3.85334e-01;
24  double d1 = -1.04647e-02;
25  double D = d0 * exp(d1 * mu);
26 
27  double c0 = 3.77629e-01;
28  double c1 = -3.23755e-01;
29  double c2 = 1.50247e+00;
30  double c3 = 3.03278e-01;
31  double C = -1 + c0 * exp(c1 * mu) * (1 + c2 * exp(c3 * mu));
32 
33  double b0 = -3.33575e-01;
34  double b1 = 4.44856e-01;
35  double b2 = 1.91766e+00;
36  double b3 = 2.69423e+00;
37  double b4 = 1.06905e+00;
38  double B =
39  (1 / mu) * (b0 + b1 * log10(mu) + b2 * pow(log10(mu), 2) + b3 * pow(log10(mu), 3) + b4 * pow(log10(mu), 4));
40 
41  double a0 = 7.18248e-02;
42  double a1 = 1.89016e+00;
43  double a2 = 2.15651e-02;
44  double a3 = 2.30786e-02;
45  double A = exp(B * mu * 0.015) * (a0 / (exp(a1 * (log10(mu) + a2)) + 1) + a3);
46 
47  double R = 0.01 * D * (4 / (0.222 + E) / (0.222 + E) - 1 / ((0.22 - z) * (z + E)));
48  f = A * exp(-B * mu * (0.22 - z)) * (1 + C * exp(R));
49 
50  return f;
51 }
double f[11][100]
const int mu
Definition: Constants.h:22
static const std::string B
DecomposeProduct< arg, typename Div::arg > D
Definition: Factorize.h:152
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
double EvolutionECAL::LightCollectionEfficiencyWeighted ( double  z,
double  mu_ind 
)

Definition at line 120 of file EvolutionECAL.cc.

References patCaloMETCorrections_cff::A, TtFullHadDaughter::B, patCaloMETCorrections_cff::C, fftjetpileupestimator_calo_uncalib_cfi::c0, alignmentValidation::c1, allConversions_cfi::d0, JetChargeProducer_cfi::exp, f, RPCpg::mu, funct::pow(), dttmaxenums::R, pfBoostedDoubleSVAK8TagInfos_cfi::R0, and z.

Referenced by EnergyResolutionVsLumi::calcLightCollectionEfficiencyWeighted(), and EnergyResolutionVsLumi::calcLightCollectionEfficiencyWeighted2().

120  {
121  if (z <= 0)
122  return 0;
123  if (z >= 1)
124  return 0;
125  if (mu_ind < 0)
126  return 1;
127 
128  double mu = mu_ind + 0.7;
129  double lmu = log10(mu);
130 
131  double e0 = 6.91563e-02;
132  double e1 = 1.64406e+00;
133  double e2 = 6.42509e-01;
134  double E = e0 / (1 + exp(e1 * (lmu - e2)));
135 
136  double d0 = 3.85334e-01;
137  double d1 = -1.04647e-02;
138  double D = d0 * exp(d1 * mu);
139 
140  double c0 = 3.77629e-01;
141  double c1 = -3.23755e-01;
142  double c2 = 1.50247e+00;
143  double c3 = 3.03278e-01;
144  double C = -1 + c0 * exp(c1 * mu) * (1 + c2 * exp(c3 * mu));
145 
146  double b0 = -3.33575e-01;
147  double b1 = 4.44856e-01;
148  double b2 = 1.91766e+00;
149  double b3 = 2.69423e+00;
150  double b4 = 1.06905e+00;
151  double B = (1 / mu) * (b0 + b1 * lmu + b2 * pow(lmu, 2) + b3 * pow(lmu, 3) + b4 * pow(lmu, 4));
152 
153  double a0 = 7.18248e-02;
154  double a1 = 1.89016e+00;
155  double a2 = 2.15651e-02;
156  double a3 = 2.30786e-02;
157  double A = exp(B * mu * 0.015) * (a0 / (exp(a1 * (lmu + a2)) + 1) + a3);
158 
159  double R = 0.01 * D * (4 / (0.222 + E) / (0.222 + E) - 1 / ((0.22 * 0.22) * (1. - z) * (z + E / 0.22)));
160 
161  // for undamaged crystal, mu0 = 0.7
162  double A0 = 0.0631452;
163  double B0 = -0.52267;
164  double C0 = -0.139646;
165  double D0 = 0.382522;
166  double E0 = 0.054473;
167  double R0 = 0.01 * D0 * (4 / (0.222 + E0) / (0.222 + E0) - 1 / ((0.22 * 0.22) * (1. - z) * (z + E0 / 0.22)));
168 
169  double f = A / A0 * exp(-(B * mu - B0 * 0.7) * 0.22 * (1. - z)) * (1 + C * exp(R)) / (1 + C0 * exp(R0));
170 
171  return f;
172 }
Divides< arg, void > D0
Definition: Factorize.h:145
double f[11][100]
const int mu
Definition: Constants.h:22
static const std::string B
DecomposeProduct< arg, typename Div::arg > D
Definition: Factorize.h:152
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
double EvolutionECAL::NoiseFactorFE ( double  lumi,
double  eta 
)

Definition at line 369 of file EvolutionECAL.cc.

References DamageProfileEtaAPD(), mathSSE::sqrt(), and x.

Referenced by EnergyResolutionVsLumi::calcnoiseADC(), EnergyResolutionVsLumi::calcnoiseIncreaseADC(), and EnergyResolutionVsLumi::CalculateDegradation().

369  {
370  double x = fabs(eta);
371  if (x < 1.497) {
372  return sqrt(1.0 + 0.495 * 0.03512 * lumi * DamageProfileEtaAPD(eta));
373  } else {
374  return 1.0;
375  }
376 }
T sqrt(T t)
Definition: SSEVec.h:18
double DamageProfileEtaAPD(double eta)
double EvolutionECAL::ResolutionConstantTermEM50GeV ( double  mu)

Definition at line 319 of file EvolutionECAL.cc.

References JetChargeProducer_cfi::exp, f, mps_fire::i, cmsBatch::log, RPCpg::mu, and x.

Referenced by EnergyResolutionVsLumi::calcresolutitonConstantTerm(), and EnergyResolutionVsLumi::CalculateDegradation().

319  {
320  double x = mu;
321  if (mu <= 0.01)
322  x = 0.01;
323  if (mu >= 200.0)
324  x = 200.0;
325 
326  double par[10] = {-6.21503e+00,
327  1.59759e+00,
328  -4.75221e-02,
329  -3.90299e-02,
330  3.97269e-03,
331  2.29574e-03,
332  -1.05280e-04,
333  -9.60963e-05,
334  -1.29594e-06,
335  1.70850e-06};
336 
337  double u = log(x);
338  double f = par[9];
339  for (int i = 8; i >= 0; i--)
340  f = par[i] + f * u;
341  return exp(f);
342 }
double f[11][100]
const int mu
Definition: Constants.h:22