Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4Evaporation Class Reference

#include <G4Evaporation.hh>

+ Inheritance diagram for G4Evaporation:

Public Member Functions

 G4Evaporation ()
 
 G4Evaporation (G4VEvaporationChannel *photoEvaporation)
 
virtual ~G4Evaporation ()
 
virtual void Initialise ()
 
G4FragmentVectorBreakItUp (const G4Fragment &theNucleus)
 
void SetDefaultChannel ()
 
void SetGEMChannel ()
 
void SetCombinedChannel ()
 
virtual void SetPhotonEvaporation (G4VEvaporationChannel *ptr)
 
- Public Member Functions inherited from G4VEvaporation
 G4VEvaporation ()
 
virtual ~G4VEvaporation ()
 
virtual G4FragmentVectorBreakItUp (const G4Fragment &theNucleus)=0
 
virtual void Initialise ()
 
virtual void SetPhotonEvaporation (G4VEvaporationChannel *ptr)
 
G4VEvaporationChannelGetPhotonEvaporation ()
 
void SetOPTxs (G4int opt)
 
void UseSICB (G4bool use)
 

Additional Inherited Members

- Protected Attributes inherited from G4VEvaporation
G4VEvaporationChannelthePhotonEvaporation
 
G4int OPTxs
 
G4bool useSICB
 

Detailed Description

Definition at line 53 of file G4Evaporation.hh.

Constructor & Destructor Documentation

◆ G4Evaporation() [1/2]

G4Evaporation::G4Evaporation ( )

Definition at line 59 of file G4Evaporation.cc.

60 : theChannels(0),nChannels(0)
61{
64 SetParameters();
65 InitialiseEvaporation();
66}
virtual void SetPhotonEvaporation(G4VEvaporationChannel *ptr)
G4VEvaporationChannel * thePhotonEvaporation

◆ G4Evaporation() [2/2]

G4Evaporation::G4Evaporation ( G4VEvaporationChannel photoEvaporation)

Definition at line 68 of file G4Evaporation.cc.

69 : theChannels(0),nChannels(0)
70{
71 if(photoEvaporation) { SetPhotonEvaporation(photoEvaporation); }
73
75 SetParameters();
76 InitialiseEvaporation();
77}

◆ ~G4Evaporation()

G4Evaporation::~G4Evaporation ( )
virtual

Definition at line 99 of file G4Evaporation.cc.

100{
101 CleanChannels();
103 delete theChannelFactory;
104}

Member Function Documentation

◆ BreakItUp()

G4FragmentVector * G4Evaporation::BreakItUp ( const G4Fragment theNucleus)
virtual

Implements G4VEvaporation.

Definition at line 165 of file G4Evaporation.cc.

166{
167 G4FragmentVector * theResult = new G4FragmentVector;
168 G4FragmentVector * theTempResult;
169 const G4double Elimit = 3*MeV;
170
171 // The residual nucleus (after evaporation of each fragment)
172 G4Fragment* theResidualNucleus = new G4Fragment(theNucleus);
173
174 G4double totprob, prob, oldprob = 0.0;
175 size_t maxchannel, i;
176
177 G4int Amax = theResidualNucleus->GetA_asInt();
178
179 // Starts loop over evaporated particles, loop is limited by number
180 // of nucleons
181 for(G4int ia=0; ia<Amax; ++ia) {
182
183 // g,n,p and light fragments - evaporation is finished
184 G4int Z = theResidualNucleus->GetZ_asInt();
185 G4int A = theResidualNucleus->GetA_asInt();
186
187 // stop deecitation loop if can be deexcited by FBU
188 if(maxZforFBU > Z && maxAforFBU >= A) {
189 theResult->push_back(theResidualNucleus);
190 return theResult;
191 }
192
193 // check if it is stable, then finish evaporation
194 G4double abun = nist->GetIsotopeAbundance(Z, A);
195 /*
196 G4cout << "### G4Evaporation::BreakItUp step " << ia << " Z= " << Z
197 << " A= " << A << " Eex(MeV)= "
198 << theResidualNucleus->GetExcitationEnergy()
199 << " aban= " << abun << G4endl;
200 */
201 // stop deecitation loop in the case of the cold stable fragment
202 G4double Eex = theResidualNucleus->GetExcitationEnergy();
203 if(Eex <= minExcitation && abun > 0.0) {
204 theResult->push_back(theResidualNucleus);
205 return theResult;
206 }
207
208 totprob = 0.0;
209 maxchannel = nChannels;
210 /*
211 G4cout << "### Evaporation loop #" << ia
212 << " Fragment: " << theResidualNucleus << G4endl;
213 */
214 // loop over evaporation channels
215 for(i=0; i<nChannels; ++i) {
216 prob = (*theChannels)[i]->GetEmissionProbability(theResidualNucleus);
217 //G4cout << " Channel# " << i << " prob= " << prob << G4endl;
218
219 totprob += prob;
220 probabilities[i] = totprob;
221 // if two recent probabilities are near zero stop computations
222 if(i>=8) {
223 if(prob <= totprob*1.e-8 && oldprob <= totprob*1.e-8) {
224 maxchannel = i+1;
225 break;
226 }
227 }
228 oldprob = prob;
229 // protection for very excited fragment - avoid GEM
230 if(7 == i && Eex > Elimit*A) {
231 maxchannel = 8;
232 break;
233 }
234 }
235
236 // photon evaporation in the case of no other channels available
237 // do evaporation chain and reset total probability
238 if(0.0 < totprob && probabilities[0] == totprob) {
239 //G4cout << "Start gamma evaporation" << G4endl;
240 theTempResult = (*theChannels)[0]->BreakUpFragment(theResidualNucleus);
241 if(theTempResult) {
242 size_t nsec = theTempResult->size();
243 for(size_t j=0; j<nsec; ++j) {
244 theResult->push_back((*theTempResult)[j]);
245 }
246 delete theTempResult;
247 }
248 totprob = 0.0;
249 }
250
251 // stable fragnent - evaporation is finished
252 if(0.0 == totprob) {
253
254 // if fragment is exotic, then try to decay it
255 if(0.0 == abun && Z < 20) {
256 //G4cout << "$$$ Decay exotic fragment" << G4endl;
257 theTempResult = unstableBreakUp.BreakUpFragment(theResidualNucleus);
258 if(theTempResult) {
259 size_t nsec = theTempResult->size();
260 for(size_t j=0; j<nsec; ++j) {
261 theResult->push_back((*theTempResult)[j]);
262 }
263 delete theTempResult;
264 }
265 }
266
267 // save residual fragment
268 theResult->push_back(theResidualNucleus);
269 return theResult;
270 }
271
272
273 // select channel
274 totprob *= G4UniformRand();
275 // loop over evaporation channels
276 for(i=0; i<maxchannel; ++i) { if(probabilities[i] >= totprob) { break; } }
277
278 // this should not happen
279 if(i >= nChannels) { i = nChannels - 1; }
280
281
282 // single photon evaporation, primary pointer is kept
283 if(0 == i) {
284 //G4cout << "Single gamma" << G4endl;
285 G4Fragment* gamma = (*theChannels)[0]->EmittedFragment(theResidualNucleus);
286 if(gamma) { theResult->push_back(gamma); }
287
288 // fission, return results to the main loop if fission is succesful
289 } else if(1 == i) {
290 //G4cout << "Fission" << G4endl;
291 theTempResult = (*theChannels)[1]->BreakUp(*theResidualNucleus);
292 if(theTempResult) {
293 size_t nsec = theTempResult->size();
294 G4bool deletePrimary = true;
295 for(size_t j=0; j<nsec; ++j) {
296 if(theResidualNucleus == (*theTempResult)[j]) { deletePrimary = false; }
297 theResult->push_back((*theTempResult)[j]);
298 }
299 if(deletePrimary) { delete theResidualNucleus; }
300 delete theTempResult;
301 return theResult;
302 }
303
304 // other channels
305 } else {
306 //G4cout << "Channel # " << i << G4endl;
307 theTempResult = (*theChannels)[i]->BreakUp(*theResidualNucleus);
308 if(theTempResult) {
309 size_t nsec = theTempResult->size();
310 if(nsec > 0) {
311 --nsec;
312 for(size_t j=0; j<nsec; ++j) {
313 theResult->push_back((*theTempResult)[j]);
314 }
315 // if the residual change its pointer
316 // then delete previous residual fragment and update to the new
317 if(theResidualNucleus != (*theTempResult)[nsec] ) {
318 delete theResidualNucleus;
319 theResidualNucleus = (*theTempResult)[nsec];
320 }
321 }
322 delete theTempResult;
323 }
324 }
325 }
326
327 // loop is stopped, save residual
328 theResult->push_back(theResidualNucleus);
329
330 return theResult;
331}
std::vector< G4Fragment * > G4FragmentVector
Definition: G4Fragment.hh:65
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66
bool G4bool
Definition: G4Types.hh:67
#define G4UniformRand()
Definition: Randomize.hh:53
G4double GetExcitationEnergy() const
Definition: G4Fragment.hh:235
G4int GetZ_asInt() const
Definition: G4Fragment.hh:223
G4int GetA_asInt() const
Definition: G4Fragment.hh:218
G4double GetIsotopeAbundance(G4int Z, G4int N) const
virtual G4FragmentVector * BreakUpFragment(G4Fragment *fragment)

◆ Initialise()

void G4Evaporation::Initialise ( )
virtual

Reimplemented from G4VEvaporation.

Definition at line 130 of file G4Evaporation.cc.

131{
132 for(size_t i=0; i<nChannels; ++i) {
133 (*theChannels)[i]->SetOPTxs(OPTxs);
134 (*theChannels)[i]->UseSICB(useSICB);
135 }
136}

◆ SetCombinedChannel()

void G4Evaporation::SetCombinedChannel ( )

Definition at line 152 of file G4Evaporation.cc.

153{
154 delete theChannelFactory;
156 InitialiseEvaporation();
157}

◆ SetDefaultChannel()

void G4Evaporation::SetDefaultChannel ( )

Definition at line 138 of file G4Evaporation.cc.

139{
140 delete theChannelFactory;
141 theChannelFactory = new G4EvaporationFactory(thePhotonEvaporation);
142 InitialiseEvaporation();
143}

◆ SetGEMChannel()

void G4Evaporation::SetGEMChannel ( )

Definition at line 145 of file G4Evaporation.cc.

146{
147 delete theChannelFactory;
148 theChannelFactory = new G4EvaporationGEMFactory(thePhotonEvaporation);
149 InitialiseEvaporation();
150}

◆ SetPhotonEvaporation()

void G4Evaporation::SetPhotonEvaporation ( G4VEvaporationChannel ptr)
virtual

Reimplemented from G4VEvaporation.

Definition at line 159 of file G4Evaporation.cc.

160{
162 if(0 < nChannels) { (*theChannels)[0] = ptr; }
163}
virtual void SetPhotonEvaporation(G4VEvaporationChannel *ptr)

Referenced by G4Evaporation().


The documentation for this class was generated from the following files: