Geant4-11
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions | Private Attributes | Static Private Attributes
G4Radioactivation Class Reference

#include <G4Radioactivation.hh>

Inheritance diagram for G4Radioactivation:
G4RadioactiveDecay G4VRestDiscreteProcess G4VProcess

Public Member Functions

void AddUserDecayDataFile (G4int Z, G4int A, G4String filename)
 
virtual G4VParticleChangeAlongStepDoIt (const G4Track &, const G4Step &)
 
virtual G4double AlongStepGetPhysicalInteractionLength (const G4Track &, G4double, G4double, G4double &, G4GPILSelection *)
 
G4double AlongStepGPIL (const G4Track &track, G4double previousStepSize, G4double currentMinimumStep, G4double &proposedSafety, G4GPILSelection *selection)
 
G4double AtRestGPIL (const G4Track &track, G4ForceCondition *condition)
 
void BuildPhysicsTable (const G4ParticleDefinition &)
 
virtual void BuildWorkerPhysicsTable (const G4ParticleDefinition &part)
 
void CalculateChainsFromParent (const G4ParticleDefinition &)
 
G4VParticleChangeDecayIt (const G4Track &theTrack, const G4Step &theStep)
 
void DeselectAllVolumes ()
 
void DeselectAVolume (const G4String &aVolume)
 
virtual void DumpInfo () const
 
virtual void EndTracking ()
 
 G4Radioactivation (const G4String &processName="Radioactivation")
 
void GetChainsFromParent (const G4ParticleDefinition &)
 
G4double GetCurrentInteractionLength () const
 
const G4ThreeVectorGetDecayDirection () const
 
G4double GetDecayHalfAngle () const
 
G4DecayTableGetDecayTable (const G4ParticleDefinition *)
 
G4DecayTableGetDecayTable1 (const G4ParticleDefinition *)
 
const G4VProcessGetMasterProcess () const
 
G4NucleusLimits GetNucleusLimits () const
 
G4double GetNumberOfInteractionLengthLeft () const
 
const G4StringGetPhysicsTableFileName (const G4ParticleDefinition *, const G4String &directory, const G4String &tableName, G4bool ascii=false)
 
G4double GetPILfactor () const
 
virtual const G4ProcessManagerGetProcessManager ()
 
const G4StringGetProcessName () const
 
G4int GetProcessSubType () const
 
G4ProcessType GetProcessType () const
 
G4int GetSplitNuclei ()
 
std::vector< G4RadioactivityTable * > GetTheRadioactivityTables ()
 
G4double GetThresholdForVeryLongDecayTime () const
 
G4double GetTotalNumberOfInteractionLengthTraversed () const
 
G4int GetVerboseLevel () const
 
G4bool isAlongStepDoItIsEnabled () const
 
G4bool IsAnalogueMonteCarlo ()
 
G4bool IsApplicable (const G4ParticleDefinition &)
 
G4bool isAtRestDoItIsEnabled () const
 
G4bool isPostStepDoItIsEnabled () const
 
G4bool IsRateTableReady (const G4ParticleDefinition &)
 
G4DecayTableLoadDecayTable (const G4ParticleDefinition &theParentNucleus)
 
G4bool operator!= (const G4VProcess &right) const
 
G4bool operator== (const G4VProcess &right) const
 
virtual G4double PostStepGetPhysicalInteractionLength (const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
 
G4double PostStepGPIL (const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
 
virtual void PreparePhysicsTable (const G4ParticleDefinition &)
 
virtual void PrepareWorkerPhysicsTable (const G4ParticleDefinition &)
 
virtual void ProcessDescription (std::ostream &outFile) const
 
virtual void ResetNumberOfInteractionLengthLeft ()
 
virtual G4bool RetrievePhysicsTable (const G4ParticleDefinition *, const G4String &, G4bool)
 
void SelectAllVolumes ()
 
void SelectAVolume (const G4String &aVolume)
 
void SetAnalogueMonteCarlo (G4bool r)
 
void SetARM (G4bool arm)
 
void SetBRBias (G4bool r)
 
void SetDecayBias (G4String filename)
 
void SetDecayCollimation (const G4ThreeVector &theDir, G4double halfAngle=0.*CLHEP::deg)
 
void SetDecayDirection (const G4ThreeVector &theDir)
 
void SetDecayHalfAngle (G4double halfAngle=0.*CLHEP::deg)
 
void SetDecayRate (G4int, G4int, G4double, G4int, std::vector< G4double >, std::vector< G4double >)
 
void SetHLThreshold (G4double hl)
 
void SetICM (G4bool icm)
 
virtual void SetMasterProcess (G4VProcess *masterP)
 
void SetNucleusLimits (G4NucleusLimits theNucleusLimits1)
 
void SetPILfactor (G4double value)
 
virtual void SetProcessManager (const G4ProcessManager *)
 
void SetProcessSubType (G4int)
 
void SetProcessType (G4ProcessType)
 
void SetSourceTimeProfile (G4String filename)
 
void SetSplitNuclei (G4int r)
 
void SetThresholdForVeryLongDecayTime (const G4double inputThreshold)
 
void SetVerboseLevel (G4int value)
 
virtual void StartTracking (G4Track *)
 
virtual G4bool StorePhysicsTable (const G4ParticleDefinition *, const G4String &, G4bool)
 
 ~G4Radioactivation ()
 

Static Public Member Functions

static const G4StringGetProcessTypeName (G4ProcessType)
 

Protected Member Functions

void AddDeexcitationSpectrumForBiasMode (G4ParticleDefinition *apartDef, G4double weight, G4double currenTime, std::vector< double > &weights_v, std::vector< double > &times_v, std::vector< G4DynamicParticle * > &secondaries_v)
 
G4ThreeVector ChooseCollimationDirection () const
 
void ClearNumberOfInteractionLengthLeft ()
 
void CollimateDecay (G4DecayProducts *products)
 
void CollimateDecayProduct (G4DynamicParticle *product)
 
G4double ConvolveSourceTimeProfile (const G4double, const G4double)
 
void DecayAnalog (const G4Track &theTrack)
 
G4DecayProductsDoDecay (const G4ParticleDefinition &theParticleDef)
 
G4double GetDecayTime ()
 
G4int GetDecayTimeBin (const G4double aDecayTime)
 
G4double GetMeanFreePath (const G4Track &theTrack, G4double previousStepSize, G4ForceCondition *condition)
 
G4double GetMeanLifeTime (const G4Track &theTrack, G4ForceCondition *condition)
 
void SubtractNumberOfInteractionLengthLeft (G4double prevStepSize)
 

Protected Attributes

G4ParticleChange aParticleChange
 
const G4ProcessManageraProcessManager = nullptr
 
G4double currentInteractionLength = -1.0
 
DecayTableMapdkmap
 
G4bool enableAlongStepDoIt = true
 
G4bool enableAtRestDoIt = true
 
G4bool enablePostStepDoIt = true
 
G4ParticleChangeForRadDecay fParticleChangeForRadDecay
 
bool isAllVolumesMode
 
G4PhotonEvaporationphotonEvaporation
 
G4VParticleChangepParticleChange = nullptr
 
G4double theInitialNumberOfInteractionLength = -1.0
 
G4double theNumberOfInteractionLengthLeft = -1.0
 
G4String thePhysicsTableFileName
 
G4double thePILfactor = 1.0
 
G4String theProcessName
 
G4int theProcessSubType = -1
 
G4ProcessType theProcessType = fNotDefined
 
G4RadioactivationMessengertheRadioactivationMessenger
 
G4RadioactiveDecayMessengertheRadioactiveDecayMessenger
 
std::vector< G4StringValidVolumes
 

Static Protected Attributes

static const G4double levelTolerance = 10.0*eV
 

Private Member Functions

G4VParticleChangeAtRestDoIt (const G4Track &theTrack, const G4Step &theStep)
 
G4double AtRestGetPhysicalInteractionLength (const G4Track &track, G4ForceCondition *condition)
 
G4VParticleChangePostStepDoIt (const G4Track &theTrack, const G4Step &theStep)
 
void StreamInfo (std::ostream &os, const G4String &endline)
 

Private Attributes

G4bool AnalogueMC
 
G4bool applyARM
 
G4bool applyICM
 
G4bool BRBias
 
G4RadioactiveDecayChainsFromParent chainsFromParent
 
G4double DBin [100]
 
G4int decayWindows [100]
 
G4String dirPath
 
G4double DProfile [100]
 
G4ThreeVector forceDecayDirection
 
G4double forceDecayHalfAngle
 
G4ProcessTablefProcessTable = nullptr
 
G4double fRemainderLifeTime
 
G4double fThresholdForVeryLongDecayTime
 
G4double halflifethreshold
 
G4bool isInitialised
 
G4VProcessmasterProcessShadow = nullptr
 
G4int NDecayBin
 
G4int NSourceBin
 
G4int NSplit
 
G4RadioactiveDecayRatesToDaughter ratesToDaughter
 
G4double SBin [100]
 
G4double SProfile [100]
 
G4RadioactiveDecayRates theDecayRateVector
 
G4NucleusLimits theNucleusLimits
 
G4RadioactiveDecayParentChainTable theParentChainTable
 
G4RadioactiveDecayMode theRadDecayMode
 
std::vector< G4RadioactivityTable * > theRadioactivityTables
 
std::map< G4int, G4StringtheUserRadioactiveDataFiles
 
G4int verboseLevel
 

Static Private Attributes

static const G4ThreeVector origin
 

Detailed Description

Definition at line 55 of file G4Radioactivation.hh.

Constructor & Destructor Documentation

◆ G4Radioactivation()

G4Radioactivation::G4Radioactivation ( const G4String processName = "Radioactivation")

Definition at line 93 of file G4Radioactivation.cc.

94 : G4RadioactiveDecay(processName)
95{
96#ifdef G4VERBOSE
97 if (GetVerboseLevel() > 1) {
98 G4cout << "G4Radioactivation constructor: processName = " << processName
99 << G4endl;
100 }
101#endif
102
103// DHW SetProcessSubType(fRadioactiveDecay);
105
106 // Apply default values.
107 NSourceBin = 1;
108 SBin[0] = 0.* s;
109 SBin[1] = 1.* s; // Convert to ns
110 SProfile[0] = 1.;
111 SProfile[1] = 0.;
112 NDecayBin = 1;
113 DBin[0] = 0. * s ;
114 DBin[1] = 1. * s;
115 DProfile[0] = 1.;
116 DProfile[1] = 0.;
117 decayWindows[0] = 0;
119 theRadioactivityTables.push_back(rTable);
120 NSplit = 1;
121 AnalogueMC = true;
122 BRBias = true;
124}
static constexpr double s
Definition: G4SIunits.hh:154
static constexpr double nanosecond
Definition: G4SIunits.hh:138
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
std::vector< G4RadioactivityTable * > theRadioactivityTables
G4double DProfile[100]
G4double SProfile[100]
G4RadioactivationMessenger * theRadioactivationMessenger
G4RadioactiveDecay(const G4String &processName="RadioactiveDecay")
G4int GetVerboseLevel() const

References AnalogueMC, BRBias, DBin, decayWindows, DProfile, G4cout, G4endl, G4RadioactiveDecay::GetVerboseLevel(), halflifethreshold, nanosecond, NDecayBin, NSourceBin, NSplit, s, SBin, SProfile, theRadioactivationMessenger, and theRadioactivityTables.

◆ ~G4Radioactivation()

G4Radioactivation::~G4Radioactivation ( )

Definition at line 139 of file G4Radioactivation.cc.

140{
142}

References theRadioactivationMessenger.

Member Function Documentation

◆ AddDeexcitationSpectrumForBiasMode()

void G4Radioactivation::AddDeexcitationSpectrumForBiasMode ( G4ParticleDefinition apartDef,
G4double  weight,
G4double  currenTime,
std::vector< double > &  weights_v,
std::vector< double > &  times_v,
std::vector< G4DynamicParticle * > &  secondaries_v 
)
protected

Definition at line 1123 of file G4Radioactivation.cc.

1128{
1129 G4double elevel=((const G4Ions*)(apartDef))->GetExcitationEnergy();
1130 G4double life_time=apartDef->GetPDGLifeTime();
1131 G4ITDecay* anITChannel = 0;
1132
1133 while (life_time < halflifethreshold && elevel > 0.) {
1134 anITChannel = new G4ITDecay(apartDef, 100., elevel, elevel, photonEvaporation);
1135 G4DecayProducts* pevap_products = anITChannel->DecayIt(0.);
1136 G4int nb_pevapSecondaries = pevap_products->entries();
1137
1138 G4DynamicParticle* a_pevap_secondary = 0;
1139 G4ParticleDefinition* secDef = 0;
1140 for (G4int ind = 0; ind < nb_pevapSecondaries; ind++) {
1141 a_pevap_secondary= pevap_products->PopProducts();
1142 secDef = a_pevap_secondary->GetDefinition();
1143
1144 if (secDef->GetBaryonNumber() > 4) {
1145 elevel = ((const G4Ions*)(secDef))->GetExcitationEnergy();
1146 life_time = secDef->GetPDGLifeTime();
1147 apartDef = secDef;
1148 if (secDef->GetPDGStable() ) {
1149 weights_v.push_back(weight);
1150 times_v.push_back(currentTime);
1151 secondaries_v.push_back(a_pevap_secondary);
1152 }
1153 } else {
1154 weights_v.push_back(weight);
1155 times_v.push_back(currentTime);
1156 secondaries_v.push_back(a_pevap_secondary);
1157 }
1158 }
1159
1160 delete anITChannel;
1161 delete pevap_products;
1162 }
1163}
double G4double
Definition: G4Types.hh:83
int G4int
Definition: G4Types.hh:85
G4int entries() const
G4DynamicParticle * PopProducts()
G4ParticleDefinition * GetDefinition() const
virtual G4DecayProducts * DecayIt(G4double)
Definition: G4ITDecay.cc:73
Definition: G4Ions.hh:52
G4bool GetPDGStable() const
G4double GetPDGLifeTime() const
G4PhotonEvaporation * photonEvaporation

References G4ITDecay::DecayIt(), G4DecayProducts::entries(), G4ParticleDefinition::GetBaryonNumber(), G4DynamicParticle::GetDefinition(), G4ParticleDefinition::GetPDGLifeTime(), G4ParticleDefinition::GetPDGStable(), G4RadioactiveDecay::photonEvaporation, and G4DecayProducts::PopProducts().

Referenced by DecayIt().

◆ AddUserDecayDataFile()

void G4RadioactiveDecay::AddUserDecayDataFile ( G4int  Z,
G4int  A,
G4String  filename 
)
inherited

Definition at line 911 of file G4RadioactiveDecay.cc.

912{
913 if (Z < 1 || A < 2) G4cout << "Z and A not valid!" << G4endl;
914
915 std::ifstream DecaySchemeFile(filename);
916 if (DecaySchemeFile) {
917 G4int ID_ion = A*1000 + Z;
918 theUserRadioactiveDataFiles[ID_ion] = filename;
919 } else {
921 ed << filename << " does not exist! " << G4endl;
922 G4Exception("G4RadioactiveDecay::AddUserDecayDataFile()", "HAD_RDM_001",
923 FatalException, ed);
924 }
925}
@ FatalException
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35
std::ostringstream G4ExceptionDescription
Definition: G4Exception.hh:40
const G4int Z[17]
const G4double A[17]
std::map< G4int, G4String > theUserRadioactiveDataFiles

References A, FatalException, G4cout, G4endl, G4Exception(), G4RadioactiveDecay::theUserRadioactiveDataFiles, and Z.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ AlongStepDoIt()

virtual G4VParticleChange * G4VRestDiscreteProcess::AlongStepDoIt ( const G4Track ,
const G4Step  
)
inlinevirtualinherited

Implements G4VProcess.

Definition at line 87 of file G4VRestDiscreteProcess.hh.

90 { return 0; }

◆ AlongStepGetPhysicalInteractionLength()

virtual G4double G4VRestDiscreteProcess::AlongStepGetPhysicalInteractionLength ( const G4Track ,
G4double  ,
G4double  ,
G4double ,
G4GPILSelection  
)
inlinevirtualinherited

Implements G4VProcess.

Definition at line 78 of file G4VRestDiscreteProcess.hh.

84 { return -1.0; }

◆ AlongStepGPIL()

G4double G4VProcess::AlongStepGPIL ( const G4Track track,
G4double  previousStepSize,
G4double  currentMinimumStep,
G4double proposedSafety,
G4GPILSelection selection 
)
inlineinherited

Definition at line 461 of file G4VProcess.hh.

466{
467 return AlongStepGetPhysicalInteractionLength(track, previousStepSize,
468 currentMinimumStep, proposedSafety, selection);
469}
virtual G4double AlongStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4double currentMinimumStep, G4double &proposedSafety, G4GPILSelection *selection)=0

References G4VProcess::AlongStepGetPhysicalInteractionLength().

Referenced by G4SteppingManager::DefinePhysicalStepLength(), and G4ITStepProcessor::DoDefinePhysicalStepLength().

◆ AtRestDoIt()

G4VParticleChange * G4Radioactivation::AtRestDoIt ( const G4Track theTrack,
const G4Step theStep 
)
inlineprivatevirtual

Reimplemented from G4VRestDiscreteProcess.

Definition at line 177 of file G4Radioactivation.hh.

178 {return DecayIt(theTrack, theStep);}
G4VParticleChange * DecayIt(const G4Track &theTrack, const G4Step &theStep)

References DecayIt().

◆ AtRestGetPhysicalInteractionLength()

G4double G4RadioactiveDecay::AtRestGetPhysicalInteractionLength ( const G4Track track,
G4ForceCondition condition 
)
inlineprivatevirtualinherited

Reimplemented from G4VRestDiscreteProcess.

Definition at line 240 of file G4RadioactiveDecay.hh.

242 {
245 return fRemainderLifeTime;
246 }
G4double condition(const G4ErrorSymMatrix &m)
virtual G4double AtRestGetPhysicalInteractionLength(const G4Track &, G4ForceCondition *)

References G4VRestDiscreteProcess::AtRestGetPhysicalInteractionLength(), condition(), and G4RadioactiveDecay::fRemainderLifeTime.

◆ AtRestGPIL()

G4double G4VProcess::AtRestGPIL ( const G4Track track,
G4ForceCondition condition 
)
inlineinherited

Definition at line 472 of file G4VProcess.hh.

474{
476}
G4double thePILfactor
Definition: G4VProcess.hh:352
virtual G4double AtRestGetPhysicalInteractionLength(const G4Track &track, G4ForceCondition *condition)=0

References G4VProcess::AtRestGetPhysicalInteractionLength(), condition(), and G4VProcess::thePILfactor.

Referenced by G4ITStepProcessor::GetAtRestIL(), and G4SteppingManager::InvokeAtRestDoItProcs().

◆ BuildPhysicsTable()

void G4RadioactiveDecay::BuildPhysicsTable ( const G4ParticleDefinition )
virtualinherited

Reimplemented from G4VProcess.

Definition at line 448 of file G4RadioactiveDecay.cc.

449{
450 if (!isInitialised) {
451 isInitialised = true;
452#ifdef G4VERBOSE
455#endif
456 }
459}
static G4GenericIon * GenericIon()
Definition: G4GenericIon.cc:92
static G4HadronicParameters * Instance()
void RegisterParticleForExtraProcess(G4VProcess *, const G4ParticleDefinition *)
static G4HadronicProcessStore * Instance()
void StreamInfo(std::ostream &os, const G4String &endline)
G4bool IsMasterThread()
Definition: G4Threading.cc:124

References G4cout, G4GenericIon::GenericIon(), G4RadioactiveDecay::GetVerboseLevel(), G4HadronicProcessStore::Instance(), G4HadronicParameters::Instance(), G4RadioactiveDecay::isInitialised, G4Threading::IsMasterThread(), G4HadronicProcessStore::RegisterParticleForExtraProcess(), and G4RadioactiveDecay::StreamInfo().

◆ BuildWorkerPhysicsTable()

void G4VProcess::BuildWorkerPhysicsTable ( const G4ParticleDefinition part)
virtualinherited

Reimplemented in G4BiasingProcessInterface.

Definition at line 200 of file G4VProcess.cc.

201{
202 BuildPhysicsTable(part);
203}
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
Definition: G4VProcess.hh:187

References G4VProcess::BuildPhysicsTable().

Referenced by G4BiasingProcessInterface::BuildWorkerPhysicsTable().

◆ CalculateChainsFromParent()

void G4Radioactivation::CalculateChainsFromParent ( const G4ParticleDefinition theParentNucleus)

Definition at line 341 of file G4Radioactivation.cc.

343{
344 // Use extended Bateman equation to calculate the radioactivities of all
345 // progeny of theParentNucleus. The coefficients required to do this are
346 // calculated using the method of P. Truscott (Ph.D. thesis and
347 // DERA Technical Note DERA/CIS/CIS2/7/36/4/10) 11 January 2000.
348 // Coefficients are then added to the decay rate table vector
349
350 // Create and initialise variables used in the method.
351 theDecayRateVector.clear();
352
353 G4int nGeneration = 0;
354
355 std::vector<G4double> taos;
356
357 // Dimensionless A coefficients of Eqs. 4.24 and 4.25 of the TN
358 std::vector<G4double> Acoeffs;
359
360 // According to Eq. 4.26 the first coefficient (A_1:1) is -1
361 Acoeffs.push_back(-1.);
362
363 G4int A = ((const G4Ions*)(&theParentNucleus))->GetAtomicMass();
364 G4int Z = ((const G4Ions*)(&theParentNucleus))->GetAtomicNumber();
365 G4double E = ((const G4Ions*)(&theParentNucleus))->GetExcitationEnergy();
366 G4double tao = theParentNucleus.GetPDGLifeTime();
367 if (tao < 0.) tao = 1e-100;
368 taos.push_back(tao);
369 G4int nEntry = 0;
370
371 // Fill the decay rate container (G4RadioactiveDecayRate) with the parent
372 // isotope data
373 SetDecayRate(Z,A,E,nGeneration,Acoeffs,taos); // Fill TP with parent lifetime
374
375 // store the decay rate in decay rate vector
377 nEntry++;
378
379 // Now start treating the secondary generations.
380 G4bool stable = false;
381// G4int i;
382 G4int j;
383 G4VDecayChannel* theChannel = 0;
384 G4NuclearDecay* theNuclearDecayChannel = 0;
385
386 G4ITDecay* theITChannel = 0;
387 G4BetaMinusDecay* theBetaMinusChannel = 0;
388 G4BetaPlusDecay* theBetaPlusChannel = 0;
389 G4AlphaDecay* theAlphaChannel = 0;
390 G4ProtonDecay* theProtonChannel = 0;
391 G4TritonDecay* theTritonChannel = 0;
392 G4NeutronDecay* theNeutronChannel = 0;
393 G4SFDecay* theFissionChannel = 0;
394
395 G4RadioactiveDecayMode theDecayMode;
396 G4double theBR = 0.0;
397 G4int AP = 0;
398 G4int ZP = 0;
399 G4int AD = 0;
400 G4int ZD = 0;
401 G4double EP = 0.;
402 std::vector<G4double> TP;
403 std::vector<G4double> RP; // A coefficients of the previous generation
404 G4ParticleDefinition *theDaughterNucleus;
405 G4double daughterExcitation;
406 G4double nearestEnergy = 0.0;
407 G4int nearestLevelIndex = 0;
408 G4ParticleDefinition *aParentNucleus;
409 G4IonTable* theIonTable;
410 G4DecayTable* parentDecayTable;
411 G4double theRate;
412 G4double TaoPlus;
413 G4int nS = 0; // Running index of first decay in a given generation
414 G4int nT = nEntry; // Total number of decays accumulated over entire history
415 const G4int nMode = G4RadioactiveDecayModeSize;
416 G4double brs[nMode];
417 //
418 theIonTable =
420
421 G4int loop = 0;
422 while (!stable) { /* Loop checking, 01.09.2015, D.Wright */
423 loop++;
424 if (loop > 10000) {
425 G4Exception("G4Radioactivation::CalculateChainsFromParent()", "HAD_RDM_100",
426 JustWarning, "While loop count exceeded");
427 break;
428 }
429 nGeneration++;
430 for (j = nS; j < nT; j++) {
431 // First time through, get data for parent nuclide
432 ZP = theDecayRateVector[j].GetZ();
433 AP = theDecayRateVector[j].GetA();
434 EP = theDecayRateVector[j].GetE();
435 RP = theDecayRateVector[j].GetDecayRateC();
436 TP = theDecayRateVector[j].GetTaos();
437 if (GetVerboseLevel() > 1) {
438 G4cout << "G4RadioactiveDecay::CalculateChainsFromParent: daughters of ("
439 << ZP << ", " << AP << ", " << EP
440 << ") are being calculated, generation = " << nGeneration
441 << G4endl;
442 }
443// G4cout << " Taus = " << G4endl;
444// for (G4int ii = 0; ii < TP.size(); ii++) G4cout << TP[ii] << ", " ;
445// G4cout << G4endl;
446
447 aParentNucleus = theIonTable->GetIon(ZP,AP,EP);
448 parentDecayTable = GetDecayTable1(aParentNucleus);
449
450 G4DecayTable* summedDecayTable = new G4DecayTable();
451 // This instance of G4DecayTable is for accumulating BRs and decay
452 // channels. It will contain one decay channel per type of decay
453 // (alpha, beta, etc.); its branching ratio will be the sum of all
454 // branching ratios for that type of decay of the parent. If the
455 // halflife of a particular channel is longer than some threshold,
456 // that channel will be inserted specifically and its branching
457 // ratio will not be included in the above sums.
458 // This instance is not used to perform actual decays.
459
460 for (G4int k = 0; k < nMode; k++) brs[k] = 0.0;
461
462 // Go through the decay table and sum all channels having the same decay mode
463 for (G4int i = 0; i < parentDecayTable->entries(); i++) {
464 theChannel = parentDecayTable->GetDecayChannel(i);
465 theNuclearDecayChannel = static_cast<G4NuclearDecay*>(theChannel);
466 theDecayMode = theNuclearDecayChannel->GetDecayMode();
467 daughterExcitation = theNuclearDecayChannel->GetDaughterExcitation();
468 theDaughterNucleus = theNuclearDecayChannel->GetDaughterNucleus() ;
469 AD = ((const G4Ions*)(theDaughterNucleus))->GetAtomicMass();
470 ZD = ((const G4Ions*)(theDaughterNucleus))->GetAtomicNumber();
471 const G4LevelManager* levelManager =
473
474 // Check each nuclide to see if it is metastable (lifetime > 1 usec)
475 // If so, add it to the decay chain by inserting its decay channel in
476 // summedDecayTable. If not, just add its BR to sum for that decay mode.
477 if (levelManager->NumberOfTransitions() ) {
478 nearestEnergy = levelManager->NearestLevelEnergy(daughterExcitation);
479 if (std::abs(daughterExcitation - nearestEnergy) < levelTolerance) {
480 // Level half-life is in ns and the threshold is set to 1 micros
481 // by default, user can set it via the UI command
482 nearestLevelIndex = levelManager->NearestLevelIndex(daughterExcitation);
483 if (levelManager->LifeTime(nearestLevelIndex)*ns >= halflifethreshold){
484 // save the metastable decay channel
485 summedDecayTable->Insert(theChannel);
486 } else {
487 brs[theDecayMode] += theChannel->GetBR();
488 }
489 } else {
490 brs[theDecayMode] += theChannel->GetBR();
491 }
492 } else {
493 brs[theDecayMode] += theChannel->GetBR();
494 }
495
496 } // Combine decay channels (loop i)
497
498 brs[BetaPlus] = brs[BetaPlus]+brs[KshellEC]+brs[LshellEC]+brs[MshellEC]+brs[NshellEC]; // Combine beta+ and EC
499 brs[KshellEC] = brs[LshellEC] = brs[MshellEC] = brs[NshellEC] = 0.0;
500 for (G4int i = 0; i < nMode; i++) { // loop over decay modes
501 if (brs[i] > 0.) {
502 switch (i) {
503 case IT:
504 // Decay mode is isomeric transition
505 theITChannel = new G4ITDecay(aParentNucleus, brs[IT], 0.0, 0.0,
507
508 summedDecayTable->Insert(theITChannel);
509 break;
510
511 case BetaMinus:
512 // Decay mode is beta-
513 theBetaMinusChannel = new G4BetaMinusDecay(aParentNucleus, brs[BetaMinus],
514 0.*MeV, 0.*MeV,
516 summedDecayTable->Insert(theBetaMinusChannel);
517 break;
518
519 case BetaPlus:
520 // Decay mode is beta+ + EC.
521 theBetaPlusChannel = new G4BetaPlusDecay(aParentNucleus, brs[BetaPlus],
522 0.*MeV, 0.*MeV,
524 summedDecayTable->Insert(theBetaPlusChannel);
525 break;
526
527 case Alpha:
528 // Decay mode is alpha.
529 theAlphaChannel = new G4AlphaDecay(aParentNucleus, brs[Alpha], 0.*MeV,
530 0.*MeV, noFloat);
531 summedDecayTable->Insert(theAlphaChannel);
532 break;
533
534 case Proton:
535 // Decay mode is proton.
536 theProtonChannel = new G4ProtonDecay(aParentNucleus, brs[Proton], 0.*MeV,
537 0.*MeV, noFloat);
538 summedDecayTable->Insert(theProtonChannel);
539 break;
540
541 case Neutron:
542 // Decay mode is neutron.
543 theNeutronChannel = new G4NeutronDecay(aParentNucleus, brs[Neutron], 0.*MeV,
544 0.*MeV, noFloat);
545 summedDecayTable->Insert(theNeutronChannel);
546 break;
547
548 case SpFission:
549 // Decay mode is spontaneous fission
550 theFissionChannel = new G4SFDecay(aParentNucleus, brs[SpFission], 0.*MeV,
551 0.*MeV, noFloat);
552 summedDecayTable->Insert(theFissionChannel);
553 break;
554
555 case BDProton:
556 // Not yet implemented
557 break;
558
559 case BDNeutron:
560 // Not yet implemented
561 break;
562
563 case Beta2Minus:
564 // Not yet implemented
565 break;
566
567 case Beta2Plus:
568 // Not yet implemented
569 break;
570
571 case Proton2:
572 // Not yet implemented
573 break;
574
575 case Neutron2:
576 // Not yet implemented
577 break;
578
579 case Triton:
580 // Decay mode is Triton.
581 theTritonChannel = new G4TritonDecay(aParentNucleus, brs[Triton], 0.*MeV,
582 0.*MeV, noFloat);
583 summedDecayTable->Insert(theTritonChannel);
584 break;
585
586 default:
587 break;
588 }
589 }
590 }
591
592 // loop over all branches in summedDecayTable
593 //
594 for (G4int i = 0; i < summedDecayTable->entries(); i++){
595 theChannel = summedDecayTable->GetDecayChannel(i);
596 theNuclearDecayChannel = static_cast<G4NuclearDecay*>(theChannel);
597 theBR = theChannel->GetBR();
598 theDaughterNucleus = theNuclearDecayChannel->GetDaughterNucleus();
599
600 // First check if the decay of the original nucleus is an IT channel,
601 // if true create a new ground-state nucleus
602 if (theNuclearDecayChannel->GetDecayMode() == IT && nGeneration == 1) {
603
604 A = ((const G4Ions*)(theDaughterNucleus))->GetAtomicMass();
605 Z = ((const G4Ions*)(theDaughterNucleus))->GetAtomicNumber();
606 theDaughterNucleus=theIonTable->GetIon(Z,A,0.);
607 }
608 if (IsApplicable(*theDaughterNucleus) && theBR > 0.0 &&
609 aParentNucleus != theDaughterNucleus) {
610 // need to make sure daughter has decay table
611 parentDecayTable = GetDecayTable1(theDaughterNucleus);
612 if (parentDecayTable->entries() ) {
613 A = ((const G4Ions*)(theDaughterNucleus))->GetAtomicMass();
614 Z = ((const G4Ions*)(theDaughterNucleus))->GetAtomicNumber();
615 E = ((const G4Ions*)(theDaughterNucleus))->GetExcitationEnergy();
616
617 TaoPlus = theDaughterNucleus->GetPDGLifeTime();
618 if (TaoPlus <= 0.) TaoPlus = 1e-100;
619
620 // first set the taos, one simply need to add to the parent ones
621 taos.clear();
622 taos = TP; // load lifetimes of all previous generations
623 size_t k;
624 //check that TaoPlus differs from other taos from at least 1.e5 relative difference
625 //for (k = 0; k < TP.size(); k++){
626 //if (std::abs((TaoPlus-TP[k])/TP[k])<1.e-5 ) TaoPlus=1.00001*TP[k];
627 //}
628 taos.push_back(TaoPlus); // add daughter lifetime to list
629 // now calculate the coefficiencies
630 //
631 // they are in two parts, first the less than n ones
632 // Eq 4.24 of the TN
633 Acoeffs.clear();
634 long double ta1,ta2;
635 ta2 = (long double)TaoPlus;
636 for (k = 0; k < RP.size(); k++){
637 ta1 = (long double)TP[k]; // loop over lifetimes of all previous generations
638 if (ta1 == ta2) {
639 theRate = 1.e100;
640 } else {
641 theRate = ta1/(ta1-ta2);
642 }
643 theRate = theRate * theBR * RP[k];
644 Acoeffs.push_back(theRate);
645 }
646
647 // the second part: the n:n coefficiency
648 // Eq 4.25 of the TN. Note Yn+1 is zero apart from Y1 which is -1
649 // as treated at line 1013
650 theRate = 0.;
651 long double aRate, aRate1;
652 aRate1 = 0.L;
653 for (k = 0; k < RP.size(); k++){
654 ta1 = (long double)TP[k];
655 if (ta1 == ta2 ) {
656 aRate = 1.e100;
657 } else {
658 aRate = ta2/(ta1-ta2);
659 }
660 aRate = aRate * (long double)(theBR * RP[k]);
661 aRate1 += aRate;
662 }
663 theRate = -aRate1;
664 Acoeffs.push_back(theRate);
665 SetDecayRate (Z,A,E,nGeneration,Acoeffs,taos);
667 nEntry++;
668 } // there are entries in the table
669 } // nuclide is OK to decay
670 } // end of loop (i) over decay table branches
671
672 delete summedDecayTable;
673
674 } // Getting contents of decay rate vector (end loop on j)
675 nS = nT;
676 nT = nEntry;
677 if (nS == nT) stable = true;
678 } // while nuclide is not stable
679
680 // end of while loop
681 // the calculation completed here
682
683
684 // fill the first part of the decay rate table
685 // which is the name of the original particle (isotope)
686 chainsFromParent.SetIonName(theParentNucleus.GetParticleName());
687
688 // now fill the decay table with the newly completed decay rate vector
690
691 // finally add the decayratetable to the tablevector
693}
@ allowed
@ JustWarning
#define noFloat
Definition: G4Ions.hh:112
G4RadioactiveDecayMode
@ G4RadioactiveDecayModeSize
static constexpr double MeV
Definition: G4SIunits.hh:200
bool G4bool
Definition: G4Types.hh:86
G4VDecayChannel * GetDecayChannel(G4int index) const
void Insert(G4VDecayChannel *aChannel)
Definition: G4DecayTable.cc:53
G4int entries() const
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
Definition: G4IonTable.cc:522
G4double LifeTime(size_t i) const
size_t NearestLevelIndex(G4double energy, size_t index=0) const
G4double NearestLevelEnergy(G4double energy, size_t index=0) const
size_t NumberOfTransitions() const
G4double GetDaughterExcitation()
G4ParticleDefinition * GetDaughterNucleus()
G4RadioactiveDecayMode GetDecayMode()
const G4LevelManager * GetLevelManager(G4int Z, G4int A)
static G4NuclearLevelData * GetInstance()
const G4String & GetParticleName() const
G4IonTable * GetIonTable() const
static G4ParticleTable * GetParticleTable()
G4RadioactiveDecayRates theDecayRateVector
G4RadioactiveDecayRatesToDaughter ratesToDaughter
G4RadioactiveDecayChainsFromParent chainsFromParent
G4RadioactiveDecayParentChainTable theParentChainTable
void SetDecayRate(G4int, G4int, G4double, G4int, std::vector< G4double >, std::vector< G4double >)
G4DecayTable * GetDecayTable1(const G4ParticleDefinition *)
void SetItsRates(G4RadioactiveDecayRates arate)
static const G4double levelTolerance
G4bool IsApplicable(const G4ParticleDefinition &)
G4double GetBR() const
static const G4double AP[5]
Definition: paraMaker.cc:42
#define ns
Definition: xmlparse.cc:614

References A, allowed, Alpha, anonymous_namespace{paraMaker.cc}::AP, BDNeutron, BDProton, Beta2Minus, Beta2Plus, BetaMinus, BetaPlus, chainsFromParent, G4DecayTable::entries(), G4cout, G4endl, G4Exception(), G4RadioactiveDecayModeSize, G4VDecayChannel::GetBR(), G4NuclearDecay::GetDaughterExcitation(), G4NuclearDecay::GetDaughterNucleus(), G4DecayTable::GetDecayChannel(), G4NuclearDecay::GetDecayMode(), GetDecayTable1(), G4NuclearLevelData::GetInstance(), G4IonTable::GetIon(), G4ParticleTable::GetIonTable(), G4NuclearLevelData::GetLevelManager(), G4ParticleDefinition::GetParticleName(), G4ParticleTable::GetParticleTable(), G4ParticleDefinition::GetPDGLifeTime(), G4RadioactiveDecay::GetVerboseLevel(), halflifethreshold, G4DecayTable::Insert(), G4RadioactiveDecay::IsApplicable(), IT, JustWarning, KshellEC, G4RadioactiveDecay::levelTolerance, G4LevelManager::LifeTime(), LshellEC, MeV, MshellEC, G4LevelManager::NearestLevelEnergy(), G4LevelManager::NearestLevelIndex(), Neutron, Neutron2, noFloat, ns, NshellEC, G4LevelManager::NumberOfTransitions(), G4RadioactiveDecay::photonEvaporation, Proton, Proton2, ratesToDaughter, SetDecayRate(), G4RadioactiveDecayChainsFromParent::SetIonName(), G4RadioactiveDecayChainsFromParent::SetItsRates(), SpFission, theDecayRateVector, theParentChainTable, Triton, and Z.

Referenced by DecayIt().

◆ ChooseCollimationDirection()

G4ThreeVector G4RadioactiveDecay::ChooseCollimationDirection ( ) const
protectedinherited

Definition at line 1306 of file G4RadioactiveDecay.cc.

1306 {
1307 if (origin == forceDecayDirection) return origin; // Don't do collimation
1308 if (forceDecayHalfAngle == 180.*deg) return origin;
1309
1311
1312 // Return direction offset by random throw
1313 if (forceDecayHalfAngle > 0.) {
1314 // Generate uniform direction around central axis
1315 G4double phi = 2.*pi*G4UniformRand();
1316 G4double cosMin = std::cos(forceDecayHalfAngle);
1317 G4double cosTheta = (1.-cosMin)*G4UniformRand() + cosMin; // [cosMin,1.)
1318
1319 dir.setPhi(dir.phi()+phi);
1320 dir.setTheta(dir.theta()+std::acos(cosTheta));
1321 }
1322
1323#ifdef G4VERBOSE
1324 if (GetVerboseLevel()>1)
1325 G4cout << " ChooseCollimationDirection returns " << dir << G4endl;
1326#endif
1327
1328 return dir;
1329}
static constexpr double pi
Definition: G4SIunits.hh:55
static constexpr double deg
Definition: G4SIunits.hh:132
#define G4UniformRand()
Definition: Randomize.hh:52
double phi() const
double theta() const
void setTheta(double)
void setPhi(double)
static const G4ThreeVector origin
G4ThreeVector forceDecayDirection

References deg, G4RadioactiveDecay::forceDecayDirection, G4RadioactiveDecay::forceDecayHalfAngle, G4cout, G4endl, G4UniformRand, G4RadioactiveDecay::GetVerboseLevel(), G4RadioactiveDecay::origin, CLHEP::Hep3Vector::phi(), pi, CLHEP::Hep3Vector::setPhi(), CLHEP::Hep3Vector::setTheta(), and CLHEP::Hep3Vector::theta().

Referenced by G4RadioactiveDecay::CollimateDecayProduct().

◆ ClearNumberOfInteractionLengthLeft()

void G4VProcess::ClearNumberOfInteractionLengthLeft ( )
inlineprotectedinherited

◆ CollimateDecay()

void G4RadioactiveDecay::CollimateDecay ( G4DecayProducts products)
protectedinherited

Definition at line 1261 of file G4RadioactiveDecay.cc.

1261 {
1262
1263 if (origin == forceDecayDirection) return; // No collimation requested
1264 if (180.*deg == forceDecayHalfAngle) return;
1265 if (0 == products || 0 == products->entries()) return;
1266
1267#ifdef G4VERBOSE
1268 if (GetVerboseLevel() > 1) G4cout << "Begin of CollimateDecay..." << G4endl;
1269#endif
1270
1271 // Particles suitable for directional biasing (for if-blocks below)
1275 static const G4ParticleDefinition* gamma = G4Gamma::Definition();
1279
1280 G4ThreeVector newDirection; // Re-use to avoid memory churn
1281 for (G4int i=0; i<products->entries(); i++) {
1282 G4DynamicParticle* daughter = (*products)[i];
1283 const G4ParticleDefinition* daughterType =
1284 daughter->GetParticleDefinition();
1285 if (daughterType == electron || daughterType == positron ||
1286 daughterType == neutron || daughterType == gamma ||
1287 daughterType == alpha || daughterType == triton || daughterType == proton) CollimateDecayProduct(daughter);
1288 }
1289}
static const G4double alpha
static G4Alpha * Definition()
Definition: G4Alpha.cc:48
const G4ParticleDefinition * GetParticleDefinition() const
static G4Electron * Definition()
Definition: G4Electron.cc:48
static G4Gamma * Definition()
Definition: G4Gamma.cc:48
static G4Neutron * Definition()
Definition: G4Neutron.cc:53
static G4Positron * Definition()
Definition: G4Positron.cc:48
static G4Proton * Definition()
Definition: G4Proton.cc:48
void CollimateDecayProduct(G4DynamicParticle *product)
static G4Triton * Definition()
Definition: G4Triton.cc:49

References alpha, G4RadioactiveDecay::CollimateDecayProduct(), G4Gamma::Definition(), G4Neutron::Definition(), G4Proton::Definition(), G4Alpha::Definition(), G4Triton::Definition(), G4Electron::Definition(), G4Positron::Definition(), deg, G4InuclParticleNames::electron, G4DecayProducts::entries(), G4RadioactiveDecay::forceDecayDirection, G4RadioactiveDecay::forceDecayHalfAngle, G4cout, G4endl, G4DynamicParticle::GetParticleDefinition(), G4RadioactiveDecay::GetVerboseLevel(), G4InuclParticleNames::neutron, G4RadioactiveDecay::origin, G4InuclParticleNames::positron, G4InuclParticleNames::proton, and G4InuclParticleNames::triton.

Referenced by G4RadioactiveDecay::DoDecay().

◆ CollimateDecayProduct()

void G4RadioactiveDecay::CollimateDecayProduct ( G4DynamicParticle product)
protectedinherited

Definition at line 1291 of file G4RadioactiveDecay.cc.

1291 {
1292#ifdef G4VERBOSE
1293 if (GetVerboseLevel() > 1) {
1294 G4cout << "CollimateDecayProduct for daughter "
1295 << daughter->GetParticleDefinition()->GetParticleName() << G4endl;
1296 }
1297#endif
1298
1300 if (origin != collimate) daughter->SetMomentumDirection(collimate);
1301}
G4ThreeVector ChooseCollimationDirection() const

References G4RadioactiveDecay::ChooseCollimationDirection(), G4cout, G4endl, G4DynamicParticle::GetParticleDefinition(), G4ParticleDefinition::GetParticleName(), G4RadioactiveDecay::GetVerboseLevel(), G4RadioactiveDecay::origin, and G4DynamicParticle::SetMomentumDirection().

Referenced by G4RadioactiveDecay::CollimateDecay().

◆ ConvolveSourceTimeProfile()

G4double G4Radioactivation::ConvolveSourceTimeProfile ( const G4double  t,
const G4double  tau 
)
protected

Definition at line 198 of file G4Radioactivation.cc.

199{
200 G4double convolvedTime = 0.0;
201 G4int nbin;
202 if ( t > SBin[NSourceBin]) {
203 nbin = NSourceBin;
204 } else {
205 nbin = 0;
206
207 G4int loop = 0;
208 while (t > SBin[nbin]) { // Loop checking, 01.09.2015, D.Wright
209 loop++;
210 if (loop > 1000) {
211 G4Exception("G4Radioactivation::ConvolveSourceTimeProfile()",
212 "HAD_RDM_100", JustWarning, "While loop count exceeded");
213 break;
214 }
215 nbin++;
216 }
217 nbin--;
218 }
219
220 // Use expm1 wherever possible to avoid large cancellation errors in
221 // 1 - exp(x) for small x
222 G4double earg = 0.0;
223 if (nbin > 0) {
224 for (G4int i = 0; i < nbin; i++) {
225 earg = (SBin[i+1] - SBin[i])/tau;
226 if (earg < 100.) {
227 convolvedTime += SProfile[i] * std::exp((SBin[i] - t)/tau) *
228 std::expm1(earg);
229 } else {
230 convolvedTime += SProfile[i] *
231 (std::exp(-(t-SBin[i+1])/tau)-std::exp(-(t-SBin[i])/tau));
232 }
233 }
234 }
235 convolvedTime -= SProfile[nbin] * std::expm1((SBin[nbin] - t)/tau);
236 // tau divided out of final result to provide probability of decay in window
237
238 if (convolvedTime < 0.) {
239 G4cout << " Convolved time =: " << convolvedTime << " reset to zero! " << G4endl;
240 G4cout << " t = " << t << " tau = " << tau << G4endl;
241 G4cout << SBin[nbin] << " " << SBin[0] << G4endl;
242 convolvedTime = 0.;
243 }
244#ifdef G4VERBOSE
245 if (GetVerboseLevel() > 2)
246 G4cout << " Convolved time: " << convolvedTime << G4endl;
247#endif
248 return convolvedTime;
249}

References G4cout, G4endl, G4Exception(), G4RadioactiveDecay::GetVerboseLevel(), JustWarning, NSourceBin, SBin, and SProfile.

Referenced by DecayIt().

◆ DecayAnalog()

void G4RadioactiveDecay::DecayAnalog ( const G4Track theTrack)
protectedinherited

Definition at line 1101 of file G4RadioactiveDecay.cc.

1102{
1103 const G4DynamicParticle* theParticle = theTrack.GetDynamicParticle();
1104 const G4ParticleDefinition* theParticleDef = theParticle->GetDefinition();
1105 G4DecayProducts* products = DoDecay(*theParticleDef);
1106
1107 // Check if the product is the same as input and kill the track if
1108 // necessary to prevent infinite loop (11/05/10, F.Lei)
1109 if (products->entries() == 1) {
1114 delete products;
1115 return;
1116 }
1117
1118 G4double energyDeposit = 0.0;
1119 G4double finalGlobalTime = theTrack.GetGlobalTime();
1120 G4double finalLocalTime = theTrack.GetLocalTime();
1121
1122 // Get parent particle information and boost the decay products to the
1123 // laboratory frame
1124
1125 // ParentEnergy used for the boost should be the total energy of the nucleus
1126 // of the parent ion without the energy of the shell electrons
1127 // (correction for bug 1359 by L. Desorgher)
1128 G4double ParentEnergy = theParticle->GetKineticEnergy()
1129 + theParticle->GetParticleDefinition()->GetPDGMass();
1130 G4ThreeVector ParentDirection(theParticle->GetMomentumDirection());
1131
1132 if (theTrack.GetTrackStatus() == fStopButAlive) {
1133 // this condition seems to be always True, further investigation is needed (L.Desorgher)
1134
1135 // The particle is decayed at rest
1136 // Since the time is for the particle at rest, need to add additional time
1137 // lapsed between particle coming to rest and the actual decay. This time
1138 // is sampled with the mean-life of the particle. Need to protect the case
1139 // PDGTime < 0. (F.Lei 11/05/10)
1140 G4double temptime = -std::log(G4UniformRand() ) *
1141 theParticleDef->GetPDGLifeTime();
1142 if (temptime < 0.) temptime = 0.;
1143 finalGlobalTime += temptime;
1144 finalLocalTime += temptime;
1145 energyDeposit += theParticle->GetKineticEnergy();
1146
1147 // Kill the parent particle, and ignore its decay, if it decays later than the
1148 // threshold fThresholdForVeryLongDecayTime (whose default value corresponds
1149 // to more than twice the age of the universe).
1150 // This kind of cut has been introduced (in April 2021) in order to avoid to
1151 // account energy depositions happening after many billions of years in
1152 // ordinary materials used in calorimetry, in particular Tungsten and Lead
1153 // (via their natural unstable, but very long lived, isotopes, such as
1154 // W183, W180 and Pb204).
1155 // Note that the cut is not on the average, mean lifetime, but on the actual
1156 // sampled global decay time.
1157 if ( finalGlobalTime > fThresholdForVeryLongDecayTime ) {
1162 delete products;
1163 return;
1164 }
1165 }
1166 products->Boost(ParentEnergy, ParentDirection);
1167
1168 // Add products in theParticleChangeForRadDecay.
1169 G4int numberOfSecondaries = products->entries();
1171
1172 if (GetVerboseLevel() > 1) {
1173 G4cout << "G4RadioactiveDecay::DecayAnalog: Decay vertex :";
1174 G4cout << " Time: " << finalGlobalTime/ns << "[ns]";
1175 G4cout << " X:" << (theTrack.GetPosition()).x() /cm << "[cm]";
1176 G4cout << " Y:" << (theTrack.GetPosition()).y() /cm << "[cm]";
1177 G4cout << " Z:" << (theTrack.GetPosition()).z() /cm << "[cm]";
1178 G4cout << G4endl;
1179 G4cout << "G4Decay::DecayIt : decay products in Lab. Frame" << G4endl;
1180 products->DumpInfo();
1181 products->IsChecked();
1182 }
1183
1184 const G4int modelID_forIT = G4PhysicsModelCatalog::GetModelID( "model_RDM_IT" );
1185 G4int modelID = modelID_forIT + 10*theRadDecayMode;
1186 const G4int modelID_forAtomicRelaxation =
1187 G4PhysicsModelCatalog::GetModelID( "model_RDM_AtomicRelaxation" );
1188 for ( G4int index = 0; index < numberOfSecondaries; ++index ) {
1189 G4Track* secondary = new G4Track( products->PopProducts(), finalGlobalTime,
1190 theTrack.GetPosition() );
1191 secondary->SetWeight( theTrack.GetWeight() );
1192 secondary->SetCreatorModelID( modelID );
1193 // Change for atomics relaxation
1194 if ( theRadDecayMode == IT && index > 0 ) {
1195 if ( index == numberOfSecondaries-1 ) {
1196 secondary->SetCreatorModelID( modelID_forIT );
1197 } else {
1198 secondary->SetCreatorModelID( modelID_forAtomicRelaxation) ;
1199 }
1200 } else if ( theRadDecayMode >= KshellEC && theRadDecayMode <= NshellEC &&
1201 index < numberOfSecondaries-1 ) {
1202 secondary->SetCreatorModelID( modelID_forAtomicRelaxation );
1203 }
1204 secondary->SetGoodForTrackingFlag();
1205 secondary->SetTouchableHandle( theTrack.GetTouchableHandle() );
1207 }
1208
1209 delete products;
1210
1211 // Kill the parent particle
1215
1216 // Reset NumberOfInteractionLengthLeft.
1218}
static constexpr double cm
Definition: G4SIunits.hh:99
@ fStopAndKill
@ fStopButAlive
void DumpInfo() const
G4bool IsChecked() const
void Boost(G4double totalEnergy, const G4ThreeVector &momentumDirection)
const G4ThreeVector & GetMomentumDirection() const
G4double GetKineticEnergy() const
void AddSecondary(G4Track *aSecondary)
static G4int GetModelID(const G4int modelIndex)
G4DecayProducts * DoDecay(const G4ParticleDefinition &theParticleDef)
G4ParticleChangeForRadDecay fParticleChangeForRadDecay
G4RadioactiveDecayMode theRadDecayMode
G4double fThresholdForVeryLongDecayTime
G4TrackStatus GetTrackStatus() const
G4double GetWeight() const
void SetWeight(G4double aValue)
const G4ThreeVector & GetPosition() const
void SetTouchableHandle(const G4TouchableHandle &apValue)
G4double GetGlobalTime() const
G4double GetLocalTime() const
const G4DynamicParticle * GetDynamicParticle() const
const G4TouchableHandle & GetTouchableHandle() const
void SetCreatorModelID(const G4int id)
void SetGoodForTrackingFlag(G4bool value=true)
void ProposeTrackStatus(G4TrackStatus status)
void ProposeLocalEnergyDeposit(G4double anEnergyPart)
void SetNumberOfSecondaries(G4int totSecondaries)
void ClearNumberOfInteractionLengthLeft()
Definition: G4VProcess.hh:424

References G4ParticleChangeForRadDecay::AddSecondary(), G4DecayProducts::Boost(), G4VProcess::ClearNumberOfInteractionLengthLeft(), cm, G4RadioactiveDecay::DoDecay(), G4DecayProducts::DumpInfo(), G4DecayProducts::entries(), G4RadioactiveDecay::fParticleChangeForRadDecay, fStopAndKill, fStopButAlive, G4RadioactiveDecay::fThresholdForVeryLongDecayTime, G4cout, G4endl, G4UniformRand, G4DynamicParticle::GetDefinition(), G4Track::GetDynamicParticle(), G4Track::GetGlobalTime(), G4DynamicParticle::GetKineticEnergy(), G4Track::GetLocalTime(), G4PhysicsModelCatalog::GetModelID(), G4DynamicParticle::GetMomentumDirection(), G4DynamicParticle::GetParticleDefinition(), G4ParticleDefinition::GetPDGLifeTime(), G4ParticleDefinition::GetPDGMass(), G4Track::GetPosition(), G4Track::GetTouchableHandle(), G4Track::GetTrackStatus(), G4RadioactiveDecay::GetVerboseLevel(), G4Track::GetWeight(), G4DecayProducts::IsChecked(), IT, KshellEC, ns, NshellEC, G4DecayProducts::PopProducts(), G4VParticleChange::ProposeLocalEnergyDeposit(), G4ParticleChangeForDecay::ProposeLocalTime(), G4VParticleChange::ProposeTrackStatus(), G4Track::SetCreatorModelID(), G4Track::SetGoodForTrackingFlag(), G4VParticleChange::SetNumberOfSecondaries(), G4Track::SetTouchableHandle(), G4Track::SetWeight(), and G4RadioactiveDecay::theRadDecayMode.

Referenced by DecayIt(), and G4RadioactiveDecay::DecayIt().

◆ DecayIt()

G4VParticleChange * G4Radioactivation::DecayIt ( const G4Track theTrack,
const G4Step theStep 
)

Definition at line 810 of file G4Radioactivation.cc.

811{
812 // Initialize G4ParticleChange object, get particle details and decay table
815 const G4DynamicParticle* theParticle = theTrack.GetDynamicParticle();
816 const G4ParticleDefinition* theParticleDef = theParticle->GetDefinition();
817
818 // First check whether RDM applies to the current logical volume
819 if (!isAllVolumesMode) {
820 if (!std::binary_search(ValidVolumes.begin(), ValidVolumes.end(),
821 theTrack.GetVolume()->GetLogicalVolume()->GetName())) {
822#ifdef G4VERBOSE
823 if (GetVerboseLevel()>0) {
824 G4cout <<"G4RadioactiveDecay::DecayIt : "
825 << theTrack.GetVolume()->GetLogicalVolume()->GetName()
826 << " is not selected for the RDM"<< G4endl;
827 G4cout << " There are " << ValidVolumes.size() << " volumes" << G4endl;
828 G4cout << " The Valid volumes are " << G4endl;
829 for (size_t i = 0; i< ValidVolumes.size(); i++)
830 G4cout << ValidVolumes[i] << G4endl;
831 }
832#endif
834
835 // Kill the parent particle.
840 }
841 }
842
843 // Now check if particle is valid for RDM
844 if (!(IsApplicable(*theParticleDef) ) ) {
845 // Particle is not an ion or is outside the nucleuslimits for decay
846#ifdef G4VERBOSE
847 if (GetVerboseLevel() > 1) {
848 G4cout << "G4RadioactiveDecay::DecayIt : "
849 << theParticleDef->GetParticleName()
850 << " is not an ion or is outside (Z,A) limits set for the decay. "
851 << " Set particle change accordingly. "
852 << G4endl;
853 }
854#endif
856
857 // Kill the parent particle
862 }
863
864 G4DecayTable* theDecayTable = GetDecayTable1(theParticleDef);
865
866 if (theDecayTable == 0 || theDecayTable->entries() == 0) {
867 // No data in the decay table. Set particle change parameters
868 // to indicate this.
869#ifdef G4VERBOSE
870 if (GetVerboseLevel() > 1) {
871 G4cout << "G4RadioactiveDecay::DecayIt : "
872 << "decay table not defined for "
873 << theParticleDef->GetParticleName()
874 << ". Set particle change accordingly. "
875 << G4endl;
876 }
877#endif
879
880 // Kill the parent particle.
885
886 } else {
887 // Data found. Try to decay nucleus
888 if (AnalogueMC) {
890
891 } else {
892 // Proceed with decay using variance reduction
893 G4double energyDeposit = 0.0;
894 G4double finalGlobalTime = theTrack.GetGlobalTime();
895 G4double finalLocalTime = theTrack.GetLocalTime();
896 G4int index;
897 G4ThreeVector currentPosition;
898 currentPosition = theTrack.GetPosition();
899
900 G4IonTable* theIonTable;
901 G4ParticleDefinition* parentNucleus;
902
903 // Get decay chains for the given nuclide
904 if (!IsRateTableReady(*theParticleDef)) CalculateChainsFromParent(*theParticleDef);
905 GetChainsFromParent(*theParticleDef);
906
907 // Declare some of the variables required in the implementation
908 G4int PZ;
909 G4int PA;
910 G4double PE;
911 G4String keyName;
912 std::vector<G4double> PT;
913 std::vector<G4double> PR;
914 G4double taotime;
915 long double decayRate;
916
917 size_t i;
918 G4int numberOfSecondaries;
919 G4int totalNumberOfSecondaries = 0;
920 G4double currentTime = 0.;
921 G4int ndecaych;
922 G4DynamicParticle* asecondaryparticle;
923 std::vector<G4DynamicParticle*> secondaryparticles;
924 std::vector<G4double> pw;
925 std::vector<G4double> ptime;
926 pw.clear();
927 ptime.clear();
928
929 // Now apply the nucleus splitting
930 for (G4int n = 0; n < NSplit; n++) {
931 // Get the decay time following the decay probability function
932 // supplied by user
933 G4double theDecayTime = GetDecayTime();
934 G4int nbin = GetDecayTimeBin(theDecayTime);
935
936 // calculate the first part of the weight function
937 G4double weight1 = 1.;
938 if (nbin == 1) {
939 weight1 = 1./DProfile[nbin-1]
940 *(DBin[nbin]-DBin[nbin-1])/NSplit; // width of window in ns
941 } else if (nbin > 1) {
942 // Go from nbin to nbin-2 because flux entries in file alternate between 0 and 1
943 weight1 = 1./(DProfile[nbin]-DProfile[nbin-2])
944 *(DBin[nbin]-DBin[nbin-1])/NSplit;
945 // weight1 = (probability of choosing one of the bins)*(time width of bin)/NSplit
946 }
947 // it should be calculated in seconds
948 weight1 /= s ;
949
950 // loop over all the possible secondaries of the nucleus
951 // the first one is itself.
952 for (i = 0; i < theDecayRateVector.size(); i++) {
953 PZ = theDecayRateVector[i].GetZ();
954 PA = theDecayRateVector[i].GetA();
955 PE = theDecayRateVector[i].GetE();
956 PT = theDecayRateVector[i].GetTaos();
957 PR = theDecayRateVector[i].GetDecayRateC();
958
959 // The array of arrays theDecayRateVector contains all possible decay
960 // chains of a given parent nucleus (ZP,AP,EP) to a given descendant
961 // nuclide (Z,A,E).
962 //
963 // theDecayRateVector[0] contains the decay parameters of the parent
964 // nucleus
965 // PZ = ZP
966 // PA = AP
967 // PE = EP
968 // PT[] = {TP}
969 // PR[] = {RP}
970 //
971 // theDecayRateVector[1] contains the decay of the parent to the first
972 // generation daughter (Z1,A1,E1).
973 // PZ = Z1
974 // PA = A1
975 // PE = E1
976 // PT[] = {TP, T1}
977 // PR[] = {RP, R1}
978 //
979 // theDecayRateVector[2] contains the decay of the parent to the first
980 // generation daughter (Z1,A1,E1) and the decay of the first
981 // generation daughter to the second generation daughter (Z2,A2,E2).
982 // PZ = Z2
983 // PA = A2
984 // PE = E2
985 // PT[] = {TP, T1, T2}
986 // PR[] = {RP, R1, R2}
987 //
988 // theDecayRateVector[3] may contain a branch chain
989 // PZ = Z2a
990 // PA = A2a
991 // PE = E2a
992 // PT[] = {TP, T1, T2a}
993 // PR[] = {RP, R1, R2a}
994 //
995 // and so on.
996
997 // Calculate the decay rate of the isotope. decayRate is the
998 // radioactivity of isotope (PZ,PA,PE) at 'theDecayTime'
999 // it will be used to calculate the statistical weight of the
1000 // decay products of this isotope
1001
1002 // For each nuclide, calculate all the decay chains which can reach
1003 // the parent nuclide
1004 decayRate = 0.L;
1005 for (G4int j = 0; j < G4int(PT.size() ); j++) {
1006 taotime = ConvolveSourceTimeProfile(theDecayTime,PT[j]);
1007 decayRate -= PR[j] * (long double)taotime; // PRs are Acoeffs, taotime is inverse time
1008 // Eq.4.23 of of the TN
1009 // note the negative here is required as the rate in the
1010 // equation is defined to be negative,
1011 // i.e. decay away, but we need positive value here.
1012
1013 // G4cout << j << "\t"<< PT[j]/s << "\t" << PR[j] << "\t" << decayRate << G4endl;
1014 }
1015
1016 // At this point any negative decay rates are probably small enough
1017 // (order 10**-30) that negative values are likely due to cancellation
1018 // errors. Set them to zero.
1019 if (decayRate < 0.0) decayRate = 0.0;
1020
1021 // G4cout <<theDecayTime/s <<"\t"<<nbin<<G4endl;
1022 // G4cout << theTrack.GetWeight() <<"\t"<<weight1<<"\t"<<decayRate<< G4endl;
1023
1024 // Add isotope to the radioactivity tables
1025 // One table for each observation time window specified in
1026 // SetDecayBias(G4String filename)
1027
1029 ->AddIsotope(PZ,PA,PE,weight1*decayRate,theTrack.GetWeight());
1030
1031 // Now calculate the statistical weight
1032 // One needs to fold the source bias function with the decaytime
1033 // also need to include the track weight! (F.Lei, 28/10/10)
1034 G4double weight = weight1*decayRate*theTrack.GetWeight();
1035
1036 // decay the isotope
1038 parentNucleus = theIonTable->GetIon(PZ,PA,PE);
1039
1040 // Create a temprary products buffer.
1041 // Its contents to be transfered to the products at the end of the loop
1042 G4DecayProducts* tempprods = 0;
1043
1044 // Decide whether to apply branching ratio bias or not
1045 if (BRBias) {
1046 G4DecayTable* decayTable = GetDecayTable1(parentNucleus);
1047 ndecaych = G4int(decayTable->entries()*G4UniformRand());
1048 G4VDecayChannel* theDecayChannel = decayTable->GetDecayChannel(ndecaych);
1049
1050 if (theDecayChannel == 0) {
1051 // Decay channel not found.
1052
1053 if (GetVerboseLevel() > 0) {
1054 G4cout << " G4RadioactiveDecay::DoIt : cannot determine decay channel ";
1055 G4cout << " for this nucleus; decay as if no biasing active. ";
1056 G4cout << G4endl;
1057 decayTable ->DumpInfo();
1058 }
1059
1060 tempprods = DoDecay(*parentNucleus); // DHW 6 Dec 2010 - do decay as if no biasing
1061 // to avoid deref of temppprods = 0
1062 } else {
1063 // A decay channel has been identified, so execute the DecayIt.
1064 G4double tempmass = parentNucleus->GetPDGMass();
1065 tempprods = theDecayChannel->DecayIt(tempmass);
1066 weight *= (theDecayChannel->GetBR())*(decayTable->entries());
1067 }
1068 } else {
1069 tempprods = DoDecay(*parentNucleus);
1070 }
1071
1072 // save the secondaries for buffers
1073 numberOfSecondaries = tempprods->entries();
1074 currentTime = finalGlobalTime + theDecayTime;
1075 for (index = 0; index < numberOfSecondaries; index++) {
1076 asecondaryparticle = tempprods->PopProducts();
1077 if (asecondaryparticle->GetDefinition()->GetPDGStable() ) {
1078 pw.push_back(weight);
1079 ptime.push_back(currentTime);
1080 secondaryparticles.push_back(asecondaryparticle);
1081 }
1082 // Generate gammas and Xrays from excited nucleus, added by L.Desorgher
1083 else if (((const G4Ions*)(asecondaryparticle->GetDefinition()))
1084 ->GetExcitationEnergy() > 0. && weight > 0.) { //Compute the gamma
1085 G4ParticleDefinition* apartDef = asecondaryparticle->GetDefinition();
1086 AddDeexcitationSpectrumForBiasMode(apartDef,weight,currentTime,pw,
1087 ptime,secondaryparticles);
1088 }
1089 }
1090
1091 delete tempprods;
1092 } // end of i loop
1093 } // end of n loop
1094
1095 // now deal with the secondaries in the two stl containers
1096 // and submmit them back to the tracking manager
1097 totalNumberOfSecondaries = pw.size();
1098 fParticleChangeForRadDecay.SetNumberOfSecondaries(totalNumberOfSecondaries);
1099 for (index=0; index < totalNumberOfSecondaries; index++) {
1100 G4Track* secondary = new G4Track(secondaryparticles[index],
1101 ptime[index], currentPosition);
1102 secondary->SetGoodForTrackingFlag();
1103 secondary->SetTouchableHandle(theTrack.GetTouchableHandle());
1104 secondary->SetWeight(pw[index]);
1106 }
1107
1108 // Kill the parent particle
1112 // Reset NumberOfInteractionLengthLeft.
1114 } // end VR decay
1115
1117 } // end of data found branch
1118}
void DumpInfo() const
const G4String & GetName() const
virtual void Initialize(const G4Track &)
G4int GetDecayTimeBin(const G4double aDecayTime)
void AddDeexcitationSpectrumForBiasMode(G4ParticleDefinition *apartDef, G4double weight, G4double currenTime, std::vector< double > &weights_v, std::vector< double > &times_v, std::vector< G4DynamicParticle * > &secondaries_v)
G4bool IsRateTableReady(const G4ParticleDefinition &)
G4double ConvolveSourceTimeProfile(const G4double, const G4double)
void CalculateChainsFromParent(const G4ParticleDefinition &)
void GetChainsFromParent(const G4ParticleDefinition &)
void DecayAnalog(const G4Track &theTrack)
std::vector< G4String > ValidVolumes
G4VPhysicalVolume * GetVolume() const
virtual G4DecayProducts * DecayIt(G4double parentMass=-1.0)=0
void ProposeWeight(G4double finalWeight)
G4LogicalVolume * GetLogicalVolume() const

References AddDeexcitationSpectrumForBiasMode(), G4ParticleChangeForRadDecay::AddSecondary(), AnalogueMC, BRBias, CalculateChainsFromParent(), G4VProcess::ClearNumberOfInteractionLengthLeft(), ConvolveSourceTimeProfile(), DBin, G4RadioactiveDecay::DecayAnalog(), G4VDecayChannel::DecayIt(), decayWindows, G4RadioactiveDecay::DoDecay(), DProfile, G4DecayTable::DumpInfo(), G4DecayProducts::entries(), G4DecayTable::entries(), G4RadioactiveDecay::fParticleChangeForRadDecay, fStopAndKill, G4cout, G4endl, G4UniformRand, G4VDecayChannel::GetBR(), GetChainsFromParent(), G4DecayTable::GetDecayChannel(), GetDecayTable1(), GetDecayTime(), GetDecayTimeBin(), G4DynamicParticle::GetDefinition(), G4Track::GetDynamicParticle(), G4Track::GetGlobalTime(), G4IonTable::GetIon(), G4ParticleTable::GetIonTable(), G4Track::GetLocalTime(), G4VPhysicalVolume::GetLogicalVolume(), G4LogicalVolume::GetName(), G4ParticleDefinition::GetParticleName(), G4ParticleTable::GetParticleTable(), G4ParticleDefinition::GetPDGMass(), G4ParticleDefinition::GetPDGStable(), G4Track::GetPosition(), G4Track::GetTouchableHandle(), G4RadioactiveDecay::GetVerboseLevel(), G4Track::GetVolume(), G4Track::GetWeight(), G4ParticleChangeForDecay::Initialize(), G4RadioactiveDecay::isAllVolumesMode, G4RadioactiveDecay::IsApplicable(), IsRateTableReady(), CLHEP::detail::n, NSplit, G4DecayProducts::PopProducts(), G4VParticleChange::ProposeLocalEnergyDeposit(), G4ParticleChangeForDecay::ProposeLocalTime(), G4VParticleChange::ProposeTrackStatus(), G4VParticleChange::ProposeWeight(), s, G4Track::SetGoodForTrackingFlag(), G4VParticleChange::SetNumberOfSecondaries(), G4Track::SetTouchableHandle(), G4Track::SetWeight(), theDecayRateVector, theRadioactivityTables, and G4RadioactiveDecay::ValidVolumes.

Referenced by AtRestDoIt(), and PostStepDoIt().

◆ DeselectAllVolumes()

void G4RadioactiveDecay::DeselectAllVolumes ( )
inherited

Definition at line 331 of file G4RadioactiveDecay.cc.

332{
333 ValidVolumes.clear();
334 isAllVolumesMode=false;
335#ifdef G4VERBOSE
336 if (GetVerboseLevel() > 1) G4cout << "RDM removed from all volumes" << G4endl;
337#endif
338}

References G4cout, G4endl, G4RadioactiveDecay::GetVerboseLevel(), G4RadioactiveDecay::isAllVolumesMode, and G4RadioactiveDecay::ValidVolumes.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ DeselectAVolume()

void G4RadioactiveDecay::DeselectAVolume ( const G4String aVolume)
inherited

Definition at line 272 of file G4RadioactiveDecay.cc.

273{
275 G4LogicalVolume* volume = nullptr;
276 volume = theLogicalVolumes->GetVolume(aVolume);
277 if (volume != nullptr)
278 {
279 auto location= std::find(ValidVolumes.cbegin(),ValidVolumes.cend(),aVolume);
280 if (location != ValidVolumes.cend() )
281 {
282 ValidVolumes.erase(location);
283 std::sort(ValidVolumes.begin(), ValidVolumes.end());
284 isAllVolumesMode = false;
285 if (GetVerboseLevel() > 0)
286 G4cout << " G4RadioactiveDecay::DeselectAVolume: " << aVolume
287 << " is removed from list " << G4endl;
288 }
289 else
290 {
292 ed << aVolume << " is not in the list. No action taken." << G4endl;
293 G4Exception("G4RadioactiveDecay::DeselectAVolume()", "HAD_RDM_300",
294 JustWarning, ed);
295 }
296 }
297 else
298 {
300 ed << aVolume << " is not a valid logical volume name. No action taken."
301 << G4endl;
302 G4Exception("G4RadioactiveDecay::DeselectAVolume()", "HAD_RDM_300",
303 JustWarning, ed);
304 }
305}
G4LogicalVolume * GetVolume(const G4String &name, G4bool verbose=true, G4bool reverseSearch=false) const
static G4LogicalVolumeStore * GetInstance()

References G4cout, G4endl, G4Exception(), G4LogicalVolumeStore::GetInstance(), G4RadioactiveDecay::GetVerboseLevel(), G4LogicalVolumeStore::GetVolume(), G4RadioactiveDecay::isAllVolumesMode, JustWarning, and G4RadioactiveDecay::ValidVolumes.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ DoDecay()

G4DecayProducts * G4RadioactiveDecay::DoDecay ( const G4ParticleDefinition theParticleDef)
protectedinherited

Definition at line 1222 of file G4RadioactiveDecay.cc.

1223{
1224 G4DecayProducts* products = 0;
1225 G4DecayTable* theDecayTable = GetDecayTable(&theParticleDef);
1226
1227 // Choose a decay channel.
1228 // G4DecayTable::SelectADecayChannel checks to see if sum of daughter masses
1229 // exceeds parent mass. Pass it the parent mass + maximum Q value to account
1230 // for difference in mass defect.
1231 G4double parentPlusQ = theParticleDef.GetPDGMass() + 30.*MeV;
1232 G4VDecayChannel* theDecayChannel = theDecayTable->SelectADecayChannel(parentPlusQ);
1233
1234 if (theDecayChannel == 0) {
1235 // Decay channel not found.
1237 ed << " Cannot determine decay channel for " << theParticleDef.GetParticleName() << G4endl;
1238 G4Exception("G4RadioactiveDecay::DoDecay", "HAD_RDM_013",
1239 FatalException, ed);
1240 } else {
1241 // A decay channel has been identified, so execute the DecayIt.
1242#ifdef G4VERBOSE
1243 if (GetVerboseLevel() > 1) {
1244 G4cout << "G4RadioactiveDecay::DoIt : selected decay channel addr: "
1245 << theDecayChannel << G4endl;
1246 }
1247#endif
1248 theRadDecayMode = (static_cast<G4NuclearDecay*>(theDecayChannel))->GetDecayMode();
1249 products = theDecayChannel->DecayIt(theParticleDef.GetPDGMass() );
1250
1251 // Apply directional bias if requested by user
1252 CollimateDecay(products);
1253 }
1254
1255 return products;
1256}
G4VDecayChannel * SelectADecayChannel(G4double parentMass=-1.)
Definition: G4DecayTable.cc:82
G4DecayTable * GetDecayTable(const G4ParticleDefinition *)
void CollimateDecay(G4DecayProducts *products)

References G4RadioactiveDecay::CollimateDecay(), G4VDecayChannel::DecayIt(), FatalException, G4cout, G4endl, G4Exception(), G4RadioactiveDecay::GetDecayTable(), G4ParticleDefinition::GetParticleName(), G4ParticleDefinition::GetPDGMass(), G4RadioactiveDecay::GetVerboseLevel(), MeV, G4DecayTable::SelectADecayChannel(), and G4RadioactiveDecay::theRadDecayMode.

Referenced by G4RadioactiveDecay::DecayAnalog(), and DecayIt().

◆ DumpInfo()

void G4VProcess::DumpInfo ( ) const
virtualinherited

Reimplemented in G4AdjointAlongStepWeightCorrection, G4AdjointForcedInteractionForGamma, G4AdjointhMultipleScattering, G4ContinuousGainOfEnergy, G4eAdjointMultipleScattering, G4eInverseBremsstrahlung, G4eInverseCompton, G4eInverseIonisation, G4InversePEEffect, G4IonInverseIonisation, G4PolarizedAnnihilation, G4PolarizedBremsstrahlung, G4PolarizedCompton, G4PolarizedGammaConversion, G4PolarizedIonisation, G4PolarizedPhotoElectric, G4Cerenkov, G4ForwardXrayTR, G4GammaXTRadiator, G4GaussXTRadiator, G4RegularXTRadiator, G4Scintillation, G4StrawTubeXTRadiator, G4SynchrotronRadiation, G4TransitionRadiation, G4TransparentRegXTRadiator, G4VTransitionRadiation, G4VXTRenergyLoss, G4XTRGammaRadModel, G4XTRRegularRadModel, and G4XTRTransparentRegRadModel.

Definition at line 167 of file G4VProcess.cc.

168{
169 G4cout << "Process Name " << theProcessName ;
170 G4cout << " : Type[" << GetProcessTypeName(theProcessType) << "]";
171 G4cout << " : SubType[" << theProcessSubType << "]"<< G4endl;
172}
static const G4String & GetProcessTypeName(G4ProcessType)
Definition: G4VProcess.cc:134
G4ProcessType theProcessType
Definition: G4VProcess.hh:346
G4int theProcessSubType
Definition: G4VProcess.hh:349
G4String theProcessName
Definition: G4VProcess.hh:341

References G4cout, G4endl, G4VProcess::GetProcessTypeName(), G4VProcess::theProcessName, G4VProcess::theProcessSubType, and G4VProcess::theProcessType.

Referenced by G4ProcessTable::DumpInfo(), export_G4VProcess(), G4Scintillation::ProcessDescription(), G4Cerenkov::ProcessDescription(), and G4ProcessManagerMessenger::SetNewValue().

◆ EndTracking()

void G4VProcess::EndTracking ( )
virtualinherited

◆ GetChainsFromParent()

void G4Radioactivation::GetChainsFromParent ( const G4ParticleDefinition aParticle)

Definition at line 173 of file G4Radioactivation.cc.

174{
175 // Retrieve the decay rate table for the specified aParticle
176 G4String aParticleName = aParticle.GetParticleName();
177
178 for (size_t i = 0; i < theParentChainTable.size(); i++) {
179 if (theParentChainTable[i].GetIonName() == aParticleName) {
180 theDecayRateVector = theParentChainTable[i].GetItsRates();
181 }
182 }
183#ifdef G4VERBOSE
184 if (GetVerboseLevel() > 1) {
185 G4cout << "The DecayRate Table for " << aParticleName << " is selected."
186 << G4endl;
187 }
188#endif
189}

References G4cout, G4endl, G4ParticleDefinition::GetParticleName(), G4RadioactiveDecay::GetVerboseLevel(), theDecayRateVector, and theParentChainTable.

Referenced by DecayIt().

◆ GetCurrentInteractionLength()

G4double G4VProcess::GetCurrentInteractionLength ( ) const
inlineinherited

◆ GetDecayDirection()

const G4ThreeVector & G4RadioactiveDecay::GetDecayDirection ( ) const
inlineinherited

Definition at line 134 of file G4RadioactiveDecay.hh.

134 {
135 return forceDecayDirection;
136 }

References G4RadioactiveDecay::forceDecayDirection.

◆ GetDecayHalfAngle()

G4double G4RadioactiveDecay::GetDecayHalfAngle ( ) const
inlineinherited

Definition at line 142 of file G4RadioactiveDecay.hh.

142{return forceDecayHalfAngle;}

References G4RadioactiveDecay::forceDecayHalfAngle.

◆ GetDecayTable()

G4DecayTable * G4RadioactiveDecay::GetDecayTable ( const G4ParticleDefinition aNucleus)
inherited

Definition at line 230 of file G4RadioactiveDecay.cc.

231{
232 G4String key = aNucleus->GetParticleName();
233 DecayTableMap::iterator table_ptr = dkmap->find(key);
234
235 G4DecayTable* theDecayTable = 0;
236 if (table_ptr == dkmap->end() ) { // If table not there,
237 theDecayTable = LoadDecayTable(*aNucleus); // load from file and
238 if(theDecayTable) (*dkmap)[key] = theDecayTable; // store in library
239 } else {
240 theDecayTable = table_ptr->second;
241 }
242 return theDecayTable;
243}
G4DecayTable * LoadDecayTable(const G4ParticleDefinition &theParentNucleus)

References G4RadioactiveDecay::dkmap, G4ParticleDefinition::GetParticleName(), and G4RadioactiveDecay::LoadDecayTable().

Referenced by G4RadioactiveDecay::DecayIt(), and G4RadioactiveDecay::DoDecay().

◆ GetDecayTable1()

G4DecayTable * G4Radioactivation::GetDecayTable1 ( const G4ParticleDefinition aNucleus)

Definition at line 144 of file G4Radioactivation.cc.

145{
146 G4String key = aNucleus->GetParticleName();
147 DecayTableMap::iterator table_ptr = dkmap->find(key);
148
149 G4DecayTable* theDecayTable = 0;
150 if (table_ptr == dkmap->end() ) { // If table not there,
151 theDecayTable = LoadDecayTable(*aNucleus); // load from file and
152 if(theDecayTable) (*dkmap)[key] = theDecayTable; // store in library
153 } else {
154 theDecayTable = table_ptr->second;
155 }
156 return theDecayTable;
157}

References G4RadioactiveDecay::dkmap, G4ParticleDefinition::GetParticleName(), and G4RadioactiveDecay::LoadDecayTable().

Referenced by CalculateChainsFromParent(), and DecayIt().

◆ GetDecayTime()

G4double G4Radioactivation::GetDecayTime ( )
protected

Definition at line 260 of file G4Radioactivation.cc.

261{
262 G4double decaytime = 0.;
263 G4double rand = G4UniformRand();
264 G4int i = 0;
265
266 G4int loop = 0;
267 while (DProfile[i] < rand) { /* Loop checking, 01.09.2015, D.Wright */
268 // Entries in DProfile[i] are all between 0 and 1 and arranged in inreaseing order
269 // Comparison with rand chooses which time bin to sample
270 i++;
271 loop++;
272 if (loop > 100000) {
273 G4Exception("G4Radioactivation::GetDecayTime()", "HAD_RDM_100",
274 JustWarning, "While loop count exceeded");
275 break;
276 }
277 }
278
279 rand = G4UniformRand();
280 decaytime = DBin[i] + rand*(DBin[i+1]-DBin[i]);
281#ifdef G4VERBOSE
282 if (GetVerboseLevel() > 2)
283 G4cout <<" Decay time: " <<decaytime/s <<"[s]" <<G4endl;
284#endif
285 return decaytime;
286}

References DBin, DProfile, G4cout, G4endl, G4Exception(), G4UniformRand, G4RadioactiveDecay::GetVerboseLevel(), JustWarning, and s.

Referenced by DecayIt().

◆ GetDecayTimeBin()

G4int G4Radioactivation::GetDecayTimeBin ( const G4double  aDecayTime)
protected

Definition at line 289 of file G4Radioactivation.cc.

290{
291 G4int i = 0;
292
293 G4int loop = 0;
294 while (aDecayTime > DBin[i] ) { /* Loop checking, 01.09.2015, D.Wright */
295 i++;
296 loop++;
297 if (loop > 100000) {
298 G4Exception("G4Radioactivation::GetDecayTimeBin()", "HAD_RDM_100",
299 JustWarning, "While loop count exceeded");
300 break;
301 }
302 }
303
304 return i;
305}

References DBin, G4Exception(), and JustWarning.

Referenced by DecayIt().

◆ GetMasterProcess()

const G4VProcess * G4VProcess::GetMasterProcess ( ) const
inlineinherited

◆ GetMeanFreePath()

G4double G4RadioactiveDecay::GetMeanFreePath ( const G4Track theTrack,
G4double  previousStepSize,
G4ForceCondition condition 
)
protectedvirtualinherited

Implements G4VRestDiscreteProcess.

Definition at line 383 of file G4RadioactiveDecay.cc.

385{
386 const G4DynamicParticle* aParticle = aTrack.GetDynamicParticle();
387 const G4ParticleDefinition* aParticleDef = aParticle->GetDefinition();
388 G4double tau = aParticleDef->GetPDGLifeTime();
389 G4double aMass = aParticle->GetMass();
390
391#ifdef G4VERBOSE
392 if (GetVerboseLevel() > 2) {
393 G4cout << "G4RadioactiveDecay::GetMeanFreePath() " << G4endl;
394 G4cout << " KineticEnergy: " << aParticle->GetKineticEnergy()/GeV
395 << " GeV, Mass: " << aMass/GeV << " GeV, tau: " << tau << " ns "
396 << G4endl;
397 }
398#endif
399 G4double pathlength = DBL_MAX;
400 if (tau != -1) {
401 // Ion can decay
402
403 if (tau < -1000.0) {
404 pathlength = DBL_MIN; // nuclide had very short lifetime or wasn't in table
405
406 } else if (tau < 0.0) {
407 G4cout << aParticleDef->GetParticleName() << " has lifetime " << tau << G4endl;
409 ed << "Ion has negative lifetime " << tau
410 << " but is not stable. Setting mean free path to DBL_MAX" << G4endl;
411 G4Exception("G4RadioactiveDecay::GetMeanFreePath()", "HAD_RDM_011",
412 JustWarning, ed);
413 pathlength = DBL_MAX;
414
415 } else {
416 // Calculate mean free path
417 G4double betaGamma = aParticle->GetTotalMomentum()/aMass;
418 pathlength = c_light*tau*betaGamma;
419
420 if (pathlength < DBL_MIN) {
421 pathlength = DBL_MIN;
422#ifdef G4VERBOSE
423 if (GetVerboseLevel() > 2) {
424 G4cout << "G4Decay::GetMeanFreePath: "
425 << aParticleDef->GetParticleName()
426 << " stops, kinetic energy = "
427 << aParticle->GetKineticEnergy()/keV <<" keV " << G4endl;
428 }
429#endif
430 }
431 }
432 }
433
434#ifdef G4VERBOSE
435 if (GetVerboseLevel() > 2) {
436 G4cout << "mean free path: "<< pathlength/m << " m" << G4endl;
437 }
438#endif
439 return pathlength;
440}
static constexpr double m
Definition: G4SIunits.hh:109
static constexpr double keV
Definition: G4SIunits.hh:202
static constexpr double GeV
Definition: G4SIunits.hh:203
G4double GetMass() const
G4double GetTotalMomentum() const
float c_light
Definition: hepunit.py:256
#define DBL_MIN
Definition: templates.hh:54
#define DBL_MAX
Definition: templates.hh:62

References source.hepunit::c_light, DBL_MAX, DBL_MIN, G4cout, G4endl, G4Exception(), G4DynamicParticle::GetDefinition(), G4Track::GetDynamicParticle(), G4DynamicParticle::GetKineticEnergy(), G4DynamicParticle::GetMass(), G4ParticleDefinition::GetParticleName(), G4ParticleDefinition::GetPDGLifeTime(), G4DynamicParticle::GetTotalMomentum(), G4RadioactiveDecay::GetVerboseLevel(), GeV, JustWarning, keV, and m.

◆ GetMeanLifeTime()

G4double G4Radioactivation::GetMeanLifeTime ( const G4Track theTrack,
G4ForceCondition condition 
)
protectedvirtual

Implements G4VRestDiscreteProcess.

Definition at line 313 of file G4Radioactivation.cc.

315{
316 // For variance reduction time is set to 0 so as to force the particle
317 // to decay immediately.
318 // In analogue mode it returns the particle's mean-life.
319 G4double meanlife = 0.;
320 if (AnalogueMC) meanlife = G4RadioactiveDecay::GetMeanLifeTime(theTrack, 0);
321 return meanlife;
322}
G4double GetMeanLifeTime(const G4Track &theTrack, G4ForceCondition *condition)

References AnalogueMC, and G4RadioactiveDecay::GetMeanLifeTime().

◆ GetNucleusLimits()

G4NucleusLimits G4RadioactiveDecay::GetNucleusLimits ( ) const
inlineinherited

Definition at line 128 of file G4RadioactiveDecay.hh.

128{return theNucleusLimits;}
G4NucleusLimits theNucleusLimits

References G4RadioactiveDecay::theNucleusLimits.

◆ GetNumberOfInteractionLengthLeft()

G4double G4VProcess::GetNumberOfInteractionLengthLeft ( ) const
inlineinherited

Definition at line 431 of file G4VProcess.hh.

432{
434}

References G4VProcess::theNumberOfInteractionLengthLeft.

◆ GetPhysicsTableFileName()

const G4String & G4VProcess::GetPhysicsTableFileName ( const G4ParticleDefinition particle,
const G4String directory,
const G4String tableName,
G4bool  ascii = false 
)
inherited

Definition at line 181 of file G4VProcess.cc.

186{
187 G4String thePhysicsTableFileExt;
188 if (ascii) thePhysicsTableFileExt = ".asc";
189 else thePhysicsTableFileExt = ".dat";
190
191 thePhysicsTableFileName = directory + "/";
192 thePhysicsTableFileName += tableName + "." + theProcessName + ".";
194 + thePhysicsTableFileExt;
195
197}
G4String thePhysicsTableFileName
Definition: G4VProcess.hh:344

References G4ParticleDefinition::GetParticleName(), G4VProcess::thePhysicsTableFileName, and G4VProcess::theProcessName.

Referenced by export_G4VProcess(), G4GammaGeneralProcess::RetrievePhysicsTable(), G4VEmProcess::RetrievePhysicsTable(), G4VEnergyLossProcess::RetrieveTable(), G4GammaGeneralProcess::StorePhysicsTable(), G4VEmProcess::StorePhysicsTable(), G4VMultipleScattering::StorePhysicsTable(), and G4VEnergyLossProcess::StoreTable().

◆ GetPILfactor()

G4double G4VProcess::GetPILfactor ( ) const
inlineinherited

Definition at line 455 of file G4VProcess.hh.

456{
457 return thePILfactor;
458}

References G4VProcess::thePILfactor.

Referenced by export_G4VProcess().

◆ GetProcessManager()

const G4ProcessManager * G4VProcess::GetProcessManager ( )
inlinevirtualinherited

Reimplemented in G4BiasingProcessInterface, and G4WrapperProcess.

Definition at line 494 of file G4VProcess.hh.

495{
496 return aProcessManager;
497}
const G4ProcessManager * aProcessManager
Definition: G4VProcess.hh:319

References G4VProcess::aProcessManager.

Referenced by G4BiasingProcessInterface::GetProcessManager(), and G4WrapperProcess::GetProcessManager().

◆ GetProcessName()

const G4String & G4VProcess::GetProcessName ( ) const
inlineinherited

Definition at line 382 of file G4VProcess.hh.

383{
384 return theProcessName;
385}

References G4VProcess::theProcessName.

Referenced by G4VEnergyLossProcess::ActivateForcedInteraction(), G4VEmProcess::ActivateForcedInteraction(), G4ProcessManager::ActivateProcess(), G4VEmProcess::ActivateSecondaryBiasing(), G4VEnergyLossProcess::ActivateSecondaryBiasing(), G4ParallelGeometriesLimiterProcess::AddParallelWorld(), G4IonQMDPhysics::AddProcess(), G4IonINCLXXPhysics::AddProcess(), G4ProcessManager::AddProcess(), G4ProcessPlacer::AddProcessAs(), G4ITSteppingVerbose::AlongStepDoItAllDone(), G4SteppingVerbose::AlongStepDoItAllDone(), G4SteppingVerboseWithUnits::AlongStepDoItAllDone(), G4ITSteppingVerbose::AlongStepDoItOneByOne(), G4SteppingVerbose::AlongStepDoItOneByOne(), G4SteppingVerboseWithUnits::AlongStepDoItOneByOne(), G4VContinuousDiscreteProcess::AlongStepGetPhysicalInteractionLength(), G4ParallelWorldProcess::AlongStepGetPhysicalInteractionLength(), G4VRestContinuousDiscreteProcess::AlongStepGetPhysicalInteractionLength(), G4VRestContinuousProcess::AlongStepGetPhysicalInteractionLength(), G4VContinuousProcess::AlongStepGetPhysicalInteractionLength(), G4BOptnLeadingParticle::ApplyFinalStateBiasing(), G4ITSteppingVerbose::AtRestDoItInvoked(), G4SteppingVerbose::AtRestDoItInvoked(), G4SteppingVerboseWithUnits::AtRestDoItInvoked(), G4ITSteppingVerbose::AtRestDoItOneByOne(), G4VRestContinuousDiscreteProcess::AtRestGetPhysicalInteractionLength(), G4VRestContinuousProcess::AtRestGetPhysicalInteractionLength(), G4VRestDiscreteProcess::AtRestGetPhysicalInteractionLength(), G4VITRestDiscreteProcess::AtRestGetPhysicalInteractionLength(), G4VITRestProcess::AtRestGetPhysicalInteractionLength(), G4VRestProcess::AtRestGetPhysicalInteractionLength(), G4HadronicProcess::BiasCrossSectionByFactor(), G4VXTRenergyLoss::BuildAngleForEnergyBank(), G4VEnergyLossProcess::BuildDEDXTable(), G4VUserPhysicsList::BuildIntegralPhysicsTable(), G4VEmProcess::BuildLambdaTable(), G4VEnergyLossProcess::BuildLambdaTable(), G4DNABrownianTransportation::BuildPhysicsTable(), G4GammaGeneralProcess::BuildPhysicsTable(), G4VEmProcess::BuildPhysicsTable(), G4VEnergyLossProcess::BuildPhysicsTable(), G4VMultipleScattering::BuildPhysicsTable(), G4LossTableManager::BuildPhysicsTable(), G4LossTableManager::BuildTables(), G4HadronicProcess::CheckEnergyMomentumConservation(), G4ProcessManager::CheckOrderingParameters(), G4HadronicProcess::CheckResult(), G4StackChecker::ClassifyNewTrack(), G4BOptrForceCollision::ConfigureForWorker(), G4RunManagerKernel::ConfirmCoupledTransportation(), G4FastSimulationPhysics::ConstructProcess(), G4GenericBiasingPhysics::ConstructProcess(), G4IonElasticPhysics::ConstructProcess(), G4LossTableManager::CopyTables(), G4RichTrajectory::CreateAttValues(), G4RichTrajectoryPoint::CreateAttValues(), G4VPhononProcess::CreateSecondary(), G4EmExtraParameters::DefineRegParamForEM(), G4EmExtraParameters::DefineRegParamForLoss(), G4HadronicProcessStore::DeRegisterExtraProcess(), G4ITSteppingVerbose::DPSLAlongStep(), G4SteppingVerbose::DPSLAlongStep(), G4SteppingVerboseWithUnits::DPSLAlongStep(), G4ITSteppingVerbose::DPSLPostStep(), G4SteppingVerbose::DPSLPostStep(), G4SteppingVerboseWithUnits::DPSLPostStep(), G4HadronicProcessStore::Dump(), G4HadronicProcess::DumpState(), G4MuonicAtomDecay::DumpState(), G4ExceptionHandler::DumpTrackInfo(), export_G4VProcess(), G4EmCalculator::FindEmModel(), G4VEmProcess::FindLambdaMax(), G4BiasingProcessInterface::G4BiasingProcessInterface(), G4Cerenkov::G4Cerenkov(), G4ErrorEnergyLoss::G4ErrorEnergyLoss(), G4ErrorTrackLengthTarget::G4ErrorTrackLengthTarget(), G4FastSimulationManagerProcess::G4FastSimulationManagerProcess(), G4ImportanceProcess::G4ImportanceProcess(), G4MaxTimeCuts::G4MaxTimeCuts(), G4MicroElecSurface::G4MicroElecSurface(), G4MinEkineCuts::G4MinEkineCuts(), G4OpAbsorption::G4OpAbsorption(), G4OpBoundaryProcess::G4OpBoundaryProcess(), G4OpMieHG::G4OpMieHG(), G4OpRayleigh::G4OpRayleigh(), G4OpWLS::G4OpWLS(), G4OpWLS2::G4OpWLS2(), G4ParallelWorldProcess::G4ParallelWorldProcess(), G4ParallelWorldScoringProcess::G4ParallelWorldScoringProcess(), G4Scintillation::G4Scintillation(), G4ScoreSplittingProcess::G4ScoreSplittingProcess(), G4SpecialCuts::G4SpecialCuts(), G4StepLimiter::G4StepLimiter(), G4UCNAbsorption::G4UCNAbsorption(), G4UCNBoundaryProcess::G4UCNBoundaryProcess(), G4UCNLoss::G4UCNLoss(), G4UCNMultiScattering::G4UCNMultiScattering(), G4UserSpecialCuts::G4UserSpecialCuts(), G4WeightCutOffProcess::G4WeightCutOffProcess(), G4WeightWindowProcess::G4WeightWindowProcess(), G4HadronicProcess::GetElementCrossSection(), G4VEmProcess::GetEmProcess(), G4GammaGeneralProcess::GetEmProcess(), G4WeightWindowProcess::GetName(), G4ProcessManager::GetProcess(), G4ProcessManager::GetProcessVectorIndex(), G4GammaGeneralProcess::GetSubProcessName(), G4ProcessManager::InActivateProcess(), G4hhIonisation::InitialiseEnergyLossProcess(), G4ProcessTable::Insert(), G4ITStepProcessor::InvokeAlongStepDoItProcs(), G4SteppingManager::InvokeAlongStepDoItProcs(), G4SteppingManager::InvokeAtRestDoItProcs(), G4SteppingManager::InvokePSDIP(), G4LossTableManager::LocalPhysicsTables(), G4ErrorPropagator::MakeOneStep(), G4VEmProcess::PostStepDoIt(), G4ITSteppingVerbose::PostStepDoItAllDone(), G4SteppingVerbose::PostStepDoItAllDone(), G4SteppingVerboseWithUnits::PostStepDoItAllDone(), G4ITSteppingVerbose::PostStepDoItOneByOne(), G4SteppingVerbose::PostStepDoItOneByOne(), G4SteppingVerboseWithUnits::PostStepDoItOneByOne(), G4VITDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4DNASecondOrderReaction::PostStepGetPhysicalInteractionLength(), G4VContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VITRestDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VEnergyLossProcess::PostStepGetPhysicalInteractionLength(), G4ITSteppingVerbose::PostStepVerbose(), G4EmConfigurator::PrepareModels(), G4HadronStoppingProcess::PreparePhysicsTable(), G4GammaGeneralProcess::PreparePhysicsTable(), G4VEmProcess::PreparePhysicsTable(), G4VEnergyLossProcess::PreparePhysicsTable(), G4VMultipleScattering::PreparePhysicsTable(), G4LossTableManager::PreparePhysicsTable(), G4HadronicProcessStore::Print(), G4HadronicProcessStore::PrintHtml(), G4AnnihiToMuPair::PrintInfoDefinition(), G4GammaConversionToMuons::PrintInfoDefinition(), G4hImpactIonisation::PrintInfoDefinition(), G4ProcessPlacer::PrintProcVec(), G4VEnergyLossProcess::PrintWarning(), G4VEmProcess::PrintWarning(), G4SynchrotronRadiation::ProcessDescription(), G4Decay::ProcessDescription(), G4DecayWithSpin::ProcessDescription(), G4PionDecayMakeSpin::ProcessDescription(), G4UnknownDecay::ProcessDescription(), G4ChannelingOptrChangeCrossSection::ProposeOccurenceBiasingOperation(), G4StackManager::PushOneTrack(), G4HadronicProcessStore::Register(), G4LossTableManager::Register(), G4LossTableManager::RegisterExtraParticle(), G4HadronicProcessStore::RegisterExtraProcess(), G4HadronicProcessStore::RegisterParticle(), G4WrapperProcess::RegisterProcess(), G4PhysicsListHelper::RegisterProcess(), G4ProcessTable::Remove(), G4ParallelGeometriesLimiterProcess::RemoveParallelWorld(), G4ProcessManager::RemoveProcess(), G4ProcessPlacer::RemoveProcess(), G4GammaGeneralProcess::RetrievePhysicsTable(), G4VEmProcess::RetrievePhysicsTable(), G4VEnergyLossProcess::RetrievePhysicsTable(), G4VEmProcess::SetCrossSectionBiasingFactor(), G4VEnergyLossProcess::SetCrossSectionBiasingFactor(), G4VEnergyLossProcess::SetCSDARangeTable(), G4VEnergyLossProcess::SetInverseRangeTable(), G4VEnergyLossProcess::SetLambdaTable(), G4ProcessTableMessenger::SetNewValue(), G4ProcessTable::SetProcessActivation(), G4ProcessManager::SetProcessOrdering(), G4ProcessManager::SetProcessOrderingToFirst(), G4ProcessManager::SetProcessOrderingToLast(), G4ProcessManager::SetProcessOrderingToSecond(), G4VEnergyLossProcess::SetRangeTableForLoss(), G4VEnergyLossProcess::SetSecondaryRangeTable(), G4FastSimulationManagerProcess::SetWorldVolume(), G4ITSteppingVerbose::ShowStep(), G4SteppingVerbose::ShowStep(), G4SteppingVerboseWithUnits::ShowStep(), G4ChannelingOptrChangeCrossSection::StartRun(), G4ITSteppingVerbose::StepInfo(), G4SteppingVerbose::StepInfo(), G4SteppingVerboseWithUnits::StepInfo(), G4ITSteppingVerbose::StepInfoForLeadingTrack(), G4VEmProcess::StorePhysicsTable(), G4VMultipleScattering::StorePhysicsTable(), G4VEnergyLossProcess::StreamInfo(), G4VEmProcess::StreamInfo(), G4VMultipleScattering::StreamInfo(), G4EmCalculator::UpdateParticle(), G4ParallelWorldScoringProcess::Verbose(), G4ScoreSplittingProcess::Verbose(), G4ITSteppingVerbose::VerboseTrack(), G4SteppingVerbose::VerboseTrack(), and G4SteppingVerboseWithUnits::VerboseTrack().

◆ GetProcessSubType()

G4int G4VProcess::GetProcessSubType ( ) const
inlineinherited

◆ GetProcessType()

G4ProcessType G4VProcess::GetProcessType ( ) const
inlineinherited

◆ GetProcessTypeName()

const G4String & G4VProcess::GetProcessTypeName ( G4ProcessType  aType)
staticinherited

Definition at line 134 of file G4VProcess.cc.

135{
136 switch (aType)
137 {
138 case fNotDefined: return typeNotDefined; break;
139 case fTransportation: return typeTransportation; break;
140 case fElectromagnetic: return typeElectromagnetic; break;
141 case fOptical: return typeOptical; break;
142 case fHadronic: return typeHadronic; break;
144 case fDecay: return typeDecay; break;
145 case fGeneral: return typeGeneral; break;
146 case fParameterisation: return typeParameterisation; break;
147 case fUserDefined: return typeUserDefined; break;
148 case fPhonon: return typePhonon; break;
149 default: ;
150 }
151 return noType;
152}
@ fOptical
@ fPhonon
@ fParameterisation
@ fGeneral
@ fDecay
@ fElectromagnetic
@ fHadronic
@ fUserDefined
@ fTransportation
@ fPhotolepton_hadron
@ fNotDefined
static const G4String typeNotDefined
Definition: G4VProcess.cc:119
static const G4String typeParameterisation
Definition: G4VProcess.cc:127
static const G4String typePhotolepton_hadron
Definition: G4VProcess.cc:124
static const G4String typeElectromagnetic
Definition: G4VProcess.cc:121
static const G4String noType
Definition: G4VProcess.cc:130
static const G4String typeUserDefined
Definition: G4VProcess.cc:128
static const G4String typeDecay
Definition: G4VProcess.cc:125
static const G4String typeTransportation
Definition: G4VProcess.cc:120
static const G4String typeHadronic
Definition: G4VProcess.cc:123
static const G4String typeOptical
Definition: G4VProcess.cc:122
static const G4String typeGeneral
Definition: G4VProcess.cc:126
static const G4String typePhonon
Definition: G4VProcess.cc:129

References fDecay, fElectromagnetic, fGeneral, fHadronic, fNotDefined, fOptical, fParameterisation, fPhonon, fPhotolepton_hadron, fTransportation, fUserDefined, anonymous_namespace{G4VProcess.cc}::noType, anonymous_namespace{G4VProcess.cc}::typeDecay, anonymous_namespace{G4VProcess.cc}::typeElectromagnetic, anonymous_namespace{G4VProcess.cc}::typeGeneral, anonymous_namespace{G4VProcess.cc}::typeHadronic, anonymous_namespace{G4VProcess.cc}::typeNotDefined, anonymous_namespace{G4VProcess.cc}::typeOptical, anonymous_namespace{G4VProcess.cc}::typeParameterisation, anonymous_namespace{G4VProcess.cc}::typePhonon, anonymous_namespace{G4VProcess.cc}::typePhotolepton_hadron, anonymous_namespace{G4VProcess.cc}::typeTransportation, and anonymous_namespace{G4VProcess.cc}::typeUserDefined.

Referenced by G4RichTrajectory::CreateAttValues(), G4RichTrajectoryPoint::CreateAttValues(), G4ProcessManager::DumpInfo(), G4VProcess::DumpInfo(), G4ProcessTableMessenger::G4ProcessTableMessenger(), G4ProcessTableMessenger::GetProcessType(), G4ProcessTableMessenger::GetProcessTypeName(), and G4ProcessTableMessenger::SetNumberOfProcessType().

◆ GetSplitNuclei()

G4int G4Radioactivation::GetSplitNuclei ( )
inline

Definition at line 128 of file G4Radioactivation.hh.

128{return NSplit;}

References NSplit.

◆ GetTheRadioactivityTables()

std::vector< G4RadioactivityTable * > G4Radioactivation::GetTheRadioactivityTables ( )
inline

Definition at line 98 of file G4Radioactivation.hh.

References theRadioactivityTables.

◆ GetThresholdForVeryLongDecayTime()

G4double G4RadioactiveDecay::GetThresholdForVeryLongDecayTime ( ) const
inlineinherited

◆ GetTotalNumberOfInteractionLengthTraversed()

G4double G4VProcess::GetTotalNumberOfInteractionLengthTraversed ( ) const
inlineinherited

◆ GetVerboseLevel()

G4int G4RadioactiveDecay::GetVerboseLevel ( ) const
inlineinherited

◆ isAlongStepDoItIsEnabled()

G4bool G4VProcess::isAlongStepDoItIsEnabled ( ) const
inlineinherited

Definition at line 506 of file G4VProcess.hh.

507{
508 return enableAlongStepDoIt;
509}
G4bool enableAlongStepDoIt
Definition: G4VProcess.hh:360

References G4VProcess::enableAlongStepDoIt.

Referenced by G4ProcessManager::CheckOrderingParameters().

◆ IsAnalogueMonteCarlo()

G4bool G4Radioactivation::IsAnalogueMonteCarlo ( )
inline

Definition at line 113 of file G4Radioactivation.hh.

113{return AnalogueMC;}

References AnalogueMC.

◆ IsApplicable()

G4bool G4RadioactiveDecay::IsApplicable ( const G4ParticleDefinition aParticle)
virtualinherited

Reimplemented from G4VProcess.

Definition at line 208 of file G4RadioactiveDecay.cc.

209{
210 // All particles other than G4Ions, are rejected by default
211 if (((const G4Ions*)(&aParticle))->GetExcitationEnergy() > 0.) {return true;}
212 if (aParticle.GetParticleName() == "GenericIon") {
213 return true;
214 } else if (!(aParticle.GetParticleType() == "nucleus")
215 || aParticle.GetPDGLifeTime() < 0. ) {
216 return false;
217 }
218
219 // Determine whether the nuclide falls into the correct A and Z range
220 G4int A = ((const G4Ions*) (&aParticle))->GetAtomicMass();
221 G4int Z = ((const G4Ions*) (&aParticle))->GetAtomicNumber();
222
224 {return false;}
226 {return false;}
227 return true;
228}
G4int GetZMax() const
G4int GetZMin() const
G4int GetAMin() const
G4int GetAMax() const
const G4String & GetParticleType() const

References A, G4NucleusLimits::GetAMax(), G4NucleusLimits::GetAMin(), G4ParticleDefinition::GetParticleName(), G4ParticleDefinition::GetParticleType(), G4ParticleDefinition::GetPDGLifeTime(), G4NucleusLimits::GetZMax(), G4NucleusLimits::GetZMin(), G4RadioactiveDecay::theNucleusLimits, and Z.

Referenced by CalculateChainsFromParent(), DecayIt(), and G4RadioactiveDecay::DecayIt().

◆ isAtRestDoItIsEnabled()

G4bool G4VProcess::isAtRestDoItIsEnabled ( ) const
inlineinherited

Definition at line 500 of file G4VProcess.hh.

501{
502 return enableAtRestDoIt;
503}
G4bool enableAtRestDoIt
Definition: G4VProcess.hh:359

References G4VProcess::enableAtRestDoIt.

Referenced by G4ProcessManager::CheckOrderingParameters().

◆ isPostStepDoItIsEnabled()

G4bool G4VProcess::isPostStepDoItIsEnabled ( ) const
inlineinherited

Definition at line 512 of file G4VProcess.hh.

513{
514 return enablePostStepDoIt;
515}
G4bool enablePostStepDoIt
Definition: G4VProcess.hh:361

References G4VProcess::enablePostStepDoIt.

Referenced by G4ProcessManager::CheckOrderingParameters().

◆ IsRateTableReady()

G4bool G4Radioactivation::IsRateTableReady ( const G4ParticleDefinition aParticle)

Definition at line 160 of file G4Radioactivation.cc.

161{
162 // Check whether the radioactive decay rates table for the ion has already
163 // been calculated.
164 G4String aParticleName = aParticle.GetParticleName();
165 for (size_t i = 0; i < theParentChainTable.size(); i++) {
166 if (theParentChainTable[i].GetIonName() == aParticleName) return true;
167 }
168 return false;
169}

References G4ParticleDefinition::GetParticleName(), and theParentChainTable.

Referenced by DecayIt().

◆ LoadDecayTable()

G4DecayTable * G4RadioactiveDecay::LoadDecayTable ( const G4ParticleDefinition theParentNucleus)
inherited

Definition at line 517 of file G4RadioactiveDecay.cc.

518{
519 // Generate input data file name using Z and A of the parent nucleus
520 // file containing radioactive decay data.
521 G4int A = ((const G4Ions*)(&theParentNucleus))->GetAtomicMass();
522 G4int Z = ((const G4Ions*)(&theParentNucleus))->GetAtomicNumber();
523
524 G4double levelEnergy = ((const G4Ions*)(&theParentNucleus))->GetExcitationEnergy();
525 G4Ions::G4FloatLevelBase floatingLevel =
526 ((const G4Ions*)(&theParentNucleus))->GetFloatLevelBase();
527
528#ifdef G4MULTITHREADED
529 G4AutoLock lk(&G4RadioactiveDecay::radioactiveDecayMutex);
530
531 G4String key = theParentNucleus.GetParticleName();
532 DecayTableMap::iterator master_table_ptr = master_dkmap->find(key);
533
534 if (master_table_ptr != master_dkmap->end() ) { // If table is there
535 return master_table_ptr->second;
536 }
537#endif
538
539 //Check if data have been provided by the user
541
542 if (file == "") {
543 std::ostringstream os;
544 os << dirPath << "/z" << Z << ".a" << A << '\0';
545 file = os.str();
546 }
547
548 G4DecayTable* theDecayTable = new G4DecayTable();
549 G4bool found(false); // True if energy level matches one in table
550
551 std::ifstream DecaySchemeFile;
552 DecaySchemeFile.open(file);
553
554 if (DecaySchemeFile.good()) {
555 // Initialize variables used for reading in radioactive decay data
556 G4bool floatMatch(false);
557 const G4int nMode = G4RadioactiveDecayModeSize;
558 G4double modeTotalBR[nMode] = {0.0};
559 G4double modeSumBR[nMode];
560 for (G4int i = 0; i < nMode; i++) {
561 modeSumBR[i] = 0.0;
562 }
563
564 char inputChars[120]={' '};
565 G4String inputLine;
566 G4String recordType("");
567 G4String floatingFlag("");
568 G4String daughterFloatFlag("");
569 G4Ions::G4FloatLevelBase daughterFloatLevel;
570 G4RadioactiveDecayMode theDecayMode;
571 G4double decayModeTotal(0.0);
572 G4double parentExcitation(0.0);
573 G4double a(0.0);
574 G4double b(0.0);
575 G4double c(0.0);
576 G4double dummy(0.0);
577 G4BetaDecayType betaType(allowed);
578
579 // Loop through each data file record until you identify the decay
580 // data relating to the nuclide of concern.
581
582 G4bool complete(false); // bool insures only one set of values read for any
583 // given parent energy level
584 G4int loop = 0;
585 while (!complete && !DecaySchemeFile.getline(inputChars, 120).eof()) { /* Loop checking, 01.09.2015, D.Wright */
586 loop++;
587 if (loop > 100000) {
588 G4Exception("G4RadioactiveDecay::LoadDecayTable()", "HAD_RDM_100",
589 JustWarning, "While loop count exceeded");
590 break;
591 }
592
593 inputLine = inputChars;
594 G4StrUtil::rstrip(inputLine);
595 if (inputChars[0] != '#' && inputLine.length() != 0) {
596 std::istringstream tmpStream(inputLine);
597
598 if (inputChars[0] == 'P') {
599 // Nucleus is a parent type. Check excitation level to see if it
600 // matches that of theParentNucleus
601 tmpStream >> recordType >> parentExcitation >> floatingFlag >> dummy;
602 // "dummy" takes the place of half-life
603 // Now read in from ENSDFSTATE in particle category
604
605 if (found) {
606 complete = true;
607 } else {
608 // Take first level which matches excitation energy regardless of floating level
609 found = (std::abs(parentExcitation*keV - levelEnergy) < levelTolerance);
610 if (floatingLevel != noFloat) {
611 // If floating level specificed, require match of both energy and floating level
612 floatMatch = (floatingLevel == G4Ions::FloatLevelBase(floatingFlag.back()) );
613 if (!floatMatch) found = false;
614 }
615 }
616
617 } else if (found) {
618 // The right part of the radioactive decay data file has been found. Search
619 // through it to determine the mode of decay of the subsequent records.
620
621 // Store for later the total decay probability for each decay mode
622 if (inputLine.length() < 72) {
623 tmpStream >> theDecayMode >> dummy >> decayModeTotal;
624 switch (theDecayMode) {
625 case IT:
626 {
627 G4ITDecay* anITChannel = new G4ITDecay(&theParentNucleus, decayModeTotal,
628 0.0, 0.0, photonEvaporation);
629// anITChannel->SetHLThreshold(halflifethreshold);
630 anITChannel->SetARM(applyARM);
631 theDecayTable->Insert(anITChannel);
632// anITChannel->DumpNuclearInfo();
633 }
634 break;
635 case BetaMinus:
636 modeTotalBR[BetaMinus] = decayModeTotal; break;
637 case BetaPlus:
638 modeTotalBR[BetaPlus] = decayModeTotal; break;
639 case KshellEC:
640 modeTotalBR[KshellEC] = decayModeTotal; break;
641 case LshellEC:
642 modeTotalBR[LshellEC] = decayModeTotal; break;
643 case MshellEC:
644 modeTotalBR[MshellEC] = decayModeTotal; break;
645 case NshellEC:
646 modeTotalBR[NshellEC] = decayModeTotal; break;
647 case Alpha:
648 modeTotalBR[Alpha] = decayModeTotal; break;
649 case Proton:
650 modeTotalBR[Proton] = decayModeTotal; break;
651 case Neutron:
652 modeTotalBR[Neutron] = decayModeTotal; break;
653 case SpFission:
654 modeTotalBR[SpFission] = decayModeTotal; break;
655 case BDProton:
656 /* Not yet implemented */ break;
657 case BDNeutron:
658 /* Not yet implemented */ break;
659 case Beta2Minus:
660 /* Not yet implemented */ break;
661 case Beta2Plus:
662 /* Not yet implemented */ break;
663 case Proton2:
664 /* Not yet implemented */ break;
665 case Neutron2:
666 /* Not yet implemented */ break;
667 case Triton:
668 modeTotalBR[Triton] = decayModeTotal; break;
669 case RDM_ERROR:
670
671 default:
672 G4Exception("G4RadioactiveDecay::LoadDecayTable()", "HAD_RDM_000",
673 FatalException, "Selected decay mode does not exist");
674 } // switch
675
676 } else {
677 if (inputLine.length() < 84) {
678 tmpStream >> theDecayMode >> a >> daughterFloatFlag >> b >> c;
679 betaType = allowed;
680 } else {
681 tmpStream >> theDecayMode >> a >> daughterFloatFlag >> b >> c >> betaType;
682 }
683
684 // Allowed transitions are the default. Forbidden transitions are
685 // indicated in the last column.
686 a /= 1000.;
687 c /= 1000.;
688 b /= 100.;
689 daughterFloatLevel = G4Ions::FloatLevelBase(daughterFloatFlag.back());
690
691 switch (theDecayMode) {
692 case BetaMinus:
693 {
694 G4BetaMinusDecay* aBetaMinusChannel =
695 new G4BetaMinusDecay(&theParentNucleus, b, c*MeV, a*MeV,
696 daughterFloatLevel, betaType);
697// aBetaMinusChannel->DumpNuclearInfo();
698// aBetaMinusChannel->SetHLThreshold(halflifethreshold);
699 theDecayTable->Insert(aBetaMinusChannel);
700 modeSumBR[BetaMinus] += b;
701 }
702 break;
703
704 case BetaPlus:
705 {
706 G4BetaPlusDecay* aBetaPlusChannel =
707 new G4BetaPlusDecay(&theParentNucleus, b, c*MeV, a*MeV,
708 daughterFloatLevel, betaType);
709// aBetaPlusChannel->DumpNuclearInfo();
710// aBetaPlusChannel->SetHLThreshold(halflifethreshold);
711 theDecayTable->Insert(aBetaPlusChannel);
712 modeSumBR[BetaPlus] += b;
713 }
714 break;
715
716 case KshellEC: // K-shell electron capture
717 {
718 G4ECDecay* aKECChannel =
719 new G4ECDecay(&theParentNucleus, b, c*MeV, a*MeV,
720 daughterFloatLevel, KshellEC);
721// aKECChannel->DumpNuclearInfo();
722// aKECChannel->SetHLThreshold(halflifethreshold);
723 aKECChannel->SetARM(applyARM);
724 theDecayTable->Insert(aKECChannel);
725 modeSumBR[KshellEC] += b;
726 }
727 break;
728
729 case LshellEC: // L-shell electron capture
730 {
731 G4ECDecay* aLECChannel =
732 new G4ECDecay(&theParentNucleus, b, c*MeV, a*MeV,
733 daughterFloatLevel, LshellEC);
734// aLECChannel->DumpNuclearInfo();
735// aLECChannel->SetHLThreshold(halflifethreshold);
736 aLECChannel->SetARM(applyARM);
737 theDecayTable->Insert(aLECChannel);
738 modeSumBR[LshellEC] += b;
739 }
740 break;
741
742 case MshellEC: // M-shell electron capture
743 {
744 G4ECDecay* aMECChannel =
745 new G4ECDecay(&theParentNucleus, b, c*MeV, a*MeV,
746 daughterFloatLevel, MshellEC);
747// aMECChannel->DumpNuclearInfo();
748// aMECChannel->SetHLThreshold(halflifethreshold);
749 aMECChannel->SetARM(applyARM);
750 theDecayTable->Insert(aMECChannel);
751 modeSumBR[MshellEC] += b;
752 }
753 break;
754
755 case NshellEC: // N-shell electron capture
756 {
757 G4ECDecay* aNECChannel =
758 new G4ECDecay(&theParentNucleus, b, c*MeV, a*MeV,
759 daughterFloatLevel, NshellEC);
760// aNECChannel->DumpNuclearInfo();
761// aNECChannel->SetHLThreshold(halflifethreshold);
762 aNECChannel->SetARM(applyARM);
763 theDecayTable->Insert(aNECChannel);
764 modeSumBR[NshellEC] += b;
765 }
766 break;
767
768 case Alpha:
769 {
770 G4AlphaDecay* anAlphaChannel =
771 new G4AlphaDecay(&theParentNucleus, b, c*MeV, a*MeV,
772 daughterFloatLevel);
773// anAlphaChannel->DumpNuclearInfo();
774// anAlphaChannel->SetHLThreshold(halflifethreshold);
775 theDecayTable->Insert(anAlphaChannel);
776 modeSumBR[Alpha] += b;
777 }
778 break;
779
780 case Proton:
781 {
782 G4ProtonDecay* aProtonChannel =
783 new G4ProtonDecay(&theParentNucleus, b, c*MeV, a*MeV,
784 daughterFloatLevel);
785// aProtonChannel->DumpNuclearInfo();
786// aProtonChannel->SetHLThreshold(halflifethreshold);
787 theDecayTable->Insert(aProtonChannel);
788 modeSumBR[Proton] += b;
789 }
790 break;
791
792 case Neutron:
793 {
794 G4NeutronDecay* aNeutronChannel =
795 new G4NeutronDecay(&theParentNucleus, b, c*MeV, a*MeV,
796 daughterFloatLevel);
797// aNeutronChannel->DumpNuclearInfo();
798// aNeutronChannel->SetHLThreshold(halflifethreshold);
799 theDecayTable->Insert(aNeutronChannel);
800 modeSumBR[Neutron] += b;
801 }
802 break;
803
804 case SpFission:
805 {
806 G4SFDecay* aSpontFissChannel =
807// new G4SFDecay(&theParentNucleus, decayModeTotal, 0.0, 0.0);
808 new G4SFDecay(&theParentNucleus, b, c*MeV, a*MeV,
809 daughterFloatLevel);
810 theDecayTable->Insert(aSpontFissChannel);
811 modeSumBR[SpFission] += b;
812 }
813 break;
814
815 case BDProton:
816 // Not yet implemented
817 // G4cout << " beta-delayed proton decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
818 break;
819
820 case BDNeutron:
821 // Not yet implemented
822 // G4cout << " beta-delayed neutron decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
823 break;
824
825 case Beta2Minus:
826 // Not yet implemented
827 // G4cout << " Double beta- decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
828 break;
829
830 case Beta2Plus:
831 // Not yet implemented
832 // G4cout << " Double beta+ decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
833 break;
834
835 case Proton2:
836 // Not yet implemented
837 // G4cout << " Double proton decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
838 break;
839
840 case Neutron2:
841 // Not yet implemented
842 // G4cout << " Double beta- decay, a = " << a << ", b = " << b << ", c = " << c << G4endl;
843 break;
844
845 case Triton:
846 {
847 G4TritonDecay* aTritonChannel =
848 new G4TritonDecay(&theParentNucleus, b, c*MeV, a*MeV,
849 daughterFloatLevel);
850 // anAlphaChannel->DumpNuclearInfo();
851 // anAlphaChannel->SetHLThreshold(halflifethreshold);
852 theDecayTable->Insert(aTritonChannel);
853 modeSumBR[Triton] += b;
854 }
855 break;
856
857 case RDM_ERROR:
858
859 default:
860 G4Exception("G4RadioactiveDecay::LoadDecayTable()", "HAD_RDM_000",
861 FatalException, "Selected decay mode does not exist");
862 } // switch
863 } // line < 72
864 } // if char == P
865 } // if char != #
866 } // While
867
868 // Go through the decay table and make sure that the branching ratios are
869 // correctly normalised.
870
871 G4VDecayChannel* theChannel = 0;
872 G4NuclearDecay* theNuclearDecayChannel = 0;
873 G4String mode = "";
874
875 G4double theBR = 0.0;
876 for (G4int i = 0; i < theDecayTable->entries(); i++) {
877 theChannel = theDecayTable->GetDecayChannel(i);
878 theNuclearDecayChannel = static_cast<G4NuclearDecay*>(theChannel);
879 theDecayMode = theNuclearDecayChannel->GetDecayMode();
880
881 if (theDecayMode != IT) {
882 theBR = theChannel->GetBR();
883 theChannel->SetBR(theBR*modeTotalBR[theDecayMode]/modeSumBR[theDecayMode]);
884 }
885 }
886 } // decay file exists
887
888 DecaySchemeFile.close();
889
890 if (!found && levelEnergy > 0) {
891 // Case where IT cascade for excited isotopes has no entries in RDM database
892 // Decay mode is isomeric transition.
893 G4ITDecay* anITChannel = new G4ITDecay(&theParentNucleus, 1.0, 0.0, 0.0,
895// anITChannel->SetHLThreshold(halflifethreshold);
896 anITChannel->SetARM(applyARM);
897 theDecayTable->Insert(anITChannel);
898 }
899
900 if (theDecayTable && GetVerboseLevel() > 1) {
901 theDecayTable->DumpInfo();
902 }
903
904#ifdef G4MULTITHREADED
905 //(*master_dkmap)[key] = theDecayTable; // store in master library
906#endif
907 return theDecayTable;
908}
G4BetaDecayType
void SetARM(G4bool onoff)
Definition: G4ECDecay.hh:56
void SetARM(G4bool onoff)
Definition: G4ITDecay.hh:59
static G4Ions::G4FloatLevelBase FloatLevelBase(char flbChar)
Definition: G4Ions.cc:103
G4FloatLevelBase
Definition: G4Ions.hh:83
void SetBR(G4double value)
void rstrip(G4String &str, char c=' ')
Remove trailing characters from string.

References A, allowed, Alpha, G4RadioactiveDecay::applyARM, BDNeutron, BDProton, Beta2Minus, Beta2Plus, BetaMinus, BetaPlus, G4RadioactiveDecay::dirPath, G4DecayTable::DumpInfo(), G4DecayTable::entries(), FatalException, geant4_check_module_cycles::file, G4Ions::FloatLevelBase(), G4Exception(), G4RadioactiveDecayModeSize, G4VDecayChannel::GetBR(), G4DecayTable::GetDecayChannel(), G4NuclearDecay::GetDecayMode(), G4ParticleDefinition::GetParticleName(), G4RadioactiveDecay::GetVerboseLevel(), G4DecayTable::Insert(), IT, JustWarning, keV, KshellEC, G4RadioactiveDecay::levelTolerance, LshellEC, MeV, MshellEC, Neutron, Neutron2, noFloat, NshellEC, G4RadioactiveDecay::photonEvaporation, Proton, Proton2, RDM_ERROR, G4StrUtil::rstrip(), G4ECDecay::SetARM(), G4ITDecay::SetARM(), G4VDecayChannel::SetBR(), SpFission, G4RadioactiveDecay::theUserRadioactiveDataFiles, Triton, and Z.

Referenced by G4RadioactiveDecay::GetDecayTable(), and GetDecayTable1().

◆ operator!=()

G4bool G4VProcess::operator!= ( const G4VProcess right) const
inherited

Definition at line 161 of file G4VProcess.cc.

162{
163 return (this != &right);
164}

◆ operator==()

G4bool G4VProcess::operator== ( const G4VProcess right) const
inherited

Definition at line 155 of file G4VProcess.cc.

156{
157 return (this == &right);
158}

◆ PostStepDoIt()

G4VParticleChange * G4Radioactivation::PostStepDoIt ( const G4Track theTrack,
const G4Step theStep 
)
inlineprivatevirtual

Reimplemented from G4VRestDiscreteProcess.

Definition at line 181 of file G4Radioactivation.hh.

182 {return DecayIt(theTrack, theStep);}

References DecayIt().

◆ PostStepGetPhysicalInteractionLength()

G4double G4VRestDiscreteProcess::PostStepGetPhysicalInteractionLength ( const G4Track track,
G4double  previousStepSize,
G4ForceCondition condition 
)
virtualinherited

Implements G4VProcess.

Reimplemented in G4MuonicAtomDecay, and G4Decay.

Definition at line 71 of file G4VRestDiscreteProcess.cc.

75{
76 if ( (previousStepSize < 0.0) || (theNumberOfInteractionLengthLeft<=0.0))
77 {
78 // beginning of tracking (or just after DoIt() of this process)
80 }
81 else if ( previousStepSize > 0.0)
82 {
83 // subtract NumberOfInteractionLengthLeft
85 }
86 else
87 {
88 // zero step
89 // DO NOTHING
90 }
91
92 // condition is set to "Not Forced"
94
95 // get mean free path
96 currentInteractionLength = GetMeanFreePath(track,previousStepSize,condition);
97
98 G4double value;
100 {
102 }
103 else
104 {
105 value = DBL_MAX;
106 }
107#ifdef G4VERBOSE
108 if (verboseLevel>1)
109 {
110 G4cout << "G4VRestDiscreteProcess::PostStepGetPhysicalInteractionLength() - ";
111 G4cout << "[ " << GetProcessName() << "]" << G4endl;
112 track.GetDynamicParticle()->DumpInfo();
113 G4cout << " in Material " << track.GetMaterial()->GetName() << G4endl;
114 G4cout << "InteractionLength= " << value/cm <<"[cm] " << G4endl;
115 }
116#endif
117 return value;
118}
@ NotForced
void DumpInfo(G4int mode=0) const
const G4String & GetName() const
Definition: G4Material.hh:173
G4Material * GetMaterial() const
void SubtractNumberOfInteractionLengthLeft(G4double prevStepSize)
Definition: G4VProcess.hh:524
virtual void ResetNumberOfInteractionLengthLeft()
Definition: G4VProcess.cc:80
const G4String & GetProcessName() const
Definition: G4VProcess.hh:382
virtual G4double GetMeanFreePath(const G4Track &aTrack, G4double previousStepSize, G4ForceCondition *condition)=0

References cm, condition(), G4VProcess::currentInteractionLength, DBL_MAX, G4DynamicParticle::DumpInfo(), G4cout, G4endl, G4Track::GetDynamicParticle(), G4Track::GetMaterial(), G4VRestDiscreteProcess::GetMeanFreePath(), G4Material::GetName(), G4VProcess::GetProcessName(), NotForced, G4VProcess::ResetNumberOfInteractionLengthLeft(), G4VProcess::SubtractNumberOfInteractionLengthLeft(), G4VProcess::theNumberOfInteractionLengthLeft, and G4VProcess::verboseLevel.

◆ PostStepGPIL()

G4double G4VProcess::PostStepGPIL ( const G4Track track,
G4double  previousStepSize,
G4ForceCondition condition 
)
inlineinherited

Definition at line 479 of file G4VProcess.hh.

482{
483 return thePILfactor *
484 PostStepGetPhysicalInteractionLength(track, previousStepSize, condition);
485}
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)=0

References condition(), G4VProcess::PostStepGetPhysicalInteractionLength(), and G4VProcess::thePILfactor.

Referenced by G4SteppingManager::DefinePhysicalStepLength(), and G4ITStepProcessor::DoDefinePhysicalStepLength().

◆ PreparePhysicsTable()

virtual void G4VProcess::PreparePhysicsTable ( const G4ParticleDefinition )
inlinevirtualinherited

◆ PrepareWorkerPhysicsTable()

void G4VProcess::PrepareWorkerPhysicsTable ( const G4ParticleDefinition part)
virtualinherited

Reimplemented in G4BiasingProcessInterface.

Definition at line 206 of file G4VProcess.cc.

207{
209}
virtual void PreparePhysicsTable(const G4ParticleDefinition &)
Definition: G4VProcess.hh:194

References G4VProcess::PreparePhysicsTable().

Referenced by G4BiasingProcessInterface::PrepareWorkerPhysicsTable().

◆ ProcessDescription()

void G4Radioactivation::ProcessDescription ( std::ostream &  outFile) const
virtual

Reimplemented from G4RadioactiveDecay.

Definition at line 127 of file G4Radioactivation.cc.

128{
129 outFile << "The G4Radioactivation process performs radioactive decay of\n"
130 << "nuclides (G4GenericIon) in biased mode which includes nucleus\n"
131 << "duplication, branching ratio biasing, source time convolution\n"
132 << "and detector time convolution. It is designed for use in\n"
133 << "activation physics.\n"
134 << "The required half-lives and decay schemes are retrieved from\n"
135 << "the RadioactiveDecay database which was derived from ENSDF.\n";
136}

◆ ResetNumberOfInteractionLengthLeft()

void G4VProcess::ResetNumberOfInteractionLengthLeft ( )
virtualinherited

◆ RetrievePhysicsTable()

virtual G4bool G4VProcess::RetrievePhysicsTable ( const G4ParticleDefinition ,
const G4String ,
G4bool   
)
inlinevirtualinherited

◆ SelectAllVolumes()

void G4RadioactiveDecay::SelectAllVolumes ( )
inherited

Definition at line 308 of file G4RadioactiveDecay.cc.

309{
311 G4LogicalVolume* volume = nullptr;
312 ValidVolumes.clear();
313#ifdef G4VERBOSE
314 if (GetVerboseLevel()>1)
315 G4cout << " RDM Applies to all Volumes" << G4endl;
316#endif
317 for (std::size_t i = 0; i < theLogicalVolumes->size(); ++i){
318 volume = (*theLogicalVolumes)[i];
319 ValidVolumes.push_back(volume->GetName());
320#ifdef G4VERBOSE
321 if (GetVerboseLevel()>1)
322 G4cout << " RDM Applies to Volume " << volume->GetName() << G4endl;
323#endif
324 }
325 std::sort(ValidVolumes.begin(), ValidVolumes.end());
326 // sort needed in order to allow binary_search
327 isAllVolumesMode=true;
328}

References G4cout, G4endl, G4LogicalVolumeStore::GetInstance(), G4LogicalVolume::GetName(), G4RadioactiveDecay::GetVerboseLevel(), G4RadioactiveDecay::isAllVolumesMode, and G4RadioactiveDecay::ValidVolumes.

Referenced by G4RadioactiveDecay::G4RadioactiveDecay(), and G4RadioactiveDecayMessenger::SetNewValue().

◆ SelectAVolume()

void G4RadioactiveDecay::SelectAVolume ( const G4String aVolume)
inherited

Definition at line 246 of file G4RadioactiveDecay.cc.

247{
249 G4LogicalVolume* volume = nullptr;
250 volume = theLogicalVolumes->GetVolume(aVolume);
251 if (volume != nullptr)
252 {
253 ValidVolumes.push_back(aVolume);
254 std::sort(ValidVolumes.begin(), ValidVolumes.end());
255 // sort need for performing binary_search
256
257 if (GetVerboseLevel() > 0)
258 G4cout << " Radioactive decay applied to " << aVolume << G4endl;
259 }
260 else
261 {
263 ed << aVolume << " is not a valid logical volume name."
264 << " Decay not activated for it."
265 << G4endl;
266 G4Exception("G4RadioactiveDecay::SelectAVolume()", "HAD_RDM_300",
267 JustWarning, ed);
268 }
269}

References G4cout, G4endl, G4Exception(), G4LogicalVolumeStore::GetInstance(), G4RadioactiveDecay::GetVerboseLevel(), G4LogicalVolumeStore::GetVolume(), JustWarning, and G4RadioactiveDecay::ValidVolumes.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ SetAnalogueMonteCarlo()

void G4Radioactivation::SetAnalogueMonteCarlo ( G4bool  r)
inline

Definition at line 106 of file G4Radioactivation.hh.

106 {
107 AnalogueMC = r;
109 }
static constexpr double s

References AnalogueMC, halflifethreshold, and CLHEP::s.

◆ SetARM()

void G4RadioactiveDecay::SetARM ( G4bool  arm)
inlineinherited

Definition at line 106 of file G4RadioactiveDecay.hh.

106{applyARM = arm;}

References G4RadioactiveDecay::applyARM.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ SetBRBias()

void G4Radioactivation::SetBRBias ( G4bool  r)
inline

Definition at line 116 of file G4Radioactivation.hh.

116 {
117 BRBias = r;
118 AnalogueMC = false;
119 }

References AnalogueMC, and BRBias.

◆ SetDecayBias()

void G4Radioactivation::SetDecayBias ( G4String  filename)

Definition at line 751 of file G4Radioactivation.cc.

752{
753 std::ifstream infile(filename, std::ios::in);
754 if (!infile) G4Exception("G4Radioactivation::SetDecayBias()", "HAD_RDM_001",
755 FatalException, "Unable to open bias data file" );
756
757 G4double bin, flux;
758 G4int dWindows = 0;
759 G4int i ;
760
762
763 NDecayBin = -1;
764
765 G4int loop = 0;
766 while (infile >> bin >> flux ) { /* Loop checking, 01.09.2015, D.Wright */
767 NDecayBin++;
768 loop++;
769 if (loop > 10000) {
770 G4Exception("G4Radioactivation::SetDecayBias()", "HAD_RDM_100",
771 JustWarning, "While loop count exceeded");
772 break;
773 }
774
775 if (NDecayBin > 99) {
776 G4Exception("G4Radioactivation::SetDecayBias()", "HAD_RDM_002",
777 FatalException, "Input bias file too big (>100 rows)" );
778 } else {
779 DBin[NDecayBin] = bin * s; // Convert read-in time to ns
780 DProfile[NDecayBin] = flux; // Dimensionless
781 if (flux > 0.) {
782 decayWindows[NDecayBin] = dWindows;
783 dWindows++;
785 theRadioactivityTables.push_back(rTable);
786 }
787 }
788 }
789 for ( i = 1; i<= NDecayBin; i++) DProfile[i] += DProfile[i-1]; // Cumulative flux vs i
790 for ( i = 0; i<= NDecayBin; i++) DProfile[i] /= DProfile[NDecayBin];
791 // Normalize so entries increase from 0 to 1
792 // converted to accumulated probabilities
793
794 AnalogueMC = false;
795 infile.close();
796
797#ifdef G4VERBOSE
798 if (GetVerboseLevel() > 2)
799 G4cout <<" Decay Bias Profile Nbin = " << NDecayBin <<G4endl;
800#endif
801}

References AnalogueMC, DBin, decayWindows, DProfile, FatalException, G4cout, G4endl, G4Exception(), G4RadioactiveDecay::GetVerboseLevel(), JustWarning, NDecayBin, s, and theRadioactivityTables.

◆ SetDecayCollimation()

void G4RadioactiveDecay::SetDecayCollimation ( const G4ThreeVector theDir,
G4double  halfAngle = 0.*CLHEP::deg 
)
inlineinherited

Definition at line 146 of file G4RadioactiveDecay.hh.

147 {
148 SetDecayDirection(theDir);
149 SetDecayHalfAngle(halfAngle);
150 }
void SetDecayHalfAngle(G4double halfAngle=0.*CLHEP::deg)
void SetDecayDirection(const G4ThreeVector &theDir)

References G4RadioactiveDecay::SetDecayDirection(), and G4RadioactiveDecay::SetDecayHalfAngle().

◆ SetDecayDirection()

void G4RadioactiveDecay::SetDecayDirection ( const G4ThreeVector theDir)
inlineinherited

◆ SetDecayHalfAngle()

void G4RadioactiveDecay::SetDecayHalfAngle ( G4double  halfAngle = 0.*CLHEP::deg)
inlineinherited

Definition at line 138 of file G4RadioactiveDecay.hh.

138 {
140 }
static constexpr double deg
T max(const T t1, const T t2)
brief Return the largest of the two arguments
T min(const T t1, const T t2)
brief Return the smallest of the two arguments

References CLHEP::deg, G4RadioactiveDecay::forceDecayHalfAngle, G4INCL::Math::max(), and G4INCL::Math::min().

Referenced by G4RadioactiveDecay::SetDecayCollimation(), and G4RadioactiveDecayMessenger::SetNewValue().

◆ SetDecayRate()

void G4Radioactivation::SetDecayRate ( G4int  theZ,
G4int  theA,
G4double  theE,
G4int  theG,
std::vector< G4double theCoefficients,
std::vector< G4double theTaos 
)

◆ SetHLThreshold()

void G4Radioactivation::SetHLThreshold ( G4double  hl)
inline

Definition at line 71 of file G4Radioactivation.hh.

References halflifethreshold.

◆ SetICM()

void G4RadioactiveDecay::SetICM ( G4bool  icm)
inlineinherited

◆ SetMasterProcess()

void G4VProcess::SetMasterProcess ( G4VProcess masterP)
virtualinherited

◆ SetNucleusLimits()

void G4RadioactiveDecay::SetNucleusLimits ( G4NucleusLimits  theNucleusLimits1)
inlineinherited

Definition at line 121 of file G4RadioactiveDecay.hh.

122 {theNucleusLimits = theNucleusLimits1 ;}

References G4RadioactiveDecay::theNucleusLimits.

◆ SetPILfactor()

void G4VProcess::SetPILfactor ( G4double  value)
inlineinherited

Definition at line 449 of file G4VProcess.hh.

450{
451 if (value>0.) { thePILfactor = value; }
452}

References G4VProcess::thePILfactor.

Referenced by export_G4VProcess().

◆ SetProcessManager()

void G4VProcess::SetProcessManager ( const G4ProcessManager procMan)
inlinevirtualinherited

◆ SetProcessSubType()

void G4VProcess::SetProcessSubType ( G4int  value)
inlineinherited

Definition at line 406 of file G4VProcess.hh.

407{
408 theProcessSubType = value;
409}

References G4VProcess::theProcessSubType.

Referenced by G4DNAElectronHoleRecombination::Create(), G4DNASecondOrderReaction::Create(), G4AnnihiToMuPair::G4AnnihiToMuPair(), G4BiasingProcessInterface::G4BiasingProcessInterface(), G4Cerenkov::G4Cerenkov(), G4ComptonScattering::G4ComptonScattering(), G4CoulombScattering::G4CoulombScattering(), G4CoupledTransportation::G4CoupledTransportation(), G4Decay::G4Decay(), G4DecayWithSpin::G4DecayWithSpin(), G4DNAAttachment::G4DNAAttachment(), G4DNABrownianTransportation::G4DNABrownianTransportation(), G4DNAChargeDecrease::G4DNAChargeDecrease(), G4DNAChargeIncrease::G4DNAChargeIncrease(), G4DNAElastic::G4DNAElastic(), G4DNAElectronSolvation::G4DNAElectronSolvation(), G4DNAExcitation::G4DNAExcitation(), G4DNAIonisation::G4DNAIonisation(), G4DNAMolecularDissociation::G4DNAMolecularDissociation(), G4DNAScavengerProcess::G4DNAScavengerProcess(), G4DNAVibExcitation::G4DNAVibExcitation(), G4eBremsstrahlung::G4eBremsstrahlung(), G4eeToHadrons::G4eeToHadrons(), G4eIonisation::G4eIonisation(), G4ePairProduction::G4ePairProduction(), G4eplusAnnihilation::G4eplusAnnihilation(), G4FastSimulationManagerProcess::G4FastSimulationManagerProcess(), G4GammaConversion::G4GammaConversion(), G4GammaConversionToMuons::G4GammaConversionToMuons(), G4GammaGeneralProcess::G4GammaGeneralProcess(), G4HadronicProcess::G4HadronicProcess(), G4hhIonisation::G4hhIonisation(), G4hIonisation::G4hIonisation(), G4ionIonisation::G4ionIonisation(), G4ITTransportation::G4ITTransportation(), G4JAEAElasticScattering::G4JAEAElasticScattering(), G4MicroElecElastic::G4MicroElecElastic(), G4MicroElecInelastic::G4MicroElecInelastic(), G4MicroElecLOPhononScattering::G4MicroElecLOPhononScattering(), G4MicroElecSurface::G4MicroElecSurface(), G4mplIonisation::G4mplIonisation(), G4MuBremsstrahlung::G4MuBremsstrahlung(), G4MuIonisation::G4MuIonisation(), G4MuonMinusAtomicCapture::G4MuonMinusAtomicCapture(), G4MuPairProduction::G4MuPairProduction(), G4NeutronKiller::G4NeutronKiller(), G4NuclearStopping::G4NuclearStopping(), G4OpAbsorption::G4OpAbsorption(), G4OpBoundaryProcess::G4OpBoundaryProcess(), G4OpMieHG::G4OpMieHG(), G4OpRayleigh::G4OpRayleigh(), G4OpWLS::G4OpWLS(), G4OpWLS2::G4OpWLS2(), G4ParallelWorldProcess::G4ParallelWorldProcess(), G4PhotoElectricEffect::G4PhotoElectricEffect(), G4PionDecayMakeSpin::G4PionDecayMakeSpin(), G4PolarizedCompton::G4PolarizedCompton(), G4PolarizedGammaConversion::G4PolarizedGammaConversion(), G4PolarizedIonisation::G4PolarizedIonisation(), G4PolarizedPhotoElectric::G4PolarizedPhotoElectric(), G4RadioactiveDecay::G4RadioactiveDecay(), G4RayleighScattering::G4RayleighScattering(), G4Scintillation::G4Scintillation(), G4StepLimiter::G4StepLimiter(), G4SynchrotronRadiation::G4SynchrotronRadiation(), G4SynchrotronRadiationInMat::G4SynchrotronRadiationInMat(), G4TransitionRadiation::G4TransitionRadiation(), G4Transportation::G4Transportation(), G4UCNAbsorption::G4UCNAbsorption(), G4UCNBoundaryProcess::G4UCNBoundaryProcess(), G4UCNLoss::G4UCNLoss(), G4UCNMultiScattering::G4UCNMultiScattering(), G4UnknownDecay::G4UnknownDecay(), G4UserSpecialCuts::G4UserSpecialCuts(), G4VMultipleScattering::G4VMultipleScattering(), G4VTransitionRadiation::G4VTransitionRadiation(), G4VXTRenergyLoss::G4VXTRenergyLoss(), and G4Decay::SetExtDecayer().

◆ SetProcessType()

void G4VProcess::SetProcessType ( G4ProcessType  aType)
inlineinherited

Definition at line 394 of file G4VProcess.hh.

395{
396 theProcessType = aType;
397}

References G4VProcess::theProcessType.

Referenced by G4MaxTimeCuts::G4MaxTimeCuts(), and G4MinEkineCuts::G4MinEkineCuts().

◆ SetSourceTimeProfile()

void G4Radioactivation::SetSourceTimeProfile ( G4String  filename)

Definition at line 702 of file G4Radioactivation.cc.

703{
704 std::ifstream infile ( filename, std::ios::in );
705 if (!infile) {
707 ed << " Could not open file " << filename << G4endl;
708 G4Exception("G4Radioactivation::SetSourceTimeProfile()", "HAD_RDM_001",
709 FatalException, ed);
710 }
711
712 G4double bin, flux;
713 NSourceBin = -1;
714
715 G4int loop = 0;
716 while (infile >> bin >> flux) { /* Loop checking, 01.09.2015, D.Wright */
717 loop++;
718 if (loop > 10000) {
719 G4Exception("G4Radioactivation::SetSourceTimeProfile()", "HAD_RDM_100",
720 JustWarning, "While loop count exceeded");
721 break;
722 }
723
724 NSourceBin++;
725 if (NSourceBin > 99) {
726 G4Exception("G4Radioactivation::SetSourceTimeProfile()", "HAD_RDM_002",
727 FatalException, "Input source time file too big (>100 rows)");
728
729 } else {
730 SBin[NSourceBin] = bin * s; // Convert read-in time to ns
731 SProfile[NSourceBin] = flux; // Dimensionless
732 }
733 }
734
735 AnalogueMC = false;
736 infile.close();
737
738#ifdef G4VERBOSE
739 if (GetVerboseLevel() > 2)
740 G4cout <<" Source Timeprofile Nbin = " << NSourceBin <<G4endl;
741#endif
742}

References AnalogueMC, FatalException, G4cout, G4endl, G4Exception(), G4RadioactiveDecay::GetVerboseLevel(), JustWarning, NSourceBin, s, SBin, and SProfile.

◆ SetSplitNuclei()

void G4Radioactivation::SetSplitNuclei ( G4int  r)
inline

Definition at line 122 of file G4Radioactivation.hh.

122 {
123 NSplit = r;
124 AnalogueMC = false;
125 }

References AnalogueMC, and NSplit.

◆ SetThresholdForVeryLongDecayTime()

void G4RadioactiveDecay::SetThresholdForVeryLongDecayTime ( const G4double  inputThreshold)
inlineinherited

◆ SetVerboseLevel()

void G4RadioactiveDecay::SetVerboseLevel ( G4int  value)
inlineinherited

Definition at line 115 of file G4RadioactiveDecay.hh.

115{verboseLevel = value;}

References G4RadioactiveDecay::verboseLevel.

Referenced by G4RadioactiveDecayMessenger::SetNewValue().

◆ StartTracking()

void G4VProcess::StartTracking ( G4Track )
virtualinherited

Reimplemented in G4ParallelGeometriesLimiterProcess, G4ImportanceProcess, G4WeightCutOffProcess, G4WeightWindowProcess, G4VITProcess, G4DNASecondOrderReaction, G4WrapperProcess, G4FastSimulationManagerProcess, G4ParallelWorldProcess, G4ParallelWorldScoringProcess, G4ScoreSplittingProcess, G4GammaGeneralProcess, G4Decay, G4AdjointProcessEquivalentToDirectProcess, G4eAdjointMultipleScattering, G4DNAElectronHoleRecombination, G4DNAScavengerProcess, G4VEmProcess, G4VEnergyLossProcess, G4VMultipleScattering, G4ITTransportation, G4DNABrownianTransportation, G4CoupledTransportation, G4Transportation, G4BiasingProcessInterface, and G4VPhononProcess.

Definition at line 87 of file G4VProcess.cc.

88{
92#ifdef G4VERBOSE
93 if (verboseLevel>2)
94 {
95 G4cout << "G4VProcess::StartTracking() - [" << theProcessName << "]"
96 << G4endl;
97 }
98#endif
99}

References G4VProcess::currentInteractionLength, G4cout, G4endl, G4VProcess::theInitialNumberOfInteractionLength, G4VProcess::theNumberOfInteractionLengthLeft, G4VProcess::theProcessName, and G4VProcess::verboseLevel.

Referenced by G4DNASecondOrderReaction::StartTracking(), G4WrapperProcess::StartTracking(), G4AdjointProcessEquivalentToDirectProcess::StartTracking(), G4DNAElectronHoleRecombination::StartTracking(), G4DNAScavengerProcess::StartTracking(), G4ITTransportation::StartTracking(), G4Transportation::StartTracking(), G4BiasingProcessInterface::StartTracking(), and G4VPhononProcess::StartTracking().

◆ StorePhysicsTable()

virtual G4bool G4VProcess::StorePhysicsTable ( const G4ParticleDefinition ,
const G4String ,
G4bool   
)
inlinevirtualinherited

◆ StreamInfo()

void G4RadioactiveDecay::StreamInfo ( std::ostream &  os,
const G4String endline 
)
privateinherited

Definition at line 468 of file G4RadioactiveDecay.cc.

469{
473
474 G4int prec = os.precision(5);
475 os << "======================================================================"
476 << endline;
477 os << "====== Radioactive Decay Physics Parameters ======="
478 << endline;
479 os << "======================================================================"
480 << endline;
481 os << "Max life time "
482 << deex->GetMaxLifeTime()/CLHEP::ps << " ps" << endline;
483 os << "Internal e- conversion flag "
484 << deex->GetInternalConversionFlag() << endline;
485 os << "Stored internal conversion coefficients "
486 << deex->StoreICLevelData() << endline;
487 os << "Enable correlated gamma emission "
488 << deex->CorrelatedGamma() << endline;
489 os << "Max 2J for sampling of angular correlations "
490 << deex->GetTwoJMAX() << endline;
491 os << "Atomic de-excitation enabled "
492 << emparam->Fluo() << endline;
493 os << "Auger electron emission enabled "
494 << emparam->Auger() << endline;
495 os << "Check EM cuts disabled for atomic de-excitation "
496 << emparam->DeexcitationIgnoreCut() << endline;
497 os << "Use Bearden atomic level energies "
498 << emparam->BeardenFluoDir() << endline;
499 os << "Use ANSTO fluorescence model "
500 << emparam->ANSTOFluoDir() << endline;
501 os << "Threshold for very long decay time at rest "
502 << fThresholdForVeryLongDecayTime/CLHEP::ns << " ns" << endline;
503 os << "======================================================================"
504 << G4endl;
505 os.precision(prec);
506}
G4bool GetInternalConversionFlag() const
static G4EmParameters * Instance()
G4bool BeardenFluoDir() const
G4bool ANSTOFluoDir() const
G4bool Fluo() const
G4bool DeexcitationIgnoreCut() const
G4bool Auger() const
G4DeexPrecoParameters * GetParameters()
static const double prec
Definition: RanecuEngine.cc:61
static constexpr double ns
static constexpr double ps

References G4EmParameters::ANSTOFluoDir(), G4EmParameters::Auger(), G4EmParameters::BeardenFluoDir(), G4DeexPrecoParameters::CorrelatedGamma(), G4EmParameters::DeexcitationIgnoreCut(), G4EmParameters::Fluo(), G4RadioactiveDecay::fThresholdForVeryLongDecayTime, G4endl, G4NuclearLevelData::GetInstance(), G4DeexPrecoParameters::GetInternalConversionFlag(), G4DeexPrecoParameters::GetMaxLifeTime(), G4NuclearLevelData::GetParameters(), G4DeexPrecoParameters::GetTwoJMAX(), G4EmParameters::Instance(), CLHEP::ns, CLHEP::prec, CLHEP::ps, and G4DeexPrecoParameters::StoreICLevelData().

Referenced by G4RadioactiveDecay::BuildPhysicsTable().

◆ SubtractNumberOfInteractionLengthLeft()

void G4VProcess::SubtractNumberOfInteractionLengthLeft ( G4double  prevStepSize)
inlineprotectedinherited

Definition at line 524 of file G4VProcess.hh.

525{
527 {
530 {
532 }
533 }
534 else
535 {
536#ifdef G4VERBOSE
537 if (verboseLevel>0)
538 {
539 G4cerr << "G4VProcess::SubtractNumberOfInteractionLengthLeft()";
540 G4cerr << " [" << theProcessName << "]" <<G4endl;
541 G4cerr << " currentInteractionLength = "
542 << currentInteractionLength << " [mm]";
543 G4cerr << " previousStepSize = " << prevStepSize << " [mm]";
544 G4cerr << G4endl;
545 }
546#endif
547 G4String msg = "Negative currentInteractionLength for ";
548 msg += theProcessName;
549 G4Exception("G4VProcess::SubtractNumberOfInteractionLengthLeft()",
550 "ProcMan201", EventMustBeAborted, msg);
551 }
552}
@ EventMustBeAborted
G4GLOB_DLL std::ostream G4cerr
static constexpr double perMillion

References G4VProcess::currentInteractionLength, EventMustBeAborted, G4cerr, G4endl, G4Exception(), CLHEP::perMillion, G4VProcess::theNumberOfInteractionLengthLeft, G4VProcess::theProcessName, and G4VProcess::verboseLevel.

Referenced by G4VContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestDiscreteProcess::PostStepGetPhysicalInteractionLength(), and G4Decay::PostStepGetPhysicalInteractionLength().

Field Documentation

◆ AnalogueMC

G4bool G4Radioactivation::AnalogueMC
private

◆ aParticleChange

G4ParticleChange G4VProcess::aParticleChange
protectedinherited

◆ applyARM

G4bool G4RadioactiveDecay::applyARM
privateinherited

◆ applyICM

G4bool G4RadioactiveDecay::applyICM
privateinherited

◆ aProcessManager

const G4ProcessManager* G4VProcess::aProcessManager = nullptr
protectedinherited

Definition at line 319 of file G4VProcess.hh.

Referenced by G4VProcess::GetProcessManager(), and G4VProcess::SetProcessManager().

◆ BRBias

G4bool G4Radioactivation::BRBias
private

Definition at line 155 of file G4Radioactivation.hh.

Referenced by DecayIt(), G4Radioactivation(), and SetBRBias().

◆ chainsFromParent

G4RadioactiveDecayChainsFromParent G4Radioactivation::chainsFromParent
private

Definition at line 169 of file G4Radioactivation.hh.

Referenced by CalculateChainsFromParent().

◆ currentInteractionLength

G4double G4VProcess::currentInteractionLength = -1.0
protectedinherited

◆ DBin

G4double G4Radioactivation::DBin[100]
private

◆ decayWindows

G4int G4Radioactivation::decayWindows[100]
private

Definition at line 174 of file G4Radioactivation.hh.

Referenced by DecayIt(), G4Radioactivation(), and SetDecayBias().

◆ dirPath

G4String G4RadioactiveDecay::dirPath
privateinherited

◆ dkmap

DecayTableMap* G4RadioactiveDecay::dkmap
protectedinherited

◆ DProfile

G4double G4Radioactivation::DProfile[100]
private

Definition at line 165 of file G4Radioactivation.hh.

Referenced by DecayIt(), G4Radioactivation(), GetDecayTime(), and SetDecayBias().

◆ enableAlongStepDoIt

G4bool G4VProcess::enableAlongStepDoIt = true
protectedinherited

◆ enableAtRestDoIt

G4bool G4VProcess::enableAtRestDoIt = true
protectedinherited

◆ enablePostStepDoIt

G4bool G4VProcess::enablePostStepDoIt = true
protectedinherited

◆ forceDecayDirection

G4ThreeVector G4RadioactiveDecay::forceDecayDirection
privateinherited

◆ forceDecayHalfAngle

G4double G4RadioactiveDecay::forceDecayHalfAngle
privateinherited

◆ fParticleChangeForRadDecay

G4ParticleChangeForRadDecay G4RadioactiveDecay::fParticleChangeForRadDecay
protectedinherited

◆ fProcessTable

G4ProcessTable* G4VProcess::fProcessTable = nullptr
privateinherited

Definition at line 374 of file G4VProcess.hh.

Referenced by G4VProcess::G4VProcess(), and G4VProcess::~G4VProcess().

◆ fRemainderLifeTime

G4double G4RadioactiveDecay::fRemainderLifeTime
privateinherited

◆ fThresholdForVeryLongDecayTime

G4double G4RadioactiveDecay::fThresholdForVeryLongDecayTime
privateinherited

◆ halflifethreshold

G4double G4Radioactivation::halflifethreshold
private

◆ isAllVolumesMode

bool G4RadioactiveDecay::isAllVolumesMode
protectedinherited

◆ isInitialised

G4bool G4RadioactiveDecay::isInitialised
privateinherited

Definition at line 206 of file G4RadioactiveDecay.hh.

Referenced by G4RadioactiveDecay::BuildPhysicsTable().

◆ levelTolerance

const G4double G4RadioactiveDecay::levelTolerance = 10.0*eV
staticprotectedinherited

◆ masterProcessShadow

G4VProcess* G4VProcess::masterProcessShadow = nullptr
privateinherited

Definition at line 370 of file G4VProcess.hh.

Referenced by G4VProcess::GetMasterProcess(), and G4VProcess::SetMasterProcess().

◆ NDecayBin

G4int G4Radioactivation::NDecayBin
private

Definition at line 163 of file G4Radioactivation.hh.

Referenced by G4Radioactivation(), and SetDecayBias().

◆ NSourceBin

G4int G4Radioactivation::NSourceBin
private

◆ NSplit

G4int G4Radioactivation::NSplit
private

Definition at line 156 of file G4Radioactivation.hh.

Referenced by DecayIt(), G4Radioactivation(), GetSplitNuclei(), and SetSplitNuclei().

◆ origin

const G4ThreeVector G4RadioactiveDecay::origin
staticprivateinherited

◆ photonEvaporation

G4PhotonEvaporation* G4RadioactiveDecay::photonEvaporation
protectedinherited

◆ pParticleChange

G4VParticleChange* G4VProcess::pParticleChange = nullptr
protectedinherited

Definition at line 321 of file G4VProcess.hh.

Referenced by G4VMultipleScattering::AddEmModel(), G4VEmProcess::AddEmModel(), G4VEnergyLossProcess::AddEmModel(), G4ImportanceProcess::AlongStepDoIt(), G4WeightCutOffProcess::AlongStepDoIt(), G4WeightWindowProcess::AlongStepDoIt(), G4VContinuousDiscreteProcess::AlongStepDoIt(), G4VContinuousProcess::AlongStepDoIt(), G4VRestContinuousDiscreteProcess::AlongStepDoIt(), G4VRestContinuousProcess::AlongStepDoIt(), G4ParallelWorldProcess::AlongStepDoIt(), G4ParallelWorldScoringProcess::AlongStepDoIt(), G4VITRestProcess::AtRestDoIt(), G4VRestContinuousDiscreteProcess::AtRestDoIt(), G4VRestContinuousProcess::AtRestDoIt(), G4VRestDiscreteProcess::AtRestDoIt(), G4VRestProcess::AtRestDoIt(), G4ParallelWorldProcess::AtRestDoIt(), G4ParallelWorldScoringProcess::AtRestDoIt(), G4ScoreSplittingProcess::AtRestDoIt(), G4VITRestDiscreteProcess::AtRestDoIt(), G4eplusAnnihilation::AtRestDoIt(), G4DNAElectronHoleRecombination::Create(), G4DNASecondOrderReaction::Create(), G4VEnergyLossProcess::FillSecondariesAlongStep(), G4Decay::G4Decay(), G4DNAMolecularDissociation::G4DNAMolecularDissociation(), G4DNAScavengerProcess::G4DNAScavengerProcess(), G4ImportanceProcess::G4ImportanceProcess(), G4ITTransportation::G4ITTransportation(), G4ParallelWorldProcess::G4ParallelWorldProcess(), G4ParallelWorldScoringProcess::G4ParallelWorldScoringProcess(), G4RadioactiveDecay::G4RadioactiveDecay(), G4ScoreSplittingProcess::G4ScoreSplittingProcess(), G4Transportation::G4Transportation(), G4UnknownDecay::G4UnknownDecay(), G4VEmProcess::G4VEmProcess(), G4VEnergyLossProcess::G4VEnergyLossProcess(), G4VMultipleScattering::G4VMultipleScattering(), G4VProcess::G4VProcess(), G4VXTRenergyLoss::G4VXTRenergyLoss(), G4WeightCutOffProcess::G4WeightCutOffProcess(), G4WeightWindowProcess::G4WeightWindowProcess(), G4VITDiscreteProcess::PostStepDoIt(), G4VContinuousDiscreteProcess::PostStepDoIt(), G4VDiscreteProcess::PostStepDoIt(), G4VRestContinuousDiscreteProcess::PostStepDoIt(), G4VRestDiscreteProcess::PostStepDoIt(), G4ParallelWorldProcess::PostStepDoIt(), G4ParallelWorldScoringProcess::PostStepDoIt(), G4ScoreSplittingProcess::PostStepDoIt(), G4NeutronKiller::PostStepDoIt(), G4VITRestDiscreteProcess::PostStepDoIt(), G4LowECapture::PostStepDoIt(), G4VEmProcess::PostStepDoIt(), G4VEnergyLossProcess::PostStepDoIt(), G4Cerenkov::PostStepDoIt(), and G4VTransitionRadiation::PostStepDoIt().

◆ ratesToDaughter

G4RadioactiveDecayRatesToDaughter G4Radioactivation::ratesToDaughter
private

Definition at line 167 of file G4Radioactivation.hh.

Referenced by CalculateChainsFromParent(), and SetDecayRate().

◆ SBin

G4double G4Radioactivation::SBin[100]
private

◆ SProfile

G4double G4Radioactivation::SProfile[100]
private

◆ theDecayRateVector

G4RadioactiveDecayRates G4Radioactivation::theDecayRateVector
private

Definition at line 168 of file G4Radioactivation.hh.

Referenced by CalculateChainsFromParent(), DecayIt(), and GetChainsFromParent().

◆ theInitialNumberOfInteractionLength

G4double G4VProcess::theInitialNumberOfInteractionLength = -1.0
protectedinherited

◆ theNucleusLimits

G4NucleusLimits G4RadioactiveDecay::theNucleusLimits
privateinherited

◆ theNumberOfInteractionLengthLeft

G4double G4VProcess::theNumberOfInteractionLengthLeft = -1.0
protectedinherited

Definition at line 331 of file G4VProcess.hh.

Referenced by G4AdjointForcedInteractionForGamma::AlongStepDoIt(), G4MuonicAtomDecay::AtRestGetPhysicalInteractionLength(), G4VRestContinuousDiscreteProcess::AtRestGetPhysicalInteractionLength(), G4VRestContinuousProcess::AtRestGetPhysicalInteractionLength(), G4VRestDiscreteProcess::AtRestGetPhysicalInteractionLength(), G4VRestProcess::AtRestGetPhysicalInteractionLength(), G4Decay::AtRestGetPhysicalInteractionLength(), G4VProcess::ClearNumberOfInteractionLengthLeft(), G4MuonicAtomDecay::DecayIt(), G4VProcess::EndTracking(), G4VProcess::GetNumberOfInteractionLengthLeft(), G4VProcess::GetTotalNumberOfInteractionLengthTraversed(), G4GammaGeneralProcess::PostStepDoIt(), G4VEmProcess::PostStepDoIt(), G4VEnergyLossProcess::PostStepDoIt(), G4VContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestContinuousDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4VRestDiscreteProcess::PostStepGetPhysicalInteractionLength(), G4GammaGeneralProcess::PostStepGetPhysicalInteractionLength(), G4Decay::PostStepGetPhysicalInteractionLength(), G4AdjointForcedInteractionForGamma::PostStepGetPhysicalInteractionLength(), G4PolarizedAnnihilation::PostStepGetPhysicalInteractionLength(), G4PolarizedCompton::PostStepGetPhysicalInteractionLength(), G4PolarizedIonisation::PostStepGetPhysicalInteractionLength(), G4VEmProcess::PostStepGetPhysicalInteractionLength(), G4VEnergyLossProcess::PostStepGetPhysicalInteractionLength(), G4VProcess::ResetNumberOfInteractionLengthLeft(), G4VProcess::StartTracking(), G4GammaGeneralProcess::StartTracking(), G4VEmProcess::StartTracking(), G4VEnergyLossProcess::StartTracking(), and G4VProcess::SubtractNumberOfInteractionLengthLeft().

◆ theParentChainTable

G4RadioactiveDecayParentChainTable G4Radioactivation::theParentChainTable
private

◆ thePhysicsTableFileName

G4String G4VProcess::thePhysicsTableFileName
protectedinherited

Definition at line 344 of file G4VProcess.hh.

Referenced by G4VProcess::GetPhysicsTableFileName().

◆ thePILfactor

G4double G4VProcess::thePILfactor = 1.0
protectedinherited

◆ theProcessName

G4String G4VProcess::theProcessName
protectedinherited

◆ theProcessSubType

G4int G4VProcess::theProcessSubType = -1
protectedinherited

◆ theProcessType

G4ProcessType G4VProcess::theProcessType = fNotDefined
protectedinherited

◆ theRadDecayMode

G4RadioactiveDecayMode G4RadioactiveDecay::theRadDecayMode
privateinherited

◆ theRadioactivationMessenger

G4RadioactivationMessenger* G4Radioactivation::theRadioactivationMessenger
protected

Definition at line 150 of file G4Radioactivation.hh.

Referenced by G4Radioactivation(), and ~G4Radioactivation().

◆ theRadioactiveDecayMessenger

G4RadioactiveDecayMessenger* G4RadioactiveDecay::theRadioactiveDecayMessenger
protectedinherited

◆ theRadioactivityTables

std::vector<G4RadioactivityTable*> G4Radioactivation::theRadioactivityTables
private

◆ theUserRadioactiveDataFiles

std::map<G4int, G4String> G4RadioactiveDecay::theUserRadioactiveDataFiles
privateinherited

◆ ValidVolumes

std::vector<G4String> G4RadioactiveDecay::ValidVolumes
protectedinherited

◆ verboseLevel

G4int G4RadioactiveDecay::verboseLevel
privateinherited

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