IAP GITLAB
Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
corsika
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pranav Sampathkumar
corsika
Commits
761248fd
Commit
761248fd
authored
3 years ago
by
Felix Riehn
Committed by
ralfulrich
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
use conversion in interaction
parent
d6631c3d
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
corsika/detail/modules/epos/Interaction.inl
+19
-5
19 additions, 5 deletions
corsika/detail/modules/epos/Interaction.inl
corsika/modules/epos/Interaction.hpp
+2
-2
2 additions, 2 deletions
corsika/modules/epos/Interaction.hpp
with
21 additions
and
7 deletions
corsika/detail/modules/epos/Interaction.inl
+
19
−
5
View file @
761248fd
...
...
@@ -263,15 +263,29 @@ namespace corsika::epos {
// ::epos::nucl1_.laproj = projectile.get_nucleus_Z(); // Z
// ::epos::nucl1_.maproj = projectile.get_nucleus_A();; // A
// } else {
::
epos
::
hadr25_
.
idprojin
=
1120
;
// id "NEXUS code"
::
epos
::
hadr25_
.
idprojin
=
convertToEposRaw
(
corsikaBeamId
);
//
1120 ; // id "NEXUS code"
::
epos
::
nucl1_
.
laproj
=
-
1
;
// Z (-1 for hadron)
::
epos
::
nucl1_
.
maproj
=
1
;
// A
//}
// target
//if(is_nucleus(targetCode)){
::
epos
::
hadr25_
.
idtargin
=
1120
;
// id "NEXUS code"
::
epos
::
nucl1_
.
latarg
=
1
;
// Z (-1 with id 1220 for neutron)
::
epos
::
nucl1_
.
matarg
=
1
;
// A
int
targetMassNumber
=
1
;
// proton
if
(
is_nucleus
(
targetCode
))
{
// nucleus
targetMassNumber
=
get_nucleus_A
(
targetCode
);
if
(
targetMassNumber
>
maxTargetMassNumber_
)
throw
std
::
runtime_error
(
"Epos target mass outside range."
);
}
else
{
if
(
targetCode
!=
Proton
::
code
||
targetCode
!=
Neutron
::
code
)
throw
std
::
runtime_error
(
"Epos target not possible."
);
// proton or neutron target
::
epos
::
hadr25_
.
idtargin
=
convertToEposRaw
(
targetCode
);
if
(
targetCode
==
Proton
::
code
)
::
epos
::
nucl1_
.
latarg
=
1
;
// Z
else
::
epos
::
nucl1_
.
latarg
=
-
1
;
// Z (-1 with id 1220 for neutron)
::
epos
::
nucl1_
.
matarg
=
1
;
// A
}
CORSIKA_LOG_DEBUG
(
"Interaction: target epos code/A: {}"
,
targetMassNumber
);
// hadron-nucleon momentum
::
epos
::
hadr1_
.
pnll
=
float
(
200
);
...
...
This diff is collapsed.
Click to expand it.
corsika/modules/epos/Interaction.hpp
+
2
−
2
View file @
761248fd
...
...
@@ -55,8 +55,8 @@ namespace corsika::epos {
default_prng_type
&
RNG_
=
RNGManager
::
getInstance
().
getRandomStream
(
"epos"
);
HEPEnergyType
const
minEnergyCoM_
=
-
10.
*
1e9
*
electronvolt
;
HEPEnergyType
const
maxEnergyCoM_
=
-
1.e6
*
1e9
*
electronvolt
;
int
const
maxTargetMassNumber_
=
-
1
;
int
const
minNuclearTargetA_
=
-
10
;
int
const
maxTargetMassNumber_
=
20
;
int
const
minNuclearTargetA_
=
4
;
};
}
// namespace corsika::epos
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment