81#define G4MT_theMessenger \
82 ((this->subInstanceManager.offset[this->g4vuplInstanceID])._theMessenger)
83#define G4MT_thePLHelper \
84 ((this->subInstanceManager.offset[this->g4vuplInstanceID])._thePLHelper)
85#define fIsPhysicsTableBuilt \
86 ((this->subInstanceManager.offset[this->g4vuplInstanceID]) \
87 ._fIsPhysicsTableBuilt)
88#define fDisplayThreshold \
89 ((this->subInstanceManager.offset[this->g4vuplInstanceID])._fDisplayThreshold)
90#define theParticleIterator \
91 ((this->subInstanceManager.offset[this->g4vuplInstanceID]) \
92 ._theParticleIterator)
110 , defaultCutValue(1.0 * mm)
111 , isSetDefaultCutValue(false)
112 , fRetrievePhysicsTable(false)
113 , fStoredInAscii(true)
114 , fIsCheckedForRetrievePhysicsTable(false)
115 , fIsRestoredCutValues(false)
116 , directoryPhysicsTable(
".")
120 fDisableCheckParticleList(false)
180 : verboseLevel(right.verboseLevel)
181 , defaultCutValue(right.defaultCutValue)
182 , isSetDefaultCutValue(right.isSetDefaultCutValue)
183 , fRetrievePhysicsTable(right.fRetrievePhysicsTable)
184 , fStoredInAscii(right.fStoredInAscii)
185 , fIsCheckedForRetrievePhysicsTable(right.fIsCheckedForRetrievePhysicsTable)
186 , fIsRestoredCutValues(right.fIsRestoredCutValues)
187 , directoryPhysicsTable(right.directoryPhysicsTable)
191 fDisableCheckParticleList(right.fDisableCheckParticleList)
212 ._fIsPhysicsTableBuilt;
235 ._fIsPhysicsTableBuilt;
252 "This method is obsolete");
260#ifdef G4MULTITHREADED
261 G4MUTEXLOCK(&G4ParticleTable::particleTableMutex());
262 G4ParticleTable::lockCount()++;
284 G4cout <<
"G4VUserPhysicsList::InitializeProcessManager: creating "
306 G4cout <<
"G4VUserPhysicsList::InitializeProcessManager: copying "
316#ifdef G4MULTITHREADED
328#ifdef G4MULTITHREADED
329 G4MUTEXLOCK(&G4ParticleTable::particleTableMutex());
330 G4ParticleTable::lockCount()++;
353 G4cout <<
"G4VUserPhysicsList::RemoveProcessManager: ";
354 G4cout <<
"remove ProcessManager from ";
364#ifdef G4MULTITHREADED
407 G4cout <<
"G4VUserPhysicsList::SetDefaultCutValue: negative cut values"
408 <<
" :" << value / mm <<
"[mm]" <<
G4endl;
426 G4cout <<
"G4VUserPhysicsList::SetDefaultCutValue:"
442 G4cout <<
"G4VUserPhysicsList::GetCutValue "
443 <<
" : No Default Region " <<
G4endl;
447 "No Default Region");
476 G4cout <<
"G4VUserPhysicsList::SetCutValue "
477 <<
" : No Region of " << rname <<
G4endl;
518 G4cout <<
"G4VUserPhysicsList::SetParticleCuts: negative cut values"
519 <<
" :" << cut / mm <<
"[mm]"
520 <<
" for " << particleName <<
G4endl;
536 G4cout <<
"G4VUserPhysicsList::SetParticleCuts "
537 <<
" : No Default Region " <<
G4endl;
540 G4Exception(
"G4VUserPhysicsList::SetParticleCuts ",
"Run0254",
544 region = world_region;
553 if(region != world_region &&
555 ->GetDefaultProductionCuts())
560 ->GetDefaultProductionCuts()));
567 G4cout <<
"G4VUserPhysicsList::SetParticleCuts: "
568 <<
" :" << cut / mm <<
"[mm]"
569 <<
" for " << particleName <<
G4endl;
596 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable"
597 <<
" Retrieve Cut Table failed !!" <<
G4endl;
600 G4Exception(
"G4VUserPhysicsList::BuildPhysicsTable",
"Run0255",
608 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable"
609 <<
" Retrieve Cut Table successfully " <<
G4endl;
619 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable"
620 <<
" does not retrieve Cut Table but calculate " <<
G4endl;
645 if(particle != GammaP && particle != EMinusP && particle != EPlusP &&
662 <<
"#### G4VUserPhysicsList::BuildPhysicsTable() - BuildPhysicsTable("
674 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable "
675 <<
"Physics table can not be retrieved and will be calculated "
686 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable "
699 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable "
714 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable "
718 <<
" should be created in your PhysicsList" <<
G4endl;
721 G4Exception(
"G4VUserPhysicsList::BuildPhysicsTable",
"Run0271",
735 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable "
740 G4Exception(
"G4VUserPhysicsList::BuildPhysicsTable",
"Run0272",
747 G4cout <<
"G4VUserPhysicsList::BuildPhysicsTable %%%%%% "
749 G4cout <<
" ProcessManager : " << pManager
750 <<
" ProcessManagerShadow : " << pManagerShadow <<
G4endl;
751 for(std::size_t iv1 = 0; iv1 < pVector->
size(); ++iv1)
753 G4cout <<
" " << iv1 <<
" - " << (*pVector)[iv1]->GetProcessName()
756 G4cout <<
"--------------------------------------------------------------"
760 for(std::size_t iv2 = 0; iv2 < pVectorShadow->
size(); ++iv2)
762 G4cout <<
" " << iv2 <<
" - "
763 << (*pVectorShadow)[iv2]->GetProcessName() <<
G4endl;
767 for(std::size_t j = 0; j < pVector->
size(); ++j)
773 if(pManagerShadow == pManager)
775 (*pVector)[j]->BuildPhysicsTable(*particle);
779 (*pVector)[j]->BuildWorkerPhysicsTable(*particle);
806 G4cout <<
"G4VUserPhysicsList::PreparePhysicsTable "
810 <<
" should be created in your PhysicsList" <<
G4endl;
813 G4Exception(
"G4VUserPhysicsList::PreparePhysicsTable",
"Run0273",
829 G4cout <<
"G4VUserPhysicsList::PreparePhysicsTable "
834 G4Exception(
"G4VUserPhysicsList::PreparePhysicsTable",
"Run0274",
838 for(std::size_t j = 0; j < pVector->
size(); ++j)
844 if(pManagerShadow == pManager)
846 (*pVector)[j]->PreparePhysicsTable(*particle);
850 (*pVector)[j]->PrepareWorkerPhysicsTable(*particle);
878 G4cout <<
"G4VUserPhysicsList::BuildIntegralPhysicsTable "
879 <<
" BuildPhysicsTable is invoked for "
938 "Fail to store Cut Table");
944 G4cout <<
"G4VUserPhysicsList::StorePhysicsTable "
945 <<
" Store material and cut values successfully" <<
G4endl;
959 for(std::size_t j = 0; j < pVector->
size(); ++j)
961 if(!(*pVector)[j]->StorePhysicsTable(particle, dir, ascii))
963 G4String comment =
"Fail to store physics table for ";
964 comment += (*pVector)[j]->GetProcessName();
966 G4Exception(
"G4VUserPhysicsList::StorePhysicsTable",
"Run0282",
997 for(std::size_t j = 0; j < pVector->
size(); ++j)
1000 (*pVector)[j]->RetrievePhysicsTable(particle, directory, ascii);
1007 G4cout <<
"G4VUserPhysicsList::RetrievePhysicsTable "
1008 <<
" Fail to retrieve Physics Table for "
1009 << (*pVector)[j]->GetProcessName() <<
G4endl;
1014 (*pVector)[j]->BuildPhysicsTable(*particle);
1017 for(std::size_t j = 0; j < pVector->
size(); ++j)
1031 G4cout <<
"G4VUserPhysicsList::SetApplyCuts for " << name <<
G4endl;
1101 G4cout <<
"G4VUserPhysicsList::SetVerboseLevel :"
1116 G4cout <<
"G4VUserPhysicsList::ResetCuts() is obsolete."
1117 <<
" This method gives no effect and you can remove it. " <<
G4endl;
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
#define G4MUTEXLOCK(mutex)
#define G4MUTEXUNLOCK(mutex)
#define G4MT_theMessenger
#define theParticleIterator
#define fIsPhysicsTableBuilt
#define fDisplayThreshold
G4GLOB_DLL std::ostream G4cout
static G4PART_DLL G4int & slavetotalspace()
G4int GetInstanceID() const
G4ProcessManager * GetProcessManager() const
void SetMasterProcessManager(G4ProcessManager *aNewPM)
G4bool IsGeneralIon() const
G4bool IsShortLived() const
G4ProcessManager * GetMasterProcessManager() const
void SetApplyCutsFlag(G4bool)
G4bool GetApplyCutsFlag() const
const G4String & GetParticleName() const
void SetProcessManager(G4ProcessManager *aProcessManager)
const G4String & GetParticleSubType() const
G4PTblDicIterator * GetIterator() const
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
static G4ParticleTable * GetParticleTable()
void DeleteAllParticles()
G4ParticleDefinition * GetGenericIon() const
static G4PhysicsListHelper * GetPhysicsListHelper()
G4ProcessVector * GetProcessList() const
G4bool RetrieveCutsTable(const G4String &directory, G4bool ascii=false)
void SetVerboseLevel(G4int value)
G4bool StoreCutsTable(const G4String &directory, G4bool ascii=false)
void SetEnergyRange(G4double lowedge, G4double highedge)
static G4ProductionCutsTable * GetProductionCutsTable()
void SetProductionCut(G4double cut, G4int index=-1)
G4double GetProductionCut(G4int index) const
static G4RegionStore * GetInstance()
G4Region * GetRegion(const G4String &name, G4bool verbose=true) const
G4ProductionCuts * GetProductionCuts() const
void SetProductionCuts(G4ProductionCuts *cut)
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
const G4String & GetProcessName() const
G4bool _fIsPhysicsTableBuilt
G4ParticleTable::G4PTblDicIterator * _theParticleIterator
G4PhysicsListHelper * _thePLHelper
G4UserPhysicsListMessenger * _theMessenger
G4RUN_DLL G4ThreadLocalStatic T * offset
G4int CreateSubInstance()
G4double GetCutValue(const G4String &pname) const
void SetDefaultCutValue(G4double newCutValue)
void SetPhysicsTableRetrieved(const G4String &directory="")
G4VUserPhysicsList & operator=(const G4VUserPhysicsList &)
void PreparePhysicsTable(G4ParticleDefinition *)
virtual void TerminateWorker()
void SetCutValue(G4double aCut, const G4String &pname)
G4bool RegisterProcess(G4VProcess *process, G4ParticleDefinition *particle)
void UseCoupledTransportation(G4bool vl=true)
void SetCutsForRegion(G4double aCut, const G4String &rname)
G4bool fDisableCheckParticleList
G4ProductionCutsTable * fCutsTable
G4bool fIsRestoredCutValues
void DumpCutValuesTableIfRequested()
G4bool StorePhysicsTable(const G4String &directory=".")
G4ParticleTable::G4PTblDicIterator * GetParticleIterator() const
G4ParticleTable * theParticleTable
G4String directoryPhysicsTable
void SetVerboseLevel(G4int value)
G4bool fRetrievePhysicsTable
void SetApplyCuts(G4bool value, const G4String &name)
G4bool isSetDefaultCutValue
void SetParticleCuts(G4double cut, G4ParticleDefinition *particle, G4Region *region=0)
virtual void RetrievePhysicsTable(G4ParticleDefinition *, const G4String &directory, G4bool ascii=false)
void ResetCuts()
obsolete methods
G4bool fIsCheckedForRetrievePhysicsTable
void DumpCutValuesTable(G4int flag=1)
G4bool GetApplyCuts(const G4String &name) const
static G4RUN_DLL G4VUPLManager subInstanceManager
virtual ~G4VUserPhysicsList()
void SetCutsWithDefault()
void AddProcessManager(G4ParticleDefinition *newParticle, G4ProcessManager *newManager=0)
void BuildIntegralPhysicsTable(G4VProcess *, G4ParticleDefinition *)
G4int GetInstanceID() const
void RemoveProcessManager()
virtual void InitializeWorker()
static const G4VUPLManager & GetSubInstanceManager()
void InitializeProcessManager()