Import Geant4 7.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 11:11:55 +02:00
parent e083ffb441
commit 516dbf1a58
5914 changed files with 202605 additions and 71141 deletions
@@ -21,7 +21,7 @@
// ********************************************************************
//
//
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-03 $
//
//
// GEANT4 physics class: G4ElectroNuclearCrossSection -- header file
@@ -145,10 +145,10 @@ inline G4double G4ElectroNuclearCrossSection::DFun(G4double x)// Parametrization
static const G4double pos=16.5; // HE Pomeron shift
static const G4double reg=.11; // HE Reggeon slope
static const G4double mel=0.5109989; // Mass of an electron in MeV
static const G4double lmel=log(mel); // Log of an electron mass
G4double y=exp(x-lastG-lmel); // y for the x
static const G4double lmel=std::log(mel); // Log of an electron mass
G4double y=std::exp(x-lastG-lmel); // y for the x
G4double flux=lastG*(2.-y*(2.-y))-1.; // flux factor
return (poc*(x-pos)+shd*exp(-reg*x))*flux;
return (poc*(x-pos)+shd*std::exp(-reg*x))*flux;
}
inline G4double G4ElectroNuclearCrossSection::Fun(G4double x) // Integrated PhoNuc cross section
@@ -161,44 +161,44 @@ inline G4double G4ElectroNuclearCrossSection::Fun(G4double x) // Integrated PhoN
inline G4double G4ElectroNuclearCrossSection::HighEnergyJ1(G4double lEn)
{
static const G4double le=log(50000.); // log(E0)
static const G4double le2=le*le; // log(E0)^2
static const G4double le=std::log(50000.); // std::log(E0)
static const G4double le2=le*le; // std::log(E0)^2
static const G4double a=.0375; // a
static const G4double ha=a*.5; // a/2
static const G4double ab=a*16.5; // a*b
static const G4double d=0.11; // d
static const G4double cd=1.0734/d; // c/d
static const G4double ele=exp(-d*le); // E0^(-d)
return ha*(lEn*lEn-le2)-ab*(lEn-le)-cd*(exp(-d*lEn)-ele);
static const G4double ele=std::exp(-d*le); // E0^(-d)
return ha*(lEn*lEn-le2)-ab*(lEn-le)-cd*(std::exp(-d*lEn)-ele);
}
inline G4double G4ElectroNuclearCrossSection::HighEnergyJ2(G4double lEn)
{
static const G4double e=50000.; // E0
static const G4double le=log(e); // log(E0)
static const G4double le1=(le-1.)*e; // (log(E0)-1)*E0
static const G4double le=std::log(e); // std::log(E0)
static const G4double le1=(le-1.)*e; // (std::log(E0)-1)*E0
static const G4double a=.0375; // a
static const G4double ab=a*16.5; // a*b
static const G4double d=1.-0.11; // 1-d
static const G4double cd=1.0734/d; // c/(1-d)
static const G4double ele=exp(d*le); // E0^(1-d)
G4double En=exp(lEn);
return a*((lEn-1.)*En-le1)-ab*(En-e)+cd*(exp(d*lEn)-ele);
static const G4double ele=std::exp(d*le); // E0^(1-d)
G4double En=std::exp(lEn);
return a*((lEn-1.)*En-le1)-ab*(En-e)+cd*(std::exp(d*lEn)-ele);
}
inline G4double G4ElectroNuclearCrossSection::HighEnergyJ3(G4double lEn)
{
static const G4double e=50000.; // E0
static const G4double le=log(e); // log(E0)
static const G4double le=std::log(e); // std::log(E0)
static const G4double e2=e*e; // E0^2
static const G4double leh=(le-.5)*e2; // (log(E0)-.5)*E0^2
static const G4double leh=(le-.5)*e2; // (std::log(E0)-.5)*E0^2
static const G4double ha=.0375*.5; // a/2
static const G4double hab=ha*16.5; // a*b/2
static const G4double d=2.-.11; // 2-d
static const G4double cd=1.0734/d; // c/(2-d)
static const G4double ele=exp(d*le); // E0^(2-d)
G4double lastE2=exp(lEn+lEn);
return ha*((lEn-.5)*lastE2-leh)-hab*(lastE2-e2)+cd*(exp(d*lEn)-ele);
static const G4double ele=std::exp(d*le); // E0^(2-d)
G4double lastE2=std::exp(lEn+lEn);
return ha*((lEn-.5)*lastE2-leh)-hab*(lastE2-e2)+cd*(std::exp(d*lEn)-ele);
}
#endif
@@ -21,7 +21,7 @@
// ********************************************************************
//
//
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// GEANT4 Hadron physics class -- header file
@@ -21,7 +21,7 @@
// ********************************************************************
//
//
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// GEANT4 physics class: G4PhotoNuclearCrossSection -- header file
@@ -72,25 +72,25 @@ class G4ProjectileFragmentCrossSection
inline G4double doit(G4double Ap, G4double Zp, G4double At, G4double Zt, G4double A, G4double Z)
{
// calculate mass yield
G4double Ap13 = pow(Ap, 1./3.);
G4double At13 = pow(At, 1./3.);
G4double Ap13 = std::pow(Ap, 1./3.);
G4double At13 = std::pow(At, 1./3.);
G4double S = p_S[2] * (At13 + Ap13 + p_S[1]);
// cout << "debug0 "<<S<<" "<<At13<<" "<<Ap13<<" "<<p_S[1]<<" "<<p_S[2]<<endl;
G4double p = exp(p_P[2]*Ap + p_P[1]);
G4double yield_a = p * S * exp(-p * (Ap - A));
G4double p = std::exp(p_P[2]*Ap + p_P[1]);
G4double yield_a = p * S * std::exp(-p * (Ap - A));
cout << "debug1 "<<yield_a<<endl;
// modification close to projectile
G4double f_mod_y=1.0;
if (A/Ap > corr_y[2])
{
f_mod_y=corr_y[1]*pow(A/Ap-corr_y[2], 2) + 1.0;
f_mod_y=corr_y[1]*std::pow(A/Ap-corr_y[2], 2) + 1.0;
}
yield_a= yield_a * f_mod_y;
cout << "debug1 "<<yield_a<<endl;
// calculate maximum of charge dispersion zprob
G4double zbeta = A/(1.98+0.0155*pow(A, (2./3.)));
G4double zbeta_p = Ap/(1.98+0.0155*pow(Ap, (2./3.)));
G4double zbeta = A/(1.98+0.0155*std::pow(A, (2./3.)));
G4double zbeta_p = Ap/(1.98+0.0155*std::pow(Ap, (2./3.)));
G4double delta;
if(A > p_Delta[4])
{
@@ -105,7 +105,7 @@ class G4ProjectileFragmentCrossSection
G4double f_mod=1.0;
if(A/Ap > corr_d[2])
{
f_mod = corr_d[1]*pow(A/Ap-corr_d[2], 2) + 1.0;
f_mod = corr_d[1]*std::pow(A/Ap-corr_d[2], 2) + 1.0;
}
delta = delta*f_mod;
G4double zprob = zbeta+delta;
@@ -114,13 +114,13 @@ class G4ProjectileFragmentCrossSection
G4double dq;
if((Zp-zbeta_p)>0)
{
dq = exp(p_mp[1] + G4double(A)/G4double(Ap)*p_mp[2]);
dq = std::exp(p_mp[1] + G4double(A)/G4double(Ap)*p_mp[2]);
cout << "dq "<<A<<" "<<Ap<<" "<<p_mp[1]
<<" "<<p_mp[2]<<" "<<dq<<" "<<p_mp[1] + A/Ap*p_mp[2]<<endl;
}
else
{
dq = p_mn[1]*pow(A/Ap, 2.0) + p_mn[2]*pow(A/Ap, 4.0);
dq = p_mn[1]*std::pow(A/Ap, 2.0) + p_mn[2]*std::pow(A/Ap, 4.0);
}
zprob = zprob + dq * (Zp-zbeta_p);
@@ -130,20 +130,20 @@ class G4ProjectileFragmentCrossSection
<<" "<<zbeta<<" "<<delta<<endl;
// calculate width parameter R
G4double r = exp(p_R[1] + p_R[2]*A);
G4double r = std::exp(p_R[1] + p_R[2]*A);
// modification close to projectile
f_mod=1.0;
if (A/Ap > corr_r[2])
{
f_mod = corr_r[1]*Ap*pow(A/Ap-corr_r[2], 4.0)+1.0;
f_mod = corr_r[1]*Ap*std::pow(A/Ap-corr_r[2], 4.0)+1.0;
}
r = r*f_mod;
// change width according to dev. from beta-stability
if ((Zp-zbeta_p) < 0.0)
{
r=r*(1.0-0.0833*abs(Zp-zbeta_p));
r=r*(1.0-0.0833*std::abs(Zp-zbeta_p));
}
// calculate slope parameters u_n, u_p
@@ -155,23 +155,23 @@ class G4ProjectileFragmentCrossSection
if((zprob-Z) > 0)
{
// neutron-rich
expo = -r*pow(abs(zprob-Z), u_n);
fract = exp(expo)*sqrt(r/3.14159);
expo = -r*std::pow(std::abs(zprob-Z), u_n);
fract = std::exp(expo)*std::sqrt(r/3.14159);
}
else
{
// proton-rich
expo = -r*pow(abs(zprob-Z), u_p);
fract = exp(expo)*sqrt(r/3.14159);
expo = -r*std::pow(std::abs(zprob-Z), u_p);
fract = std::exp(expo)*std::sqrt(r/3.14159);
cout << "1 "<<expo<<" "<<r<<" "<<zprob<<" "<<Z<<" "<<u_p<<endl;
// go to exponential slope
G4double dfdz = 1.2 + 0.647*pow(A/2.,0.3);
G4double z_exp = zprob + dfdz * log(10.) / (2.*r);
G4double dfdz = 1.2 + 0.647*std::pow(A/2.,0.3);
G4double z_exp = zprob + dfdz * std::log(10.) / (2.*r);
if( Z>z_exp )
{
expo = -r*pow(abs(zprob-z_exp), u_p);
fract = exp(expo)*sqrt(r/3.14159)
/ pow(pow(10, dfdz), Z-z_exp);
expo = -r*std::pow(std::abs(zprob-z_exp), u_p);
fract = std::exp(expo)*std::sqrt(r/3.14159)
/ std::pow(std::pow(10, dfdz), Z-z_exp);
}
}
@@ -161,10 +161,10 @@ G4PhysicsFreeVector *
//
// Initialise variables and calculate the energies for the GDR and GQR.
//
G4double AProot3 = pow(AP,1.0/3.0);
G4double AProot3 = std::pow(AP,1.0/3.0);
G4double u = 3.0 * J / Qprime / AProot3;
G4double R0 = r0 * AProot3;
G4double E_GDR = hbarc / sqrt(0.7*amu_c2*R0*R0/8.0/J*
G4double E_GDR = hbarc / std::sqrt(0.7*amu_c2*R0*R0/8.0/J*
(1.0 + u - (1.0 + epsilon + 3.0*u)/(1.0 + epsilon + u)*epsilon));
G4double E_GQR = 63.0 * MeV / AProot3;
//
@@ -232,7 +232,7 @@ G4double
else
{
G4double p1 = (G4double) Z / (G4double) A;
G4double p2 = 1.95*exp(-0.075*Z);
G4double p2 = 1.95*std::exp(-0.075*Z);
if (p1 < p2) p = p1;
else p = p2;
}
@@ -75,7 +75,7 @@ G4double G4EMDissociationSpectrum::GetGeneralE1Spectrum
(G4double Eg, G4double b, G4double bmin)
{
G4double b2 = b*b;
G4double g = 1.0/sqrt(1.0-b2);
G4double g = 1.0/std::sqrt(1.0-b2);
G4double xi = Eg * bmin / g / b / hbarc;
G4double K0 = bessel->K0(xi);
G4double K1 = bessel->K1(xi);
@@ -90,12 +90,12 @@ G4double G4EMDissociationSpectrum::GetGeneralE2Spectrum
{
G4double b2 = b * b;
G4double b4 = b2 * b2;
G4double g = 1.0/sqrt(1.0-b2);
G4double g = 1.0/std::sqrt(1.0-b2);
G4double xi = Eg * bmin / g / b / hbarc;
G4double K0 = bessel->K0(xi);
G4double K1 = bessel->K1(xi);
G4double n = 2.0 * fine_structure_const / pi / b4 / Eg *
(2.0*(1.0-b2)*K1*K1 + xi*pow((2.0-b2),2.0)*K0*K1 -
(2.0*(1.0-b2)*K1*K1 + xi*std::pow((2.0-b2),2.0)*K0*K1 -
xi*xi*b4/2.0*(K1*K1-K0*K0));
return n;
}
@@ -105,9 +105,9 @@ G4double G4EMDissociationSpectrum::GetClosestApproach
(const G4double AP, const G4double ZP, G4double AT, G4double ZT, G4double b)
{
G4double bsq = b * b;
G4double g = 1.0/sqrt(1-bsq);
G4double AProot3 = pow(AP,1.0/3.0);
G4double ATroot3 = pow(AT,1.0/3.0);
G4double g = 1.0/std::sqrt(1-bsq);
G4double AProot3 = std::pow(AP,1.0/3.0);
G4double ATroot3 = std::pow(AT,1.0/3.0);
G4double bc = 1.34 * fermi * (AProot3+ATroot3 - 0.75 *(1.0/AProot3+1.0/ATroot3));
// G4double a0 = ZP * ZT * classic_electr_radius/bsq;
G4double a0 = ZP * ZT * elm_coupling / (AT*AP*amu_c2/(AT+AP)) / bsq;
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4ElectroNuclearCrossSection.cc,v 1.22 2003/11/19 11:08:40 mkossov Exp $
// GEANT4 tag $Name: geant4-06-00-patch-01 $
// $Id: G4ElectroNuclearCrossSection.cc,v 1.23 2004/12/07 13:45:17 gunter Exp $
// GEANT4 tag $Name: geant4-07-00-cand-03 $
//
//
// G4 Physics class: G4ElectroNuclearCrossSection for gamma+A cross sections
@@ -62,12 +62,12 @@ G4double G4ElectroNuclearCrossSection::GetCrossSection(const G4DynamicParticle*
static const G4int mL=nE-1;
static const G4double EMi=2.0612; // Minimum tabulated Energy of the Electron
static const G4double EMa=50000.; // Maximum tabulated Energy of the Electron
static const G4double lEMi=log(EMi); // Minimum tabulated logarithmic Energy of the Electron
static const G4double lEMa=log(EMa); // Maximum tabulated logarithmic Energy of the Electron
static const G4double lEMi=std::log(EMi); // Minimum tabulated logarithmic Energy of the Electron
static const G4double lEMa=std::log(EMa); // Maximum tabulated logarithmic Energy of the Electron
static const G4double dlnE=(lEMa-lEMi)/mL; // Logarithmic step in the table for the electron Energy
static const G4double alop=1./137.036/3.14159265; //coef. for the calculated functions (Ee>50000.)
static const G4double mel=0.5109989; // Mass of the electron in MeV
static const G4double lmel=log(mel); // Log of the electron mass
static const G4double lmel=std::log(mel); // Log of the electron mass
// *** Begin of the Associative memory for acceleration of the cross section calculations
static std::vector <G4int> colN; // Vector of N for calculated nucleus (isotop)
static std::vector <G4int> colZ; // Vector of Z for calculated nucleus (isotop)
@@ -111,7 +111,7 @@ G4double G4ElectroNuclearCrossSection::GetCrossSection(const G4DynamicParticle*
lastJ2 = new G4double[nE]; // Allocate memory for the new J2 function
lastJ3 = new G4double[nE]; // Allocate memory for the new J3 function
lastF = GetFunctions(A,lastJ1,lastJ2,lastJ3); // new ZeroPos and filling of J-functions
lastH = alop*A*(1.-.072*log(A));// corresponds to lastSP from G4PhotonuclearCrossSection
lastH = alop*A*(1.-.072*std::log(A));// corresponds to lastSP from G4PhotonuclearCrossSection
lastTH = ThresholdEnergy(targZ, targN); // The last Threshold Energy
#ifdef pdebug
G4cout<<"G4ElNucCS::GetCrossSection: lastH="<<lastH<<",A="<<A<<G4endl;
@@ -126,7 +126,7 @@ G4double G4ElectroNuclearCrossSection::GetCrossSection(const G4DynamicParticle*
colTH.push_back(lastTH);
} // End of creation of the new set of parameters
} // End of parameters udate
else if(abs((lastE-Energy)/Energy)<.001) return lastSig*millibarn; // Don't calc. same CS twice
else if(std::abs((lastE-Energy)/Energy)<.001) return lastSig*millibarn; // Don't calc. same CS twice
// ============================== NOW Calculate the Cross Section ==========================
lastE=Energy; // lastE - the electron energy
if (Energy<=lastTH) // Once more check that the eE is higher than the ThreshE
@@ -134,8 +134,8 @@ G4double G4ElectroNuclearCrossSection::GetCrossSection(const G4DynamicParticle*
lastSig=0.;
return 0.;
}
G4double lE=log(Energy); // log(eE) (it is necessary at this point for the fit)
lastG=lE-lmel; // Gamma of the electron (used to recover log(eE))
G4double lE=std::log(Energy); // std::log(eE) (it is necessary at this point for the fit)
lastG=lE-lmel; // Gamma of the electron (used to recover std::log(eE))
G4double dlg1=lastG+lastG-1.;
G4double lgoe=lastG/lastE;
if(lE<lEMa) // Linear fit is made explicitly to fix the last bin for the randomization
@@ -193,7 +193,7 @@ G4double G4ElectroNuclearCrossSection::GetCrossSection(const G4DynamicParticle*
// return YN[j]-(Xj-X)*(YN[j]-YN[j-1])/(Xj-Xp);
//}
// Calculate the functions for the log(A)
// Calculate the functions for the std::log(A)
G4int G4ElectroNuclearCrossSection::GetFunctions(G4double a, G4double* x, G4double* y, G4double* z)
{
static const G4int nN=14;
@@ -2274,7 +2274,7 @@ G4int G4ElectroNuclearCrossSection::GetFunctions(G4double a, G4double* x, G4doub
if(a!=ai) a=ai;
for(G4int i=0; i<nN; i++)
{
if(abs(a-A[i])<.0005) // A coincide with one of the basic A's -> get from Tab
if(std::abs(a-A[i])<.0005) // A coincide with one of the basic A's -> get from Tab
{
for(G4int k=0; k<nE; k++)
{
@@ -2316,18 +2316,18 @@ G4double G4ElectroNuclearCrossSection::GetEquivalentPhotonEnergy()
static const G4int mL=nE-1;
static const G4double EMi=2.0612; // Minimum Energy
static const G4double EMa=50000.; // Maximum Energy
static const G4double lEMi=log(EMi); // Minimum logarithmic Energy
static const G4double lEMa=log(EMa); // Maximum logarithmic Energy
static const G4double lEMi=std::log(EMi); // Minimum logarithmic Energy
static const G4double lEMa=std::log(EMa); // Maximum logarithmic Energy
static const G4double dlnE=(lEMa-lEMi)/mL; // Logarithmic step in Energy
static const G4double mel=0.5109989; // Mass of electron in MeV
static const G4double lmel=log(mel); // Log of electron mass
G4double phLE=0.; // Prototype of the log(nu=E_gamma)
static const G4double lmel=std::log(mel); // Log of electron mass
G4double phLE=0.; // Prototype of the std::log(nu=E_gamma)
G4double Y[nE]; // Prepare the array for randomization
#ifdef debug
G4cout<<"G4ElectroNuclearCrossSection::GetEguPhotE:B="<<lastF<<",l="<<lastL<<",J1="<<lastJ1[lastL]
<<",J2="<<lastJ2[lastL]<<",J3="<<lastJ3[lastL]<<",S="<<lastSig<<",E="<<lastE<<G4endl;
#endif
G4double lastLE=lastG+lmel; // recover log(eE) from the gamma (lastG)
G4double lastLE=lastG+lmel; // recover std::log(eE) from the gamma (lastG)
G4double dlg1=lastG+lastG-1.;
G4double lgoe=lastG/lastE;
for(G4int i=lastF;i<=lastL;i++) Y[i]=dlg1*lastJ1[i]-lgoe*(lastJ2[i]+lastJ2[i]-lastJ3[i]/lastE);
@@ -2373,10 +2373,10 @@ G4double G4ElectroNuclearCrossSection::GetEquivalentPhotonEnergy()
{
G4cerr<<"***G4ElectroNuclearCS::GetEquPhotE:N="<<lastN<<",Z="<<lastZ<<", lpE"<<phLE<<">leE"<<lastLE
<<",Sig="<<lastSig<<",rndSig="<<ris<<",Beg="<<lastF<<",End="<<lastL<<",Y="<<Y[lastL]<<G4endl;
if(lastLE<7.2) phLE=log(exp(lastLE)-.511);
if(lastLE<7.2) phLE=std::log(std::exp(lastLE)-.511);
else phLE=7.;
}
return exp(phLE);
return std::exp(phLE);
}
G4double G4ElectroNuclearCrossSection::SolveTheEquation(G4double f)
@@ -2388,14 +2388,14 @@ G4double G4ElectroNuclearCrossSection::SolveTheEquation(G4double f)
static const G4double reg=.11; // HE Reggeon slope
static const G4double EMa=50000.; // Maximum Energy
static const G4double mel=0.5109989; // Mass of electron in MeV
static const G4double lmel=log(mel); // Log of electron mass
static const G4double z=log(EMa); // Initial argument
static const G4double p=poc*(z-pos)+shd*exp(-reg*z); // CrossX on theHighTableEdge (small change)
static const G4double lmel=std::log(mel); // Log of electron mass
static const G4double z=std::log(EMa); // Initial argument
static const G4double p=poc*(z-pos)+shd*std::exp(-reg*z); // CrossX on theHighTableEdge (small change)
static const G4int imax=27; // Not more than "imax" steps to find the solution
static const G4double eps=0.001; // Accuracy which satisfies the search
G4double lastLE=lastG+lmel; // recover log(eE) from the gamma (lastG)
G4double topLim=lastLE-.001; // maximum log(phE) for equivalent photons
G4double rE=EMa/exp(lastLE); // r=EMa/Eel to make the firs guess
G4double lastLE=lastG+lmel; // recover std::log(eE) from the gamma (lastG)
G4double topLim=lastLE-.001; // maximum std::log(phE) for equivalent photons
G4double rE=EMa/std::exp(lastLE); // r=EMa/Eel to make the firs guess
G4double x=z+f/p/(lastG*(2.-rE*(2.-rE))-1.); // First guess (the first step from the edge)
#ifdef pdebug
G4cout<<"SolveTheEq: e="<<eps<<",f="<<f<<",z="<<z<<",p="<<p<<",lastG="<<lastG<<",x="<<x<<G4endl;
@@ -2417,7 +2417,7 @@ G4double G4ElectroNuclearCrossSection::SolveTheEquation(G4double f)
x=topLim;
if(i)G4Exception("G4ElectroNuclearCrossSection::SolveTheEquation()","009",FatalException,"E>eE");
}
if(abs(d)<eps) break;
if(std::abs(d)<eps) break;
if(i+1>=imax) G4cerr<<"*G4ElNucCS::SolveTheEq:"<<i+2<<">"<<imax<<"->Use bigger max. ln(eE)="
<<lastLE<<",Z="<<lastZ<<", N="<<lastN<<G4endl;
}
@@ -2437,7 +2437,7 @@ G4double G4ElectroNuclearCrossSection::GetEquivalentPhotonQ2(G4double nu)
G4double iar=Qi2/Qa2; // Q2min/Q2max ratio
G4double Dy=ye+.5*y2; // D(y) function
G4double Py=ye/Dy; // P(y) function
G4double ePy=1.-exp(Py); // 1-exp(P(y)) part
G4double ePy=1.-std::exp(Py); // 1-std::exp(P(y)) part
G4double Uy=Py*(1.-iar); // U(y) function
G4double Fy=(ye+ye)*(1.+ye)*iar/y2; // F(y) function
G4double fr=iar/(1.-ePy*iar); // Q-fraction
@@ -2448,7 +2448,7 @@ G4double G4ElectroNuclearCrossSection::GetEquivalentPhotonQ2(G4double nu)
#endif
return 0.;
}
G4double LyQa2=log(Fy+fr); // L(y,Q2max) function
G4double LyQa2=std::log(Fy+fr); // L(y,Q2max) function
G4bool cond=true;
G4int maxTry=3;
G4int cntTry=0;
@@ -2456,7 +2456,7 @@ G4double G4ElectroNuclearCrossSection::GetEquivalentPhotonQ2(G4double nu)
while(cond&&cntTry<maxTry) // The loop to avoid x>1.
{
G4double R=G4UniformRand(); // Random number (0,1)
Q2=Qi2*(ePy+1./(exp(R*LyQa2-(1.-R)*Uy)-Fy));
Q2=Qi2*(ePy+1./(std::exp(R*LyQa2-(1.-R)*Uy)-Fy));
cntTry++;
cond = Q2>1878.*nu;
}
@@ -2482,9 +2482,9 @@ G4double G4ElectroNuclearCrossSection::GetVirtualFactor(G4double nu, G4double Q2
static const G4double dM=938.27+939.57; // Mean double nucleon mass = m_n+m_p (@@ no binding)
static const G4double Q0=843.; // Coefficient of the dipole nucleonic form-factor
static const G4double Q02=Q0*Q0; // Squared coefficient of the dipole nucleonic form-factor
static const G4double blK0=log(185.); // Coefficient of the b-function
static const G4double blK0=std::log(185.); // Coefficient of the b-function
static const G4double bp=0.85; // Power of the b-function
static const G4double clK0=log(1390.); // Coefficient of the c-function
static const G4double clK0=std::log(1390.); // Coefficient of the c-function
static const G4double cp=3.; // Power of the c-function
//G4double x=Q2/dM/nu; // Direct x definition
G4double K=nu-Q2/dM; // K=nu*(1-x)
@@ -2495,12 +2495,12 @@ G4double G4ElectroNuclearCrossSection::GetVirtualFactor(G4double nu, G4double Q2
#endif
return 0.;
}
G4double lK=log(K); // ln(K)
G4double lK=std::log(K); // ln(K)
G4double x=1.-K/nu; // This definitin saves one div.
G4double GD=1.+Q2/Q02; // Reversed nucleonic form-factor
G4double b=exp(bp*(lK-blK0)); // b-factor
G4double c=exp(cp*(lK-clK0)); // c-factor
G4double r=.5*log(Q2+nu*nu)-lK; // r=.5*log((Q^2+nu^2)/K^2)
G4double ef=exp(r*(b-c*r*r)); // exponential factor
G4double b=std::exp(bp*(lK-blK0)); // b-factor
G4double c=std::exp(cp*(lK-clK0)); // c-factor
G4double r=.5*std::log(Q2+nu*nu)-lK; // r=.5*std::log((Q^2+nu^2)/K^2)
G4double ef=std::exp(r*(b-c*r*r)); // exponential factor
return (1.-x)*ef/GD/GD;
}
@@ -22,7 +22,7 @@
//
//
// $Id: G4HadronCaptureDataSet.cc,v 1.6 2003/07/01 15:08:46 hpw Exp $
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// G4 Physics class: HadronCaptureDataSet for cross sections
@@ -21,7 +21,7 @@
// ********************************************************************
//
//
// GEANT4 tag $Name: geant4-06-02 $
// GEANT4 tag $Name: geant4-07-00-cand-03 $
//
//
// G4 Hadron Physics class G4HadronCrossSections
@@ -1243,11 +1243,11 @@ G4HadronCrossSections::CalcScatteringCrossSections(
if (ipart >= 30 && ipart <= 32) {
G4double apart=0;
if (ipart == 30) apart = pow(2., 1./3.);
else if (ipart == 31) apart = pow(3., 1./3.);
else if (ipart == 32) apart = pow(4., 1./3.);
if (ipart == 30) apart = std::pow(2., 1./3.);
else if (ipart == 31) apart = std::pow(3., 1./3.);
else if (ipart == 32) apart = std::pow(4., 1./3.);
G4double term = apart + pow(a, 1./3.);
G4double term = apart + std::pow(a, 1./3.);
sigin = 49.*term*term;
// Convert cross section from mb to default units
siginelastic = sigin*millibarn;
@@ -1424,24 +1424,24 @@ G4HadronCrossSections::CalcScatteringCrossSections(
// in K.E. Subject to further improvements.
if (correctInelasticNearZero && je1 == 0 && i <= 3) {
G4double m0 = aParticle->GetMass()/GeV;
G4double T = sqrt(m0*m0 + p*p) - m0;
G4double dx = sqrt(m0*m0 + plab[1]*plab[1]) - m0;
G4double T = std::sqrt(m0*m0 + p*p) - m0;
G4double dx = std::sqrt(m0*m0 + plab[1]*plab[1]) - m0;
rc = dy/dx;
xsecin = rc*T + b;
}
if (sigel >= 0.001)
crel = xsecel/(0.36*sigel*pow(G4double(csa[i]), 1.17));
crel = xsecel/(0.36*sigel*std::pow(G4double(csa[i]), 1.17));
sigtot = sigel + sigin;
if (sigtot >= 0.001)
crin = xsecin/(sigtot*pow(G4double(csa[i]), alph));
crin = xsecin/(sigtot*std::pow(G4double(csa[i]), alph));
}
else if (ipart < 15) {
// Calculate correction factors (crel, crin) from values
// on Al, Cu, Pb. Note that data is only available for pions and protons.
G4double wgch = 0.5;
if (a < 20.) wgch = 0.5 + 0.5*exp(-(a - 1.));
if (a < 20.) wgch = 0.5 + 0.5*std::exp(-(a - 1.));
sigel = wgch*sigel + (1. - wgch)*xsecel;
sigin = wgch*sigin + (1. - wgch)*xsecin;
@@ -1460,23 +1460,23 @@ G4HadronCrossSections::CalcScatteringCrossSections(
G4cout << "xspiin " << xspiin << G4endl;
}
if (sigel >= 0.001)
crel = xspiel/(0.36*sigel*pow(G4double(csa[i]),1.17));
crel = xspiel/(0.36*sigel*std::pow(G4double(csa[i]),1.17));
sigtot = sigel + sigin;
if (sigtot >= 0.001)
crin = xspiin/(sigtot*pow(G4double(csa[i]), alph));
crin = xspiin/(sigtot*std::pow(G4double(csa[i]), alph));
}
}
// Apply correction factors
sigin = crin*(sigin + sigel)*pow(a, alph);
sigel = crel*0.36*sigel*pow(a, 1.17);
sigin = crin*(sigin + sigel)*std::pow(a, alph);
sigel = crel*0.36*sigel*std::pow(a, 1.17);
sigel = sigel*partel[ipart1];
sigin = sigin*partin[ipart1];
}
// Correction factor for high (p > 100 GeV/c) energies:
G4double corh = 1.;
if (p > 100.) corh = 0.1085736156*log(p) + 0.5;
if (p > 100.) corh = 0.1085736156*std::log(p) + 0.5;
sigel = corh*sigel;
sigin = corh*sigin;
@@ -1503,7 +1503,7 @@ G4HadronCrossSections::GetCaptureCrossSection(
G4int izno = static_cast<G4int> (z + 0.01);
if (izno > 100) izno = 100; // Not in GHESIG
izno = izno - 1; // For array indexing
G4double sigcap = 11.12*cscap[izno]/pow(ekx*1.e6, 0.577);
G4double sigcap = 11.12*cscap[izno]/std::pow(ekx*1.e6, 0.577);
// Convert cross section from mb to default units
sigcap = sigcap*millibarn;
return sigcap;
@@ -1545,13 +1545,13 @@ G4HadronCrossSections::GetFissionCrossSection(
G4int j = 4;
if (ek <= 0.01) {
if (z == 92. && abs(a - 233.) < 0.5) j = 1;
else if (z == 92. && abs(a - 235.) < 0.5) j = 2;
else if (z == 94. && abs(a - 239.) < 0.5) j = 3;
if (z == 92. && std::abs(a - 233.) < 0.5) j = 1;
else if (z == 92. && std::abs(a - 235.) < 0.5) j = 2;
else if (z == 94. && std::abs(a - 239.) < 0.5) j = 3;
}
G4double z43ba;
if (j == 4) {
z43ba = pow(z, 4./3.)/a;
z43ba = std::pow(z, 4./3.)/a;
z43ba = std::max(-67. + 38.7*z43ba, 0.);
}
else {
@@ -22,7 +22,7 @@
//
//
// $Id: G4HadronElasticDataSet.cc,v 1.6 2003/07/01 15:08:46 hpw Exp $
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// G4 Physics class: HadronElasticDataSet for cross sections
@@ -22,7 +22,7 @@
//
//
// $Id: G4HadronFissionDataSet.cc,v 1.6 2003/07/01 15:08:46 hpw Exp $
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// G4 Physics class: HadronFissionDataSet for cross sections
@@ -22,7 +22,7 @@
//
//
// $Id: G4HadronInelasticDataSet.cc,v 1.6 2003/07/01 15:08:46 hpw Exp $
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
//
// G4 Physics class: HadronInelasticDataSet for cross sections
@@ -47,8 +47,8 @@ GetCrossSection(const G4DynamicParticle* aParticle,
G4double one_third = 1.0 / 3.0;
G4double cubicrAt = pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = pow ( G4double(Ap) , G4double(one_third) );
G4double cubicrAt = std::pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = std::pow ( G4double(Ap) , G4double(one_third) );
G4double Bc = Zt * Zp / ( ( rc / fermi ) * ( cubicrAp + cubicrAt ) ); // rc divide fermi
@@ -78,10 +78,10 @@ GetCrossSection(const G4DynamicParticle* aParticle,
G4double G4IonsKoxCrossSection::calEcm ( G4double mp , G4double mt , G4double Plab )
{
G4double Elab = sqrt ( mp * mp + Plab * Plab );
G4double Ecm = sqrt ( mp * mp + mt * mt + 2 * Elab * mt );
G4double Elab = std::sqrt ( mp * mp + Plab * Plab );
G4double Ecm = std::sqrt ( mp * mp + mt * mt + 2 * Elab * mt );
G4double Pcm = Plab * mt / Ecm;
G4double KEcm = sqrt ( Pcm * Pcm + mp * mp ) - mp;
G4double KEcm = std::sqrt ( Pcm * Pcm + mp * mp ) - mp;
return KEcm;
}
@@ -94,14 +94,14 @@ G4double G4IonsKoxCrossSection::calCeValue( const G4double ke )
// There are no data below 30 MeV/n in Kox et al.,
G4double Ce;
G4double log10_ke = log10 ( ke );
G4double log10_ke = std::log10 ( ke );
if ( log10_ke > 1.5 )
{
Ce = - 10.0 / pow ( G4double(log10_ke) , G4double(5) ) + 2.0;
Ce = - 10.0 / std::pow ( G4double(log10_ke) , G4double(5) ) + 2.0;
}
else
{
Ce = ( - 10.0 / pow ( G4double(1.5) , G4double(5) ) + 2.0 ) / pow ( G4double(1.5) , G4double(3) ) * pow ( G4double(log10_ke) , G4double(3) );
Ce = ( - 10.0 / std::pow ( G4double(1.5) , G4double(5) ) + 2.0 ) / std::pow ( G4double(1.5) , G4double(3) ) * std::pow ( G4double(log10_ke) , G4double(3) );
}
return Ce;
@@ -47,8 +47,8 @@ GetCrossSection(const G4DynamicParticle* aParticle, const G4Element* anElement,
G4double one_third = 1.0 / 3.0;
G4double cubicrAt = pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = pow ( G4double(Ap) , G4double(one_third) );
G4double cubicrAt = std::pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = std::pow ( G4double(Ap) , G4double(one_third) );
G4double Rt = 1.12 * cubicrAt - 0.94 * ( 1.0 / cubicrAt );
G4double Rp = 1.12 * cubicrAp - 0.94 * ( 1.0 / cubicrAp );
@@ -72,7 +72,7 @@ GetCrossSection(const G4DynamicParticle* aParticle, const G4Element* anElement,
G4double Ecm = calEcmValue ( proj_mass , targ_mass , proj_momentum );
G4double R3 = 0.176 / pow ( G4double(Ecm) , G4double(one_third) ) * cubicrAt * cubicrAp / ( cubicrAt + cubicrAp );
G4double R3 = 0.176 / std::pow ( G4double(Ecm) , G4double(one_third) ) * cubicrAt * cubicrAp / ( cubicrAt + cubicrAp );
G4double R = R1 + R2 + R3;
@@ -86,10 +86,10 @@ GetCrossSection(const G4DynamicParticle* aParticle, const G4Element* anElement,
G4double G4IonsShenCrossSection::calEcmValue( const G4double mp , const G4double mt , const G4double Plab )
{
G4double Elab = sqrt ( mp * mp + Plab * Plab );
G4double Ecm = sqrt ( mp * mp + mt * mt + 2 * Elab * mt );
G4double Elab = std::sqrt ( mp * mp + Plab * Plab );
G4double Ecm = std::sqrt ( mp * mp + mt * mt + 2 * Elab * mt );
G4double Pcm = Plab * mt / Ecm;
G4double KEcm = sqrt ( Pcm * Pcm + mp * mp ) - mp;
G4double KEcm = std::sqrt ( Pcm * Pcm + mp * mp ) - mp;
return KEcm;
}
@@ -103,14 +103,14 @@ G4double G4IonsShenCrossSection::calCeValue( const G4double ke )
// There are no data below 30 MeV/n in Kox et al.,
G4double Ce;
G4double log10_ke = log10 ( ke );
G4double log10_ke = std::log10 ( ke );
if ( log10_ke > 1.5 )
{
Ce = - 10.0 / pow ( G4double(log10_ke) , G4double(5) ) + 2.0;
Ce = - 10.0 / std::pow ( G4double(log10_ke) , G4double(5) ) + 2.0;
}
else
{
Ce = ( - 10.0 / pow ( G4double(1.5) , G4double(5) ) + 2.0 ) / pow ( G4double(1.5) , G4double(3) ) * pow ( G4double(log10_ke) , G4double(3) );
Ce = ( - 10.0 / std::pow ( G4double(1.5) , G4double(5) ) + 2.0 ) / std::pow ( G4double(1.5) , G4double(3) ) * std::pow ( G4double(log10_ke) , G4double(3) );
}
return Ce;
}
@@ -40,13 +40,13 @@ GetCrossSection(const G4DynamicParticle* aParticle,
G4double one_third = 1.0 / 3.0;
G4double cubicrAt = pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = pow ( G4double(Ap) , G4double(one_third) );
G4double cubicrAt = std::pow ( G4double(At) , G4double(one_third) );
G4double cubicrAp = std::pow ( G4double(Ap) , G4double(one_third) );
G4double b0 = 1.581 - 0.876 * ( 1.0 / cubicrAp + 1.0 / cubicrAt );
xsection = pi * square_r0
* pow ( G4double(cubicrAp + cubicrAt - b0 * ( 1.0 / cubicrAp + 1.0 / cubicrAt ) ), G4double(2) );
* std::pow ( G4double(cubicrAp + cubicrAt - b0 * ( 1.0 / cubicrAp + 1.0 / cubicrAt ) ), G4double(2) );
return xsection;
}
@@ -37,7 +37,7 @@
G4double G4NeutronInelasticCrossSection::
GetCrossSection(G4double anEnergy, G4double atomicNumber, G4double nOfProtons)
{
G4double kineticEnergy = log10(anEnergy/MeV);
G4double kineticEnergy = std::log10(anEnergy/MeV);
G4double nOfNeutrons = atomicNumber-nOfProtons;
const G4double p1=1.3773;
const G4double p2=1.+10./atomicNumber-0.0006*atomicNumber;
@@ -47,15 +47,15 @@
const G4double p6=1.+200./atomicNumber+0.02*atomicNumber;
const G4double p7=(atomicNumber-70.)*(atomicNumber-200.)/11000.;
double part1 = pi*(p1*p1)*log(nOfNeutrons);
double part2 = 1.+ pow(atomicNumber, 1./3.) - p2*(1.-1./pow(atomicNumber, 1./3.));
double part1 = pi*(p1*p1)*std::log(nOfNeutrons);
double part2 = 1.+ std::pow(atomicNumber, 1./3.) - p2*(1.-1./std::pow(atomicNumber, 1./3.));
double firstexp = -p4*(kineticEnergy-p5);
double first=1.+exp(firstexp);
double first=1.+std::exp(firstexp);
double corr = 1.+p3*(1.-1./first);
double secondexp = -p6*(kineticEnergy-p7);
double second=1.+exp(secondexp);
double second=1.+std::exp(secondexp);
double corr2 =1./second;
double xsec = corr*corr2*part1*part2*10.*millibarn;
@@ -22,7 +22,7 @@
//
//
// The lust update: M.V. Kossov, CERN/ITEP(Moscow) 17-June-02
// GEANT4 tag $Name: gcross-V05-02-01 $
// GEANT4 tag $Name: geant4-07-00-cand-03 $
//
//
// G4 Physics class: G4PhotoNuclearCrossSection for gamma+A cross sections
@@ -57,11 +57,11 @@ G4double G4PhotoNuclearCrossSection::GetCrossSection(const G4DynamicParticle* aP
static const G4double Emin=THmin+(nL-1)*dE; // minE for the HighE part
static const G4double Emax=50000.; // maxE for the HighE part
static const G4int nH=224; // A#of HResonance points in lnE
static const G4double milE=log(Emin); // Low logarithm energy for the HighE part
static const G4double malE=log(Emax); // High logarithm energy (each 2.75 percent)
static const G4double milE=std::log(Emin); // Low logarithm energy for the HighE part
static const G4double malE=std::log(Emax); // High logarithm energy (each 2.75 percent)
static const G4double dlE=(malE-milE)/(nH-1); // Step in logarithm energy in the HighE part
//
//static const G4double shd=1.075-.0023*log(2.); // HE PomShadowing(D)
//static const G4double shd=1.075-.0023*std::log(2.); // HE PomShadowing(D)
static const G4double shd=1.0734; // HE PomShadowing(D)
static const G4double shc=0.072; // HE Shadowing constant
static const G4double poc=0.0375; // HE Pomeron coefficient
@@ -108,7 +108,7 @@ G4double G4PhotoNuclearCrossSection::GetCrossSection(const G4DynamicParticle* aP
#endif
if(!in) // Fill the new set of parameters for the new nucleus
{
G4double lnA=log(A); // The nucleus is not found in DB. It is new.
G4double lnA=std::log(A); // The nucleus is not found in DB. It is new.
if(A==1.) lastSP=1.; // The Reggeon shadowing (A=1)
else lastSP=A*(1.-shc*lnA); // The Reggeon shadowing
#ifdef debug
@@ -156,7 +156,7 @@ G4double G4PhotoNuclearCrossSection::GetCrossSection(const G4DynamicParticle* aP
}
else if (Energy<Emax) // High Energy region
{
G4double lE=log(Energy);
G4double lE=std::log(Energy);
#ifdef debug
G4cout<<"G4PNCS::GetCS: before HEN nH="<<nH<<",iE="<<milE<<",dlE="<<dlE<<G4endl;
#endif
@@ -164,10 +164,10 @@ G4double G4PhotoNuclearCrossSection::GetCrossSection(const G4DynamicParticle* aP
}
else // UHE region (calculation, but not so frequent)
{
G4double lE=log(Energy);
G4double lE=std::log(Energy);
//G4double sh=shd;
//if(A==1.)sh=shp;
sigma=lastSP*(poc*(lE-pos)+shd*exp(-reg*lE));
sigma=lastSP*(poc*(lE-pos)+shd*std::exp(-reg*lE));
}
#ifdef debug
G4cout<<"G4PNCS::GetCS: sigma="<<sigma<<G4endl;
@@ -223,7 +223,7 @@ G4double G4PhotoNuclearCrossSection::EquLinearFit(G4double X, G4int N, const G4d
return sigma;
}
// Calculate the functions for the log(A)
// Calculate the functions for the std::log(A)
G4int G4PhotoNuclearCrossSection::GetFunctions(G4double a, G4double* y, G4double* z)
{
static const G4int nLA=49; // A#of GDResonance basic nuclei
@@ -1494,13 +1494,13 @@ G4int G4PhotoNuclearCrossSection::GetFunctions(G4double a, G4double* y, G4double
return -1;
}
G4int r=0; // Low channel for GDR (filling-flag for GDR)
for(G4int i=0; i<nLA; i++) if(abs(a-LA[i])<.0005)
for(G4int i=0; i<nLA; i++) if(std::abs(a-LA[i])<.0005)
{
for(G4int k=0; k<nL; k++) y[k]=SL[i][k];
r=1; // Flag of filled GDR part
}
G4int h=0;
for(G4int j=0; j<nHA; j++) if(abs(a-HA[j])<.0005)
for(G4int j=0; j<nHA; j++) if(std::abs(a-HA[j])<.0005)
{
for(G4int k=0; k<nH; k++) z[k]=SH[j][k];
h=1; // Flag of filled GDR part
@@ -20,7 +20,7 @@
// * statement, and all its terms. *
// ********************************************************************
//
// GEANT4 tag $Name: geant4-06-00-patch-01 $
// GEANT4 tag $Name: geant4-07-00-cand-01 $
//
// --------------------------------------------------------------------
// by J.P Wellisch, Sun Sep 15 2002.
@@ -20,259 +20,261 @@
// * statement, and all its terms. *
// ********************************************************************
//
#include "G4PiNuclearCrossSection.hh"
#include "G4HadronicException.hh"
#include "G4HadTmpUtil.hh"
#include "G4ping.hh"
#include "G4PiNuclearCrossSection.hh"
#include "G4HadronicException.hh"
#include "G4HadTmpUtil.hh"
#include "G4ping.hh"
// by J.P Wellisch, Sun Sep 15 2002.
// Implements P2-90-158;
// by J.P Wellisch, Sun Sep 15 2002.
// Implements P2-90-158;
const G4double G4PiNuclearCrossSection::e1[38] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17, 0.18, 0.19, 0.2, 0.22, 0.24, 0.26, 0.28, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::he_t[38] = {40, 70, 108, 152, 208, 276, 300, 320, 329, 333, 332, 328, 322, 310, 288, 260, 240, 216, 196, 144, 125, 112, 108.5, 109, 110.5, 117, 123, 128.5, 135, 110, 96, 87, 85, 83.5, 83.5, 83.5, 83.5, 83.5};
const G4double G4PiNuclearCrossSection::he_in[38] = {18, 38, 62, 98, 136, 176, 190, 200, 209, 212, 212, 208, 204, 196, 176, 164, 150, 134, 124, 97.5, 90, 85, 82.5, 83.5, 86.5, 93, 97.5, 100, 102, 83, 77, 75, 74, 72.5, 72.5, 72.5, 72.5, 72.5};
const G4double G4PiNuclearCrossSection::be_m_t[38] = {150, 210, 294, 396, 520, 600, 623, 635, 642, 640, 630, 615, 600, 576, 540, 504, 470, 435, 400, 340, 294, 258, 236, 230, 233, 244, 257, 270, 276, 250, 230, 215, 205, 194, 188, 186, 186, 186};
const G4double G4PiNuclearCrossSection::be_m_in[38] = {90, 126, 177, 240, 320, 380, 400, 410, 414, 410, 400, 387, 371, 360, 333, 312, 285, 260, 237, 216, 198, 187, 182, 180, 182, 187, 193, 203, 207, 179, 172, 165, 159, 155, 144, 144, 144, 144};
const G4double G4PiNuclearCrossSection::be_p_t[24] = {96, 150, 222, 320, 430, 514, 545, 565, 574, 574, 564, 552, 535, 522, 490, 462, 432, 398, 367, 314, 276, 248, 232, 230};
const G4double G4PiNuclearCrossSection::be_p_in[24] = {60, 95, 142, 194, 262, 319, 345, 361, 364, 364, 354, 350, 330, 319, 298, 280, 258, 237, 216, 200, 189, 183, 182, 180};
const G4double G4PiNuclearCrossSection::e2[39] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.11, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17, 0.18, 0.2, 0.22, 0.24, 0.26, 0.28, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.575, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::c_m_t[39] = {204, 260, 366, 517, 630, 673, 694, 704, 710, 711, 706, 694, 676, 648, 616, 584, 548, 518, 489, 426, 376, 342, 323, 310, 312, 313, 319, 333, 342, 348, 310, 290, 268, 250, 245, 237, 234, 234, 234};
const G4double G4PiNuclearCrossSection::c_m_in[39] = {128, 160, 224, 315, 388, 416, 430, 438, 444, 445, 440, 432, 416, 400, 380, 354, 320, 304, 288, 264, 246, 240, 233, 232, 233, 234, 238, 246, 252, 256, 220, 210, 198, 187, 183, 176, 174, 174, 174};
const G4double G4PiNuclearCrossSection::c_p_t[24] = {140, 192, 294, 428, 594, 642, 662, 687, 685, 688, 684, 672, 656, 630, 598, 567, 533, 504, 474, 416, 369, 336, 319, 310};
const G4double G4PiNuclearCrossSection::c_p_in[24] = {94, 132, 184, 260, 370, 398, 408, 420, 426, 428, 424, 416, 400, 386, 366, 340, 308, 294, 280, 257, 241, 236, 231, 232};
const G4double G4PiNuclearCrossSection::n_m_t[39] = {246, 308, 424, 590, 729, 776, 800, 821, 822, 817, 800, 778, 768, 728, 690, 654, 615, 584, 556, 480, 430, 393, 373, 367, 368, 370, 375, 388, 390, 397, 364, 337, 310, 291, 275, 268, 268, 268, 268};
const G4double G4PiNuclearCrossSection::n_m_in[39] = {155, 188, 256, 360, 456, 492, 512, 526, 526, 520, 504, 491, 475, 450, 425, 396, 376, 360, 340, 300, 282, 270, 265, 265, 266, 268, 273, 280, 288, 288, 256, 237, 226, 218, 208, 202, 202, 202, 202};
const G4double G4PiNuclearCrossSection::n_p_t[27] = {150, 212, 328, 500, 680, 735, 762, 781, 782, 779, 770, 748, 740, 706, 672, 633, 600, 569, 541, 467, 419, 385, 368, 364, 366, 368, 375};
const G4double G4PiNuclearCrossSection::n_p_in[27] = {90, 140, 208, 300, 426, 467, 490, 504, 504, 500, 484, 474, 460, 437, 413, 381, 365, 350, 330, 292, 276, 267, 263, 264, 265, 267, 273};
const G4double G4PiNuclearCrossSection::e3[31] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::o_m_t[31] = {280, 360, 500, 685, 812, 861, 870, 865, 835, 800, 755, 700, 600, 537, 493, 468, 441, 436, 443, 449, 460, 463, 432, 385, 350, 325, 312, 307, 303, 303, 303};
const G4double G4PiNuclearCrossSection::o_m_in[31] = {190, 207, 300, 420, 500, 540, 550, 542, 520, 490, 460, 423, 360, 339, 321, 314, 312, 314, 319, 324, 328, 330, 300, 275, 250, 240, 229, 225, 222, 222, 222};
const G4double G4PiNuclearCrossSection::o_p_t[20] = {170, 240, 390, 570, 740, 818, 830, 822, 800, 765, 725, 675, 585, 525, 483, 458, 444, 447, 453, 449};
const G4double G4PiNuclearCrossSection::o_p_in[20] = {100, 145, 240, 340, 470, 518, 530, 522, 505, 477, 448, 412, 350, 330, 316, 310, 308, 311, 317, 324};
const G4double G4PiNuclearCrossSection::na_m_t[31] = {450, 545, 705, 910, 1020, 1075, 1087, 1080, 1042, 987, 943, 885, 790, 700, 650, 610, 585, 575, 585, 595, 600, 610, 556, 524, 494, 458, 445, 429, 427, 427, 427};
const G4double G4PiNuclearCrossSection::na_m_in[31] = {275, 315, 413, 545, 620, 660, 670, 662, 630, 593, 570, 520, 465, 420, 410, 395, 390, 400, 410, 418, 420, 422, 372, 348, 330, 320, 310, 294, 292, 292, 292};
const G4double G4PiNuclearCrossSection::na_p_t[22] = {210, 320, 530, 795, 960, 1035, 1050, 1040, 1007, 957, 918, 865, 773, 685, 636, 598, 575, 565, 578, 590, 598, 610};
const G4double G4PiNuclearCrossSection::na_p_in[22] = {115, 210, 340, 495, 585, 630, 645, 637, 605, 572, 550, 505, 455, 410, 401, 388, 383, 393, 405, 414, 418, 422};
const G4double G4PiNuclearCrossSection::e1[38] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17, 0.18, 0.19, 0.2, 0.22, 0.24, 0.26, 0.28, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::he_t[38] = {40, 70, 108, 152, 208, 276, 300, 320, 329, 333, 332, 328, 322, 310, 288, 260, 240, 216, 196, 144, 125, 112, 108.5, 109, 110.5, 117, 123, 128.5, 135, 110, 96, 87, 85, 83.5, 83.5, 83.5, 83.5, 83.5};
const G4double G4PiNuclearCrossSection::he_in[38] = {18, 38, 62, 98, 136, 176, 190, 200, 209, 212, 212, 208, 204, 196, 176, 164, 150, 134, 124, 97.5, 90, 85, 82.5, 83.5, 86.5, 93, 97.5, 100, 102, 83, 77, 75, 74, 72.5, 72.5, 72.5, 72.5, 72.5};
const G4double G4PiNuclearCrossSection::be_m_t[38] = {150, 210, 294, 396, 520, 600, 623, 635, 642, 640, 630, 615, 600, 576, 540, 504, 470, 435, 400, 340, 294, 258, 236, 230, 233, 244, 257, 270, 276, 250, 230, 215, 205, 194, 188, 186, 186, 186};
const G4double G4PiNuclearCrossSection::be_m_in[38] = {90, 126, 177, 240, 320, 380, 400, 410, 414, 410, 400, 387, 371, 360, 333, 312, 285, 260, 237, 216, 198, 187, 182, 180, 182, 187, 193, 203, 207, 179, 172, 165, 159, 155, 144, 144, 144, 144};
const G4double G4PiNuclearCrossSection::be_p_t[24] = {96, 150, 222, 320, 430, 514, 545, 565, 574, 574, 564, 552, 535, 522, 490, 462, 432, 398, 367, 314, 276, 248, 232, 230};
const G4double G4PiNuclearCrossSection::be_p_in[24] = {60, 95, 142, 194, 262, 319, 345, 361, 364, 364, 354, 350, 330, 319, 298, 280, 258, 237, 216, 200, 189, 183, 182, 180};
const G4double G4PiNuclearCrossSection::e2[39] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.11, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17, 0.18, 0.2, 0.22, 0.24, 0.26, 0.28, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.575, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::c_m_t[39] = {204, 260, 366, 517, 630, 673, 694, 704, 710, 711, 706, 694, 676, 648, 616, 584, 548, 518, 489, 426, 376, 342, 323, 310, 312, 313, 319, 333, 342, 348, 310, 290, 268, 250, 245, 237, 234, 234, 234};
const G4double G4PiNuclearCrossSection::c_m_in[39] = {128, 160, 224, 315, 388, 416, 430, 438, 444, 445, 440, 432, 416, 400, 380, 354, 320, 304, 288, 264, 246, 240, 233, 232, 233, 234, 238, 246, 252, 256, 220, 210, 198, 187, 183, 176, 174, 174, 174};
const G4double G4PiNuclearCrossSection::c_p_t[24] = {140, 192, 294, 428, 594, 642, 662, 687, 685, 688, 684, 672, 656, 630, 598, 567, 533, 504, 474, 416, 369, 336, 319, 310};
const G4double G4PiNuclearCrossSection::c_p_in[24] = {94, 132, 184, 260, 370, 398, 408, 420, 426, 428, 424, 416, 400, 386, 366, 340, 308, 294, 280, 257, 241, 236, 231, 232};
const G4double G4PiNuclearCrossSection::n_m_t[39] = {246, 308, 424, 590, 729, 776, 800, 821, 822, 817, 800, 778, 768, 728, 690, 654, 615, 584, 556, 480, 430, 393, 373, 367, 368, 370, 375, 388, 390, 397, 364, 337, 310, 291, 275, 268, 268, 268, 268};
const G4double G4PiNuclearCrossSection::n_m_in[39] = {155, 188, 256, 360, 456, 492, 512, 526, 526, 520, 504, 491, 475, 450, 425, 396, 376, 360, 340, 300, 282, 270, 265, 265, 266, 268, 273, 280, 288, 288, 256, 237, 226, 218, 208, 202, 202, 202, 202};
const G4double G4PiNuclearCrossSection::n_p_t[27] = {150, 212, 328, 500, 680, 735, 762, 781, 782, 779, 770, 748, 740, 706, 672, 633, 600, 569, 541, 467, 419, 385, 368, 364, 366, 368, 375};
const G4double G4PiNuclearCrossSection::n_p_in[27] = {90, 140, 208, 300, 426, 467, 490, 504, 504, 500, 484, 474, 460, 437, 413, 381, 365, 350, 330, 292, 276, 267, 263, 264, 265, 267, 273};
const G4double G4PiNuclearCrossSection::e3[31] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::o_m_t[31] = {280, 360, 500, 685, 812, 861, 870, 865, 835, 800, 755, 700, 600, 537, 493, 468, 441, 436, 443, 449, 460, 463, 432, 385, 350, 325, 312, 307, 303, 303, 303};
const G4double G4PiNuclearCrossSection::o_m_in[31] = {190, 207, 300, 420, 500, 540, 550, 542, 520, 490, 460, 423, 360, 339, 321, 314, 312, 314, 319, 324, 328, 330, 300, 275, 250, 240, 229, 225, 222, 222, 222};
const G4double G4PiNuclearCrossSection::o_p_t[20] = {170, 240, 390, 570, 740, 818, 830, 822, 800, 765, 725, 675, 585, 525, 483, 458, 444, 447, 453, 449};
const G4double G4PiNuclearCrossSection::o_p_in[20] = {100, 145, 240, 340, 470, 518, 530, 522, 505, 477, 448, 412, 350, 330, 316, 310, 308, 311, 317, 324};
const G4double G4PiNuclearCrossSection::na_m_t[31] = {450, 545, 705, 910, 1020, 1075, 1087, 1080, 1042, 987, 943, 885, 790, 700, 650, 610, 585, 575, 585, 595, 600, 610, 556, 524, 494, 458, 445, 429, 427, 427, 427};
const G4double G4PiNuclearCrossSection::na_m_in[31] = {275, 315, 413, 545, 620, 660, 670, 662, 630, 593, 570, 520, 465, 420, 410, 395, 390, 400, 410, 418, 420, 422, 372, 348, 330, 320, 310, 294, 292, 292, 292};
const G4double G4PiNuclearCrossSection::na_p_t[22] = {210, 320, 530, 795, 960, 1035, 1050, 1040, 1007, 957, 918, 865, 773, 685, 636, 598, 575, 565, 578, 590, 598, 610};
const G4double G4PiNuclearCrossSection::na_p_in[22] = {115, 210, 340, 495, 585, 630, 645, 637, 605, 572, 550, 505, 455, 410, 401, 388, 383, 393, 405, 414, 418, 422};
const G4double G4PiNuclearCrossSection::e3_1[31] = {.02, .04, .06, .08, .1, .12, .14, .16, .18, .2, .22, .25, .3, .35, .4, .45, .5, .6, .7, .8, .9, 1., 2., 3., 5., 10., 20., 50., 100., 500., 1000.};
const G4double G4PiNuclearCrossSection::al_m_t[31] = {532, 637, 832, 1057, 1207, 1230, 1210, 1174, 1133, 1095, 1038, 970, 890, 807, 750, 710, 675, 665, 670, 673, 678, 682, 618, 574, 546, 520, 507, 495, 488, 488, 488};
const G4double G4PiNuclearCrossSection::al_m_in[31] = {300, 360, 495, 665, 750, 765, 750, 730, 700, 660, 615, 570, 520, 490, 470, 450, 448, 450, 450, 452, 456, 460, 408, 392, 376, 356, 347, 338, 332, 332, 332};
const G4double G4PiNuclearCrossSection::al_p_t[21] = {225, 350, 616, 945, 1122, 1175, 1157, 1128, 1088, 1045, 988, 935, 870, 787, 730, 690, 660, 652, 660, 668, 678};
const G4double G4PiNuclearCrossSection::al_p_in[21] = {120, 238, 390, 610, 712, 735, 720, 703, 655, 635, 590, 550, 505, 475, 455, 438, 440, 445, 445, 450, 456};
const G4double G4PiNuclearCrossSection::ca_m_t[31] = {800, 980, 1240, 1460, 1570, 1600, 1580, 1535, 1475, 1425, 1375, 1295, 1200, 1083, 1000, 948, 915, 895, 900, 908, 915, 922, 856, 795, 740, 705, 682, 660, 660, 660, 660};
const G4double G4PiNuclearCrossSection::ca_m_in[31] = {470, 550, 620, 860, 955, 960, 920, 860, 820, 780, 740, 665, 637, 615, 600, 590, 600, 608, 610, 615, 550, 525, 510, 488, 470, 450, 450, 450, 450};
const G4double G4PiNuclearCrossSection::ca_p_t[23] = {275, 445, 790, 1195, 1440, 1485, 1475, 1435, 1385, 1335, 1295, 1245, 1160, 1050, 970, 923, 895, 877, 887, 897, 904, 913, 855};
const G4double G4PiNuclearCrossSection::ca_p_in[23] = {160, 315, 500, 745, 870, 905, 900, 860, 810, 770, 740, 710, 640, 617, 595, 585, 575, 575, 590, 600, 602, 608, 510}; // last number is 500 in org, changed to make things smooth.
const G4double G4PiNuclearCrossSection::e4[32] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::fe_m_t[32] = {1175, 1363, 1670, 1950, 2050, 2040, 1975, 1886, 1834, 1773, 1720, 1635, 1474, 1380, 1269, 1225, 1182, 1162, 1159, 1162, 1178, 1190, 1197, 1102, 1135, 975, 945, 925, 905, 905, 905, 905};
const G4double G4PiNuclearCrossSection::fe_m_in[32] = {625, 725, 910, 1180, 1275, 1250, 1200, 1150, 1100, 1040, 995, 925, 825, 810, 780, 760, 745, 740, 740, 740, 750, 760, 765, 690, 660, 635, 615, 600, 585, 585, 585, 585};
const G4double G4PiNuclearCrossSection::fe_p_t[25] = {330, 575, 1010, 1500, 1837, 1875, 1820, 1751, 1691, 1636, 1690, 1450, 1396, 1305, 1219, 1190, 1148, 1138, 1134, 1144, 1163, 1175, 1183, 1198, 1135};
const G4double G4PiNuclearCrossSection::fe_p_in[25] = {210, 410, 707, 1010, 1125, 1150, 1100, 1070, 1010, 960, 920, 776, 780, 760, 750, 740, 720, 725, 725, 730, 740, 750, 755, 690, 660};
const G4double G4PiNuclearCrossSection::cu_m_t[32] = {1400, 1600, 1875, 2088, 2200, 2220, 2175, 2125, 2075, 2012, 1950, 1855, 1670, 1530, 1430, 1370, 1315, 1315, 1315, 1330, 1345, 1360, 1365, 1250, 1185, 1128, 1070, 1035, 1010, 1010, 1010, 1010};
const G4double G4PiNuclearCrossSection::cu_m_in[32] = {725, 840, 1020, 1200, 1295, 1300, 1267, 1240, 1213, 1175, 1125, 1042, 950, 900, 860, 840, 830, 832, 835, 840, 850, 860, 865, 785, 735, 705, 680, 650, 630, 630, 630, 630};
const G4double G4PiNuclearCrossSection::cu_p_t[25] = {355, 605, 1120, 1630, 1940, 2010, 2010, 1980, 1925, 1895, 1830, 1730, 1585, 1490, 1400, 1340, 1290, 1290, 1290, 1310, 1330, 1345, 1350, 1240, 1185};
const G4double G4PiNuclearCrossSection::cu_p_in[25] = {230, 425, 780, 1025, 1155, 1190, 1190, 1180, 1125, 1100, 1050, 1000, 900, 870, 835, 815, 810, 812, 815, 825, 840, 850, 855, 780, 735};
const G4double G4PiNuclearCrossSection::e3_1[31] = {.02, .04, .06, .08, .1, .12, .14, .16, .18, .2, .22, .25, .3, .35, .4, .45, .5, .6, .7, .8, .9, 1., 2., 3., 5., 10., 20., 50., 100., 500., 1000.};
const G4double G4PiNuclearCrossSection::al_m_t[31] = {532, 637, 832, 1057, 1207, 1230, 1210, 1174, 1133, 1095, 1038, 970, 890, 807, 750, 710, 675, 665, 670, 673, 678, 682, 618, 574, 546, 520, 507, 495, 488, 488, 488};
const G4double G4PiNuclearCrossSection::al_m_in[31] = {300, 360, 495, 665, 750, 765, 750, 730, 700, 660, 615, 570, 520, 490, 470, 450, 448, 450, 450, 452, 456, 460, 408, 392, 376, 356, 347, 338, 332, 332, 332};
const G4double G4PiNuclearCrossSection::al_p_t[21] = {225, 350, 616, 945, 1122, 1175, 1157, 1128, 1088, 1045, 988, 935, 870, 787, 730, 690, 660, 652, 660, 668, 678};
const G4double G4PiNuclearCrossSection::al_p_in[21] = {120, 238, 390, 610, 712, 735, 720, 703, 655, 635, 590, 550, 505, 475, 455, 438, 440, 445, 445, 450, 456};
const G4double G4PiNuclearCrossSection::ca_m_t[31] = {800, 980, 1240, 1460, 1570, 1600, 1580, 1535, 1475, 1425, 1375, 1295, 1200, 1083, 1000, 948, 915, 895, 900, 908, 915, 922, 856, 795, 740, 705, 682, 660, 660, 660, 660};
const G4double G4PiNuclearCrossSection::ca_m_in[31] = {470, 550, 620, 860, 955, 960, 920, 860, 820, 780, 740, 665, 637, 615, 600, 590, 600, 608, 610, 615, 550, 525, 510, 488, 470, 450, 450, 450, 450};
const G4double G4PiNuclearCrossSection::ca_p_t[23] = {275, 445, 790, 1195, 1440, 1485, 1475, 1435, 1385, 1335, 1295, 1245, 1160, 1050, 970, 923, 895, 877, 887, 897, 904, 913, 855};
const G4double G4PiNuclearCrossSection::ca_p_in[23] = {160, 315, 500, 745, 870, 905, 900, 860, 810, 770, 740, 710, 640, 617, 595, 585, 575, 575, 590, 600, 602, 608, 510}; // last number is 500 in org, changed to make things smooth.
const G4double G4PiNuclearCrossSection::e5[34] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::mo_m_t[34] = {2430, 2610, 2710, 2790, 2880, 2940, 2965, 2970, 2970, 2920, 2840, 2720, 2570, 2500, 2365, 2200, 2050, 1926, 1825, 1768, 1749, 1750, 1778, 1789, 1808, 1690, 1645, 1530, 1492, 1450, 1425, 1425, 1425, 1425};
const G4double G4PiNuclearCrossSection::mo_m_in[34] = {925, 1125, 1250, 1375, 1500, 1600, 1680, 1750, 1770, 1730, 1660, 1580, 1500, 1450, 1330, 1250, 1190, 1140, 1100, 1075, 1075, 1070, 1088, 1095, 1110, 1035, 1005, 940, 917, 880, 860, 860, 860, 860};
const G4double G4PiNuclearCrossSection::mo_p_t[27] = {410, 730, 1110, 1530, 1920, 2200, 2385, 2520, 2600, 2630, 2575, 2470, 2320, 2285, 2185, 2053, 1945, 1852, 1776, 1719, 1710, 1716, 1746, 1759, 1778, 1675, 1645};
const G4double G4PiNuclearCrossSection::mo_p_in[27] = {270, 540, 825, 975, 1140, 1285, 1400, 1480, 1555, 1580, 1525, 1470, 1360, 1340, 1255, 1160, 1120, 1085, 1060, 1045, 1045, 1045, 1065, 1075, 1090, 1025, 1005};
const G4double G4PiNuclearCrossSection::cd_m_t[34] = {3060, 3125, 3170, 3220, 3255, 3280, 3290, 3260, 3270, 3200, 3120, 3080, 3090, 2920, 2810, 2640, 2362, 2230, 2115, 2050, 2020, 2025, 2040, 2070, 2100, 1900, 1795, 1740, 1675, 1645, 1625, 1620, 1620, 1620};
const G4double G4PiNuclearCrossSection::cd_m_in[34]= {1025, 1275, 1440, 1625, 1740, 1800, 1880, 1920, 1980, 1920, 1850, 1810, 1720, 1650, 1560, 1450, 1330, 1290, 1245, 1210, 1200, 1200, 1205, 1205, 1230, 1130, 1085, 1060, 1000, 985, 975, 970, 970, 970};
const G4double G4PiNuclearCrossSection::cd_p_t[28] = {455, 780, 1170, 1700, 2120, 2400, 2600, 2720, 2820, 2840, 2800, 2760, 2720, 2640, 2560, 2450, 2252, 2130, 2035, 1985, 1970, 1975, 2005, 2035, 2070, 1880, 1795, 1740};
const G4double G4PiNuclearCrossSection::cd_p_in[28] = {310, 580, 880, 1060, 1270, 1400, 1530, 1610, 1660, 1680, 1640, 1600, 1560, 1500, 1430, 1330, 1280, 1230, 1200, 1180, 1170, 1175, 1180, 1180, 1210, 1120, 1085, 1060};
const G4double G4PiNuclearCrossSection::e4[32] = {0.02, 0.04, 0.06, 0.08, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::fe_m_t[32] = {1175, 1363, 1670, 1950, 2050, 2040, 1975, 1886, 1834, 1773, 1720, 1635, 1474, 1380, 1269, 1225, 1182, 1162, 1159, 1162, 1178, 1190, 1197, 1102, 1135, 975, 945, 925, 905, 905, 905, 905};
const G4double G4PiNuclearCrossSection::fe_m_in[32] = {625, 725, 910, 1180, 1275, 1250, 1200, 1150, 1100, 1040, 995, 925, 825, 810, 780, 760, 745, 740, 740, 740, 750, 760, 765, 690, 660, 635, 615, 600, 585, 585, 585, 585};
const G4double G4PiNuclearCrossSection::fe_p_t[25] = {330, 575, 1010, 1500, 1837, 1875, 1820, 1751, 1691, 1636, 1690, 1450, 1396, 1305, 1219, 1190, 1148, 1138, 1134, 1144, 1163, 1175, 1183, 1198, 1135};
const G4double G4PiNuclearCrossSection::fe_p_in[25] = {210, 410, 707, 1010, 1125, 1150, 1100, 1070, 1010, 960, 920, 776, 780, 760, 750, 740, 720, 725, 725, 730, 740, 750, 755, 690, 660};
const G4double G4PiNuclearCrossSection::cu_m_t[32] = {1400, 1600, 1875, 2088, 2200, 2220, 2175, 2125, 2075, 2012, 1950, 1855, 1670, 1530, 1430, 1370, 1315, 1315, 1315, 1330, 1345, 1360, 1365, 1250, 1185, 1128, 1070, 1035, 1010, 1010, 1010, 1010};
const G4double G4PiNuclearCrossSection::cu_m_in[32] = {725, 840, 1020, 1200, 1295, 1300, 1267, 1240, 1213, 1175, 1125, 1042, 950, 900, 860, 840, 830, 832, 835, 840, 850, 860, 865, 785, 735, 705, 680, 650, 630, 630, 630, 630};
const G4double G4PiNuclearCrossSection::cu_p_t[25] = {355, 605, 1120, 1630, 1940, 2010, 2010, 1980, 1925, 1895, 1830, 1730, 1585, 1490, 1400, 1340, 1290, 1290, 1290, 1310, 1330, 1345, 1350, 1240, 1185};
const G4double G4PiNuclearCrossSection::cu_p_in[25] = {230, 425, 780, 1025, 1155, 1190, 1190, 1180, 1125, 1100, 1050, 1000, 900, 870, 835, 815, 810, 812, 815, 825, 840, 850, 855, 780, 735};
const G4double G4PiNuclearCrossSection::e6[35] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::sn_m_t[35] = {3000, 3180, 3250, 3300, 3300, 3410, 3470, 3450, 3410, 3350, 3280, 3200, 3120, 3050, 2900, 2630, 2500, 2325, 2190, 2100, 2060, 2055, 2055, 2055, 2067, 2085, 2000, 1900, 1835, 1770, 1720, 1700, 1695, 1695, 1695};
const G4double G4PiNuclearCrossSection::sn_m_in[35] = {1050, 1350, 1520, 1650, 1800, 1980, 2070, 2120, 2090, 2050, 1980, 1920, 1830, 1770, 1670, 1500, 1435, 1350, 1300, 1230, 1220, 1235, 1235, 1235, 1237, 1240, 1160, 1120, 1090, 1065, 1040, 1020, 1015, 1015, 1015};
const G4double G4PiNuclearCrossSection::sn_p_t[29] = { 465, 800, 1200, 1760, 2170, 2480, 2730, 2885, 2970, 2980, 2970, 2890, 2840, 2790, 2620, 2450, 2335, 2205, 2080, 2020, 2010, 1990, 1990, 2015, 2030, 2045, 1980, 1890, 1835};
const G4double G4PiNuclearCrossSection::sn_p_in[29] = { 315, 590, 880, 1220, 1460, 1580, 1700, 1770, 1810, 1810, 1800, 1730, 1680, 1630, 1530, 1400, 1335, 1270, 1210, 1180, 1190, 1190, 1190, 1205, 1210, 1210, 1150, 1115, 1090};
const G4double G4PiNuclearCrossSection::w_m_t[35] = {5200, 5115, 5025, 4975, 4900, 4850, 4780, 4725, 4600, 4490, 4355, 4255, 4125, 4040, 3830, 3580, 3330, 3110, 2955, 2860, 2852, 2845, 2885, 2900, 2915, 2940, 2800, 2660, 2570, 2490, 2460, 2425, 2420, 2420, 2420};
const G4double G4PiNuclearCrossSection::w_m_in[35] = {1450, 1850, 2100, 2350, 2550, 2700, 2825, 2900, 2850, 2750, 2630, 2525, 2400, 2300, 2200, 2070, 1880, 1770, 1715, 1680, 1680, 1680, 1685, 1690, 1700, 1720, 1635, 1560, 1530, 1460, 1440, 1410, 1410, 1410, 1410};
const G4double G4PiNuclearCrossSection::w_p_t[30] = { 480, 900, 1500, 2350, 3020, 3420, 3650, 3775, 3875, 3830, 3750, 3700, 3630, 3550, 3550, 3290, 3070, 2890, 2840, 2730, 2725, 2720, 2770, 2805, 2828, 2865, 2770, 2640, 2570, 2490};
const G4double G4PiNuclearCrossSection::w_p_in[30] = { 325, 680, 990, 1500, 1850, 2150, 2250, 2300, 2350, 2330, 2280, 2230, 2200, 2120, 2130, 1900, 1780, 1670, 1635, 1600, 1602, 1605, 1610, 1615, 1630, 1660, 1620, 1550, 1530, 1460};
const G4double G4PiNuclearCrossSection::e5[34] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::mo_m_t[34] = {2430, 2610, 2710, 2790, 2880, 2940, 2965, 2970, 2970, 2920, 2840, 2720, 2570, 2500, 2365, 2200, 2050, 1926, 1825, 1768, 1749, 1750, 1778, 1789, 1808, 1690, 1645, 1530, 1492, 1450, 1425, 1425, 1425, 1425};
const G4double G4PiNuclearCrossSection::mo_m_in[34] = {925, 1125, 1250, 1375, 1500, 1600, 1680, 1750, 1770, 1730, 1660, 1580, 1500, 1450, 1330, 1250, 1190, 1140, 1100, 1075, 1075, 1070, 1088, 1095, 1110, 1035, 1005, 940, 917, 880, 860, 860, 860, 860};
const G4double G4PiNuclearCrossSection::mo_p_t[27] = {410, 730, 1110, 1530, 1920, 2200, 2385, 2520, 2600, 2630, 2575, 2470, 2320, 2285, 2185, 2053, 1945, 1852, 1776, 1719, 1710, 1716, 1746, 1759, 1778, 1675, 1645};
const G4double G4PiNuclearCrossSection::mo_p_in[27] = {270, 540, 825, 975, 1140, 1285, 1400, 1480, 1555, 1580, 1525, 1470, 1360, 1340, 1255, 1160, 1120, 1085, 1060, 1045, 1045, 1045, 1065, 1075, 1090, 1025, 1005};
const G4double G4PiNuclearCrossSection::cd_m_t[34] = {3060, 3125, 3170, 3220, 3255, 3280, 3290, 3260, 3270, 3200, 3120, 3080, 3090, 2920, 2810, 2640, 2362, 2230, 2115, 2050, 2020, 2025, 2040, 2070, 2100, 1900, 1795, 1740, 1675, 1645, 1625, 1620, 1620, 1620};
const G4double G4PiNuclearCrossSection::cd_m_in[34]= {1025, 1275, 1440, 1625, 1740, 1800, 1880, 1920, 1980, 1920, 1850, 1810, 1720, 1650, 1560, 1450, 1330, 1290, 1245, 1210, 1200, 1200, 1205, 1205, 1230, 1130, 1085, 1060, 1000, 985, 975, 970, 970, 970};
const G4double G4PiNuclearCrossSection::cd_p_t[28] = {455, 780, 1170, 1700, 2120, 2400, 2600, 2720, 2820, 2840, 2800, 2760, 2720, 2640, 2560, 2450, 2252, 2130, 2035, 1985, 1970, 1975, 2005, 2035, 2070, 1880, 1795, 1740};
const G4double G4PiNuclearCrossSection::cd_p_in[28] = {310, 580, 880, 1060, 1270, 1400, 1530, 1610, 1660, 1680, 1640, 1600, 1560, 1500, 1430, 1330, 1280, 1230, 1200, 1180, 1170, 1175, 1180, 1180, 1210, 1120, 1085, 1060};
const G4double G4PiNuclearCrossSection::e7[35] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::pb_m_t[35] = {5890, 5700, 5610, 5580, 5550, 5480, 5400, 5300, 5100, 4930, 4750, 4600, 4400, 4280, 4170, 3915, 3650, 3470, 3260, 3150, 3120, 3070, 3085, 3100, 3120, 3160, 3070, 2930, 2820, 2750, 2710, 2655, 2640, 2640, 2640};
const G4double G4PiNuclearCrossSection::pb_m_in[35] = {1575, 2025, 2300, 2575, 2850, 3000, 3115, 3180, 3080, 2940, 2800, 2670, 2550, 2450, 2370, 2220, 2110, 2000, 1920, 1880, 1850, 1800, 1805, 1810, 1820, 1840, 1800, 1720, 1640, 1620, 1570, 1530, 1530, 1530, 1530};
const G4double G4PiNuclearCrossSection::pb_p_t[30] = { 515, 940, 1500, 2400, 3270, 3750, 4050, 4140, 4260, 4200, 4080, 3990, 3990, 3810, 3730, 3520, 3370, 3186, 3110, 3010, 2990, 2985, 3005, 3020, 3040, 3080, 3020, 2905, 2790, 2750};
const G4double G4PiNuclearCrossSection::pb_p_in[30] = { 348, 707, 1040, 1650, 2100, 2400, 2580, 2640, 2650, 2520, 2410, 2300, 2250, 2190, 2130, 2000, 1930, 1870, 1830, 1790, 1770, 1765, 1775, 1780, 1790, 1800, 1775, 1710, 1620, 1620};
const G4double G4PiNuclearCrossSection::u_m_t[35] = {7080, 6830, 6650, 6530, 6400, 6280, 6100, 5840, 5660, 5520, 5330, 5160, 4990, 4810, 4630, 4323, 4130, 3870, 3700, 3550, 3490, 3465, 3467, 3475, 3495, 3515, 3440, 3360, 3150, 3040, 2985, 2955, 2940, 2940, 2940};
const G4double G4PiNuclearCrossSection::u_m_in[35] = {1740, 2220, 2500, 2820, 3080, 3300, 3420, 3500, 3420, 3330, 3200, 3060, 2940, 2850, 2710, 2470, 2380, 2250, 2160, 2080, 2040, 2045, 2047, 2050, 2055, 2060, 2010, 1980, 1830, 1780, 1735, 1710, 1700, 1700, 1700};
const G4double G4PiNuclearCrossSection::u_p_t[30] = { 485, 960, 1580, 2700, 3550, 4050, 4320, 4420, 4620, 4660, 4580, 4470, 4350, 4295, 4187, 3938, 3755, 3573, 3450, 3342, 3310, 3295, 3310, 3330, 3375, 3405, 3350, 3338, 3135, 3040};
const G4double G4PiNuclearCrossSection::u_p_in[30] = { 334, 720, 1020, 1560, 2100, 2300, 2550, 2700, 2880, 2880, 2760, 2660, 2550, 2510, 2430, 2270, 2130, 2060, 2000, 1970, 1950, 1950, 1960, 1960, 1970, 1980, 1950, 1978, 1830, 1780};
const G4double G4PiNuclearCrossSection::e6[35] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::sn_m_t[35] = {3000, 3180, 3250, 3300, 3300, 3410, 3470, 3450, 3410, 3350, 3280, 3200, 3120, 3050, 2900, 2630, 2500, 2325, 2190, 2100, 2060, 2055, 2055, 2055, 2067, 2085, 2000, 1900, 1835, 1770, 1720, 1700, 1695, 1695, 1695};
const G4double G4PiNuclearCrossSection::sn_m_in[35] = {1050, 1350, 1520, 1650, 1800, 1980, 2070, 2120, 2090, 2050, 1980, 1920, 1830, 1770, 1670, 1500, 1435, 1350, 1300, 1230, 1220, 1235, 1235, 1235, 1237, 1240, 1160, 1120, 1090, 1065, 1040, 1020, 1015, 1015, 1015};
const G4double G4PiNuclearCrossSection::sn_p_t[29] = { 465, 800, 1200, 1760, 2170, 2480, 2730, 2885, 2970, 2980, 2970, 2890, 2840, 2790, 2620, 2450, 2335, 2205, 2080, 2020, 2010, 1990, 1990, 2015, 2030, 2045, 1980, 1890, 1835};
const G4double G4PiNuclearCrossSection::sn_p_in[29] = { 315, 590, 880, 1220, 1460, 1580, 1700, 1770, 1810, 1810, 1800, 1730, 1680, 1630, 1530, 1400, 1335, 1270, 1210, 1180, 1190, 1190, 1190, 1205, 1210, 1210, 1150, 1115, 1090};
const G4double G4PiNuclearCrossSection::w_m_t[35] = {5200, 5115, 5025, 4975, 4900, 4850, 4780, 4725, 4600, 4490, 4355, 4255, 4125, 4040, 3830, 3580, 3330, 3110, 2955, 2860, 2852, 2845, 2885, 2900, 2915, 2940, 2800, 2660, 2570, 2490, 2460, 2425, 2420, 2420, 2420};
const G4double G4PiNuclearCrossSection::w_m_in[35] = {1450, 1850, 2100, 2350, 2550, 2700, 2825, 2900, 2850, 2750, 2630, 2525, 2400, 2300, 2200, 2070, 1880, 1770, 1715, 1680, 1680, 1680, 1685, 1690, 1700, 1720, 1635, 1560, 1530, 1460, 1440, 1410, 1410, 1410, 1410};
const G4double G4PiNuclearCrossSection::w_p_t[30] = { 480, 900, 1500, 2350, 3020, 3420, 3650, 3775, 3875, 3830, 3750, 3700, 3630, 3550, 3550, 3290, 3070, 2890, 2840, 2730, 2725, 2720, 2770, 2805, 2828, 2865, 2770, 2640, 2570, 2490};
const G4double G4PiNuclearCrossSection::w_p_in[30] = { 325, 680, 990, 1500, 1850, 2150, 2250, 2300, 2350, 2330, 2280, 2230, 2200, 2120, 2130, 1900, 1780, 1670, 1635, 1600, 1602, 1605, 1610, 1615, 1630, 1660, 1620, 1550, 1530, 1460};
G4PiNuclearCrossSection::
G4PiNuclearCrossSection()
{
thePimData.push_back(new G4PiData(he_t, he_in, e1, 38));
thePipData.push_back(new G4PiData(he_t, he_in, e1, 38));
thePimData.push_back(new G4PiData(be_m_t, be_m_in, e1, 38));
thePipData.push_back(new G4PiData(be_p_t, be_p_in, e1, 24));
thePimData.push_back(new G4PiData(c_m_t, c_m_in, e2, 39));
thePipData.push_back(new G4PiData(c_p_t, c_p_in, e2, 24));
thePimData.push_back(new G4PiData(n_m_t, n_m_in, e2, 39));
thePipData.push_back(new G4PiData(n_p_t, n_p_in, e2, 27));
thePimData.push_back(new G4PiData(o_m_t, o_m_in, e3, 31));
thePipData.push_back(new G4PiData(o_p_t, o_p_in, e3, 20));
thePimData.push_back(new G4PiData(na_m_t, na_m_in, e3, 31));
thePipData.push_back(new G4PiData(na_p_t, na_p_in, e3, 22));
thePimData.push_back(new G4PiData(al_m_t, al_m_in, e3_1, 31));
thePipData.push_back(new G4PiData(al_p_t, al_p_in, e3_1, 21));
thePimData.push_back(new G4PiData(ca_m_t, ca_m_in, e3_1, 31));
thePipData.push_back(new G4PiData(ca_p_t, ca_p_in, e3_1, 23));
thePimData.push_back(new G4PiData(fe_m_t, fe_m_in, e4, 32));
thePipData.push_back(new G4PiData(fe_p_t, fe_p_in, e4, 25));
thePimData.push_back(new G4PiData(cu_m_t, cu_m_in, e4, 32));
thePipData.push_back(new G4PiData(cu_p_t, cu_p_in, e4, 25));
thePimData.push_back(new G4PiData(mo_m_t, mo_m_in, e5, 34));
thePipData.push_back(new G4PiData(mo_p_t, mo_p_in, e5, 27));
thePimData.push_back(new G4PiData(cd_m_t, cd_m_in, e5, 34));
thePipData.push_back(new G4PiData(cd_p_t, cd_p_in, e5, 28));
thePimData.push_back(new G4PiData(sn_m_t, sn_m_in, e6, 35));
thePipData.push_back(new G4PiData(sn_p_t, sn_p_in, e6, 29));
thePimData.push_back(new G4PiData(w_m_t, w_m_in, e6, 35));
thePipData.push_back(new G4PiData(w_p_t, w_p_in, e6, 30));
thePimData.push_back(new G4PiData(pb_m_t, pb_m_in, e7, 35));
thePipData.push_back(new G4PiData(pb_p_t, pb_p_in, e7, 30));
thePimData.push_back(new G4PiData(u_m_t, u_m_in, e7, 35));
thePipData.push_back(new G4PiData(u_p_t, u_p_in, e7, 30));
const G4double G4PiNuclearCrossSection::e7[35] = {0.02, 0.04, 0.05, 0.06, 0.07, 0.08, 0.09, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.22, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.7, 0.8, 0.9, 1, 2, 3, 5, 10, 20, 50, 100, 500, 1000};
const G4double G4PiNuclearCrossSection::pb_m_t[35] = {5890, 5700, 5610, 5580, 5550, 5480, 5400, 5300, 5100, 4930, 4750, 4600, 4400, 4280, 4170, 3915, 3650, 3470, 3260, 3150, 3120, 3070, 3085, 3100, 3120, 3160, 3070, 2930, 2820, 2750, 2710, 2655, 2640, 2640, 2640};
const G4double G4PiNuclearCrossSection::pb_m_in[35] = {1575, 2025, 2300, 2575, 2850, 3000, 3115, 3180, 3080, 2940, 2800, 2670, 2550, 2450, 2370, 2220, 2110, 2000, 1920, 1880, 1850, 1800, 1805, 1810, 1820, 1840, 1800, 1720, 1640, 1620, 1570, 1530, 1530, 1530, 1530};
const G4double G4PiNuclearCrossSection::pb_p_t[30] = { 515, 940, 1500, 2400, 3270, 3750, 4050, 4140, 4260, 4200, 4080, 3990, 3990, 3810, 3730, 3520, 3370, 3186, 3110, 3010, 2990, 2985, 3005, 3020, 3040, 3080, 3020, 2905, 2790, 2750};
const G4double G4PiNuclearCrossSection::pb_p_in[30] = { 348, 707, 1040, 1650, 2100, 2400, 2580, 2640, 2650, 2520, 2410, 2300, 2250, 2190, 2130, 2000, 1930, 1870, 1830, 1790, 1770, 1765, 1775, 1780, 1790, 1800, 1775, 1710, 1620, 1620};
const G4double G4PiNuclearCrossSection::u_m_t[35] = {7080, 6830, 6650, 6530, 6400, 6280, 6100, 5840, 5660, 5520, 5330, 5160, 4990, 4810, 4630, 4323, 4130, 3870, 3700, 3550, 3490, 3465, 3467, 3475, 3495, 3515, 3440, 3360, 3150, 3040, 2985, 2955, 2940, 2940, 2940};
const G4double G4PiNuclearCrossSection::u_m_in[35] = {1740, 2220, 2500, 2820, 3080, 3300, 3420, 3500, 3420, 3330, 3200, 3060, 2940, 2850, 2710, 2470, 2380, 2250, 2160, 2080, 2040, 2045, 2047, 2050, 2055, 2060, 2010, 1980, 1830, 1780, 1735, 1710, 1700, 1700, 1700};
const G4double G4PiNuclearCrossSection::u_p_t[30] = { 485, 960, 1580, 2700, 3550, 4050, 4320, 4420, 4620, 4660, 4580, 4470, 4350, 4295, 4187, 3938, 3755, 3573, 3450, 3342, 3310, 3295, 3310, 3330, 3375, 3405, 3350, 3338, 3135, 3040};
const G4double G4PiNuclearCrossSection::u_p_in[30] = { 334, 720, 1020, 1560, 2100, 2300, 2550, 2700, 2880, 2880, 2760, 2660, 2550, 2510, 2430, 2270, 2130, 2060, 2000, 1970, 1950, 1950, 1960, 1960, 1970, 1980, 1950, 1978, 1830, 1780};
theZ.push_back(2); // He
theZ.push_back(4); // Be
theZ.push_back(6); // C
theZ.push_back(7); // N
theZ.push_back(8); // O
theZ.push_back(11); // Na
theZ.push_back(13); // Al
theZ.push_back(20); // Ca
theZ.push_back(26); // Fe
theZ.push_back(29); // Cu
theZ.push_back(42); // Mo
theZ.push_back(48); // Cd
theZ.push_back(50); // Sn
theZ.push_back(74); // W
theZ.push_back(82); // Pb
theZ.push_back(92); // U
}
G4PiNuclearCrossSection::
G4PiNuclearCrossSection()
{
thePimData.push_back(new G4PiData(he_t, he_in, e1, 38));
thePipData.push_back(new G4PiData(he_t, he_in, e1, 38));
thePimData.push_back(new G4PiData(be_m_t, be_m_in, e1, 38));
thePipData.push_back(new G4PiData(be_p_t, be_p_in, e1, 24));
thePimData.push_back(new G4PiData(c_m_t, c_m_in, e2, 39));
thePipData.push_back(new G4PiData(c_p_t, c_p_in, e2, 24));
thePimData.push_back(new G4PiData(n_m_t, n_m_in, e2, 39));
thePipData.push_back(new G4PiData(n_p_t, n_p_in, e2, 27));
thePimData.push_back(new G4PiData(o_m_t, o_m_in, e3, 31));
thePipData.push_back(new G4PiData(o_p_t, o_p_in, e3, 20));
thePimData.push_back(new G4PiData(na_m_t, na_m_in, e3, 31));
thePipData.push_back(new G4PiData(na_p_t, na_p_in, e3, 22));
thePimData.push_back(new G4PiData(al_m_t, al_m_in, e3_1, 31));
thePipData.push_back(new G4PiData(al_p_t, al_p_in, e3_1, 21));
thePimData.push_back(new G4PiData(ca_m_t, ca_m_in, e3_1, 31));
thePipData.push_back(new G4PiData(ca_p_t, ca_p_in, e3_1, 23));
thePimData.push_back(new G4PiData(fe_m_t, fe_m_in, e4, 32));
thePipData.push_back(new G4PiData(fe_p_t, fe_p_in, e4, 25));
thePimData.push_back(new G4PiData(cu_m_t, cu_m_in, e4, 32));
thePipData.push_back(new G4PiData(cu_p_t, cu_p_in, e4, 25));
thePimData.push_back(new G4PiData(mo_m_t, mo_m_in, e5, 34));
thePipData.push_back(new G4PiData(mo_p_t, mo_p_in, e5, 27));
thePimData.push_back(new G4PiData(cd_m_t, cd_m_in, e5, 34));
thePipData.push_back(new G4PiData(cd_p_t, cd_p_in, e5, 28));
thePimData.push_back(new G4PiData(sn_m_t, sn_m_in, e6, 35));
thePipData.push_back(new G4PiData(sn_p_t, sn_p_in, e6, 29));
thePimData.push_back(new G4PiData(w_m_t, w_m_in, e6, 35));
thePipData.push_back(new G4PiData(w_p_t, w_p_in, e6, 30));
thePimData.push_back(new G4PiData(pb_m_t, pb_m_in, e7, 35));
thePipData.push_back(new G4PiData(pb_p_t, pb_p_in, e7, 30));
thePimData.push_back(new G4PiData(u_m_t, u_m_in, e7, 35));
thePipData.push_back(new G4PiData(u_p_t, u_p_in, e7, 30));
G4PiNuclearCrossSection::
~G4PiNuclearCrossSection()
{
std::for_each(thePimData.begin(), thePimData.end(), G4PiData::Delete());
std::for_each(thePipData.begin(), thePipData.end(), G4PiData::Delete());
}
theZ.push_back(2); // He
theZ.push_back(4); // Be
theZ.push_back(6); // C
theZ.push_back(7); // N
theZ.push_back(8); // O
theZ.push_back(11); // Na
theZ.push_back(13); // Al
theZ.push_back(20); // Ca
theZ.push_back(26); // Fe
theZ.push_back(29); // Cu
theZ.push_back(42); // Mo
theZ.push_back(48); // Cd
theZ.push_back(50); // Sn
theZ.push_back(74); // W
theZ.push_back(82); // Pb
theZ.push_back(92); // U
G4double G4PiNuclearCrossSection::
GetCrossSection(const G4DynamicParticle* aParticle,
const G4Element* anElement,
G4double )
{
// precondition
G4ping debug("debug_PiNuclearCrossSection");
using namespace std;
G4bool ok = false;
if(aParticle->GetDefinition() == G4PionMinus::PionMinus()) ok=true;
if(aParticle->GetDefinition() == G4PionPlus::PionPlus()) ok=true;
if(!ok)
{
throw G4HadronicException(__FILE__, __LINE__,
"Call to G4PiNuclearCrossSection failed.");
}
G4double charge = aParticle->GetDefinition()->GetPDGCharge();
G4double kineticEnergy = aParticle->GetKineticEnergy();
}
// body
G4double result = 0;
G4int Z=G4lrint(anElement->GetZ());
debug.push_back(Z);
size_t it=0;
while(it<theZ.size() && Z>theZ[it]) it++;
debug.push_back(theZ[it]);
debug.push_back(kineticEnergy);
if(Z > theZ[it])
{
throw G4HadronicException(__FILE__, __LINE__,
"Called G4PiNuclearCrossSection outside parametrization");
}
G4int Z1, Z2;
G4double x1, x2;
if(charge<0)
{
if(theZ[it]==Z)
{
result = thePimData[it]->ReactionXSection(kineticEnergy);
debug.push_back("D1 ");
debug.push_back(result);
}
else
{
x1 = thePimData[it-1]->ReactionXSection(kineticEnergy);
Z1 = theZ[it-1];
x2 = thePimData[it]->ReactionXSection(kineticEnergy);
Z2 = theZ[it];
result = Interpolate(Z1, Z2, Z, x1, x2);
debug.push_back("D2 ");
debug.push_back(x1);
debug.push_back(x2);
debug.push_back(Z1);
debug.push_back(Z2);
debug.push_back(result);
}
}
else
{
if(theZ[it]==Z)
{
std::vector<G4PiData *> * theData = &thePimData;
if(thePipData[it]->AppliesTo(kineticEnergy))
{
theData = &thePipData;
}
result = theData->operator[](it)->ReactionXSection(kineticEnergy);
debug.push_back("D3 ");
debug.push_back(result);
}
else
{
std::vector<G4PiData *> * theLData = &thePimData;
if(thePipData[it-1]->AppliesTo(kineticEnergy))
{
theLData = &thePipData;
}
std::vector<G4PiData *> * theHData = &thePimData;
if(thePipData[it]->AppliesTo(kineticEnergy))
{
theHData = &thePipData;
}
x1 = theLData->operator[](it-1)->ReactionXSection(kineticEnergy);
Z1 = theZ[it-1];
x2 = theHData->operator[](it)->ReactionXSection(kineticEnergy);
Z2 = theZ[it];
result = Interpolate(Z1, Z2, Z, x1, x2);
debug.push_back("D4 ");
debug.push_back(x1);
debug.push_back(x2);
debug.push_back(Z1);
debug.push_back(Z2);
debug.push_back(result);
}
}
debug.dump();
return result;
}
G4PiNuclearCrossSection::
~G4PiNuclearCrossSection()
{
std::for_each(thePimData.begin(), thePimData.end(), G4PiData::Delete());
std::for_each(thePipData.begin(), thePipData.end(), G4PiData::Delete());
}
G4double G4PiNuclearCrossSection::
Interpolate(G4int Z1, G4int Z2, G4int Z, G4double x1, G4double x2)
{
G4double result = 0;
G4double r1 = x1/pow(G4double(Z1), 2./3.)*pow(G4double(Z), 2./3.);
G4double r2 = x2/pow(G4double(Z2), 2./3.)*pow(G4double(Z), 2./3.);
result = (r1+r2)/2.;
return result;
}
G4double G4PiNuclearCrossSection::
GetCrossSection(const G4DynamicParticle* aParticle,
const G4Element* anElement,
G4double )
{
// precondition
G4ping debug("debug_PiNuclearCrossSection");
G4double tuning = 1.;
using namespace std;
G4bool ok = false;
if(aParticle->GetDefinition() == G4PionMinus::PionMinus()) ok=true;
if(aParticle->GetDefinition() == G4PionPlus::PionPlus()) ok=true;
if(!ok)
{
throw G4HadronicException(__FILE__, __LINE__,
"Call to G4PiNuclearCrossSection failed.");
}
G4double charge = aParticle->GetDefinition()->GetPDGCharge();
G4double kineticEnergy = aParticle->GetKineticEnergy();
// body
G4double result = 0;
G4int Z=G4lrint(anElement->GetZ());
debug.push_back(Z);
size_t it=0;
while(it<theZ.size() && Z>theZ[it]) it++;
debug.push_back(theZ[it]);
debug.push_back(kineticEnergy);
if(Z==29) tuning=.96;
if(Z > theZ[it])
{
throw G4HadronicException(__FILE__, __LINE__,
"Called G4PiNuclearCrossSection outside parametrization");
}
G4int Z1, Z2;
G4double x1, x2;
if(charge<0)
{
if(theZ[it]==Z)
{
result = thePimData[it]->ReactionXSection(kineticEnergy);
debug.push_back("D1 ");
debug.push_back(result);
}
else
{
x1 = thePimData[it-1]->ReactionXSection(kineticEnergy);
Z1 = theZ[it-1];
x2 = thePimData[it]->ReactionXSection(kineticEnergy);
Z2 = theZ[it];
result = Interpolate(Z1, Z2, Z, x1, x2);
debug.push_back("D2 ");
debug.push_back(x1);
debug.push_back(x2);
debug.push_back(Z1);
debug.push_back(Z2);
debug.push_back(result);
}
}
else
{
if(theZ[it]==Z)
{
std::vector<G4PiData *> * theData = &thePimData;
if(thePipData[it]->AppliesTo(kineticEnergy))
{
theData = &thePipData;
}
result = theData->operator[](it)->ReactionXSection(kineticEnergy);
debug.push_back("D3 ");
debug.push_back(result);
}
else
{
std::vector<G4PiData *> * theLData = &thePimData;
if(thePipData[it-1]->AppliesTo(kineticEnergy))
{
theLData = &thePipData;
}
std::vector<G4PiData *> * theHData = &thePimData;
if(thePipData[it]->AppliesTo(kineticEnergy))
{
theHData = &thePipData;
}
x1 = theLData->operator[](it-1)->ReactionXSection(kineticEnergy);
Z1 = theZ[it-1];
x2 = theHData->operator[](it)->ReactionXSection(kineticEnergy);
Z2 = theZ[it];
result = Interpolate(Z1, Z2, Z, x1, x2);
debug.push_back("D4 ");
debug.push_back(x1);
debug.push_back(x2);
debug.push_back(Z1);
debug.push_back(Z2);
debug.push_back(result);
}
}
debug.dump();
return tuning*result;
}
G4double G4PiNuclearCrossSection::
Interpolate(G4int Z1, G4int Z2, G4int Z, G4double x1, G4double x2)
{
G4double result = 0;
G4double r1 = x1/std::pow(G4double(Z1), 2./3.)*std::pow(G4double(Z), 2./3.);
G4double r2 = x2/std::pow(G4double(Z2), 2./3.)*std::pow(G4double(Z), 2./3.);
result = (r1+r2)/2.;
return result;
}
@@ -43,24 +43,24 @@
const G4double nuleonRadius=1.36E-15;
const G4double pi=3.14159265;
G4double fac=pi*nuleonRadius*nuleonRadius;
G4double b0=2.247-0.915*(1-pow(a,-0.3333));
G4double fac1=b0*(1-pow(a,-0.3333));
G4double b0=2.247-0.915*(1-std::pow(a,-0.3333));
G4double fac1=b0*(1-std::pow(a,-0.3333));
G4double fac2=1.;
if(nOfNeutrons>1.5) fac2=log((nOfNeutrons));
G4double crossSection = 1E31*fac*fac2*(1+pow(a,0.3333)-fac1);
if(nOfNeutrons>1.5) fac2=std::log((nOfNeutrons));
G4double crossSection = 1E31*fac*fac2*(1+std::pow(a,0.3333)-fac1);
// high energy correction
crossSection = (1-0.15*exp(-kineticEnergy))*crossSection/(1.00-0.0007*a);
crossSection = (1-0.15*std::exp(-kineticEnergy))*crossSection/(1.00-0.0007*a);
// first try on low energies: rise
G4double ff1= 0.70-0.002*a; // slope of the drop at medium energies.
G4double ff2= 1.00+1/a; // start of the slope.
G4double ff3= 0.8+18/a-0.002*a; // stephight
fac=1-(1/(1+exp(-8*ff1*(log10(kineticEnergy)+1.37*ff2))));
fac=1-(1/(1+std::exp(-8*ff1*(std::log10(kineticEnergy)+1.37*ff2))));
crossSection = crossSection*(1+ff3*fac);
// low energy return to zero
ff1=1.-1/a-0.001*a; // slope of the rise
ff2=1.17-2.7/a-0.0014*a; // start of the rise
fac=-8.*ff1*(log10(kineticEnergy)+2.0*ff2);
fac=1/(1+exp(fac));
fac=-8.*ff1*(std::log10(kineticEnergy)+2.0*ff2);
fac=1/(1+std::exp(fac));
crossSection = crossSection*fac;
return crossSection*millibarn;
}
@@ -53,8 +53,8 @@ GetCrossSection(const G4DynamicParticle* aPart,
G4double E_cm = (pTarget.mag()-targetMass-pProjectile.m())/MeV;
// done
G4double r_rms_p = 0.6 * myNuleonRadius * pow(projectileAtomicNumber, 1./3.);
G4double r_rms_t = 0.6 * myNuleonRadius * pow(targetAtomicNumber, 1./3.);
G4double r_rms_p = 0.6 * myNuleonRadius * std::pow(projectileAtomicNumber, 1./3.);
G4double r_rms_t = 0.6 * myNuleonRadius * std::pow(targetAtomicNumber, 1./3.);
// done
G4double r_p = 1.29*r_rms_p/nuleonRadius ;
@@ -62,8 +62,8 @@ GetCrossSection(const G4DynamicParticle* aPart,
// done
G4double Radius = r_p + r_t +
1.2*(pow(targetAtomicNumber, 1./3.) + pow(projectileAtomicNumber, 1./3.))/
pow(E_cm, 1./3.);
1.2*(std::pow(targetAtomicNumber, 1./3.) + std::pow(projectileAtomicNumber, 1./3.))/
std::pow(E_cm, 1./3.);
//done
G4double B = 1.44*nProjProtons*nTargetProtons/Radius;
@@ -86,7 +86,7 @@ GetCrossSection(const G4DynamicParticle* aPart,
else if (nProjProtons==2 && projectileAtomicNumber==4)
{
D = 2.77-(8.0E-3*targetAtomicNumber)+(1.8E-5*targetAtomicNumber*targetAtomicNumber)
- 0.8/(1+exp((250.-Energy)/75.));
- 0.8/(1+std::exp((250.-Energy)/75.));
}
else
{
@@ -99,21 +99,21 @@ GetCrossSection(const G4DynamicParticle* aPart,
D = 1.75;
}
// done
G4double C_E = D * (1-exp(-Energy/40.)) - 0.292*exp(-Energy/792.)*cos(0.229*pow(Energy, 0.453));
G4double C_E = D * (1-std::exp(-Energy/40.)) - 0.292*std::exp(-Energy/792.)*std::cos(0.229*std::pow(Energy, 0.453));
// done
G4double S = pow(projectileAtomicNumber, 1./3.)*pow(targetAtomicNumber, 1./3.)/
(pow(projectileAtomicNumber, 1./3.) + pow(targetAtomicNumber, 1./3.));
G4double S = std::pow(projectileAtomicNumber, 1./3.)*std::pow(targetAtomicNumber, 1./3.)/
(std::pow(projectileAtomicNumber, 1./3.) + std::pow(targetAtomicNumber, 1./3.));
// done
G4double deltaE = 1.85*S + 0.16*S/pow(E_cm,1./3.) - C_E +
G4double deltaE = 1.85*S + 0.16*S/std::pow(E_cm,1./3.) - C_E +
0.91*(targetAtomicNumber-2.*nTargetProtons)*nProjProtons/
(targetAtomicNumber*projectileAtomicNumber);
// done
result = pi * nuleonRadius*nuleonRadius *
pow(( pow(targetAtomicNumber, 1./3.) +
pow(projectileAtomicNumber, 1./3.) + deltaE),2.) * (1-B/E_cm);
std::pow(( std::pow(targetAtomicNumber, 1./3.) +
std::pow(projectileAtomicNumber, 1./3.) + deltaE),2.) * (1-B/E_cm);
if(result < 0) result = 0;
return result*m2;
@@ -155,8 +155,8 @@ G4double G4TripathiLightCrossSection::GetCrossSection
G4double r_p = 1.29*r_rms_p;
G4double r_t = 1.29*r_rms_t;
G4double Radius = (r_p + r_t)/fermi + 1.2*(pow(AT, third) + pow(AP, third))/
pow(E_cm, third);
G4double Radius = (r_p + r_t)/fermi + 1.2*(std::pow(AT, third) + std::pow(AP, third))/
std::pow(E_cm, third);
G4double B = 1.44 * ZP * ZT / Radius;
//
@@ -171,17 +171,17 @@ G4double G4TripathiLightCrossSection::GetCrossSection
if ((AT==1 && ZT==1) || (AP==1 && ZP==1))
{
T1 = 23.0;
D = 1.85 + 0.16/(1+exp((500.0-E)/200.0));
D = 1.85 + 0.16/(1+std::exp((500.0-E)/200.0));
}
else if ((AT==1 && ZT==0) || (AP==1 && ZP==0))
{
T1 = 18.0;
D = 1.85 + 0.16/(1+exp((500.0-E)/200.0));
D = 1.85 + 0.16/(1+std::exp((500.0-E)/200.0));
}
else if ((AT==2 && ZT==1) || (AP==2 && ZP==1))
{
T1 = 23.0;
D = 1.65 + 0.1/(1+exp((500.0-E)/200.0));
D = 1.65 + 0.1/(1+std::exp((500.0-E)/200.0));
}
else if ((AT==3 && ZT==2) || (AP==3 && ZP==2))
{
@@ -196,7 +196,7 @@ G4double G4TripathiLightCrossSection::GetCrossSection
else if (ZT==13) {T1 = 25.0; G = 300.0;}
else if (ZT==26) {T1 = 40.0; G = 300.0;}
else {T1 = 40.0; G = 75.0;}
D = 2.77 - 8.0E-3*AT + 1.8E-5*AT*AT-0.8/(1.0+exp((250.0-E)/G));
D = 2.77 - 8.0E-3*AT + 1.8E-5*AT*AT-0.8/(1.0+std::exp((250.0-E)/G));
}
else if (AT==4 && ZT==2)
{
@@ -206,32 +206,32 @@ G4double G4TripathiLightCrossSection::GetCrossSection
else if (ZP==13) {T1 = 25.0; G = 300.0;}
else if (ZP==26) {T1 = 40.0; G = 300.0;}
else {T1 = 40.0; G = 75.0;}
D = 2.77 - 8.0E-3*AP + 1.8E-5*AP*AP-0.8/(1.0+exp((250.0-E)/G));
D = 2.77 - 8.0E-3*AP + 1.8E-5*AP*AP-0.8/(1.0+std::exp((250.0-E)/G));
}
//
//
// C_E, S, deltaE, X1, S_L and X_m correspond directly with the original
// formulae of Tripathi et al in his report.
//
G4double C_E = D*(1.0-exp(-E/T1)) -
0.292*exp(-E/792.0)*cos(0.229*pow(E,0.453));
G4double C_E = D*(1.0-std::exp(-E/T1)) -
0.292*std::exp(-E/792.0)*std::cos(0.229*std::pow(E,0.453));
G4double S = pow(AP,third)*pow(AT,third)/(pow(AP,third) + pow(AT,third));
G4double S = std::pow(AP,third)*std::pow(AT,third)/(std::pow(AP,third) + std::pow(AT,third));
G4double deltaE = 0.0;
G4double X1 = 0.0;
if (AT >= AP)
{
deltaE = 1.85*S + 0.16*S/pow(E_cm,third) - C_E + 0.91*(AT-2.0*ZT)*ZP/AT/AP;
deltaE = 1.85*S + 0.16*S/std::pow(E_cm,third) - C_E + 0.91*(AT-2.0*ZT)*ZP/AT/AP;
X1 = 2.83 - 3.1E-2*AT + 1.7E-4*AT*AT;
}
else
{
deltaE = 1.85*S + 0.16*S/pow(E_cm,third) - C_E + 0.91*(AP-2.0*ZP)*ZT/AT/AP;
deltaE = 1.85*S + 0.16*S/std::pow(E_cm,third) - C_E + 0.91*(AP-2.0*ZP)*ZT/AT/AP;
X1 = 2.83 - 3.1E-2*AP + 1.7E-4*AP*AP;
}
G4double S_L = 1.2 + 1.6*(1.0-exp(-E/15.0));
G4double X_m = 1.0 - X1*exp(-E/X1*S_L);
G4double S_L = 1.2 + 1.6*(1.0-std::exp(-E/15.0));
G4double X_m = 1.0 - X1*std::exp(-E/X1*S_L);
//
//
// R_c is also highly dependent upon the A and Z of the projectile and
@@ -275,7 +275,7 @@ G4double G4TripathiLightCrossSection::GetCrossSection
// set to zero.
//
result = pi * r_0*r_0 *
pow((pow(AT,third) + pow(AP,third) + deltaE),2.0) *
std::pow((std::pow(AT,third) + std::pow(AP,third) + deltaE),2.0) *
(1.0 - R_c*B/E_cm) * X_m;
if (!lowEnergyCheck)
{