Geant4  10.00.p01
PhysicsList.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
28 //
29 //
30 // $Id: PhysicsList.cc 66241 2012-12-13 18:34:42Z gunter $
31 //
32 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
33 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
34 
35 #include "PhysicsList.hh"
36 #include "PhysicsListMessenger.hh"
37 
38 #include "PhysListEmStandard.hh"
39 #include "G4EmStandardPhysics.hh"
44 #include "G4EmLivermorePhysics.hh"
45 #include "G4EmPenelopePhysics.hh"
46 
47 #include "G4LossTableManager.hh"
48 #include "G4UnitsTable.hh"
49 #include "G4SystemOfUnits.hh"
50 
51 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
52 
54 : G4VModularPhysicsList(),fCutForGamma(0),fCutForElectron(0),fCutForPositron(0),
55  fCurrentDefaultCut(0),fEmPhysicsList(0),fEmName("local"),fMessenger(0)
56 {
58 
59  fCurrentDefaultCut = 1.0*mm;
63 
64  fMessenger = new PhysicsListMessenger(this);
65 
66  SetVerboseLevel(1);
67 
68  // EM physics
69  fEmName = G4String("local");
71 
72  //add new units for cross sections
73  //
74  new G4UnitDefinition( "mm2/g", "mm2/g","Surface/Mass", mm2/g);
75  new G4UnitDefinition( "um2/mg", "um2/mg","Surface/Mass", um*um/mg);
76 }
77 
78 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
79 
81 {
82  delete fMessenger;
83 }
84 
85 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
86 
87 // Bosons
88 #include "G4ChargedGeantino.hh"
89 #include "G4Geantino.hh"
90 #include "G4Gamma.hh"
91 #include "G4OpticalPhoton.hh"
92 
93 // leptons
94 #include "G4MuonPlus.hh"
95 #include "G4MuonMinus.hh"
96 #include "G4NeutrinoMu.hh"
97 #include "G4AntiNeutrinoMu.hh"
98 
99 #include "G4Electron.hh"
100 #include "G4Positron.hh"
101 #include "G4NeutrinoE.hh"
102 #include "G4AntiNeutrinoE.hh"
103 
104 // Mesons
105 #include "G4PionPlus.hh"
106 #include "G4PionMinus.hh"
107 #include "G4PionZero.hh"
108 #include "G4Eta.hh"
109 #include "G4EtaPrime.hh"
110 
111 #include "G4KaonPlus.hh"
112 #include "G4KaonMinus.hh"
113 #include "G4KaonZero.hh"
114 #include "G4AntiKaonZero.hh"
115 #include "G4KaonZeroLong.hh"
116 #include "G4KaonZeroShort.hh"
117 
118 // Baryons
119 #include "G4Proton.hh"
120 #include "G4AntiProton.hh"
121 #include "G4Neutron.hh"
122 #include "G4AntiNeutron.hh"
123 
124 // Nuclei
125 #include "G4Deuteron.hh"
126 #include "G4Triton.hh"
127 #include "G4Alpha.hh"
128 #include "G4GenericIon.hh"
129 
130 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
131 
133 {
134 // pseudo-particles
137 
138 // gamma
140 
141 // optical photon
143 
144 // leptons
149 
154 
155 // mesons
167 
168 // barions
173 
174 // ions
179 }
180 
181 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
182 
183 #include "G4EmProcessOptions.hh"
184 
186 {
187  // Transportation
188  //
190 
191  // Electromagnetic physics list
192  //
194 
195  // Em options
196  //
197  // Main options and setting parameters are shown here.
198  // Several of them have default values.
199  //
200  G4EmProcessOptions emOptions;
201 
202  //physics tables
203  //
204  //emOptions.SetMinEnergy(100*eV); //default
205  //emOptions.SetMaxEnergy(100*TeV); //default
206  //emOptions.SetDEDXBinning(12*20); //default=12*7
207  //emOptions.SetLambdaBinning(12*20); //default=12*7
208 
209  emOptions.SetBuildCSDARange(true);
210  emOptions.SetMaxEnergyForCSDARange(10*GeV);
211  //emOptions.SetDEDXBinningForCSDARange(12*20);
212 
213  //emOptions.SetSplineFlag(true); //default
214 
215  emOptions.SetVerbose(0);
216 }
217 
218 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
219 
221 {
222  if (verboseLevel>0) {
223  G4cout << "PhysicsList::AddPhysicsList: <" << name << ">" << G4endl;
224  }
225 
226  if (name == fEmName) return;
227 
228  if (name == "local") {
229 
230  fEmName = name;
231  delete fEmPhysicsList;
233 
234  } else if (name == "emstandard_opt0"){
235  fEmName = name;
236  delete fEmPhysicsList;
238 
239  } else if (name == "emstandard_opt1"){
240  fEmName = name;
241  delete fEmPhysicsList;
243 
244  } else if (name == "emstandard_opt2"){
245  fEmName = name;
246  delete fEmPhysicsList;
248 
249  } else if (name == "emstandard_opt3"){
250  fEmName = name;
251  delete fEmPhysicsList;
253 
254  } else if (name == "emstandard_opt4"){
255  fEmName = name;
256  delete fEmPhysicsList;
258 
259  } else if (name == "empenelope"){
260  fEmName = name;
261  delete fEmPhysicsList;
263 
264  } else if (name == "emlivermore"){
265  fEmName = name;
266  delete fEmPhysicsList;
268 
269  } else {
270 
271  G4cout << "PhysicsList::AddPhysicsList: <" << name << ">"
272  << " is not defined"
273  << G4endl;
274  }
275 }
276 
277 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
278 
279 #include "G4Gamma.hh"
280 #include "G4Electron.hh"
281 #include "G4Positron.hh"
282 
284 {
285  // fixe lower limit for cut
287 
288  // set cut values for gamma at first and for e- second and next for e+,
289  // because some processes for e+/e- need cut values for gamma
290  SetCutValue(fCutForGamma, "gamma");
294 }
295 
296 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
297 
299 {
300  fCutForGamma = cut;
302 }
303 
304 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
305 
307 {
308  fCutForElectron = cut;
310 }
311 
312 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
313 
315 {
316  fCutForPositron = cut;
318 }
319 
320 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
static G4Geantino * GeantinoDefinition()
Definition: G4Geantino.cc:82
static G4Electron * ElectronDefinition()
Definition: G4Electron.cc:89
static G4Triton * TritonDefinition()
Definition: G4Triton.cc:90
static G4KaonPlus * KaonPlusDefinition()
Definition: G4KaonPlus.cc:108
static G4GenericIon * GenericIonDefinition()
Definition: G4GenericIon.cc:88
void ConstructParticle()
Definition: PhysicsList.cc:117
static G4MuonPlus * MuonPlusDefinition()
Definition: G4MuonPlus.cc:94
static G4LossTableManager * Instance()
void SetCutValue(G4double aCut, const G4String &pname)
void SetCutForGamma(G4double)
Definition: PhysicsList.cc:231
void SetEnergyRange(G4double lowedge, G4double highedge)
static G4KaonMinus * KaonMinusDefinition()
Definition: G4KaonMinus.cc:108
G4String name
Definition: TRTMaterials.hh:40
G4double fCutForPositron
Definition: PhysicsList.hh:70
static G4Proton * ProtonDefinition()
Definition: G4Proton.cc:88
void SetCutForPositron(G4double)
Definition: PhysicsList.cc:247
G4double fCutForElectron
Definition: PhysicsList.hh:69
static G4KaonZero * KaonZeroDefinition()
Definition: G4KaonZero.cc:99
static G4AntiKaonZero * AntiKaonZeroDefinition()
static G4KaonZeroShort * KaonZeroShortDefinition()
static const double mg
Definition: G4SIunits.hh:163
static G4AntiProton * AntiProtonDefinition()
Definition: G4AntiProton.cc:88
void SetCutForElectron(G4double)
Definition: PhysicsList.cc:239
static G4AntiNeutron * AntiNeutronDefinition()
static G4PionZero * PionZeroDefinition()
Definition: G4PionZero.cc:99
PhysicsListMessenger * fMessenger
Definition: PhysicsList.hh:78
void SetMaxEnergyForCSDARange(G4double val)
void AddPhysicsList(const G4String &name)
Definition: PhysicsList.cc:191
void SetParticleCuts(G4double cut, G4ParticleDefinition *particle, G4Region *region=0)
void DumpCutValuesTable(G4int flag=1)
G4GLOB_DLL std::ostream G4cout
G4double fCutForGamma
Definition: PhysicsList.hh:64
static G4PionMinus * PionMinusDefinition()
Definition: G4PionMinus.cc:93
static G4KaonZeroLong * KaonZeroLongDefinition()
static G4NeutrinoE * NeutrinoEDefinition()
Definition: G4NeutrinoE.cc:80
static G4AntiNeutrinoMu * AntiNeutrinoMuDefinition()
static G4PionPlus * PionPlusDefinition()
Definition: G4PionPlus.cc:93
static const double GeV
Definition: G4SIunits.hh:196
void SetVerboseLevel(G4int value)
static G4Gamma * Gamma()
Definition: G4Gamma.cc:86
void SetCuts()
Definition: PhysicsList.cc:219
static G4Positron * PositronDefinition()
Definition: G4Positron.cc:89
static G4EtaPrime * EtaPrimeDefinition()
Definition: G4EtaPrime.cc:100
static G4ProductionCutsTable * GetProductionCutsTable()
static const double eV
Definition: G4SIunits.hh:194
static G4Positron * Positron()
Definition: G4Positron.cc:94
static const double mm2
Definition: G4SIunits.hh:103
G4double fCurrentDefaultCut
Definition: PhysicsList.hh:71
static const double g
Definition: G4SIunits.hh:162
static G4MuonMinus * MuonMinusDefinition()
Definition: G4MuonMinus.cc:95
G4VPhysicsConstructor * fEmPhysicsList
Definition: PhysicsList.hh:73
virtual void ConstructProcess()=0
void SetBuildCSDARange(G4bool val)
static G4ChargedGeantino * ChargedGeantinoDefinition()
static G4Electron * Electron()
Definition: G4Electron.cc:94
#define G4endl
Definition: G4ios.hh:61
static G4AntiNeutrinoE * AntiNeutrinoEDefinition()
static G4OpticalPhoton * OpticalPhotonDefinition()
double G4double
Definition: G4Types.hh:76
G4String fEmName
Definition: PhysicsList.hh:72
void ConstructProcess()
Definition: PhysicsList.cc:170
static G4NeutrinoMu * NeutrinoMuDefinition()
Definition: G4NeutrinoMu.cc:80
static G4Deuteron * DeuteronDefinition()
Definition: G4Deuteron.cc:89
static const double mm
Definition: G4SIunits.hh:102
static G4Alpha * AlphaDefinition()
Definition: G4Alpha.cc:84
static G4Neutron * NeutronDefinition()
Definition: G4Neutron.cc:99
static G4Eta * EtaDefinition()
Definition: G4Eta.cc:104
static G4Gamma * GammaDefinition()
Definition: G4Gamma.cc:81
void SetVerbose(G4int val, const G4String &name="all", G4bool worker=false)