72 LEN =
new std::vector<G4double*>;
73 HEN =
new std::vector<G4double*>;
78 std::size_t lens=LEN->size();
79 for(std::size_t i=0; i<lens; ++i)
delete[] (*LEN)[i];
81 std::size_t hens=HEN->size();
82 for(std::size_t i=0; i<hens; ++i)
delete[] (*HEN)[i];
88 outFile <<
"G4ChipsAntiBaryonInelasticXS provides the inelastic cross\n"
89 <<
"section for anti-baryon nucleus scattering as a function of incident\n"
90 <<
"momentum. The cross section is calculated using M. Kossov's\n"
91 <<
"CHIPS parameterization of cross section data.\n";
160 if(tgN!=lastN || tgZ!=lastZ)
166 lastI = (
G4int)colN.size();
168 if(lastI)
for(
G4int i=0; i<lastI; i++)
170 if(colN[i]==tgN && colZ[i]==tgZ)
182 lastCS=CalculateCrossSection(-1,j,cPDG,lastZ,lastN,pMom);
183 if(lastCS<=0. && pMom>lastTH)
195 lastCS=CalculateCrossSection(0,j,cPDG,lastZ,lastN,pMom);
202 colP.push_back(pMom);
203 colTH.push_back(lastTH);
204 colCS.push_back(lastCS);
206 return lastCS*millibarn;
214 else if(pMom<=lastTH)
220 lastCS=CalculateCrossSection(1,j,cPDG,lastZ,lastN,pMom);
223 return lastCS*millibarn;
231 static const G4double THmiG=THmin*.001;
234 static const G4int nL=105;
235 static const G4double Pmin=THmin+(nL-1)*dP;
237 static const G4int nH=224;
240 static const G4double dlP=(malP-milP)/(nH-1);
250 if(sync<=I)
G4cerr<<
"*!*G4QPiMinusNuclCS::CalcCrosSect:Sync="<<sync<<
"<="<<I<<
G4endl;
260 for(
G4int k=0; k<nL; k++)
262 lastLEN[k] = CrossSectionLin(targZ, targN, P);
268 lastHEN[
n] = CrossSectionLog(targZ, targN, lP);
276 G4cerr<<
"***G4QPiMinusNuclCS::CalcCrossSect: Sinc="<<sync<<
"#"<<
I<<
", Z=" <<targZ
277 <<
", N="<<targN<<
", F="<<F<<
G4endl;
280 LEN->push_back(lastLEN);
281 HEN->push_back(lastHEN);
285 if (Momentum<lastTH)
return 0.;
286 else if (Momentum<Pmin)
288 sigma=EquLinearFit(Momentum,nL,THmin,dP,lastLEN);
290 else if (Momentum<Pmax)
293 sigma=EquLinearFit(lP,nH,milP,dlP,lastHEN);
298 sigma=CrossSectionFormula(targZ, targN, P,
G4Log(P));
300 if(sigma<0.)
return 0.;
308 return CrossSectionFormula(tZ, tN, P, lP);
315 return CrossSectionFormula(tZ, tN, P, lP);
330 sigma=(To-El)+.2443*ld2+31.48;
332 else if(tZ==1 && tN==1)
335 sigma=0.6*r*r+67.+90.*
G4Exp(-lP*.666);
337 else if(tZ<97 && tN<152)
347 G4double r=(170.+0.01*a3)/(1.+a3/28000.);
352 G4cerr<<
"-Warning-G4QAntiBarNuclearCroSect::CSForm:*Bad A* Z="<<tZ<<
", N="<<tN<<
G4endl;
355 if(sigma<0.)
return 0.;
363 G4cerr<<
"***G4ChipsAntiBaryonInelasticXS::EquLinearFit: DX="<<DX<<
", N="<<
N<<
G4endl;
369 G4int jj=
static_cast<int>(d);
371 else if(jj>N2) jj=N2;
#define G4_DECLARE_XS_FACTORY(cross_section)
G4double Y(G4double density)
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
G4double G4Log(G4double x)
G4GLOB_DLL std::ostream G4cerr
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)
virtual void CrossSectionDescription(std::ostream &) const
~G4ChipsAntiBaryonInelasticXS()
G4ChipsAntiBaryonInelasticXS()
G4ParticleDefinition * GetDefinition() const
G4double GetTotalMomentum() const
G4int GetPDGEncoding() const
static G4Pow * GetInstance()
G4double powA(G4double A, G4double y) const