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
NeutronHPphysics.cc
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file NeutronHPphysics.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
//
28
//
29
//
30
31
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
32
33
#include "
NeutronHPphysics.hh
"
34
35
#include "NeutronHPMessenger.hh"
36
37
#include "
G4ParticleDefinition.hh
"
38
#include "
G4ProcessManager.hh
"
39
#include "
G4ProcessTable.hh
"
40
41
// Processes
42
43
#include "
G4HadronElasticProcess.hh
"
44
#include "
G4ParticleHPElasticData.hh
"
45
#include "
G4ParticleHPThermalScatteringData.hh
"
46
#include "
G4ParticleHPElastic.hh
"
47
#include "
G4ParticleHPThermalScattering.hh
"
48
49
#include "
G4NeutronInelasticProcess.hh
"
50
#include "
G4ParticleHPInelasticData.hh
"
51
#include "
G4ParticleHPInelastic.hh
"
52
53
#include "
G4HadronCaptureProcess.hh
"
54
#include "
G4ParticleHPCaptureData.hh
"
55
#include "
G4ParticleHPCapture.hh
"
56
57
#include "
G4HadronFissionProcess.hh
"
58
#include "
G4ParticleHPFissionData.hh
"
59
#include "
G4ParticleHPFission.hh
"
60
61
#include "
G4SystemOfUnits.hh
"
62
63
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
64
65
NeutronHPphysics::NeutronHPphysics
(
const
G4String
&
name
)
66
:
G4VPhysicsConstructor
(name), fThermal(
true
), fNeutronMessenger(0)
67
{
68
fNeutronMessenger
=
new
NeutronHPMessenger
(
this
);
69
}
70
71
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
72
73
NeutronHPphysics::~NeutronHPphysics
()
74
{
75
delete
fNeutronMessenger
;
76
}
77
78
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
79
80
void
NeutronHPphysics::ConstructProcess
()
81
{
82
G4ParticleDefinition
*
neutron
=
G4Neutron::Neutron
();
83
G4ProcessManager
* pManager = neutron->
GetProcessManager
();
84
85
// delete all neutron processes if already registered
86
//
87
G4VProcess
* process = 0;
88
process = pManager->
GetProcess
(
"hadElastic"
);
89
if
(process) pManager->
RemoveProcess
(process);
90
//
91
process = pManager->
GetProcess
(
"neutronInelastic"
);
92
if
(process) pManager->
RemoveProcess
(process);
93
//
94
process = pManager->
GetProcess
(
"nCapture"
);
95
if
(process) pManager->
RemoveProcess
(process);
96
//
97
process = pManager->
GetProcess
(
"nFission"
);
98
if
(process) pManager->
RemoveProcess
(process);
99
100
// (re) create process: elastic
101
//
102
G4HadronElasticProcess
* process1 =
new
G4HadronElasticProcess
();
103
pManager->
AddDiscreteProcess
(process1);
104
//
105
// model1a
106
G4ParticleHPElastic
* model1a =
new
G4ParticleHPElastic
();
107
process1->
RegisterMe
(model1a);
108
process1->
AddDataSet
(
new
G4ParticleHPElasticData
());
109
//
110
// model1b
111
if
(
fThermal
) {
112
model1a->
SetMinEnergy
(4*
eV
);
113
G4ParticleHPThermalScattering
* model1b =
new
G4ParticleHPThermalScattering
();
114
process1->
RegisterMe
(model1b);
115
process1->
AddDataSet
(
new
G4ParticleHPThermalScatteringData
());
116
}
117
118
// (re) create process: inelastic
119
//
120
G4NeutronInelasticProcess
* process2 =
new
G4NeutronInelasticProcess
();
121
pManager->
AddDiscreteProcess
(process2);
122
//
123
// cross section data set
124
G4ParticleHPInelasticData
* dataSet2 =
new
G4ParticleHPInelasticData
();
125
process2->
AddDataSet
(dataSet2);
126
//
127
// models
128
G4ParticleHPInelastic
* model2 =
new
G4ParticleHPInelastic
();
129
process2->
RegisterMe
(model2);
130
131
// (re) create process: nCapture
132
//
133
G4HadronCaptureProcess
* process3 =
new
G4HadronCaptureProcess
();
134
pManager->
AddDiscreteProcess
(process3);
135
//
136
// cross section data set
137
G4ParticleHPCaptureData
* dataSet3 =
new
G4ParticleHPCaptureData
();
138
process3->
AddDataSet
(dataSet3);
139
//
140
// models
141
G4ParticleHPCapture
* model3 =
new
G4ParticleHPCapture
();
142
process3->
RegisterMe
(model3);
143
144
// (re) create process: nFission
145
//
146
G4HadronFissionProcess
* process4 =
new
G4HadronFissionProcess
();
147
pManager->
AddDiscreteProcess
(process4);
148
//
149
// cross section data set
150
G4ParticleHPFissionData
* dataSet4 =
new
G4ParticleHPFissionData
();
151
process4->
AddDataSet
(dataSet4);
152
//
153
// models
154
G4ParticleHPFission
* model4 =
new
G4ParticleHPFission
();
155
process4->
RegisterMe
(model4);
156
}
157
158
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
geant4
tree
geant4-10.6-release
examples
extended
hadronic
Hadr04
src
NeutronHPphysics.cc
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:07
using
1.8.2 with
ECCE GitHub integration