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
G4ElasticHadrNucleusHE.hh
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file G4ElasticHadrNucleusHE.hh
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
// G4ElasticHadrNucleusHe.hh
27
28
// The generator of high energy hadron-nucleus elastic scattering
29
// The hadron kinetic energy T > 1 GeV
30
// N.Starkov 2003.
31
//
32
// 19.11.05 The HE elastic scattering on proton is added (N.Starkov)
33
// 16.11.06 General redesign (N.Starkov)
34
// 23.11.06 General cleanup, ONQ0=3 (V.Ivanchenko)
35
// 15.05.07 Redesign and cleanup (V.Ivanchenko)
36
// 18.05.07 Cleanup (V.Grichine)
37
// 19.04.12 Fixed reproducibility violation (A.Ribon)
38
// 12.06.12 Fixed warnings of shadowed variables (A.Ribon)
39
//
40
41
#ifndef G4ElasticHadrNucleusHE_h
42
#define G4ElasticHadrNucleusHE_h 1
43
44
#include <vector>
45
46
#include "
globals.hh
"
47
#include "
G4ParticleDefinition.hh
"
48
#include "
G4ParticleChange.hh
"
49
#include "
G4Nucleus.hh
"
50
#include "
G4HadronElastic.hh
"
51
#include "
G4Threading.hh
"
52
53
class
G4NistManager
;
54
55
static
const
G4int
NHADRONS
= 26;
// Number of allowed hadrons
56
static
const
G4int
ONQ2
= 102;
// Number of points on Q2
57
static
const
G4int
NENERGY
= 24;
58
static
const
G4int
ZMAX
= 93;
59
61
62
class
G4ElasticData
63
{
64
65
friend
class
G4ElasticHadrNucleusHE
;
66
67
public
:
68
69
G4ElasticData
(
const
G4ParticleDefinition
*
h
,
G4int
Z
,
G4int
A
,
70
const
G4double
*
e
);
71
72
~G4ElasticData
() {}
73
74
private
:
75
76
void
DefineNucleusParameters
(
G4int
A
);
77
78
// hide assignment operator
79
G4ElasticData
&
operator=
(
const
G4ElasticData
&
right
);
80
G4ElasticData
(
const
G4ElasticData
&);
81
82
G4double
R1
,
R2
,
Pnucl
,
Aeff
;
83
G4double
dQ2
;
84
G4double
massA
;
85
G4double
massA2
;
86
G4double
maxQ2
[
NENERGY
];
87
std::vector<G4double>
fCumProb
[
NENERGY
];
88
};
89
91
92
class
G4ElasticHadrNucleusHE
:
public
G4HadronElastic
93
{
94
public
:
95
96
explicit
G4ElasticHadrNucleusHE
(
const
G4String
&
name
=
"hElasticGlauber"
);
97
98
~G4ElasticHadrNucleusHE
()
override
;
99
100
G4double
SampleInvariantT
(
const
G4ParticleDefinition
*
p
,
G4double
plab,
101
G4int
Z
,
G4int
A
)
override
;
102
103
void
InitialiseModel
()
override
;
104
105
void
ModelDescription
(std::ostream&)
const override
;
106
107
private
:
108
109
G4double
HadronNucleusQ2_2
(
const
G4ElasticData
*pElD,
G4double
plabGeV,
110
G4double
tmax);
111
112
void
DefineHadronValues
(
G4int
Z);
113
G4int
FillFq2
(
G4int
A);
114
115
G4double
GetLightFq2
(
G4int
Z,
G4int
A,
G4double
Q
);
116
117
G4double
GetQ2_2
(
G4int
N
,
G4int
Nmax,
118
const
std::vector<G4double>&
F
,
G4double
rand);
119
120
G4double
HadrNucDifferCrSec
(
G4int
A,
G4double
Q2);
121
122
void
InterpolateHN
(
G4int
n
,
const
G4double
EnP[],
123
const
G4double
C0P[],
const
G4double
C1P[],
124
const
G4double
B0P[],
const
G4double
B1P[]);
125
126
G4double
GetFt
(
G4double
Q2);
127
128
G4double
HadronProtonQ2
(
G4double
plab,
G4double
tmax);
129
130
void
Binom
();
131
132
void
FillData
(
const
G4ParticleDefinition
* p,
G4int
idx
,
G4int
Z);
133
134
inline
G4double
LineInterpol
(
G4double
p0,
G4double
p2,
135
G4double
c1
,
G4double
c2
,
G4double
p);
136
137
inline
G4double
GetBinomCof
(
G4int
n,
G4int
m
);
138
139
// hide assignment operator
140
G4ElasticHadrNucleusHE
&
operator=
(
const
G4ElasticHadrNucleusHE
&
right
);
141
G4ElasticHadrNucleusHE
(
const
G4ElasticHadrNucleusHE
&);
142
143
// fields
144
G4int
iHadrCode
;
145
G4int
iHadron
;
146
G4int
iHadron1
;
147
static
const
G4int
fHadronCode
[
NHADRONS
];
148
static
const
G4int
fHadronType
[
NHADRONS
];
149
static
const
G4int
fHadronType1
[
NHADRONS
];
150
151
// momemtum limits
152
G4double
ekinLowLimit
;
153
G4double
dQ2
;
154
155
// projectile kinematics in GeV
156
G4double
hMass
;
157
G4double
hMass2
;
158
G4double
hLabMomentum
;
159
G4double
hLabMomentum2
;
160
G4double
HadrEnergy
;
161
162
// elastic parameters
163
G4double
HadrTot
,
HadrSlope
,
HadrReIm
,
TotP
;
164
G4double
DDSect2
,
DDSect3
,
ConstU
;
165
166
// momentum limits for different models of hadron/nucleon scatetring
167
G4double
BoundaryP
[7],
BoundaryTL
[7],
BoundaryTG
[7];
168
169
// parameterisation of scattering
170
G4double
Slope1
,
Slope2
,
Coeff1
,
Coeff2
;
171
G4double
Slope0
,
Coeff0
;
172
173
G4double
aAIm
,
aDIm
,
Dtot11
;
174
175
// nucleaus parameters
176
G4double
R1
,
R2
,
Pnucl
,
Aeff
,
Q2max
;
177
178
static
G4double
fLineF
[
ONQ2
];
179
static
G4double
fEnergy
[
NENERGY
];
180
static
G4double
fLowEdgeEnergy
[
NENERGY
];
181
static
G4double
fBinom
[240][240];
182
183
static
G4ElasticData
*
fElasticData
[
NHADRONS
][
ZMAX
];
184
G4NistManager
*
nistManager
;
185
G4bool
isMaster
;
186
187
#ifdef G4MULTITHREADED
188
static
G4Mutex
elasticMutex;
189
#endif
190
191
};
192
194
195
inline
196
G4double
G4ElasticHadrNucleusHE::LineInterpol
(
G4double
p1,
G4double
p2,
197
G4double
c1
,
G4double
c2
,
198
G4double
p
)
199
{
200
return
c1+(p-p1)*(c2-c1)/(p2-p1);
201
}
202
204
205
inline
206
G4double
G4ElasticHadrNucleusHE::GetBinomCof
(
G4int
numN,
G4int
numM)
207
{
208
return
(numN >= numM && numN < 240) ?
fBinom
[numN][numM] : 0.0;
209
}
210
212
213
#endif
geant4
tree
geant4-10.6-release
source
processes
hadronic
models
coherent_elastic
include
G4ElasticHadrNucleusHE.hh
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:40
using
1.8.2 with
ECCE GitHub integration