13 #ifndef DPhaseCoherentNoiseService_H 14 #define DPhaseCoherentNoiseService_H 22 class HepRandomEngine;
30 typedef std::map<int, std::vector< float >>
Map;
31 typedef std::map<Channel, AdcSignalVector>
Mask;
57 void getAmplitudeArray(
Channel chan, std::vector<float> &
array )
const;
60 void getFrequencyArray(
Channel chan, std::vector<float> &
array )
const;
63 void makePhaseMap( Map & phaseMap,
int size,
float minShift,
float maxShift);
66 int getNumber(
Channel chan )
const;
70 std::vector< float > & noiseArray,
71 std::vector< float > ampArray, std::vector< float > freqArray, std::vector< float > phaseArray,
float randAmp )
const;
78 Map & chFrequencyMap, Map & chAmplitudeMap,
double cut,
int &normalization )
const;
std::string fNoiseModel
< noise model root file
std::vector< float > fRandomize
< randomization of the amplitude
int fLogLevel
< Log message level: 0=quiet, 1=init only, 2+=every event
int fNumberOfPhases
< Number of pregenerated phase shift maps
Map fChFrequencyMap
Map storing the frequency vector for each channel.
int fNormalization
< Normalization factor ( similar to the one for the InFFT )
DECLARE_ART_SERVICE_INTERFACE_IMPL(MySharedService, art::test::MyServiceInterface, SHARED) DEFINE_ART_SERVICE_INTERFACE_IMPL(MySharedService
std::vector< int > fChannelGroup
< Channels in the same group get the same phase
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Map fChAmplitudeMap
Map holding the amplitude of the frequency for each channel.
std::vector< float > fInchoerentNoise
< Mean and std of the incoherent noise
int fRandomSeed
< Seed for random number service. If absent or zero, use SeedSvc.
auto array(Array const &a)
Returns a manipulator which will print the specified array.
Contains all timing reference information for the detector.
std::vector< Map > fPhaseMap
Pregenerated phase shift maps.
std::vector< AdcSignal > AdcSignalVector
double fAmplitudeCut
< only frequencies with amplitude above this cut will be considered
std::vector< float > fPhaseShift
< Phase shift for each group of 30 channels
std::map< int, std::vector< float > > Map
CLHEP::HepRandomEngine * m_pran
std::map< Channel, AdcSignalVector > Mask