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
9824d30c
Commit
9824d30c
authored
4 years ago
by
ralfulrich
Browse files
Options
Downloads
Patches
Plain Diff
runs, but test fails
parent
57ab567f
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Processes/CONEXSourceCut/CONEXSourceCut.cc
+14
-13
14 additions, 13 deletions
Processes/CONEXSourceCut/CONEXSourceCut.cc
Processes/CONEXSourceCut/CONEXSourceCut.h
+5
-0
5 additions, 0 deletions
Processes/CONEXSourceCut/CONEXSourceCut.h
with
19 additions
and
13 deletions
Processes/CONEXSourceCut/CONEXSourceCut.cc
+
14
−
13
View file @
9824d30c
...
@@ -77,8 +77,8 @@ corsika::process::EProcessReturn CONEXSourceCut::DoSecondaries(
...
@@ -77,8 +77,8 @@ corsika::process::EProcessReturn CONEXSourceCut::DoSecondaries(
<<
std
::
endl
;
<<
std
::
endl
;
p
.
Delete
();
p
.
Delete
();
conex
::
s
how
_
(
egs_pid
,
E
,
x
,
y
,
altitude
,
slantDistance
,
lateralX
,
lateralY
,
slantX
,
conex
_
.
S
how
er
(
egs_pid
,
E
,
x
,
y
,
altitude
,
slantDistance
,
lateralX
,
lateralY
,
slantX
,
time
,
u
,
v
,
w
,
iri
,
weight
,
latchin
);
time
,
u
,
v
,
w
,
iri
,
weight
,
latchin
);
}
}
return
corsika
::
process
::
EProcessReturn
::
eOk
;
return
corsika
::
process
::
EProcessReturn
::
eOk
;
...
@@ -91,12 +91,12 @@ void CONEXSourceCut::SolveCE() {
...
@@ -91,12 +91,12 @@ void CONEXSourceCut::SolveCE() {
int
iCEmode
=
1
;
int
iCEmode
=
1
;
int
id
=
0
;
// RU: max, fix this
int
id
=
0
;
// RU: max, fix this
int
nshtot_
=
0
;
//RU: max, fix this
int
nshtot_
=
0
;
//RU: max, fix this
conex
::
h
adron
c
ascade
_
(
id
,
nshtot_
,
zero
,
iCEmode
);
conex
_
.
H
adron
C
ascade
(
id
,
nshtot_
,
zero
,
iCEmode
);
conex
::
s
olve
m
oment
e
quations
_
(
zero
);
conex
_
.
S
olve
M
oment
E
quations
(
zero
);
// RU: this here is from cxroot,
// RU: this here is from cxroot,
const
int
nX
=
conex
::
get_number_of_d
epth
_b
ins
_
();
// make sure this works!
int
nX
=
conex
_
.
GetNumberOfD
epth
B
ins
();
// make sure this works!
int
icut
=
1
;
int
icut
=
1
;
int
icutg
=
2
;
int
icutg
=
2
;
...
@@ -120,12 +120,12 @@ void CONEXSourceCut::SolveCE() {
...
@@ -120,12 +120,12 @@ void CONEXSourceCut::SolveCE() {
float
EGround
[
3
],
fitpars
[
13
],
currlgE
,
Xmx
,
Nmx
,
XmxdEdX
,
dEdXmx
;
float
EGround
[
3
],
fitpars
[
13
],
currlgE
,
Xmx
,
Nmx
,
XmxdEdX
,
dEdXmx
;
conex
::
get_s
hower
_d
ata
_
(
icut
,
iSec
,
nX
,
X
[
0
],
N
[
0
],
fitpars
[
0
],
H
[
0
],
D
[
0
]);
conex
_
.
GetS
hower
D
ata
(
icut
,
iSec
,
nX
,
X
[
0
],
N
[
0
],
fitpars
[
0
],
H
[
0
],
D
[
0
]);
conex
::
get_shower_edep_
(
icut
,
nX
,
dEdX
[
0
],
EGround
[
0
]);
conex
_
.
GetdEdXProfile
(
icut
,
nX
,
dEdX
[
0
],
EGround
[
0
]);
conex
::
get_shower_muon_
(
icutm
,
nX
,
Mu
[
0
],
dMu
[
0
]);
conex
_
.
GetMuonProfile
(
icutm
,
nX
,
Mu
[
0
],
dMu
[
0
]);
conex
::
get_shower_gamma_
(
icutg
,
nX
,
Gamma
[
0
]);
conex
_
.
GetGammaProfile
(
icutg
,
nX
,
Gamma
[
0
]);
conex
::
get_shower_electron_
(
icute
,
nX
,
Electrons
[
0
]);
conex
_
.
GetElectronProfile
(
icute
,
nX
,
Electrons
[
0
]);
conex
::
get_shower_hadron_
(
icuth
,
nX
,
Hadrons
[
0
]);
conex
_
.
GetHadronProfile
(
icuth
,
nX
,
Hadrons
[
0
]);
}
}
...
@@ -136,7 +136,8 @@ CONEXSourceCut::CONEXSourceCut(geometry::Point center, environment::ShowerAxis s
...
@@ -136,7 +136,8 @@ CONEXSourceCut::CONEXSourceCut(geometry::Point center, environment::ShowerAxis s
// units::si::GrammageType Xcut,
// units::si::GrammageType Xcut,
units
::
si
::
HEPEnergyType
primaryEnergy
,
units
::
si
::
HEPEnergyType
primaryEnergy
,
particles
::
PDGCode
primaryID
)
particles
::
PDGCode
primaryID
)
:
center_
{
center
}
:
conex_
(
ConexDynamicInterface
(
eSibyll23
))
,
center_
{
center
}
,
showerAxis_
{
showerAxis
}
,
showerAxis_
{
showerAxis
}
,
groundDist_
{
groundDist
}
,
groundDist_
{
groundDist
}
,
conexObservationCS_
{
std
::
invoke
([
&
]()
{
,
conexObservationCS_
{
std
::
invoke
([
&
]()
{
...
@@ -182,5 +183,5 @@ CONEXSourceCut::CONEXSourceCut(geometry::Point center, environment::ShowerAxis s
...
@@ -182,5 +183,5 @@ CONEXSourceCut::CONEXSourceCut(geometry::Point center, environment::ShowerAxis s
std
::
array
<
int
,
3
>
ioseed
{
static_cast
<
int
>
(
rng
()),
static_cast
<
int
>
(
rng
()),
std
::
array
<
int
,
3
>
ioseed
{
static_cast
<
int
>
(
rng
()),
static_cast
<
int
>
(
rng
()),
static_cast
<
int
>
(
rng
())};
static_cast
<
int
>
(
rng
())};
conex
::
c
onex
r
un
_
(
ipart
,
eprima
,
theta
,
phi
,
dimpact
,
ioseed
.
data
());
conex
_
.
C
onex
R
un
(
ipart
,
eprima
,
theta
,
phi
,
dimpact
,
ioseed
.
data
());
}
}
This diff is collapsed.
Click to expand it.
Processes/CONEXSourceCut/CONEXSourceCut.h
+
5
−
0
View file @
9824d30c
...
@@ -11,6 +11,7 @@
...
@@ -11,6 +11,7 @@
#ifndef _corsika_process_particle_cut_CONEXSourceCut_h_
#ifndef _corsika_process_particle_cut_CONEXSourceCut_h_
#define _corsika_process_particle_cut_CONEXSourceCut_h_
#define _corsika_process_particle_cut_CONEXSourceCut_h_
#define __CORSIKA8__ //must define this conex-internal flag
#include
<ConexDynamicInterface.h>
#include
<ConexDynamicInterface.h>
#include
<corsika/environment/ShowerAxis.h>
#include
<corsika/environment/ShowerAxis.h>
...
@@ -22,6 +23,7 @@
...
@@ -22,6 +23,7 @@
#include
<corsika/units/PhysicalUnits.h>
#include
<corsika/units/PhysicalUnits.h>
namespace
conex
{
namespace
conex
{
/*
extern "C" {
extern "C" {
// ipart,energy,theta,phi,dimpact,ioseed
// ipart,energy,theta,phi,dimpact,ioseed
void conexrun_(int& ipart, double& energy, double& theta, double& phi, double& dimpact,
void conexrun_(int& ipart, double& energy, double& theta, double& phi, double& dimpact,
...
@@ -43,6 +45,7 @@ namespace conex {
...
@@ -43,6 +45,7 @@ namespace conex {
void get_shower_electron_(const int&, const int&, float&);
void get_shower_electron_(const int&, const int&, float&);
void get_shower_hadron_(const int&, const int&, float&);
void get_shower_hadron_(const int&, const int&, float&);
}
}
*/
corsika
::
units
::
si
::
LengthType
constexpr
earthRadius
{
6371315
*
corsika
::
units
::
si
::
LengthType
constexpr
earthRadius
{
6371315
*
corsika
::
units
::
si
::
meter
};
corsika
::
units
::
si
::
meter
};
}
// namespace conex
}
// namespace conex
...
@@ -63,6 +66,8 @@ namespace corsika::process {
...
@@ -63,6 +66,8 @@ namespace corsika::process {
void
SolveCE
();
void
SolveCE
();
private:
private:
ConexDynamicInterface
conex_
;
//! CONEX e.m. particle codes
//! CONEX e.m. particle codes
static
std
::
array
<
std
::
pair
<
particles
::
Code
,
int
>
,
3
>
constexpr
egs_em_codes_
{
static
std
::
array
<
std
::
pair
<
particles
::
Code
,
int
>
,
3
>
constexpr
egs_em_codes_
{
{{
particles
::
Code
::
Gamma
,
0
},
{{
particles
::
Code
::
Gamma
,
0
},
...
...
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