32 void StartHook(hipo::banklist& banks)
override;
33 bool RunHook(hipo::banklist& banks)
const override;
34 void StopHook()
override;
38 hipo::banklist::size_type m_b_particle{};
39 hipo::banklist::size_type m_b_config{};
41 std::unique_ptr<AlgorithmSequence> m_algo_seq;
45 static constexpr double kThetaMinDeg = 5.0;
46 static constexpr double kThetaMaxDeg = 70.0;
47 static constexpr double kThetaStepDeg = 5.0;
48 static constexpr int kNBins = (int)((kThetaMaxDeg - kThetaMinDeg) / kThetaStepDeg);
53 double sum_p_before = 0.0;
54 double sum_p_after = 0.0;
58 mutable std::array<BinAccum, kNBins> m_bins{};
59 mutable long long m_total_protons_in_range = 0;
60 mutable long long m_total_protons_all = 0;
63 mutable std::mutex m_mutex{};
67 static int ThetaBinIndex(
double theta_deg);
70 static double ThetaDegFromPxPyPz(
double px,
double py,
double pz);