28 EXCEPTION_RAISE(
"RandomSeedException",
29 "Noise generator was not seeded before use");
45 double noiseHitCount =
random_->Binomial(emptyChannels, integral);
49 std::vector<double> noiseHits;
50 for (
int hitIndex = 0; hitIndex < noiseHitCount; ++hitIndex) {
51 double rand =
random_->Uniform();
54 double draw = integral * rand;
58 double cumulativeProb = 1.0 - integral + draw;
62 double valueAboveThreshold;
65 ROOT::Math::gaussian_quantile(cumulativeProb,
noise_);
72 noiseHits.push_back(valueAboveThreshold);