ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
G4EmStandardPhysics_option1.cc
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file G4EmStandardPhysics_option1.cc
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
//
26
//
27
//---------------------------------------------------------------------------
28
//
29
// ClassName: G4EmStandardPhysics_option1
30
//
31
// Author: V.Ivanchenko 09.11.2005
32
//
33
// Modified:
34
//
35
//----------------------------------------------------------------------------
36
//
37
38
#include "
G4EmStandardPhysics_option1.hh
"
39
#include "
G4SystemOfUnits.hh
"
40
#include "
G4ParticleDefinition.hh
"
41
#include "
G4LossTableManager.hh
"
42
#include "
G4EmParameters.hh
"
43
44
#include "
G4ComptonScattering.hh
"
45
#include "
G4GammaConversion.hh
"
46
#include "
G4PhotoElectricEffect.hh
"
47
#include "
G4LivermorePhotoElectricModel.hh
"
48
49
#include "
G4eMultipleScattering.hh
"
50
#include "
G4MuMultipleScattering.hh
"
51
#include "
G4hMultipleScattering.hh
"
52
#include "
G4eCoulombScatteringModel.hh
"
53
#include "
G4CoulombScattering.hh
"
54
#include "
G4WentzelVIModel.hh
"
55
#include "
G4UrbanMscModel.hh
"
56
57
#include "
G4eIonisation.hh
"
58
#include "
G4eBremsstrahlung.hh
"
59
#include "
G4eplusAnnihilation.hh
"
60
#include "
G4UAtomicDeexcitation.hh
"
61
62
#include "
G4MuIonisation.hh
"
63
#include "
G4MuBremsstrahlung.hh
"
64
#include "
G4MuPairProduction.hh
"
65
#include "
G4hBremsstrahlung.hh
"
66
#include "
G4hPairProduction.hh
"
67
68
#include "
G4MuBremsstrahlungModel.hh
"
69
#include "
G4MuPairProductionModel.hh
"
70
#include "
G4hBremsstrahlungModel.hh
"
71
#include "
G4hPairProductionModel.hh
"
72
73
#include "
G4hIonisation.hh
"
74
#include "
G4ionIonisation.hh
"
75
#include "
G4alphaIonisation.hh
"
76
77
#include "
G4ParticleTable.hh
"
78
#include "
G4Gamma.hh
"
79
#include "
G4Electron.hh
"
80
#include "
G4Positron.hh
"
81
#include "
G4MuonPlus.hh
"
82
#include "
G4MuonMinus.hh
"
83
#include "
G4PionPlus.hh
"
84
#include "
G4PionMinus.hh
"
85
#include "
G4KaonPlus.hh
"
86
#include "
G4KaonMinus.hh
"
87
#include "
G4Proton.hh
"
88
#include "
G4AntiProton.hh
"
89
#include "
G4Deuteron.hh
"
90
#include "
G4Triton.hh
"
91
#include "
G4He3.hh
"
92
#include "
G4Alpha.hh
"
93
#include "
G4GenericIon.hh
"
94
95
#include "
G4PhysicsListHelper.hh
"
96
#include "
G4BuilderType.hh
"
97
#include "
G4EmModelActivator.hh
"
98
#include "
G4GammaGeneralProcess.hh
"
99
100
// factory
101
#include "
G4PhysicsConstructorFactory.hh
"
102
//
103
G4_DECLARE_PHYSCONSTR_FACTORY
(
G4EmStandardPhysics_option1
);
104
105
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
106
107
G4EmStandardPhysics_option1::G4EmStandardPhysics_option1
(
G4int
ver,
108
const
G4String
&)
109
:
G4VPhysicsConstructor
(
"G4EmStandard_opt1"
), verbose(ver)
110
{
111
G4EmParameters
* param =
G4EmParameters::Instance
();
112
param->
SetDefaults
();
113
param->
SetVerbose
(
verbose
);
114
param->
SetApplyCuts
(
true
);
115
param->
SetGeneralProcessActive
(
true
);
116
param->
SetMscRangeFactor
(0.2);
117
param->
SetMscStepLimitType
(
fMinimal
);
118
SetPhysicsType
(
bElectromagnetic
);
119
}
120
121
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
122
123
G4EmStandardPhysics_option1::~G4EmStandardPhysics_option1
()
124
{}
125
126
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
127
128
void
G4EmStandardPhysics_option1::ConstructParticle
()
129
{
130
// gamma
131
G4Gamma::Gamma
();
132
133
// leptons
134
G4Electron::Electron
();
135
G4Positron::Positron
();
136
G4MuonPlus::MuonPlus
();
137
G4MuonMinus::MuonMinus
();
138
139
// mesons
140
G4PionPlus::PionPlusDefinition
();
141
G4PionMinus::PionMinusDefinition
();
142
G4KaonPlus::KaonPlusDefinition
();
143
G4KaonMinus::KaonMinusDefinition
();
144
145
// barions
146
G4Proton::Proton
();
147
G4AntiProton::AntiProton
();
148
149
// ions
150
G4Deuteron::Deuteron
();
151
G4Triton::Triton
();
152
G4He3::He3
();
153
G4Alpha::Alpha
();
154
G4GenericIon::GenericIonDefinition
();
155
}
156
157
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
158
159
void
G4EmStandardPhysics_option1::ConstructProcess
()
160
{
161
if
(
verbose
> 1) {
162
G4cout
<<
"### "
<<
GetPhysicsName
() <<
" Construct Processes "
<<
G4endl
;
163
}
164
G4PhysicsListHelper
* ph =
G4PhysicsListHelper::GetPhysicsListHelper
();
165
G4LossTableManager
* man =
G4LossTableManager::Instance
();
166
167
// muon & hadron bremsstrahlung and pair production
168
G4MuBremsstrahlung
* mub =
new
G4MuBremsstrahlung
();
169
G4MuPairProduction
*
mup
=
new
G4MuPairProduction
();
170
G4hBremsstrahlung
* pib =
new
G4hBremsstrahlung
();
171
G4hPairProduction
*
pip
=
new
G4hPairProduction
();
172
G4hBremsstrahlung
* kb =
new
G4hBremsstrahlung
();
173
G4hPairProduction
* kp =
new
G4hPairProduction
();
174
G4hBremsstrahlung
* pb =
new
G4hBremsstrahlung
();
175
G4hPairProduction
*
pp
=
new
G4hPairProduction
();
176
177
// muon & hadron multiple scattering
178
G4MuMultipleScattering
* mumsc =
new
G4MuMultipleScattering
();
179
mumsc->
SetEmModel
(
new
G4WentzelVIModel
());
180
G4CoulombScattering
* muss =
new
G4CoulombScattering
();
181
182
G4hMultipleScattering
* pimsc =
new
G4hMultipleScattering
();
183
pimsc->
SetEmModel
(
new
G4WentzelVIModel
());
184
G4CoulombScattering
* piss =
new
G4CoulombScattering
();
185
186
G4hMultipleScattering
* kmsc =
new
G4hMultipleScattering
();
187
kmsc->
SetEmModel
(
new
G4WentzelVIModel
());
188
G4CoulombScattering
* kss =
new
G4CoulombScattering
();
189
190
G4hMultipleScattering
* hmsc =
new
G4hMultipleScattering
(
"ionmsc"
);
191
192
// high energy limit for e+- scattering models and bremsstrahlung
193
G4double
highEnergyLimit =
G4EmParameters::Instance
()->
MscEnergyLimit
();
194
195
// Add standard EM Processes
196
G4ParticleTable
* table =
G4ParticleTable::GetParticleTable
();
197
for
(
const
auto
& particleName :
partList
.
PartNames
()) {
198
G4ParticleDefinition
*
particle
= table->
FindParticle
(particleName);
199
if
(!particle) {
continue
; }
200
if
(particleName ==
"gamma"
) {
201
202
G4PhotoElectricEffect
* pee =
new
G4PhotoElectricEffect
();
203
pee->
SetEmModel
(
new
G4LivermorePhotoElectricModel
());
204
205
if
(
G4EmParameters::Instance
()->GeneralProcessActive()) {
206
G4GammaGeneralProcess
*
sp
=
new
G4GammaGeneralProcess
();
207
sp->
AddEmProcess
(pee);
208
sp->
AddEmProcess
(
new
G4ComptonScattering
());
209
sp->
AddEmProcess
(
new
G4GammaConversion
());
210
man->
SetGammaGeneralProcess
(sp);
211
ph->
RegisterProcess
(sp, particle);
212
213
}
else
{
214
ph->
RegisterProcess
(pee, particle);
215
ph->
RegisterProcess
(
new
G4ComptonScattering
(), particle);
216
ph->
RegisterProcess
(
new
G4GammaConversion
(), particle);
217
}
218
219
}
else
if
(particleName ==
"e-"
) {
220
221
G4eIonisation
* eioni =
new
G4eIonisation
();
222
eioni->
SetStepFunction
(0.8, 1.0*
mm
);
223
224
G4eMultipleScattering
* msc =
new
G4eMultipleScattering
;
225
G4UrbanMscModel
* msc1 =
new
G4UrbanMscModel
();
226
G4WentzelVIModel
* msc2 =
new
G4WentzelVIModel
();
227
msc1->
SetHighEnergyLimit
(highEnergyLimit);
228
msc2->
SetLowEnergyLimit
(highEnergyLimit);
229
msc->
SetEmModel
(msc1);
230
msc->
SetEmModel
(msc2);
231
232
G4eCoulombScatteringModel
* ssm =
new
G4eCoulombScatteringModel
();
233
G4CoulombScattering
* ss =
new
G4CoulombScattering
();
234
ss->
SetEmModel
(ssm);
235
ss->
SetMinKinEnergy
(highEnergyLimit);
236
ssm->
SetLowEnergyLimit
(highEnergyLimit);
237
ssm->
SetActivationLowEnergyLimit
(highEnergyLimit);
238
239
ph->
RegisterProcess
(msc, particle);
240
ph->
RegisterProcess
(eioni, particle);
241
ph->
RegisterProcess
(
new
G4eBremsstrahlung
(), particle);
242
ph->
RegisterProcess
(ss, particle);
243
244
}
else
if
(particleName ==
"e+"
) {
245
246
G4eIonisation
* eioni =
new
G4eIonisation
();
247
eioni->
SetStepFunction
(0.8, 1.0*
mm
);
248
249
G4eMultipleScattering
* msc =
new
G4eMultipleScattering
;
250
G4UrbanMscModel
* msc1 =
new
G4UrbanMscModel
();
251
G4WentzelVIModel
* msc2 =
new
G4WentzelVIModel
();
252
msc1->
SetHighEnergyLimit
(highEnergyLimit);
253
msc2->
SetLowEnergyLimit
(highEnergyLimit);
254
msc->
SetEmModel
(msc1);
255
msc->
SetEmModel
(msc2);
256
257
G4eCoulombScatteringModel
* ssm =
new
G4eCoulombScatteringModel
();
258
G4CoulombScattering
* ss =
new
G4CoulombScattering
();
259
ss->
SetEmModel
(ssm);
260
ss->
SetMinKinEnergy
(highEnergyLimit);
261
ssm->
SetLowEnergyLimit
(highEnergyLimit);
262
ssm->
SetActivationLowEnergyLimit
(highEnergyLimit);
263
264
ph->
RegisterProcess
(msc, particle);
265
ph->
RegisterProcess
(eioni, particle);
266
ph->
RegisterProcess
(
new
G4eBremsstrahlung
(), particle);
267
ph->
RegisterProcess
(
new
G4eplusAnnihilation
(), particle);
268
ph->
RegisterProcess
(ss, particle);
269
270
}
else
if
(particleName ==
"mu+"
||
271
particleName ==
"mu-"
) {
272
273
ph->
RegisterProcess
(mumsc, particle);
274
ph->
RegisterProcess
(
new
G4MuIonisation
(), particle);
275
ph->
RegisterProcess
(mub, particle);
276
ph->
RegisterProcess
(mup, particle);
277
ph->
RegisterProcess
(muss, particle);
278
279
}
else
if
(particleName ==
"alpha"
||
280
particleName ==
"He3"
) {
281
282
ph->
RegisterProcess
(
new
G4hMultipleScattering
(), particle);
283
ph->
RegisterProcess
(
new
G4ionIonisation
(), particle);
284
285
}
else
if
(particleName ==
"GenericIon"
) {
286
287
ph->
RegisterProcess
(hmsc, particle);
288
ph->
RegisterProcess
(
new
G4ionIonisation
(), particle);
289
290
}
else
if
(particleName ==
"pi+"
||
291
particleName ==
"pi-"
) {
292
293
ph->
RegisterProcess
(pimsc, particle);
294
ph->
RegisterProcess
(
new
G4hIonisation
(), particle);
295
ph->
RegisterProcess
(pib, particle);
296
ph->
RegisterProcess
(pip, particle);
297
ph->
RegisterProcess
(piss, particle);
298
299
}
else
if
(particleName ==
"kaon+"
||
300
particleName ==
"kaon-"
) {
301
302
ph->
RegisterProcess
(kmsc, particle);
303
ph->
RegisterProcess
(
new
G4hIonisation
(), particle);
304
ph->
RegisterProcess
(kb, particle);
305
ph->
RegisterProcess
(kp, particle);
306
ph->
RegisterProcess
(kss, particle);
307
308
}
else
if
(particleName ==
"proton"
||
309
particleName ==
"anti_proton"
) {
310
311
G4hMultipleScattering
* pmsc =
new
G4hMultipleScattering
();
312
pmsc->
SetEmModel
(
new
G4WentzelVIModel
());
313
314
ph->
RegisterProcess
(pmsc, particle);
315
ph->
RegisterProcess
(
new
G4hIonisation
(), particle);
316
ph->
RegisterProcess
(pb, particle);
317
ph->
RegisterProcess
(pp, particle);
318
ph->
RegisterProcess
(
new
G4CoulombScattering
(), particle);
319
320
}
else
if
(particleName ==
"B+"
||
321
particleName ==
"B-"
||
322
particleName ==
"D+"
||
323
particleName ==
"D-"
||
324
particleName ==
"Ds+"
||
325
particleName ==
"Ds-"
||
326
particleName ==
"anti_He3"
||
327
particleName ==
"anti_alpha"
||
328
particleName ==
"anti_deuteron"
||
329
particleName ==
"anti_lambda_c+"
||
330
particleName ==
"anti_omega-"
||
331
particleName ==
"anti_sigma_c+"
||
332
particleName ==
"anti_sigma_c++"
||
333
particleName ==
"anti_sigma+"
||
334
particleName ==
"anti_sigma-"
||
335
particleName ==
"anti_triton"
||
336
particleName ==
"anti_xi_c+"
||
337
particleName ==
"anti_xi-"
||
338
particleName ==
"deuteron"
||
339
particleName ==
"lambda_c+"
||
340
particleName ==
"omega-"
||
341
particleName ==
"sigma_c+"
||
342
particleName ==
"sigma_c++"
||
343
particleName ==
"sigma+"
||
344
particleName ==
"sigma-"
||
345
particleName ==
"tau+"
||
346
particleName ==
"tau-"
||
347
particleName ==
"triton"
||
348
particleName ==
"xi_c+"
||
349
particleName ==
"xi-"
) {
350
351
ph->
RegisterProcess
(hmsc, particle);
352
ph->
RegisterProcess
(
new
G4hIonisation
(), particle);
353
}
354
}
355
356
// Deexcitation
357
//
358
man->
SetAtomDeexcitation
(
new
G4UAtomicDeexcitation
());
359
360
G4EmModelActivator
mact(
GetPhysicsName
());
361
}
362
363
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
geant4
tree
geant4-10.6-release
source
physics_lists
constructors
electromagnetic
src
G4EmStandardPhysics_option1.cc
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:26
using
1.8.2 with
ECCE GitHub integration