Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4INCLNucleus.hh
Go to the documentation of this file.
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26// INCL++ intra-nuclear cascade model
27// Alain Boudard, CEA-Saclay, France
28// Joseph Cugnon, University of Liege, Belgium
29// Jean-Christophe David, CEA-Saclay, France
30// Pekka Kaitaniemi, CEA-Saclay, France, and Helsinki Institute of Physics, Finland
31// Sylvie Leray, CEA-Saclay, France
32// Davide Mancusi, CEA-Saclay, France
33//
34#define INCLXX_IN_GEANT4_MODE 1
35
36#include "globals.hh"
37
38/*
39 * G4INCLNucleus.hh
40 *
41 * \date Jun 5, 2009
42 * \author Pekka Kaitaniemi
43 */
44
45#ifndef G4INCLNUCLEUS_HH_
46#define G4INCLNUCLEUS_HH_
47
48#include <list>
49#include <string>
50
51#include "G4INCLParticle.hh"
52#include "G4INCLEventInfo.hh"
53#include "G4INCLCluster.hh"
54#include "G4INCLFinalState.hh"
55#include "G4INCLStore.hh"
56#include "G4INCLGlobals.hh"
58#include "G4INCLConfig.hh"
59#include "G4INCLConfigEnums.hh"
60#include "G4INCLCluster.hh"
62
63namespace G4INCL {
64
65 class Nucleus : public Cluster {
66 public:
67 Nucleus(G4int mass, G4int charge, G4int strangess, Config const * const conf, const G4double universeRadius=-1.);
68 virtual ~Nucleus();
69
70 /// \brief Dummy copy constructor to silence Coverity warning
71 Nucleus(const Nucleus &rhs);
72
73 /// \brief Dummy assignment operator to silence Coverity warning
75
76 /**
77 * Call the Cluster method to generate the initial distribution of
78 * particles. At the beginning all particles are assigned as spectators.
79 */
81
82 /// \brief Insert a new particle (e.g. a projectile) in the nucleus.
84 theZ += p->getZ();
85 theA += p->getA();
86 theS += p->getS();
87 theStore->particleHasEntered(p);
88 if(p->isNucleon()) {
91 }
92 if(p->isPion()) {
93 theNpionplusInitial += Math::heaviside(ParticleTable::getIsospin(p->getType()));
94 theNpionminusInitial += Math::heaviside(-ParticleTable::getIsospin(p->getType()));
95 }
96 if(p->isKaon() || p->isAntiKaon()) {
97 theNkaonplusInitial += Math::heaviside(ParticleTable::getIsospin(p->getType()));
98 theNkaonminusInitial += Math::heaviside(-ParticleTable::getIsospin(p->getType()));
99 }
100 if(!p->isTargetSpectator()) theStore->getBook().incrementCascading();
101 };
102
103 /**
104 * Apply reaction final state information to the nucleus.
105 */
107
108 G4int getInitialA() const { return theInitialA; };
109 G4int getInitialZ() const { return theInitialZ; };
110 G4int getInitialS() const { return theInitialS; };
111
112 /**
113 * Propagate the particles one time step.
114 *
115 * @param step length of the time step
116 */
117 void propagateParticles(G4double step);
118
119 G4int getNumberOfEnteringProtons() const { return theNpInitial; };
120 G4int getNumberOfEnteringNeutrons() const { return theNnInitial; };
121 G4int getNumberOfEnteringPions() const { return theNpionplusInitial+theNpionminusInitial; };
122 G4int getNumberOfEnteringKaons() const { return theNkaonplusInitial+theNkaonminusInitial; };
123
124 /** \brief Outgoing - incoming separation energies.
125 *
126 * Used by CDPP.
127 */
129 G4double S = 0.0;
130 ParticleList const &outgoing = theStore->getOutgoingParticles();
131 for(ParticleIter i=outgoing.begin(), e=outgoing.end(); i!=e; ++i) {
132 const ParticleType t = (*i)->getType();
133 switch(t) {
134 case Proton:
135 case Neutron:
136 case DeltaPlusPlus:
137 case DeltaPlus:
138 case DeltaZero:
139 case DeltaMinus:
140 case Lambda:
141 case PiPlus:
142 case PiMinus:
143 case KPlus:
144 case KMinus:
145 case KZero:
146 case KZeroBar:
147 case KShort:
148 case KLong:
149 case SigmaPlus:
150 case SigmaZero:
151 case SigmaMinus:
152 S += thePotential->getSeparationEnergy(*i);
153 break;
154 case Composite:
155 S += (*i)->getZ() * thePotential->getSeparationEnergy(Proton)
156 + ((*i)->getA() + (*i)->getS() - (*i)->getZ()) * thePotential->getSeparationEnergy(Neutron)
157 - (*i)->getS() * thePotential->getSeparationEnergy(Lambda);
158 break;
159 default:
160 break;
161 }
162 }
163
164 S -= theNpInitial * thePotential->getSeparationEnergy(Proton);
165 S -= theNnInitial * thePotential->getSeparationEnergy(Neutron);
166 S -= theNpionplusInitial*thePotential->getSeparationEnergy(PiPlus);;
167 S -= theNkaonplusInitial*thePotential->getSeparationEnergy(KPlus);
168 S -= theNpionminusInitial*thePotential->getSeparationEnergy(PiMinus);
169 S -= theNkaonminusInitial*thePotential->getSeparationEnergy(KMinus);
170 return S;
171 }
172
173 /** \brief Force the decay of outgoing deltas.
174 *
175 * \return true if any delta was forced to decay.
176 */
178
179 /** \brief Force the decay of deltas inside the nucleus.
180 *
181 * \return true if any delta was forced to decay.
182 */
184
185 /** \brief Force the transformation of strange particles into a Lambda;
186 *
187 * \return true if any strange particles was forced to absorb.
188 */
190
191 /** \brief Force the decay of outgoing PionResonances (eta/omega).
192 *
193 * \return true if any eta was forced to decay.
194 */
196
197 /** \brief Force the decay of outgoing Neutral Sigma.
198 *
199 * \return true if any Sigma was forced to decay.
200 */
202
203 /** \brief Force the transformation of outgoing Neutral Kaon into propation eigenstate.
204 *
205 * \return true if any kaon was forced to decay.
206 */
208
209 /** \brief Force the decay of unstable outgoing clusters.
210 *
211 * \return true if any cluster was forced to decay.
212 */
214
215 /** \brief Force the phase-space decay of the Nucleus.
216 *
217 * Only applied if Z==0 or N==0.
218 *
219 * \return true if the nucleus was forced to decay.
220 */
221 G4bool decayMe();
222
223 /// \brief Force emission of all pions inside the nucleus.
224 void emitInsidePions();
225
226 /// \brief Force emission of all strange particles inside the nucleus.
228
229 /// \brief Force emission of all Lambda (desexitation code with strangeness not implanted yet)
231
232 /// \brief Force emission of all Kaon inside the nucleus
234
235 /** \brief Compute the recoil momentum and spin of the nucleus. */
237
238 /** \brief Compute the current center-of-mass position.
239 *
240 * \return the center-of-mass position vector [fm].
241 */
243
244 /** \brief Compute the current total energy.
245 *
246 * \return the total energy [MeV]
247 */
249
250 /** \brief Compute the current excitation energy.
251 *
252 * \return the excitation energy [MeV]
253 */
255
256 /** \brief Set the incoming angular-momentum vector. */
258 incomingAngularMomentum = j;
259 }
260
261 /** \brief Get the incoming angular-momentum vector. */
262 const ThreeVector &getIncomingAngularMomentum() const { return incomingAngularMomentum; }
263
264 /** \brief Set the incoming momentum vector. */
266 incomingMomentum = p;
267 }
268
269 /** \brief Get the incoming momentum vector. */
271 return incomingMomentum;
272 }
273
274 /** \brief Set the initial energy. */
275 void setInitialEnergy(const G4double e) { initialEnergy = e; }
276
277 /** \brief Get the initial energy. */
278 G4double getInitialEnergy() const { return initialEnergy; }
279
280 /** \brief Get the excitation energy of the nucleus.
281 *
282 * Method computeRecoilKinematics() should be called first.
283 */
285
286 ///\brief Returns true if the nucleus contains any deltas.
288 ParticleList const &inside = theStore->getParticles();
289 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
290 if((*i)->isDelta()) return true;
291 return false;
292 }
293
294 ///\brief Returns true if the nucleus contains any anti Kaons.
296 ParticleList const &inside = theStore->getParticles();
297 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
298 if((*i)->isAntiKaon()) return true;
299 return false;
300 }
301
302 ///\brief Returns true if the nucleus contains any Lambda.
304 ParticleList const &inside = theStore->getParticles();
305 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
306 if((*i)->isLambda()) return true;
307 return false;
308 }
309
310 ///\brief Returns true if the nucleus contains any Sigma.
312 ParticleList const &inside = theStore->getParticles();
313 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
314 if((*i)->isSigma()) return true;
315 return false;
316 }
317
318 ///\brief Returns true if the nucleus contains any Kaons.
320 ParticleList const &inside = theStore->getParticles();
321 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
322 if((*i)->isKaon()) return true;
323 return false;
324 }
325
326 ///\brief Returns true if the nucleus contains any etas.
328 ParticleList const &inside = theStore->getParticles();
329 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
330 if((*i)->isEta()) return true;
331 return false;
332 }
333
334 ///\brief Returns true if the nucleus contains any omegas.
336 ParticleList const &inside = theStore->getParticles();
337 for(ParticleIter i=inside.begin(), e=inside.end(); i!=e; ++i)
338 if((*i)->isOmega()) return true;
339 return false;
340 }
341
342 /**
343 * Print the nucleus info
344 */
345 std::string print();
346
347 Store* getStore() const {return theStore; };
348 void setStore(Store *s) {
349 delete theStore;
350 theStore = s;
351 };
352
353 G4double getInitialInternalEnergy() const { return initialInternalEnergy; };
354
355 /** \brief Is the event transparent?
356 *
357 * To be called at the end of the cascade.
358 **/
360
361 /** \brief Does the nucleus give a cascade remnant?
362 *
363 * To be called after computeRecoilKinematics().
364 **/
365 G4bool hasRemnant() const { return remnant; }
366
367 /**
368 * Fill the event info which contains INCL output data
369 */
370 void fillEventInfo(EventInfo *eventInfo);
371
372 G4bool getTryCompoundNucleus() { return tryCN; }
373
374 /// \brief Get the transmission barrier
376 const G4double theTransmissionRadius = theDensity->getTransmissionRadius(p);
377 const G4double theParticleZ = p->getZ();
378 return PhysicalConstants::eSquared*(theZ-theParticleZ)*theParticleZ/theTransmissionRadius;
379 }
380
381 /// \brief Struct for conservation laws
386 };
387
388 /// \brief Compute charge, mass, energy and momentum balance
389 ConservationBalance getConservationBalance(EventInfo const &theEventInfo, const G4bool afterRecoil) const;
390
391 /// \brief Adjust the kinematics for complete-fusion events
392 void useFusionKinematics();
393
394 /** \brief Get the maximum allowed radius for a given particle.
395 *
396 * Calls the NuclearDensity::getMaxRFromP() method for nucleons and deltas,
397 * and the NuclearDensity::getTrasmissionRadius() method for pions.
398 *
399 * \param particle pointer to a particle
400 * \return surface radius
401 */
402 G4double getSurfaceRadius(Particle const * const particle) const {
403 if(particle->isNucleon() || particle->isLambda() || particle->isResonance()){
404 const G4double pr = particle->getReflectionMomentum()/thePotential->getFermiMomentum(particle);
405 if(pr>=1.)
406 return getUniverseRadius();
407 else
408 return theDensity->getMaxRFromP(particle->getType(), pr);
409 }
410 else {
411 // Temporarily set RPION = RMAX
412 return getUniverseRadius();
413 //return 0.5*(theDensity->getTransmissionRadius(particle)+getUniverseRadius());
414 }
415 }
416
417 /// \brief Getter for theUniverseRadius.
418 G4double getUniverseRadius() const { return theUniverseRadius; }
419
420 /// \brief Setter for theUniverseRadius.
421 void setUniverseRadius(const G4double universeRadius) { theUniverseRadius=universeRadius; }
422
423 /// \brief Is it a nucleus-nucleus collision?
424 G4bool isNucleusNucleusCollision() const { return isNucleusNucleus; }
425
426 /// \brief Set a nucleus-nucleus collision
427 void setNucleusNucleusCollision() { isNucleusNucleus=true; }
428
429 /// \brief Set a particle-nucleus collision
430 void setParticleNucleusCollision() { isNucleusNucleus=false; }
431
432 /// \brief Set the projectile remnant
434 delete theProjectileRemnant;
435 theProjectileRemnant = c;
436 }
437
438 /// \brief Get the projectile remnant
439 ProjectileRemnant *getProjectileRemnant() const { return theProjectileRemnant; }
440
441 /// \brief Delete the projectile remnant
443 delete theProjectileRemnant;
444 theProjectileRemnant = NULL;
445 }
446
447 /** \brief Finalise the projectile remnant
448 *
449 * Complete the treatment of the projectile remnant. If it contains
450 * nucleons, assign its excitation energy and spin. Move stuff to the
451 * outgoing list, if appropriate.
452 *
453 * \param emissionTime the emission time of the projectile remnant
454 */
455 void finalizeProjectileRemnant(const G4double emissionTime);
456
457 /// \brief Update the particle potential energy.
458 inline void updatePotentialEnergy(Particle *p) const {
459 p->setPotentialEnergy(thePotential->computePotentialEnergy(p));
460 }
461
462 /// \brief Setter for theDensity
463 void setDensity(NuclearDensity const * const d) {
464 theDensity=d;
466 theParticleSampler->setDensity(theDensity);
467 };
468
469 /// \brief Getter for theDensity
470 NuclearDensity const *getDensity() const { return theDensity; };
471
472 /// \brief Getter for thePotential
473 NuclearPotential::INuclearPotential const *getPotential() const { return thePotential; };
474
475 private:
476 /** \brief Compute the recoil kinematics for a 1-nucleon remnant.
477 *
478 * Puts the remnant nucleon on mass shell and tries to enforce approximate
479 * energy conservation by modifying the masses of the outgoing particles.
480 */
481 void computeOneNucleonRecoilKinematics();
482
483 private:
484 G4int theInitialZ, theInitialA, theInitialS;
485 /// \brief The number of entering protons
486 G4int theNpInitial;
487 /// \brief The number of entering neutrons
488 G4int theNnInitial;
489 /// \brief The number of entering pions
490 G4int theNpionplusInitial;
491 G4int theNpionminusInitial;
492 /// \brief The number of entering kaons
493 G4int theNkaonplusInitial;
494 G4int theNkaonminusInitial;
495
496 G4double initialInternalEnergy;
497 ThreeVector incomingAngularMomentum, incomingMomentum;
498 ThreeVector initialCenterOfMass;
499 G4bool remnant;
500
501 G4double initialEnergy;
502 Store *theStore;
503 G4bool tryCN;
504
505 /// \brief The charge number of the projectile
506 G4int projectileZ;
507 /// \brief The mass number of the projectile
508 G4int projectileA;
509 /// \brief The strangeness number of the projectile
510 G4int projectileS;
511
512 /// \brief The radius of the universe
513 G4double theUniverseRadius;
514
515 /** \brief true if running a nucleus-nucleus collision
516 *
517 * Tells INCL whether to make a projectile-like pre-fragment or not.
518 */
519 G4bool isNucleusNucleus;
520
521 /** \brief Pointer to the quasi-projectile
522 *
523 * Owned by the Nucleus object.
524 */
525 ProjectileRemnant *theProjectileRemnant;
526
527 /// \brief Pointer to the NuclearDensity object
528 NuclearDensity const *theDensity;
529
530 /// \brief Pointer to the NuclearPotential object
531 NuclearPotential::INuclearPotential const *thePotential;
532
534 };
535
536}
537
538#endif /* G4INCLNUCLEUS_HH_ */
double S(double temp)
#define INCL_DECLARE_ALLOCATION_POOL(T)
Simple container for output of event results.
Class for constructing a projectile-like remnant.
double G4double
Definition: G4Types.hh:83
bool G4bool
Definition: G4Types.hh:86
int G4int
Definition: G4Types.hh:85
void incrementCascading()
Definition: G4INCLBook.hh:77
ParticleSampler * theParticleSampler
G4double theExcitationEnergy
G4double getTransmissionRadius(Particle const *const p) const
The radius used for calculating the transmission coefficient.
G4double getMaxRFromP(const ParticleType t, const G4double p) const
Get the maximum allowed radius for a given momentum.
G4double getFermiMomentum(const Particle *const p) const
Return the Fermi momentum for a particle.
G4double getSeparationEnergy(const Particle *const p) const
Return the separation energy for a particle.
virtual G4double computePotentialEnergy(const Particle *const p) const =0
G4int getInitialA() const
G4bool decayOutgoingNeutralKaon()
Force the transformation of outgoing Neutral Kaon into propation eigenstate.
G4bool containsSigma()
Returns true if the nucleus contains any Sigma.
const ThreeVector & getIncomingAngularMomentum() const
Get the incoming angular-momentum vector.
G4int getNumberOfEnteringPions() const
G4double computeSeparationEnergyBalance() const
Outgoing - incoming separation energies.
Store * getStore() const
ProjectileRemnant * getProjectileRemnant() const
Get the projectile remnant.
void fillEventInfo(EventInfo *eventInfo)
G4bool containsEtas()
Returns true if the nucleus contains any etas.
G4bool decayMe()
Force the phase-space decay of the Nucleus.
G4double computeTotalEnergy() const
Compute the current total energy.
void setStore(Store *s)
G4bool decayInsideDeltas()
Force the decay of deltas inside the nucleus.
void setIncomingAngularMomentum(const ThreeVector &j)
Set the incoming angular-momentum vector.
void computeRecoilKinematics()
Compute the recoil momentum and spin of the nucleus.
void setInitialEnergy(const G4double e)
Set the initial energy.
void finalizeProjectileRemnant(const G4double emissionTime)
Finalise the projectile remnant.
G4double getSurfaceRadius(Particle const *const particle) const
Get the maximum allowed radius for a given particle.
G4bool containsDeltas()
Returns true if the nucleus contains any deltas.
G4bool getTryCompoundNucleus()
G4bool emitInsideKaon()
Force emission of all Kaon inside the nucleus.
G4bool isEventTransparent() const
Is the event transparent?
G4int getNumberOfEnteringProtons() const
void applyFinalState(FinalState *)
G4bool isNucleusNucleusCollision() const
Is it a nucleus-nucleus collision?
G4int getInitialS() const
void insertParticle(Particle *p)
Insert a new particle (e.g. a projectile) in the nucleus.
G4bool containsKaon()
Returns true if the nucleus contains any Kaons.
Nucleus & operator=(const Nucleus &rhs)
Dummy assignment operator to silence Coverity warning.
void emitInsideStrangeParticles()
Force emission of all strange particles inside the nucleus.
void deleteProjectileRemnant()
Delete the projectile remnant.
std::string print()
G4bool containsOmegas()
Returns true if the nucleus contains any omegas.
G4double getTransmissionBarrier(Particle const *const p)
Get the transmission barrier.
G4bool decayOutgoingPionResonances(G4double timeThreshold)
Force the decay of outgoing PionResonances (eta/omega).
void setIncomingMomentum(const ThreeVector &p)
Set the incoming momentum vector.
G4int getNumberOfEnteringNeutrons() const
void useFusionKinematics()
Adjust the kinematics for complete-fusion events.
NuclearDensity const * getDensity() const
Getter for theDensity.
G4int getNumberOfEnteringKaons() const
G4double getInitialInternalEnergy() const
G4bool containsLambda()
Returns true if the nucleus contains any Lambda.
const ThreeVector & getIncomingMomentum() const
Get the incoming momentum vector.
void setParticleNucleusCollision()
Set a particle-nucleus collision.
void emitInsidePions()
Force emission of all pions inside the nucleus.
G4double getInitialEnergy() const
Get the initial energy.
ThreeVector computeCenterOfMass() const
Compute the current center-of-mass position.
G4bool decayOutgoingClusters()
Force the decay of unstable outgoing clusters.
G4double getExcitationEnergy() const
Get the excitation energy of the nucleus.
void setNucleusNucleusCollision()
Set a nucleus-nucleus collision.
G4int emitInsideLambda()
Force emission of all Lambda (desexitation code with strangeness not implanted yet)
void propagateParticles(G4double step)
G4bool decayInsideStrangeParticles()
Force the transformation of strange particles into a Lambda;.
ConservationBalance getConservationBalance(EventInfo const &theEventInfo, const G4bool afterRecoil) const
Compute charge, mass, energy and momentum balance.
void setProjectileRemnant(ProjectileRemnant *const c)
Set the projectile remnant.
void initializeParticles()
void setDensity(NuclearDensity const *const d)
Setter for theDensity.
G4bool hasRemnant() const
Does the nucleus give a cascade remnant?
void setUniverseRadius(const G4double universeRadius)
Setter for theUniverseRadius.
void updatePotentialEnergy(Particle *p) const
Update the particle potential energy.
NuclearPotential::INuclearPotential const * getPotential() const
Getter for thePotential.
G4double getUniverseRadius() const
Getter for theUniverseRadius.
G4double computeExcitationEnergy() const
Compute the current excitation energy.
G4bool containsAntiKaon()
Returns true if the nucleus contains any anti Kaons.
virtual ~Nucleus()
G4bool decayOutgoingDeltas()
Force the decay of outgoing deltas.
Nucleus(const Nucleus &rhs)
Dummy copy constructor to silence Coverity warning.
G4bool decayOutgoingSigmaZero(G4double timeThreshold)
Force the decay of outgoing Neutral Sigma.
G4int getInitialZ() const
void setDensity(NuclearDensity const *const d)
Setter for theDensity.
void setPotentialEnergy(G4double v)
Set the particle potential energy.
G4bool isLambda() const
Is this a Lambda?
G4int getS() const
Returns the strangeness number.
G4int getZ() const
Returns the charge number.
G4double getReflectionMomentum() const
Return the reflection momentum.
G4bool isTargetSpectator() const
G4bool isPion() const
Is this a pion?
G4bool isAntiKaon() const
Is this an antiKaon?
G4INCL::ParticleType getType() const
G4bool isKaon() const
Is this a Kaon?
G4bool isResonance() const
Is it a resonance?
G4int getA() const
Returns the baryon number.
G4bool isNucleon() const
ParticleList const & getOutgoingParticles() const
Definition: G4INCLStore.hh:223
Book & getBook()
Definition: G4INCLStore.hh:259
void particleHasEntered(Particle *const particle)
Move a particle from incoming to inside.
Definition: G4INCLStore.cc:188
ParticleList const & getParticles() const
Definition: G4INCLStore.hh:253
G4int heaviside(G4int n)
G4int getIsospin(const ParticleType t)
Get the isospin of a particle.
const G4double eSquared
Coulomb conversion factor [MeV*fm].
ParticleList::const_iterator ParticleIter
Struct for conservation laws.