Geant4
9.6.p02
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
geant4_9_6_p02
examples
extended
electromagnetic
TestEm13
src
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$
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 "PhysListEmLivermore.hh"
40
#include "PhysListEmPenelope.hh"
41
42
#include "
G4LossTableManager.hh
"
43
#include "
G4UnitsTable.hh
"
44
#include "
G4SystemOfUnits.hh
"
45
46
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
47
48
PhysicsList::PhysicsList
()
49
:
G4VModularPhysicsList
()
50
{
51
52
//add new units for cross sections
53
//
54
new
G4UnitDefinition
(
"mm2/g"
,
"mm2/g"
,
"Surface/Mass"
,
mm2
/
g
);
55
new
G4UnitDefinition
(
"um2/mg"
,
"um2/mg"
,
"Surface/Mass"
, um*um/
mg
);
56
57
G4LossTableManager::Instance
();
58
59
fCurrentDefaultCut = 1.0*
mm
;
60
fCutForGamma = fCurrentDefaultCut;
61
fCutForElectron = fCurrentDefaultCut;
62
fCutForPositron = fCurrentDefaultCut;
63
64
fMessenger =
new
PhysicsListMessenger
(
this
);
65
66
SetVerboseLevel
(1);
67
68
// EM physics
69
fEmName =
G4String
(
"standard"
);
70
fEmPhysicsList =
new
PhysListEmStandard
(fEmName);
71
}
72
73
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
74
75
PhysicsList::~PhysicsList
()
76
{
77
delete
fMessenger;
78
}
79
80
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
81
82
// Bosons
83
#include "
G4ChargedGeantino.hh
"
84
#include "
G4Geantino.hh
"
85
#include "
G4Gamma.hh
"
86
#include "
G4OpticalPhoton.hh
"
87
88
// leptons
89
#include "
G4MuonPlus.hh
"
90
#include "
G4MuonMinus.hh
"
91
#include "
G4NeutrinoMu.hh
"
92
#include "
G4AntiNeutrinoMu.hh
"
93
94
#include "
G4Electron.hh
"
95
#include "
G4Positron.hh
"
96
#include "
G4NeutrinoE.hh
"
97
#include "
G4AntiNeutrinoE.hh
"
98
99
// Mesons
100
#include "
G4PionPlus.hh
"
101
#include "
G4PionMinus.hh
"
102
#include "
G4PionZero.hh
"
103
#include "
G4Eta.hh
"
104
#include "
G4EtaPrime.hh
"
105
106
#include "
G4KaonPlus.hh
"
107
#include "
G4KaonMinus.hh
"
108
#include "
G4KaonZero.hh
"
109
#include "
G4AntiKaonZero.hh
"
110
#include "
G4KaonZeroLong.hh
"
111
#include "
G4KaonZeroShort.hh
"
112
113
// Baryons
114
#include "
G4Proton.hh
"
115
#include "
G4AntiProton.hh
"
116
#include "
G4Neutron.hh
"
117
#include "
G4AntiNeutron.hh
"
118
119
// Nuclei
120
#include "
G4Deuteron.hh
"
121
#include "
G4Triton.hh
"
122
#include "
G4Alpha.hh
"
123
#include "
G4GenericIon.hh
"
124
125
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
126
127
void
PhysicsList::ConstructParticle
()
128
{
129
// pseudo-particles
130
G4Geantino::GeantinoDefinition
();
131
G4ChargedGeantino::ChargedGeantinoDefinition
();
132
133
// gamma
134
G4Gamma::GammaDefinition
();
135
136
// optical photon
137
G4OpticalPhoton::OpticalPhotonDefinition
();
138
139
// leptons
140
G4Electron::ElectronDefinition
();
141
G4Positron::PositronDefinition
();
142
G4MuonPlus::MuonPlusDefinition
();
143
G4MuonMinus::MuonMinusDefinition
();
144
145
G4NeutrinoE::NeutrinoEDefinition
();
146
G4AntiNeutrinoE::AntiNeutrinoEDefinition
();
147
G4NeutrinoMu::NeutrinoMuDefinition
();
148
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition
();
149
150
// mesons
151
G4PionPlus::PionPlusDefinition
();
152
G4PionMinus::PionMinusDefinition
();
153
G4PionZero::PionZeroDefinition
();
154
G4Eta::EtaDefinition
();
155
G4EtaPrime::EtaPrimeDefinition
();
156
G4KaonPlus::KaonPlusDefinition
();
157
G4KaonMinus::KaonMinusDefinition
();
158
G4KaonZero::KaonZeroDefinition
();
159
G4AntiKaonZero::AntiKaonZeroDefinition
();
160
G4KaonZeroLong::KaonZeroLongDefinition
();
161
G4KaonZeroShort::KaonZeroShortDefinition
();
162
163
// barions
164
G4Proton::ProtonDefinition
();
165
G4AntiProton::AntiProtonDefinition
();
166
G4Neutron::NeutronDefinition
();
167
G4AntiNeutron::AntiNeutronDefinition
();
168
169
// ions
170
G4Deuteron::DeuteronDefinition
();
171
G4Triton::TritonDefinition
();
172
G4Alpha::AlphaDefinition
();
173
G4GenericIon::GenericIonDefinition
();
174
}
175
176
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
177
178
#include "
G4EmProcessOptions.hh
"
179
180
void
PhysicsList::ConstructProcess
()
181
{
182
// Transportation
183
//
184
AddTransportation
();
185
186
// Electromagnetic physics list
187
//
188
fEmPhysicsList->
ConstructProcess
();
189
190
// Em options
191
//
192
G4EmProcessOptions
emOptions;
193
emOptions.
SetIntegral
(
false
);
194
}
195
196
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
197
198
void
PhysicsList::AddPhysicsList
(
const
G4String
&
name
)
199
{
200
if
(
verboseLevel
>0) {
201
G4cout
<<
"PhysicsList::AddPhysicsList: <"
<< name <<
">"
<<
G4endl
;
202
}
203
204
if
(name == fEmName)
return
;
205
206
if
(name ==
"standard"
) {
207
fEmName =
name
;
208
delete
fEmPhysicsList;
209
fEmPhysicsList =
new
PhysListEmStandard
(name);
210
211
}
else
if
(name ==
"livermore"
) {
212
fEmName =
name
;
213
delete
fEmPhysicsList;
214
fEmPhysicsList =
new
PhysListEmLivermore
(name);
215
216
}
else
if
(name ==
"penelope"
) {
217
fEmName =
name
;
218
delete
fEmPhysicsList;
219
fEmPhysicsList =
new
PhysListEmPenelope
(name);
220
221
}
else
{
222
G4cout
<<
"PhysicsList::AddPhysicsList: <"
<< name <<
">"
223
<<
" is not defined"
224
<<
G4endl
;
225
}
226
}
227
228
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
229
230
#include "
G4Gamma.hh
"
231
#include "
G4Electron.hh
"
232
#include "
G4Positron.hh
"
233
234
void
PhysicsList::SetCuts
()
235
{
236
// fixe lower limit for cut
237
G4ProductionCutsTable::GetProductionCutsTable
()->
SetEnergyRange
(100*
eV
, 1*
GeV
);
238
239
// set cut values for gamma at first and for e- second and next for e+,
240
// because some processes for e+/e- need cut values for gamma
241
SetCutValue
(fCutForGamma,
"gamma"
);
242
SetCutValue
(fCutForElectron,
"e-"
);
243
SetCutValue
(fCutForPositron,
"e+"
);
244
}
245
246
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
247
248
void
PhysicsList::SetCutForGamma
(
G4double
cut)
249
{
250
fCutForGamma = cut;
251
SetParticleCuts
(fCutForGamma,
G4Gamma::Gamma
());
252
}
253
254
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
255
256
void
PhysicsList::SetCutForElectron
(
G4double
cut)
257
{
258
fCutForElectron = cut;
259
SetParticleCuts
(fCutForElectron,
G4Electron::Electron
());
260
}
261
262
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
263
264
void
PhysicsList::SetCutForPositron
(
G4double
cut)
265
{
266
fCutForPositron = cut;
267
SetParticleCuts
(fCutForPositron,
G4Positron::Positron
());
268
}
269
270
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
Generated on Sat May 25 2013 14:31:57 for Geant4 by
1.8.4