41const G4double G4XrayRayleighModel::fCofA = 2.*pi2*Bohr_radius*Bohr_radius;
43const G4double G4XrayRayleighModel::fCofR = 8.*pi*classic_electr_radius*classic_electr_radius/3.;
51 fParticleChange =
nullptr;
52 lowEnergyLimit = 250*eV;
53 highEnergyLimit = 10.*MeV;
71 << lowEnergyLimit / eV <<
" eV - "
72 << highEnergyLimit / MeV <<
" MeV"
88 G4cout <<
"Calling G4XrayRayleighModel::Initialise()" <<
G4endl;
94 if(isInitialised)
return;
108 if (verboseLevel > 3)
110 G4cout <<
"Calling CrossSectionPerAtom() of G4XrayRayleighModel" <<
G4endl;
112 if (gammaEnergy < lowEnergyLimit || gammaEnergy > highEnergyLimit)
132 fo *= 0.01*std::exp(lna);
141 xsc *= fo*fo + (1. + fo)*(1. + fo);
156 if ( verboseLevel > 3)
158 G4cout <<
"Calling SampleSecondaries() of G4XrayRayleighModel" <<
G4endl;
168 G4double cosDipole, cosTheta, sinTheta;
169 G4double c, delta, cofA, signc = 1., a, power = 1./3.;
179 delta = std::sqrt(a*a+4.);
182 cofA = -signc*std::pow(delta, power);
183 cosDipole = cofA - 1./cofA;
206 fo *= 0.01*pi*std::exp(lna);
211 cosTheta = (cosDipole + beta)/(1. + cosDipole*beta);
214 if( cosTheta > 1.) cosTheta = 1.;
215 if( cosTheta < -1.) cosTheta = -1.;
217 sinTheta = std::sqrt( (1. - cosTheta)*(1. + cosTheta) );
222 G4double dirX = sinTheta*std::cos(phi);
223 G4double dirY = sinTheta*std::sin(phi);
229 photonDirection1.
rotateUz(photonDirection0);
G4GLOB_DLL std::ostream G4cout
Hep3Vector & rotateUz(const Hep3Vector &)
const G4ThreeVector & GetMomentumDirection() const
G4double GetLogKineticEnergy() const
const G4ParticleDefinition * GetParticleDefinition() const
G4double GetKineticEnergy() const
void SetProposedKineticEnergy(G4double proposedKinEnergy)
void ProposeMomentumDirection(const G4ThreeVector &Pfinal)
void SetHighEnergyLimit(G4double)
G4ParticleChangeForGamma * GetParticleChangeForGamma()
const G4Element * SelectTargetAtom(const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double logKineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
void InitialiseElementSelectors(const G4ParticleDefinition *, const G4DataVector &)
~G4XrayRayleighModel() override
G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kinEnergy, G4double Z, G4double A=0, G4double cut=0, G4double emax=DBL_MAX) override
G4XrayRayleighModel(const G4ParticleDefinition *p=nullptr, const G4String &nam="XrayRayleigh")
void SampleSecondaries(std::vector< G4DynamicParticle * > *, const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double tmin, G4double maxEnergy) override
void Initialise(const G4ParticleDefinition *, const G4DataVector &) override