All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Public Member Functions | Private Member Functions | Private Attributes | List of all members
opdet::PMTGainFluctuations1Dynode Class Reference
Inheritance diagram for opdet::PMTGainFluctuations1Dynode:
opdet::PMTGainFluctuations

Classes

struct  Config
 

Public Member Functions

 PMTGainFluctuations1Dynode (art::ToolConfigTable< Config > const &config)
 
double GainFluctuation (unsigned int npe, CLHEP::HepRandomEngine *eng) override
 

Private Member Functions

double DynodeGain (unsigned int dynstage)
 
- Private Member Functions inherited from opdet::PMTGainFluctuations
virtual ~PMTGainFluctuations () noexcept=default
 

Private Attributes

double fDynodeK
 
double fGain
 
std::vector< double > fVoltageDistribution
 
double fDynodeGain
 

Detailed Description

Definition at line 30 of file PMTGainFluctuations1Dynode_tool.cc.

Constructor & Destructor Documentation

opdet::PMTGainFluctuations1Dynode::PMTGainFluctuations1Dynode ( art::ToolConfigTable< Config > const &  config)
explicit

Definition at line 72 of file PMTGainFluctuations1Dynode_tool.cc.

73  : fDynodeK { config().dynodeK() }
74  , fGain { config().gain() }
75  , fVoltageDistribution { config().voltageDistribution() }
76  , fDynodeGain { DynodeGain(1) }
77 {
78 }

Member Function Documentation

double opdet::PMTGainFluctuations1Dynode::DynodeGain ( unsigned int  dynstage)
private

Definition at line 81 of file PMTGainFluctuations1Dynode_tool.cc.

81  {
82  double prodRho = 1.0;
83  for(double rho: fVoltageDistribution) prodRho *= rho;
84  double const aVk = std::pow(fGain / std::pow(prodRho, fDynodeK), 1.0/static_cast<double>(fVoltageDistribution.size()));
85  return aVk * std::pow(fVoltageDistribution.at(dynstage - 1), fDynodeK);
86 }
double opdet::PMTGainFluctuations1Dynode::GainFluctuation ( unsigned int  npe,
CLHEP::HepRandomEngine *  eng 
)
overridevirtual

Implements opdet::PMTGainFluctuations.

Definition at line 89 of file PMTGainFluctuations1Dynode_tool.cc.

89  {
90  return CLHEP::RandPoissonQ::shoot(eng, npe*fDynodeGain)/fDynodeGain;
91 }

Member Data Documentation

double opdet::PMTGainFluctuations1Dynode::fDynodeGain
private

Definition at line 66 of file PMTGainFluctuations1Dynode_tool.cc.

double opdet::PMTGainFluctuations1Dynode::fDynodeK
private

Definition at line 62 of file PMTGainFluctuations1Dynode_tool.cc.

double opdet::PMTGainFluctuations1Dynode::fGain
private

Definition at line 63 of file PMTGainFluctuations1Dynode_tool.cc.

std::vector<double> opdet::PMTGainFluctuations1Dynode::fVoltageDistribution
private

Definition at line 64 of file PMTGainFluctuations1Dynode_tool.cc.


The documentation for this class was generated from the following file: