All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
ChargeInducer.h
Go to the documentation of this file.
1 #ifndef ChargeInducer_h
2 #define ChargeInducer_h
3 
4 #include <string>
5 #include <map>
6 
7 #include <random>
8 
10 struct AsicKey ;
11 
12 /**
13 \addtogroup CaloDigi CaloDigi
14 @{
15 
16 */
17 
18 
20 {
21  public :
22  ChargeInducer() ;
23  virtual ~ChargeInducer() ;
24  virtual float getCharge(SimDigitalGeomCellId* cellID) = 0 ;
25 
26  void setSeed(unsigned int value) ;
27 
28  protected :
29  std::mt19937 generator ;
30 } ;
31 
33 {
34  public :
35  UniformPolya(float _qbar , float _theta) ;
36  ~UniformPolya() ;
37 
38  virtual float getCharge(SimDigitalGeomCellId* cellID) ;
39 
40 
41  protected :
42  std::gamma_distribution<float> gammadist ;
43 
44 } ;
45 
46 class AsicPolya : public UniformPolya
47 {
48  public :
49  AsicPolya(float _qbar , float _theta , std::string fileName) ;
50  ~AsicPolya() ;
51 
52  virtual float getCharge(SimDigitalGeomCellId* cellID) ;
53 
54 
55  protected :
56  void readFile(std::string fileName) ;
57 
58  std::map<AsicKey , std::gamma_distribution<float> > polyaMap ;
59 } ;
60 
61 /** @} */
62 
63 #endif //ChargeInducer_h
virtual ~ChargeInducer()
std::gamma_distribution< float > gammadist
Definition: ChargeInducer.h:42
void readFile(std::string fileName)
std::map< AsicKey, std::gamma_distribution< float > > polyaMap
Definition: ChargeInducer.h:58
virtual float getCharge(SimDigitalGeomCellId *cellID)
std::mt19937 generator
Definition: ChargeInducer.h:29
UniformPolya(float _qbar, float _theta)
void setSeed(unsigned int value)
virtual float getCharge(SimDigitalGeomCellId *cellID)
AsicPolya(float _qbar, float _theta, std::string fileName)
virtual float getCharge(SimDigitalGeomCellId *cellID)=0