CalibCalorimetry
HcalAlgos
src
HcalTimeSlew.cc
Go to the documentation of this file.
1
#include "
CalibCalorimetry/HcalAlgos/interface/HcalTimeSlew.h
"
2
#include <cmath>
3
#include <iostream>
4
5
void
HcalTimeSlew::addM2ParameterSet
(
float
tzero
,
float
slope
,
float
tmax
) {
6
parametersM2_
.emplace_back(
tzero
,
slope
,
tmax
);
7
}
8
9
void
HcalTimeSlew::addM3ParameterSet
(
double
cap
,
10
double
tspar0
,
11
double
tspar1
,
12
double
tspar2
,
13
double
tspar0_siPM
,
14
double
tspar1_siPM
,
15
double
tspar2_siPM
) {
16
parametersM3_
.emplace_back(
cap
,
tspar0
,
tspar1
,
tspar2
,
tspar0_siPM
,
tspar1_siPM
,
tspar2_siPM
);
17
}
18
19
// Used by M2/Simulation
20
float
HcalTimeSlew::delay
(
float
fC,
BiasSetting
bias)
const
{
21
float
rawDelay =
parametersM2_
[bias].tzero +
parametersM2_
[bias].slope *
std::log
(fC);
22
return
(rawDelay < 0) ? (0) : ((rawDelay >
parametersM2_
[bias].
tmax
) ? (
parametersM2_
[bias].tmax) : (rawDelay));
23
}
24
25
// Used by M3
26
double
HcalTimeSlew::delay
(
double
fC,
ParaSource
source
,
BiasSetting
bias,
bool
isHPD)
const
{
27
double
rawDelay = 0.0;
28
if
(
source
==
TestStand
) {
29
return
HcalTimeSlew::delay
(fC, bias);
30
}
else
if
(isHPD) {
31
rawDelay = std::fmin(
32
parametersM3_
[
source
].
cap
,
33
parametersM3_
[
source
].
tspar0
+
parametersM3_
[
source
].
tspar1
*
std::log
(fC +
parametersM3_
[
source
].
tspar2
));
34
}
else
{
35
rawDelay =
parametersM3_
[
source
].cap +
parametersM3_
[
source
].tspar0_siPM;
36
}
37
return
rawDelay;
38
}
HcalTimeSlew::parametersM3_
std::vector< HcalTimeSlewM3Parameters > parametersM3_
Definition:
HcalTimeSlew.h:80
HcalTimeSlew::ParaSource
ParaSource
Definition:
HcalTimeSlew.h:70
HcalTimeSlew::parametersM2_
std::vector< HcalTimeSlewM2Parameters > parametersM2_
Definition:
HcalTimeSlew.h:79
HcalTimeSlew.h
HLT_FULL_cff.tspar1_siPM
tspar1_siPM
Definition:
HLT_FULL_cff.py:6334
HcalTimeSlew::BiasSetting
BiasSetting
Definition:
HcalTimeSlew.h:71
HcalTimeSlew::delay
float delay(float fC, BiasSetting bias=Medium) const
Returns the amount (ns) by which a pulse of the given number of fC will be delayed by the timeslew ef...
Definition:
HcalTimeSlew.cc:20
tmax
static const double tmax[3]
Definition:
CastorTimeSlew.cc:7
HcalTimeSlew::addM2ParameterSet
void addM2ParameterSet(float tzero, float slope, float tmax)
Definition:
HcalTimeSlew.cc:5
source
static const std::string source
Definition:
EdmProvDump.cc:47
tzero
static const double tzero[3]
Definition:
CastorTimeSlew.cc:5
HLT_FULL_cff.tspar1
tspar1
Definition:
HLT_FULL_cff.py:6333
HLT_FULL_cff.tspar2
tspar2
Definition:
HLT_FULL_cff.py:6331
HLT_FULL_cff.cap
cap
Definition:
HLT_FULL_cff.py:6335
HLT_FULL_cff.tspar0_siPM
tspar0_siPM
Definition:
HLT_FULL_cff.py:6336
dqm-mbProfile.log
log
Definition:
dqm-mbProfile.py:17
slope
static const double slope[3]
Definition:
CastorTimeSlew.cc:6
HcalTimeSlew::TestStand
Definition:
HcalTimeSlew.h:70
HcalTimeSlew::addM3ParameterSet
void addM3ParameterSet(double cap, double tspar0, double tspar1, double tspar2, double tspar0_siPM, double tspar1_siPM, double tspar2_siPM)
Definition:
HcalTimeSlew.cc:9
HLT_FULL_cff.tspar2_siPM
tspar2_siPM
Definition:
HLT_FULL_cff.py:6337
HLT_FULL_cff.tspar0
tspar0
Definition:
HLT_FULL_cff.py:6332
Generated for CMSSW Reference Manual by
1.8.16