diff --git a/Processes/CONEXSourceCut/CONEXSourceCut.h b/Processes/CONEXSourceCut/CONEXSourceCut.h index c15f22fd4dc00230b138558c83c6b04bece12972..9ea6e3d68c0038c00fe2a5d879a2fc9e49b8015f 100644 --- a/Processes/CONEXSourceCut/CONEXSourceCut.h +++ b/Processes/CONEXSourceCut/CONEXSourceCut.h @@ -67,4 +67,3 @@ namespace corsika::process { } // namespace conex_source_cut } // namespace corsika::process -#endif diff --git a/Processes/CONEXSourceCut/testCONEXSourceCut.cc b/Processes/CONEXSourceCut/testCONEXSourceCut.cc index 3657aea840b9d587847e6e1156c56036e0016576..058714e9556c2c02b66c7a576de7601194743f46 100644 --- a/Processes/CONEXSourceCut/testCONEXSourceCut.cc +++ b/Processes/CONEXSourceCut/testCONEXSourceCut.cc @@ -51,23 +51,10 @@ TEST_CASE("CONEXSourceCut") { builder.assemble(env); - const HEPEnergyType mass = particles::GetMass(particles::Code::Proton); const HEPEnergyType E0 = 1_PeV; double thetaDeg = 60.; auto const thetaRad = thetaDeg / 180. * M_PI; - auto elab2plab = [](HEPEnergyType Elab, HEPMassType m) { - return sqrt((Elab - m) * (Elab + m)); - }; - - HEPMomentumType P0 = elab2plab(E0, mass); - - auto momentumComponents = [](double thetaRad, HEPMomentumType ptot) { - return std::make_tuple(ptot * sin(thetaRad), 0_eV, -ptot * cos(thetaRad)); - }; - auto const [px, py, pz] = momentumComponents(thetaRad, P0); - auto plab = corsika::stack::MomentumVector(rootCS, {px, py, pz}); - auto const observationHeight = 1.4_km + conex::earthRadius; auto const injectionHeight = 112.75_km + conex::earthRadius; auto const t = diff --git a/Processes/InteractionCounter/testInteractionCounter.cc b/Processes/InteractionCounter/testInteractionCounter.cc index f81c79ddde33984ce57ca0702e05f7d7bcfba74e..24518416aece74d2547b46d31ba6bf45e54f6b4d 100644 --- a/Processes/InteractionCounter/testInteractionCounter.cc +++ b/Processes/InteractionCounter/testInteractionCounter.cc @@ -119,6 +119,8 @@ TEST_CASE("InteractionCounter") { } auto [env, csPtr, nodePtr] = setupEnvironment(particles::Code::Oxygen); + [[maybe_unused]] auto& env_dummy = env; + SECTION("DoInteraction nucleus") { unsigned short constexpr A = 14, Z = 7; auto [stackPtr, secViewPtr] = setupStack(A, Z, 105_TeV, nodePtr, *csPtr); diff --git a/Processes/Sibyll/Interaction.cc b/Processes/Sibyll/Interaction.cc index 9aa527c51ff04f0b511aae1050c965d52ee79fa4..7332a2b0da8839f0d9989b1f854d37f9c7532866 100644 --- a/Processes/Sibyll/Interaction.cc +++ b/Processes/Sibyll/Interaction.cc @@ -315,8 +315,6 @@ namespace corsika::process::sibyll { auto const pCoM = Vector<hepmomentum_d>(csPrime, tmp); HEPEnergyType const eCoM = psib.GetEnergy(); auto const Plab = boost.fromCoM(FourVector(eCoM, pCoM)); - auto const p3lab = Plab.GetSpaceLikeComponents(); - assert(p3lab.GetCoordinateSystem() == originalCS); // just to be sure! auto const pid = process::sibyll::ConvertFromSibyll(psib.GetPID()); @@ -324,8 +322,8 @@ namespace corsika::process::sibyll { auto pnew = vP.AddSecondary( tuple<particles::Code, units::si::HEPEnergyType, stack::MomentumVector, geometry::Point, units::si::TimeType>{ - process::sibyll::ConvertFromSibyll(psib.GetPID()), - Plab.GetTimeLikeComponent(), p3lab, pOrig, tOrig}); + pid, Plab.GetTimeLikeComponent(), Plab.GetSpaceLikeComponents(), pOrig, + tOrig}); Plab_final += pnew.GetMomentum(); Elab_final += pnew.GetEnergy();