42 : OPTxs(3), pVerbose(1), theZ(
Z), theA(
A), elimit(
CLHEP::MeV)
60 if(de > 0.0) { elimit = de; }
61 if(eps > 0.0) { accuracy = eps; }
85 const G4double edeltamin = 0.2*CLHEP::MeV;
86 const G4double edeltamax = 2*CLHEP::MeV;
87 G4double edelta = std::max(std::min(elimit, edeltamax), edeltamin);
88 G4double xbin = (emax - emin)/edelta + 1.0;
90 if(ibin < 4) ibin = 4;
94 edelta = (emax - emin)/ibin;
101 G4cout <<
"### G4VEmissionProbability::IntegrateProbability: "
102 <<
"probmax=" << probmax <<
" Emin=" << emin
103 <<
" Emax=" << emax <<
" QB=" << cb <<
" nbin=" << nbin
106 fE1 = fE2 = fP2 = 0.0;
109 for(
G4int i=0; i<nbin; ++i) {
117 G4cout <<
" " << i <<
". E= " << x <<
" prob= " << y
118 <<
" Edel= " << edelta <<
G4endl;
122 }
else if(0.0 == fE1 && 2*y < probmax) {
126 G4double del = (y + problast)*edelta*0.5;
134 0.7*edelta > edeltamin) {
136 }
else if(del < 0.1*
pProbability && 1.5*edelta < edeltamax) {
140 if(fE1 > emin && fE1 < emax) {
141 fE2 = std::max(0.5*(fE1 + emax), emax - edelta);
147 << probmax <<
" emin=" << emin <<
" emax=" << emax
148 <<
" E1=" << fE1 <<
" E2=" << fE2 <<
G4endl;
167 if(fE1 > 0.0 && fP2 > 0.0 && fP2 < 0.5*probmax) {
168 a0 =
G4Log(probmax/fP2)/(fE2 - fE1);
173 a1 = (x > alim) ? 1.0 -
G4Exp(-x) : x*(1.0 - 0.5*x);
181 G4cout <<
"### G4VEmissionProbability::SampleEnergy: "
182 <<
" Emin= " << emin <<
" Emax= " << emax
183 <<
"/n E1=" << fE1 <<
" p1=" << p1
184 <<
" probmax=" << probmax <<
" P2=" << fP2 <<
G4endl;
188 const G4int nmax = 1000;
196 ekin = del*q/p1 + emin;
198 ekin = fE1 -
G4Log(1.0 - (q - p1)*a1/p2)/
a0;
202 gmax = probmax*((x > alim) ?
G4Exp(-x) : 1.0 - x*(1.0 - 0.5*x));
208 <<
". prob= " << g <<
" probmax= " << probmax
209 <<
" Ekin= " << ekin <<
G4endl;
211 if((g > gmax || n > nmax) &&
pVerbose > 1) {
212 G4cout <<
"### G4VEmissionProbability::SampleEnergy for Z= " <<
theZ
213 <<
" A= " <<
theA <<
" Eex(MeV)=" << fExc <<
" p1=" << p1
214 <<
"\n Warning n= " << n
215 <<
" prob/gmax=" << g/gmax
216 <<
" prob=" << g <<
" gmax=" << gmax <<
" probmax=" << probmax
217 <<
"\n Ekin= " << ekin <<
" Emin= " << emin
218 <<
" Emax= " << emax <<
G4endl;
220 }
while(gmax*rndm->
flat() > g && n < nmax);
221 G4double enew = FindRecoilExcitation(ekin);
223 G4cout <<
"### SampleEnergy: Efinal= "
224 << enew <<
" E=" << ekin <<
" Eexc=" << fExcRes <<
G4endl;
241 G4cout <<
"### FindRecoilExcitation for resZ= "
243 <<
" evaporated Z= " <<
theZ <<
" A= " <<
theA
244 <<
" Ekin= " << e <<
" Eexc= " << fExcRes <<
G4endl;
250 return std::max(0.5*(m02 + m12 - m22)/
pMass - mass, 0.0);
252 if(!fFD) {
return e; }
256 if(
nullptr == lManager) {
return e; }
259 if(fExcRes > lManager->MaxLevelEnergy() +
pTolerance) {
return e; }
270 return std::max(0.5*(m02 + m12 - mr2)/
pMass - mass, 0.0);
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
G4double G4Log(G4double x)
G4GLOB_DLL std::ostream G4cout
G4bool GetDiscreteExcitationFlag() const
G4int GetDeexModelType() const
G4double GetMinExcitation() const
G4double NearestLevelEnergy(const G4double energy, const std::size_t index=0) const
G4DeexPrecoParameters * GetParameters()
const G4LevelManager * GetLevelManager(G4int Z, G4int A)
static G4NuclearLevelData * GetInstance()
static G4double GetNuclearMass(const G4double A, const G4double Z)
static G4Pow * GetInstance()
G4VEmissionProbability(G4int Z, G4int A)
void ResetIntegrator(size_t nbin, G4double de, G4double eps)
G4double IntegrateProbability(G4double elow, G4double ehigh, G4double CB)
virtual G4double ComputeProbability(G4double anEnergy, G4double CB)
virtual G4double EmissionProbability(const G4Fragment &fragment, G4double anEnergy)
G4NuclearLevelData * pNuclearLevelData