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

#include <G4INCLCascade.hh>

Public Member Functions

 INCL (Config const *const config)
 
 ~INCL ()
 
G4bool prepareReaction (const ParticleSpecies &projectileSpecies, const G4double kineticEnergy, const G4int A, const G4int Z)
 
G4bool initializeTarget (const G4int A, const G4int Z)
 
const EventInfoprocessEvent ()
 
const EventInfoprocessEvent (ParticleSpecies const &projectileSpecies, const G4double kineticEnergy, const G4int targetA, const G4int targetZ)
 
void finalizeGlobalInfo ()
 
const GlobalInfogetGlobalInfo () const
 
std::string configToString ()
 

Detailed Description

Definition at line 55 of file G4INCLCascade.hh.

Constructor & Destructor Documentation

◆ INCL()

G4INCL::INCL::INCL ( G4INCL::Config const *const  config)

Definition at line 82 of file G4INCLCascade.cc.

83 :propagationModel(0), theA(208), theZ(82),
84 targetInitSuccess(false),
85 maxImpactParameter(0.),
86 maxUniverseRadius(0.),
87 maxInteractionDistance(0.),
88 fixedImpactParameter(0.),
89 theConfig(config),
90 nucleus(NULL),
91 minRemnantSize(4)
92 {
93 // Set the logger object.
96
97 // Set the random number generator algorithm. The system can support
98 // multiple different generator algorithms in a completely
99 // transparent way.
100#ifdef INCLXX_IN_GEANT4_MODE
102#else
104#endif // INCLXX_IN_GEANT4_MODE
105
106 // Select the Pauli blocking algorithm:
107 G4INCL::PauliType pauli = theConfig->getPauliType();
110 else if(pauli == G4INCL::StatisticalPauli)
112 else if(pauli == G4INCL::StrictPauli)
114 else if(pauli == G4INCL::GlobalPauli)
116 else if(pauli == G4INCL::NoPauli)
118
119 if(theConfig->getCDPP())
121 else
123
124 // Select the Coulomb-distortion algorithm:
125 G4INCL::CoulombType coulombType = theConfig->getCoulombType();
126 if(coulombType == G4INCL::NonRelativisticCoulomb)
128 else // if(coulombType == G4INCL::NoCoulomb)
130
131 // Select the clustering algorithm:
132 G4INCL::ClusterAlgorithmType clusterAlgorithm = theConfig->getClusterAlgorithm();
133 if(clusterAlgorithm == G4INCL::IntercomparisonClusterAlgorithm)
135 else // if(clusterAlgorithm == G4INCL::NoClusterAlgorithm)
137
138 // Initialize the INCL particle table:
140
141 // Propagation model is responsible for finding avatars and
142 // transporting the particles. In principle this step is "hidden"
143 // behind an abstract interface and the rest of the system does not
144 // care how the transportation and avatar finding is done. This
145 // should allow us to "easily" experiment with different avatar
146 // finding schemes and even to support things like curved
147 // trajectories in the future.
148 propagationModel = new G4INCL::StandardPropagationModel(theConfig->getLocalEnergyBBType(),theConfig->getLocalEnergyPiType());
149 eventAction = new EventAction();
150 propagationAction = new PropagationAction();
151 avatarAction = new AvatarAction();
152
153 theGlobalInfo.cascadeModel = theConfig->getVersionID().c_str();
154 theGlobalInfo.deexcitationModel = "none";
155
156#ifndef INCLXX_IN_GEANT4_MODE
157 // Fill in the global information
158 theGlobalInfo.At = theConfig->getTargetA();
159 theGlobalInfo.Zt = theConfig->getTargetZ();
160 const ParticleSpecies theSpecies = theConfig->getProjectileSpecies();
161 theGlobalInfo.Ap = theSpecies.theA;
162 theGlobalInfo.Zp = theSpecies.theZ;
163 theGlobalInfo.Ep = theConfig->getProjectileKineticEnergy();
164 // Echo the input parameters to the log file
165 INFO(theConfig->echo() << std::endl);
166#endif
167
168 fixedImpactParameter = theConfig->getImpactParameter();
169 }
#define INFO(x)
Cluster coalescence algorithm used in the IAEA intercomparison.
static void setClusteringModel(IClusteringModel *const model)
Set the clustering model.
PauliType getPauliType() const
Get the Pauli-blocking algorithm.
static std::string const getVersionID()
Get the INCL version ID.
G4double getImpactParameter() const
G4int getTargetA() const
Get the target mass number.
G4int getVerbosity() const
Get the verbosity.
Definition: G4INCLConfig.hh:87
std::string const & getLogFileName() const
Get the log file name.
ParticleSpecies getProjectileSpecies() const
Get the projectile species.
ClusterAlgorithmType getClusterAlgorithm() const
Get the clustering algorithm.
std::string const echo() const
Echo the input options.
LocalEnergyType getLocalEnergyPiType() const
Get the type of local energy for pi-N and decay avatars.
G4bool getCDPP() const
Do we want CDPP?
LocalEnergyType getLocalEnergyBBType() const
Get the type of local energy for N-N avatars.
G4int getTargetZ() const
Get the target charge number.
CoulombType getCoulombType() const
Get the Coulomb-distortion algorithm.
G4float getProjectileKineticEnergy() const
Get the projectile kinetic energy.
SeedVector const getRandomSeeds() const
Get the seeds for the random-number generator.
static void setCoulomb(ICoulomb *const coulomb)
Set the Coulomb-distortion algorithm.
static void setLoggerSlave(LoggerSlave *const slave)
static void setVerbosityLevel(G4int)
static void initialize(Config const *const theConfig=0)
Initialize the particle table.
static void setBlocker(IPauli const *const)
static void setCDPP(IPauli const *const)
static void setGenerator(G4INCL::IRandomGenerator *aGenerator)
Definition: G4INCLRandom.hh:72
@ IntercomparisonClusterAlgorithm
@ NonRelativisticCoulomb
@ StrictStatisticalPauli
std::string deexcitationModel
Name of the de-excitation model.
Float_t Ep
Projectile kinetic energy given as input.
Short_t At
Target mass number given as input.
Short_t Zt
Target charge number given as input.
Short_t Ap
Projectile mass number given as input.
Short_t Zp
Projectile charge number given as input.
std::string cascadeModel
Name of the cascade model.

◆ ~INCL()

G4INCL::INCL::~INCL ( )

Definition at line 171 of file G4INCLCascade.cc.

171 {
178 delete avatarAction;
179 delete propagationAction;
180 delete eventAction;
181 delete propagationModel;
182 delete theConfig;
183 }
static void deleteClusteringModel()
static void deleteCoulomb()
Delete the Coulomb-distortion object.
static void deleteLoggerSlave()
static void deleteBlockers()
static void deleteGenerator()

Member Function Documentation

◆ configToString()

std::string G4INCL::INCL::configToString ( )
inline

Definition at line 81 of file G4INCLCascade.hh.

81{ return theConfig->echo(); }

Referenced by G4INCLXXInterface::ApplyYourself().

◆ finalizeGlobalInfo()

void G4INCL::INCL::finalizeGlobalInfo ( )

Definition at line 680 of file G4INCLCascade.cc.

680 {
681 theGlobalInfo.nucleonAbsorptionCrossSection = theGlobalInfo.geometricCrossSection *
682 ((G4double) theGlobalInfo.nNucleonAbsorptions) / ((G4double) theGlobalInfo.nShots);
683 theGlobalInfo.pionAbsorptionCrossSection = theGlobalInfo.geometricCrossSection *
684 ((G4double) theGlobalInfo.nPionAbsorptions) / ((G4double) theGlobalInfo.nShots);
685 theGlobalInfo.reactionCrossSection = theGlobalInfo.geometricCrossSection *
686 ((G4double) (theGlobalInfo.nShots - theGlobalInfo.nTransparents)) /
687 ((G4double) theGlobalInfo.nShots);
688 theGlobalInfo.errorReactionCrossSection = theGlobalInfo.geometricCrossSection *
689 std::sqrt((G4double) (theGlobalInfo.nShots - theGlobalInfo.nTransparents)) /
690 ((G4double) theGlobalInfo.nShots);
691 }
double G4double
Definition: G4Types.hh:64
Int_t nNucleonAbsorptions
Number of nucleon absorptions (no outcoming particles)
Float_t pionAbsorptionCrossSection
Pion absorption cross section.
Int_t nShots
Number of shots.
Float_t nucleonAbsorptionCrossSection
Nucleon absorption cross section.
Float_t errorReactionCrossSection
Error on the calculated reaction cross section.
Int_t nPionAbsorptions
Number of nucleon absorptions (no outcoming pions)
Int_t nTransparents
Number of transparent shots.
Float_t reactionCrossSection
Calculated reaction cross section.
Float_t geometricCrossSection
Geometric cross section.

◆ getGlobalInfo()

const GlobalInfo & G4INCL::INCL::getGlobalInfo ( ) const
inline

Definition at line 79 of file G4INCLCascade.hh.

79{ return theGlobalInfo; }

◆ initializeTarget()

G4bool G4INCL::INCL::initializeTarget ( const G4int  A,
const G4int  Z 
)

Definition at line 220 of file G4INCLCascade.cc.

220 {
221 delete nucleus;
222
223 nucleus = new Nucleus(A, Z, theConfig, maxUniverseRadius);
224 nucleus->getStore()->getBook()->reset();
225 nucleus->initializeParticles();
226
227 propagationModel->setNucleus(nucleus);
228 return true;
229 }
void reset()
Definition: G4INCLBook.hh:53
virtual void setNucleus(G4INCL::Nucleus *nucleus)=0
Store * getStore() const
void initializeParticles()
Book * getBook()
Definition: G4INCLStore.hh:243

Referenced by prepareReaction().

◆ prepareReaction()

G4bool G4INCL::INCL::prepareReaction ( const ParticleSpecies projectileSpecies,
const G4double  kineticEnergy,
const G4int  A,
const G4int  Z 
)

Definition at line 185 of file G4INCLCascade.cc.

185 {
186 if(A < 0 || A > 300 || Z < 1 || Z > 200) {
187 ERROR("Unsupported target: A = " << A << " Z = " << Z << std::endl);
188 ERROR("Target configuration rejected." << std::endl);
189 return false;
190 }
191
192 // Initialise the maximum universe radius
193 initUniverseRadius(projectileSpecies, kineticEnergy, A, Z);
194
195 // Initialise the nucleus
196 theZ = Z;
197 if(theConfig->isNaturalTarget())
199 else
200 theA = A;
201 initializeTarget(theA, theZ);
202
203 // Set the maximum impact parameter
204 maxImpactParameter = CoulombDistortion::maxImpactParameter(projectileSpecies, kineticEnergy, nucleus);
205 initMaxInteractionDistance(projectileSpecies, kineticEnergy); // for forced CN events
206
207 // Set the geometric cross section
208 theGlobalInfo.geometricCrossSection =
209 Math::tenPi*std::pow(maxImpactParameter,2);
210
211 // Set the minimum remnant size
212 if(projectileSpecies.theA > 0)
213 minRemnantSize = std::min(theA, 4);
214 else
215 minRemnantSize = std::min(theA-1, 4);
216
217 return true;
218 }
#define ERROR(x)
G4bool isNaturalTarget() const
Natural targets.
Definition: G4INCLConfig.hh:99
static G4double maxImpactParameter(ParticleSpecies const &p, const G4double kinE, Nucleus const *const n)
Return the maximum impact parameter for Coulomb-distorted trajectories.
G4bool initializeTarget(const G4int A, const G4int Z)
static G4int drawRandomNaturalIsotope(const G4int Z)
const G4double tenPi

Referenced by processEvent().

◆ processEvent() [1/2]

const EventInfo & G4INCL::INCL::processEvent ( )
inline

Definition at line 63 of file G4INCLCascade.hh.

63 {
64 return processEvent(
65 theConfig->getProjectileSpecies(),
66 theConfig->getProjectileKineticEnergy(),
67 theConfig->getTargetA(),
68 theConfig->getTargetZ()
69 );
70 }
const EventInfo & processEvent()

Referenced by G4INCLXXInterface::ApplyYourself(), and processEvent().

◆ processEvent() [2/2]

const EventInfo & G4INCL::INCL::processEvent ( ParticleSpecies const projectileSpecies,
const G4double  kineticEnergy,
const G4int  targetA,
const G4int  targetZ 
)

Definition at line 231 of file G4INCLCascade.cc.

236 {
237 // Set the target and the projectile
238 targetInitSuccess = prepareReaction(projectileSpecies, kineticEnergy, targetA, targetZ);
239
240 if(!targetInitSuccess) {
241 WARN("Target initialisation failed for A=" << targetA << ", Z=" << targetZ << std::endl);
242 theEventInfo.transparent=true;
243 return theEventInfo;
244 }
245
246 const G4bool canRunCascade = preCascade(projectileSpecies, kineticEnergy);
247 if(canRunCascade) {
248 cascade();
249 postCascade();
250 }
251 return theEventInfo;
252 }
#define WARN(x)
bool G4bool
Definition: G4Types.hh:67
G4bool prepareReaction(const ParticleSpecies &projectileSpecies, const G4double kineticEnergy, const G4int A, const G4int Z)
Bool_t transparent
True if the event is transparent.

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