QwAnalysis
QwSIS3320_LogicalAccumulator.cc
Go to the documentation of this file.
1 /**
2  * \file QwSIS3320_LogicalAccumulator.cc
3  *
4  * \brief Implementation of the SIS3320 sampling ADC accumulator
5  *
6  * \author W. Deconinck
7  * \date 2009-09-04 18:06:23
8  * \ingroup QwCompton
9  *
10  * The QwSIS3320_LogicalAccumulator should allow convenient access to the accumulator
11  * data collected with the SIS3320 for the Compton photon detector. This class
12  * implements its own sum, difference, and ratio methods inherited from the
13  * general VQwDataElement.
14  *
15  */
16 
18 #include "QwSIS3320_Accumulator.h"
19 
20 // Qweak headers
21 #include "QwLog.h"
22 #include "QwHistogramHelper.h"
23 
24 
26 {
27  for (size_t i = 0; i < fAccumulators.size(); i++) {
28  fAccumulatorSum += fAccumulatorWeights[i]*(fAccumulators[i]->GetAccumulatorSum());
29  }
30 }
31 
33  QwSIS3320_Accumulator *accum, Double_t weight)
34 {
35  if (accum) {
36  fAccumulators.push_back(accum);
37  fAccumulatorWeights.push_back(weight);
38  }
39 }
40 
std::vector< QwSIS3320_Accumulator * > fAccumulators
Double_t fAccumulatorSum
Accumulator sum.
SIS3320 sampling ADC accumulator.
A logfile class, based on an identical class in the Hermes analyzer.
void AddAccumulatorReference(QwSIS3320_Accumulator *accum, Double_t weight)
std::vector< Double_t > fAccumulatorWeights