CORSIKA8  0.0.0
The framework to simulate particle cascades for astroparticle physics
OnShellCheck.hpp
1 /*
2  * (c) Copyright 2018 CORSIKA Project, corsika-project@lists.kit.edu
3  *
4  * This software is distributed under the terms of the GNU General Public
5  * Licence version 3 (GPL Version 3). See file LICENSE for a full version of
6  * the license.
7  */
8 
9 #pragma once
10 
12 #include <corsika/framework/process/SecondariesProcess.hpp>
14 
15 namespace corsika {
16 
17  class OnShellCheck : public SecondariesProcess<OnShellCheck> {
18 
19  public:
20  OnShellCheck(const double vMassTolerance, const double vEnergyTolerance,
21  const bool vError);
22 
23  ~OnShellCheck();
24 
25  template <typename TView>
26  void doSecondaries(TView&);
27 
28  private:
29  // data members
30  double average_shift_ = 0;
31  double max_shift_ = 0;
32  double count_ = 0;
33  std::shared_ptr<spdlog::logger> logger_ = get_logger("corsika_OnShellCheck");
34  double mass_tolerance_;
35  double energy_tolerance_;
36  bool throw_error_;
37  };
38 } // namespace corsika
39 
40 #include <corsika/detail/modules/OnShellCheck.inl>
Import and extend the phys::units package.
std::shared_ptr< spdlog::logger > get_logger(std::string const &name, bool const defaultlog=false)
Get a smart pointer to an existing logger.
The cascade namespace assembles all objects needed to simulate full particles cascades.
Processes acting on the secondaries produced by other processes.
Interface to particle properties.