20#include <G4ParticleDefinition.hh>
21#include <G4ProcessTable.hh>
22#include <G4UImessenger.hh>
23#include <G4VProcess.hh>
40 "Cannot create two instances of singleton.");
111 (*fIsCutVector)[
kGamma] =
true;
114 (*fIsCutVector)[
kGamma] =
true;
117 (*fIsCutVector)[
kGamma] =
true;
140 (*fIsCutVector)[
kMuon] =
true;
156 (*fIsControlVector)[
kGamma] =
true;
160 (*fIsControlVector)[
kGamma] =
true;
164 (*fIsControlVector)[
kGamma] =
true;
168 (*fIsControlVector)[
kGamma] =
true;
173 (*fIsControlVector)[
kEplus] =
true;
175 (*fIsControlVector)[
kMuon] =
true;
179 (*fIsControlVector)[
kEplus] =
true;
184 (*fIsControlVector)[
kEplus] =
true;
185 (*fIsControlVector)[
kMuon] =
true;
194 (*fIsControlVector)[
kMuon] =
true;
198 (*fIsControlVector)[
kAny] =
true;
203 (*fIsControlVector)[
kEplus] =
true;
205 (*fIsControlVector)[
kMuon] =
true;
210 (*fIsControlVector)[
kEplus] =
true;
212 (*fIsControlVector)[
kMuon] =
true;
232 "PhysicsManager has been already locked.");
238 G4String name, G4double value,
TG4G3Cut& cut)
373 G4String name = particle->GetParticleName();
374 G4String pType = particle->GetParticleType();
376 if (name ==
"gamma") {
379 else if (name ==
"e-") {
382 else if (name ==
"e+") {
385 else if ((pType ==
"baryon" || pType ==
"meson" || pType ==
"nucleus" ||
387 if (particle->GetPDGCharge() == 0) {
393 else if (name ==
"mu-" || name ==
"mu+") {
407 switch (particleWSP) {
418 return "NeutralHadron";
421 return "ChargedHadron";
434 "TG4G3PhysicsManager",
"GetG3ParticleWSPName",
"Wrong particleWSP.");
Definition of the TG4G3ControlVector class.
Definition of the TG4G3CutVector class.
Definition of the TG4G3PhysicsManager class.
Definition of the TG4G3Units class.
Vector of control process values with convenient set/get methods.
static TG4G3Control GetControl(const G4String &controlName)
static TG4G3ControlValue GetControlValue(G4int value, TG4G3Control control)
Vector of kinetic energy cut values with convenient set/get methods.
static TG4G3Cut GetCut(const G4String &cutName)
static G4double Tolerance()
static G4bool CheckCutValue(TG4G3Cut cut, G4double value)
Provides a Geant3 way control to Geant4 physics.
G4bool IsGlobalSpecialControls() const
void SwitchIsCutVector(TG4G3Cut cut)
G4bool CheckControlWithTheVector(G4String name, G4double value, TG4G3Control &control, TG4G3ControlValue &controlValue)
TG4G3ControlVector * fControlVector
TG4G3ControlVector.
void SwitchIsControlVector(TG4G3Control control)
G4String GetG3ParticleWSPName(G4int particleWSP) const
void SetCut(TG4G3Cut cut, G4double cutValue)
TG4boolVector * fIsControlVector
vector of booleans which controls are set
TG4boolVector * fIsCutVector
vector of booleans which cuts are set
G4bool fLock
if true: cut/control vectors cannot be modified
TG4G3ParticleWSP GetG3ParticleWSP(G4ParticleDefinition *particle) const
void SetG3DefaultControls()
void SetProcess(TG4G3Control control, TG4G3ControlValue controlValue)
G4bool IsSpecialCuts() const
static TG4G3PhysicsManager * fgInstance
this instance
G4bool IsSpecialControls() const
TG4G3Defaults fG3Defaults
G3 default cuts/controls.
TG4G3CutVector * fCutVector
TG4G3CutVector.
G4bool CheckCutWithTheVector(G4String name, G4double value, TG4G3Cut &cut)
static void Exception(const TString &className, const TString &methodName, const TString &text)
TG4G3ControlValue
Enumeration for G3 processes control values.
TG4G3Cut
Enumeration for G3 types of kinetic energy cuts.
std::vector< G4bool > TG4boolVector
TG4G3Control
Enumeration for G3 types of physics processes controls.
@ kUnsetControlValue
value not set
@ kNoG3Cuts
Invalid value.
@ kNoG3Controls
No process control.
TG4G3ParticleWSP
The particles types which a special process (cuts, controls) is applicable for.
@ kNofParticlesWSP
not a particle with a special control
@ kGamma
kPAIR, kCOMP, kPHOT, kPHIS
@ kElectron
kDRAY, kBREM, kMULS, kG3LOSS
@ kEplus
kDRAY, kBREM, kMULS, kG3LOSS, kANNI
@ kMuon
kDRAY, kBREM, kMULS, kG3LOSS, kMUNU
@ kChargedHadron
kDRAY, kMULS, kG3LOSS, kHADR,