40 : OPTxs(3),pVerbose(1),theZ(Z),theA(
A),resZ(0),resA(0),
41 pMass(0.0),pEvapMass(0.0),pResMass(0.0),fExc(0.0),fExcRes(0.0),
42 elimit(
CLHEP::MeV),accuracy(0.02),fFD(false)
66 if(nbins > 0) { length = nbins; }
67 if(de > 0.0) { elimit = de; }
68 if(eps > 0.0) { accuracy = eps; }
93 nbin = (size_t)((emax - emin)/edelta) + 1;
94 const G4double edeltamin = 0.2*CLHEP::MeV;
95 const G4double edeltamax = 2*CLHEP::MeV;
98 edelta = (emax - emin)/(
G4double)nbin;
99 }
else if(nbin > length) {
108 G4cout <<
"### G4VEmissionProbability::IntegrateProbability: "
109 <<
" Emax= " << emax <<
" QB= " << cb <<
" nbin= " << nbin
111 G4cout <<
" 0. E= " << emin <<
" prob= " << probmax <<
G4endl;
113 for(
size_t i=1; i<=nbin; ++i) {
116 edelta += (emax - x);
119 G4bool endpoint = (std::abs(x - emax) < edelmicro) ?
true :
false;
120 G4double xx = endpoint ? x - edelmicro : x;
123 G4cout <<
" " << i <<
". E= " << x <<
" prob= " << y
124 <<
" Edel= " << edelta <<
G4endl;
126 probmax = std::max(probmax, y);
127 del = (y + problast)*edelta*0.5;
135 0.7*edelta > edeltamin) {
137 }
else if(del < 0.1*
pProbability && 1.5*edelta < edeltamax) {
155 G4cout <<
"### G4VEmissionProbability::SampleEnergy: "
156 <<
" Emin= " << emin <<
" Emax= " << emax
157 <<
" probmax= " << probmax <<
G4endl;
161 const G4int nmax = 100;
166 ekin = del*rndm->
flat() + emin;
171 <<
". prob= " << g <<
" probmax= " << probmax
172 <<
" Ekin= " << ekin <<
G4endl;
174 if((g > probmax || n > nmax) &&
pVerbose > 1) {
175 G4cout <<
"### G4VEmissionProbability::SampleEnergy for Z= " <<
theZ
177 <<
"\n Warning n= " << n
178 <<
" prob/probmax= " << g/probmax
179 <<
" prob= " << g <<
" probmax= " << probmax
180 <<
"\n Ekin= " << ekin <<
" Emin= " << emin
181 <<
" Emax= " << emax <<
G4endl;
183 }
while(probmax*rndm->
flat() > g && n < nmax);
184 return (fFD) ? FindRecoilExcitation(ekin) : ekin;
200 const G4double tolerance = 0.1*CLHEP::keV;
203 G4cout <<
"### G4VEmissionProbability::FindRecoilExcitation for resZ= "
205 <<
" evaporated Z= " <<
theZ <<
" A= " <<
theA
206 <<
" Ekin= " << e <<
" Eexc= " << fExcRes <<
G4endl;
210 if(fExcRes < tolerance) {
213 return std::max(0.5*(m02 + m12 - m22)/
pMass - mass,0.0);
217 if(!lManager) {
return e; }
221 if(fExcRes > lManager->MaxLevelEnergy() + tolerance) {
return e; }
227 for(; idx > 0; --idx) {
228 fExcRes = lManager->LevelEnergy(idx);
230 if(
pMass > mass +
pResMass + fExcRes && lManager->FloatingLevel(idx) == 0) {
235 return std::max(0.5*(m02 + m12 - mr2)/
pMass - mass,0.0);
241 return std::max(0.5*(m02 + m12 - m22)/
pMass - mass,0.0);
double A(double temperature)
G4GLOB_DLL std::ostream G4cout
G4bool GetDiscreteExcitationFlag() const
G4int GetDeexModelType() const
size_t NearestLevelIndex(G4double energy, 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)
virtual ~G4VEmissionProbability()
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