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
PhysicsList.cc
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file PhysicsList.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
// This example is provided by the Geant4-DNA collaboration
27
// Any report or published results obtained using the Geant4-DNA software
28
// shall cite the following Geant4-DNA collaboration publication:
29
// Med. Phys. 37 (2010) 4692-4708
30
// and papers
31
// M. Batmunkh et al. J Radiat Res Appl Sci 8 (2015) 498-507
32
// O. Belov et al. Physica Medica 32 (2016) 1510-1520
33
// The Geant4-DNA web site is available at http://geant4-dna.org
34
//
35
// -------------------------------------------------------------------
36
// November 2016
37
// -------------------------------------------------------------------
38
//
39
//
42
43
#include "PhysicsList.hh"
44
#include "
G4SystemOfUnits.hh
"
45
#include "CommandLineParser.hh"
46
#include "
G4EmParameters.hh
"
47
// for discrete physics constructors!
48
#include "
G4EmDNAPhysics.hh
"
49
#include "
G4EmDNAPhysics_option1.hh
"
50
#include "
G4EmDNAPhysics_option2.hh
"
51
#include "
G4EmDNAPhysics_option3.hh
"
52
#include "
G4EmDNAPhysics_option4.hh
"
53
#include "
G4EmDNAPhysics_option5.hh
"
54
#include "
G4EmDNAPhysics_option6.hh
"
55
#include "
G4EmDNAPhysics_option7.hh
"
56
#include "
G4EmDNAPhysics_option8.hh
"
57
#include "
G4EmDNAChemistry.hh
"
58
#include "
G4EmDNAChemistry_option1.hh
"
59
// for condensed physics constructors!
60
#include "
G4EmLivermorePhysics.hh
"
61
#include "
G4EmPenelopePhysics.hh
"
62
#include "
G4EmStandardPhysics.hh
"
63
#include "
G4EmStandardPhysics_option3.hh
"
64
#include "
G4EmStandardPhysics_option4.hh
"
65
// for hadronic physics constructors!
66
#include "
G4HadronElasticPhysics.hh
"
67
#include "
G4HadronPhysicsQGSP_BIC.hh
"
68
#include "
G4StoppingPhysics.hh
"
69
#include "
G4IonPhysics.hh
"
70
#include "
G4EmExtraPhysics.hh
"
71
#include "
G4NeutronTrackingCut.hh
"
72
#include "
G4DecayPhysics.hh
"
73
#include "
G4RadioactiveDecayPhysics.hh
"
74
75
#include "
G4EmDNAPhysicsActivator.hh
"
76
77
using namespace
G4DNAPARSER ;
78
79
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
80
81
PhysicsList::PhysicsList
()
82
:
G4VModularPhysicsList
(),
83
fEmPhysicsList(nullptr),
84
fDNAActivator(nullptr),
85
fEmDNAChemistryList(nullptr),
86
fEmDNAChemistryList1(nullptr),
87
fEmName(
""
),
fHadronic
(
false
)
88
{
89
G4double
currentDefaultCut
= 1.*
micrometer
;
90
SetDefaultCutValue
(currentDefaultCut);
91
SetVerboseLevel
(1);
92
// fixe lower limit for cut
93
G4ProductionCutsTable::GetProductionCutsTable
()->
94
SetEnergyRange(100*
eV
, 1*
GeV
);
95
96
// Options of combination Geant4-DNA processes (Physics/Chemistry)
97
// with Standard and Hadronic Physics:
98
99
// a) DNAphysics and Livermore physics inside and outside neuron
100
G4cout
<<
"Livermore + DNAphysics is activated!"
<<
G4endl
;
101
RegisterConstructor
(
"emlivermore"
);
102
103
// 'G4EmParameters' works together with 'G4EmDNAPhysicsActivator'
104
// VI: in this example Livermore is a default in any way
105
// DNA option4 is the default configuration as well
106
fDNAActivator
=
new
G4EmDNAPhysicsActivator
();
107
/*
108
G4EmParameters::Instance()->AddDNA("Soma","Opt4");
109
G4EmParameters::Instance()->AddDNA("Dendrites","Opt4");
110
G4EmParameters::Instance()->AddDNA("Axon","Opt4");
111
*/
112
// b) Livermore + DNAPhysics + DNAChemistry
113
if
(CommandLineParser::GetParser()->GetCommandIfActive(
"-dnachemON"
))
114
{
115
G4cout
<<
"DNAChemistry is activated!"
<<
G4endl
;
116
RegisterPhysics
(
new
G4EmDNAChemistry
());
117
}
118
119
// d) "QGSP_BIC_EMY" package from hadrontherapy advanced example
120
if
(CommandLineParser::GetParser()->GetCommandIfActive(
"-dnahad"
))
121
{
122
G4cout
<<
"QGSP_BIC is activated!"
<<
G4endl
;
123
RegisterConstructor
(
"QGSP_BIC"
);
124
fHadronic
=
true
;
125
}
126
}
127
128
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
129
130
PhysicsList::~PhysicsList
()
131
{}
132
133
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
134
135
void
PhysicsList::ConstructParticle
()
136
{
137
if
(
fEmPhysicsList
) {
fEmPhysicsList
->
ConstructParticle
(); }
138
if
(
fDNAActivator
) {
fDNAActivator
->
ConstructParticle
(); }
139
if
(
fEmDNAChemistryList
) {
fEmDNAChemistryList
->
ConstructParticle
(); }
140
if
(
fEmDNAChemistryList1
) {
fEmDNAChemistryList1
->
ConstructParticle
(); }
141
G4VModularPhysicsList::ConstructParticle
();
142
}
143
144
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
145
146
void
PhysicsList::ConstructProcess
()
147
{
148
if
(
fEmPhysicsList
) {
fEmPhysicsList
->
ConstructProcess
(); }
149
if
(
fDNAActivator
) {
fDNAActivator
->
ConstructProcess
(); }
150
if
(
fEmDNAChemistryList
) {
fEmDNAChemistryList
->
ConstructProcess
(); }
151
if
(
fEmDNAChemistryList1
) {
fEmDNAChemistryList1
->
ConstructProcess
(); }
152
G4VModularPhysicsList::ConstructProcess
();
153
}
154
155
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
156
157
void
PhysicsList::RegisterConstructor
(
const
G4String
&
name
)
158
{
159
if
(name ==
fEmName
) {
return
; }
160
if
(name ==
"emstandard_opt0"
){
161
fEmName
=
name
;
162
delete
fEmPhysicsList
;
163
fEmPhysicsList
=
new
G4EmStandardPhysics
();
164
165
}
else
if
(name ==
"emstandard_opt3"
){
166
fEmName
=
name
;
167
delete
fEmPhysicsList
;
168
fEmPhysicsList
=
new
G4EmStandardPhysics_option3
();
169
170
}
else
if
(name ==
"emstandard_opt4"
){
171
fEmName
=
name
;
172
delete
fEmPhysicsList
;
173
fEmPhysicsList
=
new
G4EmStandardPhysics_option4
();
174
175
}
else
if
(name ==
"empenelope"
){
176
fEmName
=
name
;
177
delete
fEmPhysicsList
;
178
fEmPhysicsList
=
new
G4EmPenelopePhysics
();
179
180
}
else
if
(name ==
"emlivermore"
){
181
fEmName
=
name
;
182
delete
fEmPhysicsList
;
183
fEmPhysicsList
=
new
G4EmLivermorePhysics
();
184
185
}
else
if
(name ==
"G4EmDNAPhysics"
) {
186
delete
fEmPhysicsList
;
187
fEmPhysicsList
=
new
G4EmDNAPhysics
(
verboseLevel
);
188
fEmName
=
name
;
189
190
}
else
if
(name ==
"G4EmDNAPhysics_option1"
) {
191
delete
fEmPhysicsList
;
192
fEmPhysicsList
=
new
G4EmDNAPhysics_option1
(
verboseLevel
);
193
fEmName
=
name
;
194
195
}
else
if
(name ==
"G4EmDNAPhysics_option2"
) {
196
delete
fEmPhysicsList
;
197
fEmPhysicsList
=
new
G4EmDNAPhysics_option2
(
verboseLevel
);
198
fEmName
=
name
;
199
200
}
else
if
(name ==
"G4EmDNAPhysics_option3"
) {
201
delete
fEmPhysicsList
;
202
fEmPhysicsList
=
new
G4EmDNAPhysics_option3
(
verboseLevel
);
203
fEmName
=
name
;
204
205
}
else
if
(name ==
"G4EmDNAPhysics_option4"
) {
206
delete
fEmPhysicsList
;
207
fEmPhysicsList
=
new
G4EmDNAPhysics_option4
(
verboseLevel
);
208
fEmName
=
name
;
209
210
}
else
if
(name ==
"G4EmDNAPhysics_option5"
) {
211
delete
fEmPhysicsList
;
212
fEmPhysicsList
=
new
G4EmDNAPhysics_option5
(
verboseLevel
);
213
fEmName
=
name
;
214
215
}
else
if
(name ==
"G4EmDNAPhysics_option6"
) {
216
delete
fEmPhysicsList
;
217
fEmPhysicsList
=
new
G4EmDNAPhysics_option6
(
verboseLevel
);
218
fEmName
=
name
;
219
220
}
else
if
(name ==
"G4EmDNAPhysics_option7"
) {
221
delete
fEmPhysicsList
;
222
fEmPhysicsList
=
new
G4EmDNAPhysics_option7
(
verboseLevel
);
223
fEmName
=
name
;
224
225
}
else
if
(name ==
"G4EmDNAPhysics_option8"
) {
226
delete
fEmPhysicsList
;
227
fEmPhysicsList
=
new
G4EmDNAPhysics_option8
(
verboseLevel
);
228
fEmName
=
name
;
229
230
}
else
if
(name ==
"QGSP_BIC"
) {
231
if
(
fHadronic
) {
return
; }
232
// Hadron Elastic Physics
233
RegisterConstructor
(
"G4HadronElasticPhysics"
);
234
// Hadron Inelastic Physics
235
RegisterConstructor
(
"G4HadronPhysicsQGSP_BIC"
);
236
// Stopping
237
RegisterConstructor
(
"G4StoppingPhysics"
);
238
// Ion Physics
239
RegisterConstructor
(
"G4IonBinaryCascadePhysics"
);
240
// Gamma-Lepto nuclear
241
RegisterConstructor
(
"G4EmExtraPhysics"
);
242
// Limiters
243
RegisterConstructor
(
"G4NeutronTrackingCut"
);
244
// Decay
245
RegisterConstructor
(
"G4DecayPhysics"
);
246
// Radioactive decay
247
RegisterConstructor
(
"G4RadioactiveDecayPhysics"
);
248
249
}
else
if
(name ==
"G4EmDNAChemistry"
) {
250
if
(
fEmDNAChemistryList
||
fEmDNAChemistryList1
) {
return
; }
251
fEmDNAChemistryList
=
new
G4EmDNAChemistry
();
252
253
}
else
if
(name ==
"G4EmDNAChemistry_option1"
) {
254
if
(
fEmDNAChemistryList
||
fEmDNAChemistryList1
) {
return
; }
255
fEmDNAChemistryList1
=
new
G4EmDNAChemistry_option1
();
256
257
}
else
{
258
G4cout
<<
"PhysicsList::RegisterConstructor: <"
<< name <<
">"
259
<<
" fails - name is not defined"
260
<<
G4endl
;
261
}
262
}
263
264
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
geant4
tree
geant4-10.6-release
examples
extended
medical
dna
neuron
src
PhysicsList.cc
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:24:50
using
1.8.2 with
ECCE GitHub integration