75 crossBornPerElectron(0),
85 peakKinEnergy = highKinEnergy;
102 if(isInitialised) {
return; }
103 isInitialised =
true;
106 emin =
model->LowEnergy();
107 emax =
model->HighEnergy();
114 G4cout <<
"CM System: emin(MeV)= " << emin/
MeV
115 <<
" epeak(MeV)= " << epeak/
MeV
116 <<
" emax(MeV)= " << emax/
MeV
120 crossBornPerElectron =
model->PhysicsVector();
121 crossPerElectron =
model->PhysicsVector();
123 for(
G4int i=0; i<nbins; ++i) {
126 crossBornPerElectron->
PutValue(i, cs);
128 ComputeCMCrossSectionPerElectron();
131 G4cout <<
"G4eeToHadronsModel: Cross sections per electron"
132 <<
" nbins= " << nbins
133 <<
" emin(MeV)= " << emin/
MeV
134 <<
" emax(MeV)= " << emax/
MeV
136 for(
G4int i=0; i<nbins; ++i) {
142 <<
" crossBorn(nb)= " << s2/
nanobarn
179 if(crossPerElectron) {
180 cross = crossPerElectron->
Value(energy);
193 if(crossPerElectron) {
211 model->SampleSecondaries(newp, mass, dir);
212 G4int np = newp->size();
213 for(
G4int j=0; j<np; ++j) {
228 newp->push_back(gamma);
230 G4cout <<
"G4eeToHadronsModel::SampleSecondaries: Ebalance(MeV)= "
231 << t/
MeV <<
" primary 4-momentum: " << inlv <<
G4endl;
239 void G4eeToHadronsModel::ComputeCMCrossSectionPerElectron()
241 for(
G4int i=0; i<nbins; i++) {
252 cs += s1*(del*
G4Exp(
G4Log(x1)*bt) - bt*(x1 - 0.25*x1*x1));
260 for(
G4int j=i-2; j>=0; --j) {
261 e1 = crossPerElectron->
Energy(j);
263 s1 = crossBornPerElectron->
Value(e1);
264 w1 = bt*(del*
G4Exp(
G4Log(x1)*btm1) - 1.0 + 0.5*x1);
265 cs += 0.5*(x1 - x2)*(w2*s2 + w1*s1);
290 G4double xmax = 0.5*(1.0 - (emin*emin)/(e*e));
312 x = 0.5*(1. - (emax*emax)/(e*e));
321 x = 0.5*(1.0 - (epeak*epeak)/(e*e));
329 const G4int iimax = 1000;
333 G4double s2 = crossBornPerElectron->
Value(sqrt(1.0 - 2*x)*e);
341 G4cout <<
"G4DynamicParticle* G4eeToHadronsModel:WARNING "
342 << f <<
" > " << grej <<
" majorant is`small!"
345 if(++ii >= iimax) {
break; }
void set(double x, double y, double z)
virtual ~G4eeToHadronsModel()
Hep3Vector boostVector() const
G4double LowEnergyLimit() const
G4double GetKineticEnergy() const
G4double HighEnergyLimit() const
G4eeToHadronsModel(G4Vee2hadrons *, G4int ver=0, const G4String &nam="eeToHadrons")
virtual G4double CrossSectionPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy, G4double maxEnergy) override
virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kineticEnergy, G4double Z, G4double A, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX) override
size_t GetVectorLength() const
virtual void SampleSecondaries(std::vector< G4DynamicParticle * > *, const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double tmin=0.0, G4double maxEnergy=DBL_MAX) override
static constexpr double electron_mass_c2
G4GLOB_DLL std::ostream G4cout
static constexpr double nanobarn
G4double GetElectronDensity() const
const G4ThreeVector & GetMomentumDirection() const
HepLorentzVector & boost(double, double, double)
void PutValue(size_t index, G4double theValue)
G4double Energy(size_t index) const
G4double Value(G4double theEnergy, size_t &lastidx) const
G4LorentzVector Get4Momentum() const
G4double G4Log(G4double x)
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
void Set4Momentum(const G4LorentzVector &momentum)
T max(const T t1, const T t2)
brief Return the largest of the two arguments
G4double energy(const ThreeVector &p, const G4double m)
G4DynamicParticle * GenerateCMPhoton(G4double)
T min(const T t1, const T t2)
brief Return the smallest of the two arguments
static const G4int LL[nN]
static constexpr double MeV
static constexpr double pi
virtual void Initialise(const G4ParticleDefinition *, const G4DataVector &) override
virtual G4double ComputeCrossSectionPerElectron(const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
static constexpr double fine_structure_const
const XML_Char XML_Content * model
CLHEP::HepLorentzVector G4LorentzVector