CORSIKA  @c8_version@
The framework to simulate particle cascades for astroparticle physics
TabulatedFlatAtmospherePropagator.hpp
1 /*
2  * (c) Copyright 2023 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 #pragma once
9 
10 #include <corsika/media/Environment.hpp>
11 #include <corsika/framework/geometry/Point.hpp>
12 #include <corsika/framework/geometry/Vector.hpp>
15 #include <corsika/modules/radio/propagators/RadioPropagator.hpp>
16 
17 namespace corsika {
18 
27  template <typename TEnvironment>
29  : public RadioPropagator<TabulatedFlatAtmospherePropagator<TEnvironment>,
30  TEnvironment> {
31 
32  using Base =
34  using SignalPathCollection = typename Base::SignalPathCollection;
35 
36  public:
41  TabulatedFlatAtmospherePropagator(TEnvironment const& env, Point const& upperLimit,
42  Point const& lowerLimit, LengthType const step);
43 
50  template <typename Particle>
51  SignalPathCollection propagate(Particle const& particle, Point const& source,
52  Point const& destination);
53 
54  private:
55  Point const upperLimit_;
56  Point const lowerLimit_;
57  LengthType const step_;
58  InverseLengthType const
59  inverseStep_;
60  LengthType const maxHeight_;
61  LengthType const minHeight_;
62  std::vector<double> refractivityTable_;
64  std::vector<LengthType>
65  heightTable_;
66  std::vector<double>
67  integratedRefractivityTable_;
68  double slopeRefrLower_;
69  double slopeIntRefrLower_;
71  double slopeRefrUpper_;
73  double slopeIntRefrUpper_;
75  double lastElement_;
77  std::deque<Point> points;
78  std::vector<double>
79  rindex;
80 
81  }; // End: FlatEarthPropagator
82 
83  template <typename TEnvironment>
85  make_tabulated_flat_atmosphere_radio_propagator(TEnvironment const& env,
86  Point const& upperLimit,
87  Point const& lowerLimit,
88  LengthType const step) {
89  return TabulatedFlatAtmospherePropagator<TEnvironment>(env, upperLimit, lowerLimit,
90  step);
91  }
92 
93 } // namespace corsika
94 
95 #include <corsika/detail/modules/radio/propagators/TabulatedFlatAtmospherePropagator.inl>
Import and extend the phys::units package.
SignalPathCollection propagate(Particle const &particle, Point const &source, Point const &destination)
Return the collection of paths from source to destination.
TabulatedFlatAtmospherePropagator(TEnvironment const &env, Point const &upperLimit, Point const &lowerLimit, LengthType const step)
Construct a new FlatEarthPropagator with a given environment.
`, since they are used everywhere as integral part of the framework.
Constants are defined with static units, based on the package (namespace) phys::units, imported in PhysicsUnits.hpp.
Radio propagators are used to calculate the propagation paths from particles to antennas.
This class implements a tabulated propagator that approximates the Earth&#39;s atmosphere as flat...