CMS 3D CMS Logo

List of all members | Public Member Functions
LowEnergyFastSimParam Class Reference

#include <LowEnergyFastSimParam.h>

Public Member Functions

G4double GetInPointEnergyFraction (G4double energy) const
 
G4double GetRadius (G4double energy) const
 
G4double GetZ () const
 

Detailed Description

Definition at line 8 of file LowEnergyFastSimParam.h.

Member Function Documentation

◆ GetInPointEnergyFraction()

G4double LowEnergyFastSimParam::GetInPointEnergyFraction ( G4double  energy) const
inline

Definition at line 10 of file LowEnergyFastSimParam.h.

References a0, testProducerWithPsetDescEmpty_cfi::a2, SiPixelPhase1Clusters_cfi::e3, and HCALHighEnergyHPDFilter_cfi::energy.

Referenced by LowEnergyFastSimModel::DoIt().

10  {
11  // normalisation of fit parameters to have the result
12  constexpr const G4double a0 = 1.02186764;
13  constexpr const G4double a1 = 2.14064635e-02 / a0;
14  constexpr const G4double a2 = 1.96988997e-04 / a0;
15  constexpr const G4double a3 = -6.42310317e-07 / a0;
16  const G4double e2 = energy * energy;
17  const G4double e3 = e2 * energy;
18  return a3 * e3 + a2 * e2 - a1 * energy + 1.0;
19  }
static constexpr float a0

◆ GetRadius()

G4double LowEnergyFastSimParam::GetRadius ( G4double  energy) const
inline

Definition at line 21 of file LowEnergyFastSimParam.h.

References HCALHighEnergyHPDFilter_cfi::energy, diffTwoXMLs::r1, diffTwoXMLs::r2, and mathSSE::sqrt().

Referenced by LowEnergyFastSimModel::DoIt().

21  {
22  constexpr const G4double r1 = 156.52094133;
23  constexpr const G4double r2 = -1.02220543;
24  const G4double r0 = r1 + r2 * energy;
25  return std::sqrt(r0 / G4UniformRand() - r0);
26  }
T sqrt(T t)
Definition: SSEVec.h:19

◆ GetZ()

G4double LowEnergyFastSimParam::GetZ ( void  ) const
inline

Definition at line 28 of file LowEnergyFastSimParam.h.

References alpha, and submitPVValidationJobs::t.

Referenced by LowEnergyFastSimModel::DoIt().

28  {
29  constexpr const G4double alpha = 1.0 / 0.02211515;
30  constexpr const G4double t = 0.66968625;
31  return -G4Log(G4UniformRand()) * alpha + t;
32  }
float alpha
Definition: AMPTWrapper.h:105