66 LEN =
new std::vector<G4double*>;
67 HEN =
new std::vector<G4double*>;
108 static std::vector <G4int> colN;
109 static std::vector <G4int> colZ;
110 static std::vector <G4double> colP;
111 static std::vector <G4double> colTH;
112 static std::vector <G4double> colCS;
116 if(tgN!=lastN || tgZ!=lastZ)
124 if(lastI)
for(
G4int i=0; i<lastI; i++)
126 if(colN[i]==tgN && colZ[i]==tgZ)
138 lastCS=CalculateCrossSection(-1,j,2212,lastZ,lastN,pMom);
139 if(lastCS<=0. && pMom>lastTH)
151 lastCS=CalculateCrossSection(0,j,2212,lastZ,lastN,pMom);
158 colP.push_back(pMom);
159 colTH.push_back(lastTH);
160 colCS.push_back(lastCS);
162 return lastCS*millibarn;
170 else if(pMom<=lastTH)
176 lastCS=CalculateCrossSection(1,j,2212,lastZ,lastN,pMom);
179 return lastCS*millibarn;
187 static const G4double THmiG=THmin*.001;
190 static const G4int nL=105;
191 static const G4double Pmin=THmin+(nL-1)*dP;
193 static const G4int nH=224;
194 static const G4double milP=std::log(Pmin);
195 static const G4double malP=std::log(Pmax);
196 static const G4double dlP=(malP-milP)/(nH-1);
197 static const G4double milPG=std::log(.001*Pmin);
205 G4int sync=LEN->size();
206 if(sync<=I)
G4cout<<
"*!*G4QProtonNuclCS::CalcCrossSect:Sync="<<sync<<
"<="<<I<<
G4endl;
216 for(
G4int k=0; k<nL; k++)
218 lastLEN[k] = CrossSectionLin(targZ, targN, P);
224 lastHEN[
n] = CrossSectionLog(targZ, targN, lP);
229 G4int sync=LEN->size();
232 G4cout<<
"***G4ChipsProtonNuclCS::CalcCrossSect: Sinc="<<sync<<
"#"<<I<<
", Z=" <<targZ
233 <<
", N="<<targN<<
", F="<<F<<
G4endl;
236 LEN->push_back(lastLEN);
237 HEN->push_back(lastHEN);
241 if (Momentum<lastTH)
return 0.;
242 else if (Momentum<Pmin)
244 sigma=EquLinearFit(Momentum,nL,THmin,dP,lastLEN);
246 else if (Momentum<Pmax)
249 sigma=EquLinearFit(lP,nH,milP,dlP,lastHEN);
254 sigma=CrossSectionFormula(targZ, targN, P, std::log(P));
256 if(sigma<0.)
return 0.;
268 if(tZ<.99 || tN<0.)
return 0.;
269 else if(tZ==1 && tN==0)
return 800.;
271 G4double dE=tZ/(1.+std::pow(tA,third));
274 return std::sqrt(T*(tpM+T));
281 if(P<ThresholdMomentum(tZ,tN)*.001)
return sigma;
283 if(tZ==1&&!tN){
if(P>.35) sigma=CrossSectionFormula(tZ,tN,P,lP);}
284 else if(tZ<97 && tN<152)
303 else if(tZ==5 && tN==6)
309 else if(tZ==4 && tN==5)
315 else if(tZ==3 && tN==4)
321 else if(tZ==3 && tN==3)
327 else if(tZ==2 && tN==1)
334 sigma=CrossSectionFormula(tZ,tN,P,lP);
338 sigma+=pex*std::exp(-dp*dp/wid);
343 G4cerr<<
"-Warning-G4ChipsProtonNuclearXS::CSLin:*Bad A* Z="<<tZ<<
", N="<<tN<<
G4endl;
346 if(sigma<0.)
return 0.;
354 return CrossSectionFormula(tZ, tN, P, lP);
367 G4double El=(.0557*lp2+6.72+30./P)/(1.+.49*rp2/P);
368 G4double To=(.3*lp2+38.2)/(1.+.54*rp2*rp2);
371 else if(tZ<97 && tN<152)
386 G4double c=(170.+3600./a2s)/(1.+65./a2s);
390 G4double gg=40.*std::exp(al*0.712)/(1.+12.2/a)/(1.+34./a2);
391 G4double e=318.+a4/(1.+.0015*a4/std::exp(al*0.09))/(1.+4.e-28*a12)+
392 8.e-18/(1./a16+1.3e-20)/(1.+1.e-21*a12);
393 G4double ss=3.57+.009*a2/(1.+.0001*a2*a);
394 G4double h=(.01/a4+2.5e-6/a)*(1.+6.e-6*a2*a)/(1.+6.e7/a12/a2);
395 sigma=(c+d*d)/(1.+r/p4)+(gg+e*std::exp(-ss*P))/(1.+h/p4/p4);
399 G4cerr<<
"-Warning-G4QProtonNuclearCroSect::CSForm:*Bad A* Z="<<tZ<<
", N="<<tN<<
G4endl;
402 if(sigma<0.)
return 0.;
410 G4cerr<<
"***G4ChipsProtonInelasticXS::EquLinearFit: DX="<<DX<<
", N="<<N<<
G4endl;
416 G4int j=
static_cast<int>(d);
#define G4_DECLARE_XS_FACTORY(cross_section)
G4DLLIMPORT std::ostream G4cerr
G4DLLIMPORT std::ostream G4cout
~G4ChipsProtonInelasticXS()
G4ChipsProtonInelasticXS()
virtual G4double GetIsoCrossSection(const G4DynamicParticle *, G4int tgZ, G4int A, const G4Isotope *iso=0, const G4Element *elm=0, const G4Material *mat=0)
virtual G4bool IsIsoApplicable(const G4DynamicParticle *Pt, G4int Z, G4int A, const G4Element *elm, const G4Material *mat)
virtual G4double GetChipsCrossSection(G4double momentum, G4int Z, G4int N, G4int pdg)
G4ParticleDefinition * GetDefinition() const
G4double GetTotalMomentum() const
G4double GetPDGMass() const
static G4Proton * Definition()
static G4Proton * Proton()