81 if(!rpCorrelationTableCache)
82 rpCorrelationTableCache =
new std::map<G4int,InterpolationTable*>;
85 const std::map<G4int,InterpolationTable*>::const_iterator mapEntry = rpCorrelationTableCache->find(nuclideID);
86 if(mapEntry == rpCorrelationTableCache->end()) {
88 INCL_DEBUG(
"Creating r-p correlation function for " << ((t==
Proton) ?
"protons" :
"neutrons") <<
" in A=" << A <<
", Z=" <<
Z << std::endl);
90 IFunction1D *rpCorrelationFunction;
95 rpCorrelationFunction =
new NuclearDensityFunctions::WoodsSaxonRP(radius, maximumRadius, diffuseness);
96 INCL_DEBUG(
" ... Woods-Saxon; R0=" << radius <<
", a=" << diffuseness <<
", Rmax=" << maximumRadius << std::endl);
97 }
else if(A <= 19 && A > 6) {
101 rpCorrelationFunction =
new NuclearDensityFunctions::ModifiedHarmonicOscillatorRP(radius, maximumRadius, diffuseness);
102 INCL_DEBUG(
" ... MHO; param1=" << radius <<
", param2=" << diffuseness <<
", Rmax=" << maximumRadius << std::endl);
103 }
else if(A <= 6 && A > 1) {
106 rpCorrelationFunction =
new NuclearDensityFunctions::GaussianRP(maximumRadius,
Math::oneOverSqrtThree * radius);
107 INCL_DEBUG(
" ... Gaussian; sigma=" << radius <<
", Rmax=" << maximumRadius << std::endl);
109 INCL_ERROR(
"No r-p correlation function for " << ((t==
Proton) ?
"protons" :
"neutrons") <<
" in A = "
110 << A <<
" Z = " <<
Z <<
'\n');
114 InterpolationTable *theTable = rpCorrelationFunction->inverseCDFTable(
Math::pow13);
115 delete rpCorrelationFunction;
116 INCL_DEBUG(
" ... here comes the table:\n" << theTable->print() <<
'\n');
118 (*rpCorrelationTableCache)[nuclideID] = theTable;
121 return mapEntry->second;
double A(double temperature)
const G4double oneOverSqrtThree
G4double getSurfaceDiffuseness(const ParticleType t, const G4int A, const G4int Z)
G4double getRadiusParameter(const ParticleType t, const G4int A, const G4int Z)
G4double getMaximumNuclearRadius(const ParticleType t, const G4int A, const G4int Z)
G4double pow13(G4double x)