CMS 3D CMS Logo

HcalAmplifier.h
Go to the documentation of this file.
1 #ifndef HcalSimAlgos_HcalAmplifier_h
2 #define HcalSimAlgos_HcalAmplifier_h
3 
10 
11 class HcalDbService;
12 class HPDIonFeedbackSim;
13 class HcalTimeSlewSim;
14 class HcalTimeSlew;
15 
16 namespace CLHEP {
17  class HepRandomEngine;
18 }
19 
21 public:
22  HcalAmplifier(const CaloVSimParameterMap* parameters, bool addNoise, bool PreMix1, bool PreMix2);
23 
24  virtual ~HcalAmplifier() {}
25 
27  void setDbService(const HcalDbService* service);
28  void setIonFeedbackSim(HPDIonFeedbackSim* feedbackSim) { theIonFeedbackSim = feedbackSim; }
29 
32  void setNoiseSignalGenerator(const CaloVNoiseSignalGenerator* noiseSignalGenerator) {
33  theNoiseSignalGenerator = noiseSignalGenerator;
34  }
35  void setTimeSlewSim(HcalTimeSlewSim* timeSlewSim) { theTimeSlewSim = timeSlewSim; }
36 
37  const HcalTimeSlew* theTimeSlew = nullptr;
38  void setTimeSlew(const HcalTimeSlew* timeSlew) { theTimeSlew = timeSlew; }
39 
40  virtual void amplify(CaloSamples& linearFrame, CLHEP::HepRandomEngine*) const;
41 
42  void setStartingCapId(int capId) { theStartingCapId = capId; }
43 
44 private:
45  void pe2fC(CaloSamples& frame) const;
46  void addPedestals(CaloSamples& frame, CLHEP::HepRandomEngine*) const;
47  void makeNoise(HcalGenericDetId::HcalGenericSubdetector hcalSubDet,
49  int fFrames,
50  double* fGauss,
51  double* fNoise) const;
52 
58  unsigned theStartingCapId;
59  bool addNoise_;
61  bool preMixAdd_;
62 };
63 
64 #endif
const CaloVNoiseSignalGenerator * theNoiseSignalGenerator
Definition: HcalAmplifier.h:55
const CaloVSimParameterMap * theParameterMap
Definition: HcalAmplifier.h:54
void setStartingCapId(int capId)
Definition: HcalAmplifier.h:42
void setIonFeedbackSim(HPDIonFeedbackSim *feedbackSim)
Definition: HcalAmplifier.h:28
const HcalDbService * theDbService
Definition: HcalAmplifier.h:53
void setTimeSlew(const HcalTimeSlew *timeSlew)
Definition: HcalAmplifier.h:38
HcalTimeSlewSim * theTimeSlewSim
Definition: HcalAmplifier.h:57
void setNoiseSignalGenerator(const CaloVNoiseSignalGenerator *noiseSignalGenerator)
Definition: HcalAmplifier.h:32
void setTimeSlewSim(HcalTimeSlewSim *timeSlewSim)
Definition: HcalAmplifier.h:35
unsigned theStartingCapId
Definition: HcalAmplifier.h:58
virtual ~HcalAmplifier()
Definition: HcalAmplifier.h:24
HPDIonFeedbackSim * theIonFeedbackSim
Definition: HcalAmplifier.h:56