CMS 3D CMS Logo

HFPreRecHit.cc
Go to the documentation of this file.
2 
3 std::pair<float, bool> HFPreRecHit::chargeAsymmetry(const float chargeThreshold) const {
4  std::pair<float, bool> result(0.f, false);
5  if (hasInfo_[0] && hasInfo_[1]) {
6  const float q0 = hfQIE10Info_[0].charge();
7  const float q1 = hfQIE10Info_[1].charge();
8  const float qsum = q0 + q1;
9  if (qsum > 0.f && qsum >= chargeThreshold) {
10  result.first = (q1 - q0) / qsum;
11  result.second = true;
12  }
13  }
14  return result;
15 }
16 
17 std::pair<float, bool> HFPreRecHit::energyAsymmetry(const float energyThreshold) const {
18  std::pair<float, bool> result(0.f, false);
19  if (hasInfo_[0] && hasInfo_[1]) {
20  const float e0 = hfQIE10Info_[0].energy();
21  const float e1 = hfQIE10Info_[1].energy();
22  const float esum = e0 + e1;
23  if (esum > 0.f && esum >= energyThreshold) {
24  result.first = (e1 - e0) / esum;
25  result.second = true;
26  }
27  }
28  return result;
29 }
HFPreRecHit::energyAsymmetry
std::pair< float, bool > energyAsymmetry(float energyThreshold) const
Definition: HFPreRecHit.cc:17
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
HFPreRecHit::chargeAsymmetry
std::pair< float, bool > chargeAsymmetry(float chargeThreshold) const
Definition: HFPreRecHit.cc:3
HFQIE10Info::energy
constexpr float energy() const
Definition: HFQIE10Info.h:80
HFQIE10Info::charge
constexpr float charge() const
Definition: HFQIE10Info.h:79
q1
double q1[4]
Definition: TauolaWrapper.h:87
StorageManager_cfg.e1
e1
Definition: StorageManager_cfg.py:16
HFPreRecHit::hasInfo_
bool hasInfo_[2]
Definition: HFPreRecHit.h:85
HFPreRecHit::hfQIE10Info_
HFQIE10Info hfQIE10Info_[2]
Definition: HFPreRecHit.h:84
mps_fire.result
result
Definition: mps_fire.py:303
ClusterTask_cfi.energyThreshold
energyThreshold
Definition: ClusterTask_cfi.py:3
HFPreRecHit.h
SiStripMonitorCluster_cfi.q0
q0
Definition: SiStripMonitorCluster_cfi.py:241