Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
|
#include <G4INCLStore.hh>
Static Public Member Functions | |
static G4bool | avatarComparisonPredicate (IAvatar *lhs, IAvatar *rhs) |
Comparison predicate for avatars. | |
The purpose of the Store object is to act as a "particle manager" that keeps track ofall the particles in our simulation. It also tracks the avatars and their connections to particles.
Definition at line 64 of file G4INCLStore.hh.
Store constructor
Definition at line 46 of file G4INCLStore.cc.
G4INCL::Store::~Store | ( | ) |
Store destructor
Definition at line 55 of file G4INCLStore.cc.
void G4INCL::Store::add | ( | IAvatar * | a | ) |
Add one avatar to the store
Avatars know about the particles they are associated with. Adding an avatar consists of the following steps:
Definition at line 91 of file G4INCLStore.cc.
void G4INCL::Store::add | ( | Particle * | p | ) |
Add one particle to the store.
Particle objects don't know anything about avatars so this method will only do two things:
Definition at line 62 of file G4INCLStore.cc.
Referenced by add(), G4INCL::Nucleus::applyFinalState(), G4INCL::Nucleus::initializeParticles(), loadParticles(), particleHasEntered(), and G4INCL::StandardPropagationModel::registerAvatar().
Add a particle to the incoming list.
p | particle to add |
Definition at line 112 of file G4INCLStore.cc.
Referenced by addParticleEntryAvatar().
void G4INCL::Store::addParticleEntryAvatar | ( | IAvatar * | a | ) |
Add one ParticleEntry avatar.
Definition at line 73 of file G4INCLStore.cc.
Referenced by addParticleEntryAvatars(), and G4INCL::StandardPropagationModel::shootParticle().
void G4INCL::Store::addParticleEntryAvatars | ( | IAvatarList const & | al | ) |
Add one ParticleEntry avatar.
Definition at line 86 of file G4INCLStore.cc.
Referenced by G4INCL::StandardPropagationModel::shootComposite().
|
inline |
add the particle to the outgoing particle list.
p | pointer to the particle to be added |
Definition at line 171 of file G4INCLStore.hh.
Referenced by addToOutgoing(), G4INCL::Nucleus::applyFinalState(), G4INCL::Nucleus::decayMe(), G4INCL::Nucleus::decayOutgoingClusters(), G4INCL::Nucleus::decayOutgoingDeltas(), G4INCL::Nucleus::emitInsidePions(), G4INCL::Nucleus::finalizeProjectileRemnant(), and G4INCL::Nucleus::moveProjectileRemnantComponentsToOutgoing().
|
inline |
Add a list of particles to the outgoing particle list.
pl | list of particles to be added |
Definition at line 177 of file G4INCLStore.hh.
|
inlinestatic |
Comparison predicate for avatars.
avatarComparisonPredicate is used by the std::sort or std::min_element functions to compare the avatar objects according to their time.
lhs | pointer to the first avatar |
rhs | pointer to the second avatar |
Definition at line 350 of file G4INCLStore.hh.
Referenced by findSmallestTime().
void G4INCL::Store::clear | ( | ) |
Clear all avatars and particles from the store.
Warning! This actually deletes the objects as well!
Definition at line 342 of file G4INCLStore.cc.
Referenced by loadParticles(), and ~Store().
void G4INCL::Store::clearAvatars | ( | ) |
Clear avatars only.
Definition at line 318 of file G4INCLStore.cc.
Referenced by clear(), and G4INCL::StandardPropagationModel::propagate().
|
inline |
Clear the incoming list.
Definition at line 130 of file G4INCLStore.hh.
Referenced by deleteIncoming().
void G4INCL::Store::clearOutgoing | ( | ) |
Clear all outgoing particles from the store.
Warning! This actually deletes the objects as well!
Definition at line 365 of file G4INCLStore.cc.
Referenced by clear().
G4bool G4INCL::Store::containsCollisions | ( | ) | const |
Definition at line 494 of file G4INCLStore.cc.
|
inline |
Definition at line 245 of file G4INCLStore.hh.
|
inline |
Clear the incoming list and delete the particles.
Definition at line 135 of file G4INCLStore.hh.
|
inline |
Returns a list of dynamical spectators.
Looks in the outgoing list for particles without collisions and decays, removes them from outgoing and returns them in a list.
Definition at line 213 of file G4INCLStore.hh.
IAvatar * G4INCL::Store::findSmallestTime | ( | ) |
Find the avatar that has the smallest time.
Definition at line 212 of file G4INCLStore.cc.
Referenced by G4INCL::StandardPropagationModel::propagate().
|
inline |
Return the list of avatars
Definition at line 111 of file G4INCLStore.hh.
|
inline |
Return the pointer to the Book object which keeps track of various counters.
Definition at line 243 of file G4INCLStore.hh.
Referenced by G4INCL::Nucleus::applyFinalState(), G4INCL::Nucleus::decayOutgoingDeltas(), G4INCL::Nucleus::emitInsidePions(), G4INCL::Nucleus::fillEventInfo(), G4INCL::StandardPropagationModel::generateBinaryCollisionAvatar(), G4INCL::BinaryCollisionAvatar::getChannel(), G4INCL::INCL::initializeTarget(), G4INCL::Nucleus::insertParticle(), G4INCL::PauliStrictStandard::isBlocked(), G4INCL::BinaryCollisionAvatar::postInteraction(), G4INCL::DecayAvatar::postInteraction(), G4INCL::InteractionAvatar::postInteraction(), G4INCL::SurfaceAvatar::postInteraction(), G4INCL::StandardPropagationModel::propagate(), and G4INCL::InteractionAvatar::shouldUseLocalEnergy().
Get the config object
Definition at line 257 of file G4INCLStore.hh.
Referenced by G4INCL::ClusteringModelIntercomparison::getCluster(), G4INCL::InteractionAvatar::postInteraction(), and G4INCL::InteractionAvatar::shouldUseLocalEnergy().
|
inline |
Return the list of incoming particles (i.e. particles that have yet to enter the cascade).
Definition at line 198 of file G4INCLStore.hh.
|
inline |
Get the value of the nucleus mass number that we read from file with loadParticles.
Definition at line 309 of file G4INCLStore.hh.
|
inline |
Get the value of the stopping time that we read from file with loadParticles.
Definition at line 321 of file G4INCLStore.hh.
|
inline |
Get the value of the nucleus charge number that we read from file with loadParticles.
Definition at line 315 of file G4INCLStore.hh.
|
inline |
Return the list of outgoing particles (i.e. particles that have left the cascade).
Definition at line 204 of file G4INCLStore.hh.
Referenced by G4INCL::Nucleus::computeRecoilKinematics(), G4INCL::Nucleus::computeSeparationEnergyBalance(), G4INCL::Nucleus::decayOutgoingClusters(), G4INCL::Nucleus::decayOutgoingDeltas(), G4INCL::Nucleus::fillEventInfo(), G4INCL::Nucleus::getConservationBalance(), G4INCL::Nucleus::isEventTransparent(), and G4INCL::Nucleus::print().
ParticleList G4INCL::Store::getParticipants | ( | ) |
Get list of participants (active nucleons).
Warning: This (slow) method may be deprecated in the near future...
Definition at line 294 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::dump(), and G4INCL::Nucleus::print().
|
inline |
Return the list of "active" particles (i.e. particles that can participate in collisions).
Definition at line 237 of file G4INCLStore.hh.
Referenced by G4INCL::Nucleus::computeCenterOfMass(), G4INCL::Nucleus::computeTotalEnergy(), G4INCL::Nucleus::containsDeltas(), G4INCL::Nucleus::decayInsideDeltas(), G4INCL::Nucleus::emitInsidePions(), G4INCL::StandardPropagationModel::generateAllAvatars(), G4INCL::PauliStandard::getBlockingProbability(), G4INCL::ClusteringModelIntercomparison::getCluster(), G4INCL::CDPP::isBlocked(), and G4INCL::StandardPropagationModel::updateAvatars().
ParticleList G4INCL::Store::getSpectators | ( | ) |
Get list of spectators (active nucleons).
Warning: This (slow) method may be deprecated in the near future...
Definition at line 306 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::print().
void G4INCL::Store::initialiseParticleAvatarConnections | ( | ) |
Initialise the particleAvatarConnections map.
Generate an empty avatar-ID vector for each particle in the inside list and fill in the relevant particle-avatar map entry.
Definition at line 335 of file G4INCLStore.cc.
Referenced by G4INCL::StandardPropagationModel::propagate().
void G4INCL::Store::loadParticles | ( | std::string | filename | ) |
Load particle configuration from ASCII file (see avatarPredictionTest).
Definition at line 381 of file G4INCLStore.cc.
void G4INCL::Store::particleHasBeenDestroyed | ( | long | ID | ) |
Remove the particle from the system. This also removes all avatars related to this particle.
Definition at line 280 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::applyFinalState().
void G4INCL::Store::particleHasBeenEjected | ( | long | ID | ) |
Mark the particle as ejected. This removes it from the list of inside particles and removes all avatars related to this particle.
Definition at line 271 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::applyFinalState(), and G4INCL::Nucleus::emitInsidePions().
void G4INCL::Store::particleHasBeenUpdated | ( | long | particleID | ) |
Notify the Store that a particle has been updated. This triggers the removal of obsolete avatars and their disconnection from the particle.
Definition at line 164 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::applyFinalState(), particleHasBeenDestroyed(), and particleHasBeenEjected().
Move a particle from incoming to inside.
particle | pointer to a particle |
Definition at line 289 of file G4INCLStore.cc.
Referenced by G4INCL::Nucleus::insertParticle().
std::string G4INCL::Store::printAvatars | ( | ) |
Print the list of avatars
Definition at line 485 of file G4INCLStore.cc.
std::string G4INCL::Store::printParticleConfiguration | ( | ) |
Print the nucleon configuration of the nucleus.
Definition at line 428 of file G4INCLStore.cc.
Referenced by writeParticles().
Add a particle to the incoming list.
p | particle to add |
Definition at line 127 of file G4INCLStore.hh.
Referenced by particleHasEntered().
void G4INCL::Store::timeStep | ( | G4double | step | ) |
Make one time step: propagate particles and subtract the length of the step from the avatar times.
Definition at line 263 of file G4INCLStore.cc.
Referenced by G4INCL::StandardPropagationModel::propagate().
void G4INCL::Store::writeParticles | ( | std::string | filename | ) |
Print the nucleon configuration of the nucleus.
Definition at line 479 of file G4INCLStore.cc.