IAP GITLAB

Skip to content
Snippets Groups Projects
Commit 4a0a2786 authored by Felix Riehn's avatar Felix Riehn Committed by ralfulrich
Browse files

be quiet

parent 3b9b029d
No related branches found
No related tags found
1 merge request!318Resolve "EPOS is missing"
......@@ -28,8 +28,8 @@ using SetupParticle = setup::Stack::stack_iterator_type;
namespace corsika::epos {
inline Interaction::Interaction(const std::string& dataPath)
: data_path_(dataPath) {
inline Interaction::Interaction(const std::string& dataPath, const bool epos_printout_on)
: data_path_(dataPath), epos_listing_(epos_printout_on) {
if (dataPath == "") {
if (std::getenv("CORSIKA_DATA")) {
data_path_ = std::string(std::getenv("CORSIKA_DATA")) + "/EPOS/";
......@@ -52,7 +52,7 @@ namespace corsika::epos {
::epos::aaset_(iarg);
//::epos::atitle_();
::epos::prnt1_.ish = 3; // debug level in epos
::epos::prnt1_.ish = 0; // debug level in epos
::epos::files_.ifch = 6; // output unit
//::epos::prnt1_.iecho = 1;
......@@ -309,7 +309,9 @@ namespace corsika::epos {
::epos::aepos_(iarg);
::epos::afinal_();
if (epos_listing_) ::epos::alistf_("EPOSLHC&");
// NSTORE-part
MomentumVector Plab_final(originalCS, {0.0_GeV, 0.0_GeV, 0.0_GeV});
......@@ -317,31 +319,29 @@ namespace corsika::epos {
// secondaries
EposStack es;
CORSIKA_LOG_DEBUG("npart: {}", es.getSize());
int i=-1;
CORSIKA_LOG_DEBUG("EPOSLHC number of particles: {}", es.getSize());
// int i=-1;
for (auto& psec : es) {
++i;
//++i;
if (!psec.isFinal()) continue;
CORSIKA_LOG_DEBUG("EPOS: i, id, energy, mass, type, state: {} {} {} {} {}", i,
::epos::cptl_.idptl[i], ::epos::cptl_.pptl[3][i],
::epos::cptl_.pptl[4][i], ::epos::cptl_.ityptl[i],
::epos::cptl_.istptl[i]);
CORSIKA_LOG_DEBUG("id, energy: {} {}", psec.getPID(), psec.getEnergy());
int id = abs(static_cast<int>(psec.getPID()));
CORSIKA_LOG_DEBUG("epos id to pdg: {}",
::epos::idtrafo_("nxs", "pdg", id));
// CORSIKA_LOG_DEBUG("EPOS: i, id, energy, mass, type, state: {} {} {} {} {}", i,
// ::epos::cptl_.idptl[i], ::epos::cptl_.pptl[3][i],
// ::epos::cptl_.pptl[4][i], ::epos::cptl_.ityptl[i],
// ::epos::cptl_.istptl[i]);
// CORSIKA_LOG_DEBUG("id, energy: {} {}", psec.getPID(), psec.getEnergy());
// int id = abs(static_cast<int>(psec.getPID()));
// CORSIKA_LOG_DEBUG("epos id to pdg: {}",
// ::epos::idtrafo_("nxs", "pdg", id));
auto momentum = psec.getMomentum(zAxisFrame);
auto const energy = psec.getEnergy();
momentum.rebase(originalCS); // transform back into standard lab frame
auto const pid = corsika::epos::convertFromEpos(psec.getPID());
CORSIKA_LOG_DEBUG(
"secondary fragment> id= {}"
" id= {}"
" p= {}",
pid, momentum.getComponents() / 1_GeV);
auto pnew =
......
......@@ -19,9 +19,10 @@ namespace corsika::epos {
class Interaction : public InteractionProcess<Interaction> {
std::string data_path_;
unsigned int count_ = 0;
bool epos_listing_;
public:
Interaction(const std::string& dataPath = "");
Interaction(const std::string& dataPath = "", const bool epos_printout_on = false);
~Interaction();
//! returns production and elastic cross section for hadrons in epos. Inputs are:
......
......@@ -44,6 +44,7 @@ namespace epos {
void ainit_();
void aepos_(int&);
void afinal_();
void alistf_(char[7]);
double lhcparameters_();
void hdecin_(bool&);
void hnbspd_(int&);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment