55 #ifndef G4UniversalFluctuation_h
56 #define G4UniversalFluctuation_h 1
62 #include <CLHEP/Random/RandomEngine.h>
96 inline void SampleGauss(CLHEP::HepRandomEngine* rndm,
154 if(p > 0.) { eloss += (1.-2.*rndm->flat())*ex; }
167 if(deltae < 0.25*sig) {
168 x += (2.*rndm->flat() - 1.)*deltae;
172 }
while (x < eav-deltae || x > eav+deltae);
ThreeVector shoot(const G4int Ap, const G4int Af)
G4double m_Inv_particleMass
G4long G4Poisson(G4double mean)
virtual G4double Dispersion(const G4Material *, const G4DynamicParticle *, G4double, G4double) override
void AddExcitation(CLHEP::HepRandomEngine *rndm, G4double a, G4double e, G4double &eav, G4double &eloss, G4double &esig2)
std::vector< ExP01TrackerHit * > a
virtual G4double SampleFluctuations(const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double, G4double, G4double) override
const G4Material * lastMaterial
G4UniversalFluctuation(const G4String &nam="UniFluc")
G4UniversalFluctuation & operator=(const G4UniversalFluctuation &right)=delete
G4double minNumberInteractionsBohr
virtual void SetParticleAndCharge(const G4ParticleDefinition *, G4double q2) final
virtual ~G4UniversalFluctuation()
const G4ParticleDefinition * particle
virtual void InitialiseMe(const G4ParticleDefinition *) final
void SampleGauss(CLHEP::HepRandomEngine *rndm, G4double eav, G4double esig2, G4double &eloss)
T min(const T t1, const T t2)
brief Return the smallest of the two arguments