IAP GITLAB

Skip to content
Snippets Groups Projects
Commit 264f6219 authored by Jean-Marco Alameddine's avatar Jean-Marco Alameddine Committed by Maximilian Reininghaus
Browse files

Update PROPOSAL to most recent version

parent 17c63346
No related branches found
No related tags found
1 merge request!421Update PROPOSAL version to 7.3.0
Pipeline #6078 passed with warnings
......@@ -4,7 +4,7 @@ catch2/2.13.8
eigen/3.3.8
boost/1.76.0
zlib/1.2.11
proposal/7.0.5
proposal/7.2.1
yaml-cpp/0.6.3
arrow/2.0.0
cli11/1.9.1
......
......@@ -68,6 +68,12 @@ namespace corsika::proposal {
auto [type, target_hash, v] = std::get<eINTERACTION>(c->second)->SampleLoss(
projectile.getEnergy() / 1_MeV, rates, distr(RNG_));
// TODO: Is this case necessary?
// In this case, the original particle should not be altered and put back on the stack
if (type == PROPOSAL::InteractionType::Undefined) {
return ProcessReturn::Ok;
}
// Read how much random numbers are required to calculate the secondaries.
// Calculate the secondaries and deploy them on the corsika stack.
auto rnd = std::vector<double>(
......@@ -86,7 +92,9 @@ namespace corsika::proposal {
auto loss = PROPOSAL::StochasticLoss(
static_cast<int>(type), v * projectile.getEnergy() / 1_MeV, point, direction,
projectile.getTime() / 1_s, 0., projectile.getEnergy() / 1_MeV);
auto target = PROPOSAL::Component::component_map->operator[](target_hash);
PROPOSAL::Component target;
if (type != PROPOSAL::InteractionType::Ioniz)
target = PROPOSAL::Component::GetComponentForHash(target_hash);
auto sec =
std::get<eSECONDARIES>(c->second)->CalculateSecondaries(loss, target, rnd);
for (auto& s : sec) {
......
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