CORSIKA  @c8_version@
The framework to simulate particle cascades for astroparticle physics
corsika Namespace Reference

`, since they are used everywhere as integral part of the framework. More...

Namespaces

 constants
 Physical and mathematical constants with units.
 
 dEdX_output
 The energy loss writer can be used to pool several energy loss processes into one output file/stream.
 
 history
 
 number_profile
 Local helper namespace to store number and names of particle number profile columns.
 
 units
 Extension of the phys::units package.
 

Classes

class  Antenna
 A common abstract interface for radio antennas. More...
 
class  AntennaCollection
 The base interface for radio detectors. More...
 
class  BaseExponential
 This class provides the grammage/length conversion functionality for (locally) flat exponential atmospheres. More...
 
class  BaseOutput
 This is the base class for all outputs so that they can be stored in homogeneous containers. More...
 
struct  BaseProcess
 Each process in C8 must derive from BaseProcess. More...
 
class  BaseTabular
 This class provides the grammage/length conversion functionality for (locally) flat tabulated atmospheres. More...
 
class  BaseTrajectory
 A Trajectory is a description of a momvement of an object in three-dimensional space that describes the trajectory (connection between two Points in space), as well as the direction of motion at any given point. More...
 
class  BaseVector
 
class  BetheBlochPDG
 PDG2018, passage of particles through matter. More...
 
class  BoundaryCrossingProcess
 Processes acting on the particles traversion from one volume into another volume. More...
 
class  Box
 Describes a sphere in space. More...
 
class  Cascade
 The Cascade class is constructed from template arguments making it very versatile. More...
 
class  CascadeEquationsProcess
 Processes executing cascade-equations calculations. More...
 
class  ClassTimer
 Measure the runtime of a single class function. More...
 
class  ClassTimer< TRet(TClass::*)(TArgs...) const, TFuncPtr, TTimer >
 Specialisation for const member functions. More...
 
class  ClassTimer< TRet(TClass::*)(TArgs...), TFuncPtr, TTimer >
 Measure the runtime of a single class function. More...
 
class  ClassTimer< void(TClass::*)(TArgs...) const, TFuncPtr, TTimer >
 Specialisation for const member functions without return value. More...
 
class  ClassTimer< void(TClass::*)(TArgs...), TFuncPtr, TTimer >
 Specialisation for member functions without return value. More...
 
class  ClassTimerImpl
 
struct  CombinedParticleInterface
 CombinedParticleInterface can be used to combine the data of several StackData objects. More...
 
class  CombinedStackImpl
 Memory implementation of a combined data stack. More...
 
class  COMBoost
 This utility class handles Lorentz boost (in one spatial direction) between different referenence frames, using FourVector. More...
 
class  CONEXhybrid
 Access to the CONEX model. More...
 
class  Configurable
 This is the base class for all classes that have YAML representations of their configurations. More...
 
class  ConstStackIteratorInterface
 This is the iterator class for const-access to stack data. More...
 
struct  contains_stack_process
 A traits marker to identify ProcessSequence that contain a StackProcess. More...
 
class  ContinuousProcess
 Processes with continuous effects along a particle Trajectory. More...
 
class  ContinuousProcessIndex
 To index individual processes (continuous processes) inside a ProcessSequence. More...
 
class  ContinuousProcessStepLength
 To store step length in LengthType and unique index in ProcessSequence of shortest step ContinuousProcess. More...
 
class  CoordinateSystem
 A class to store the reference coordinate system for a geometric object. More...
 
class  CoREAS
 
struct  count_processes
 traits class to count any type of Process, general version. More...
 
struct  count_processes< NullModel, N, void >
 count_processes traits specialization to increase process count by one. More...
 
struct  count_processes< TProcess, N, typename std::enable_if_t< is_process_v< std::decay_t< TProcess > > &&!std::decay_t< TProcess >::is_process_sequence > >
 count_processes traits specialization to increase process count by one. More...
 
struct  count_processes< TProcess, N, typename std::enable_if_t< is_process_v< std::decay_t< TProcess > > &&std::decay_t< TProcess >::is_process_sequence > >
 count_processes traits specialization to increase process count by getNumberOfProcesses(). More...
 
struct  DecayProcess
 Process decribing the decay of particles. More...
 
class  DefaultSecondaryProducer
 Class to handle the generation of new secondaries. More...
 
struct  DeltaParticleState
 
class  DensityFunction
 
class  DummyOutputManager
 
class  DummyTestPropagator
 This class implements a dummy propagator that uses the straight-line (vector) between the particle location and the antenna as the trajectory. More...
 
class  DynamicInteractionProcess
 This class allows selecting/using different InteractionProcesses at runtime without recompiling the process sequence. More...
 
class  Empty
 
class  EMThinning
 This process implements thinning for EM splitting processes (1 -> 2). More...
 
class  EnergyLossWriter
 The EnergyLossWriter can be used to pool the dEdX energy loss of several processes/modules into one output file/stream. More...
 
class  EnergyLossWriterParquet
 The actual writer to save dEdX data to disk. More...
 
class  Environment
 Base Environment class. More...
 
class  ExponentialDistribution
 Describes a random distribution with

\[ \beta e^{-\beta X} \]

for a physical quantity of type Quantity. More...

 
class  ExponentialRefractiveIndex
 An exponential refractive index. More...
 
class  FindXmax
 Interpolates profiles around maximum. More...
 
class  FlatExponential
 flat exponential density distribution with

\[ \varrho(\vec{r}) = \varrho_0 \exp\left( \frac{1}{\lambda} (\vec{r} - \vec{p}) \cdot \vec{a} \right). \]

\( \vec{a} \) denotes the axis and should be normalized to avoid degeneracy with the scale parameter \( \lambda \), \( \vec{r} \) is the location of the evaluation, \( \vec{p} \) is the anchor point at which \( \varrho_0 \) is given. More...

 
class  FourVector
 Description of physical four-vectors. More...
 
struct  full_name
 tag class for get_name() More...
 
class  FunctionTimer
 Wraps and measures the runtime of a single function type object. More...
 
class  GeomagneticModel
 A magnetic field calculated with the WMM or IGRF model. More...
 
class  GladstoneDaleRefractiveIndex
 A tabulated refractive index. More...
 
class  HadronicElasticInteraction
 A simple model for elastic hadronic interactions based on the formulas in Gaisser, Engel, Resconi, Cosmic Rays and Particle Physics (Cambridge Univ. More...
 
struct  has_method_doBoundaryCrossing
 traits test for BoundaryCrossingProcess::doBoundaryCrossing method More...
 
struct  has_method_doCascadeEquations
 traits test for CascadeEquationsProcess::doCascadeEquations method. More...
 
struct  has_method_doContinuous
 traits test for ContinuousProcess::doContinuous method More...
 
struct  has_method_doDecay
 traits test for DecayProcess::doDecay method More...
 
struct  has_method_doInteract
 traits test for InteractionProcess::doInteraction method. More...
 
struct  has_method_doSecondaries
 traits test for SecondariesProcess::doSecondaries method. More...
 
struct  has_method_doStack
 traits test for StackProcess::doStack method More...
 
struct  has_method_getCrossSection
 traits test for InteractionProcess::getCrossSection method. More...
 
struct  has_method_getCrossSectionTemplate
 traits test for TEMPLATED InteractionProcess::getCrossSection method (PROPOSAL). More...
 
struct  has_method_getLifetime
 traits test for DecayProcess::getLifetime method More...
 
struct  has_method_getMaxStepLength
 traits test for ContinuousProcess::getMaxStepLength method More...
 
class  Helix
 
class  HomogeneousMedium
 a homogeneous medium More...
 
class  IEmpty
 Intended for usage as default template argument for environments with no properties. More...
 
class  IMagneticFieldModel
 An interface for magnetic field models. More...
 
class  IMediumModel
 
class  IMediumPropertyModel
 An interface for type of media, needed e.g. More...
 
class  InhomogeneousMedium
 A general inhomogeneous medium. More...
 
class  InteractionCounter
 Wrapper around an InteractionProcess that fills histograms of the number of calls to doInteraction() binned in projectile energy (both in lab and center-of-mass frame) and species. More...
 
class  InteractionHistogram
 Class that creates and stores histograms of collisions \(dN/dE_{lab}\), \(dN/d\sqrt{s}\) which is used by class InteractionCounter. More...
 
class  InteractionLengthModifier
 
class  InteractionProcess
 Process describing the interaction of particles. More...
 
class  Intersect
 This is a CRTP class to provide a generic volume-tree intersection for the purpose of tracking. More...
 
class  Intersections
 Container to store and return a list of intersections of a trajectory with a geometric volume objects in space. More...
 
class  IRefractiveIndexModel
 An interface for refractive index models. More...
 
struct  is_boundary_process
 A traits marker to identify BoundaryProcess. More...
 
struct  is_boundary_process< TProcess, std::enable_if_t< std::is_base_of_v< BoundaryCrossingProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag BoundaryProcess objects. More...
 
struct  is_cascade_equations_process
 A traits marker to identify CascadeEquationsProcess. More...
 
struct  is_cascade_equations_process< TProcess, std::enable_if_t< std::is_base_of_v< CascadeEquationsProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag CascadeEquationsProcess objects. More...
 
struct  is_continuous_process
 A traits marker to identify ContinuousProcess. More...
 
struct  is_continuous_process< TProcess, std::enable_if_t< std::is_base_of_v< ContinuousProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag ContinuousProcess objects. More...
 
struct  is_decay_process
 A traits marker to identify DecayProcess. More...
 
struct  is_decay_process< TProcess, std::enable_if_t< std::is_base_of_v< DecayProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag DecayProcess objects. More...
 
struct  is_interaction_process
 A traits marker to identify InteractionProcess. More...
 
struct  is_interaction_process< TProcess, std::enable_if_t< std::is_base_of_v< InteractionProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag InteractionProcess objects. More...
 
struct  is_process
 A traits marker to identify BaseProcess, thus any type of process. More...
 
struct  is_process< TNull, std::enable_if_t< std::is_base_of_v< NullModel, typename std::decay_t< TNull > > > >
 is_process traits specialization to indicate compatibility with BaseProcess. More...
 
struct  is_process< TProcess, std::enable_if_t< std::is_base_of_v< BaseProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 is_process traits specialization to indicate inheritance from BaseProcess. More...
 
struct  is_secondaries_process
 A traits marker to identify SecondariesProcess. More...
 
struct  is_secondaries_process< TProcess, std::enable_if_t< std::is_base_of_v< SecondariesProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag SecondariesProcess objects. More...
 
struct  is_stack_process
 A traits marker to identify StackProcess. More...
 
struct  is_stack_process< TProcess, std::enable_if_t< std::is_base_of_v< StackProcess< typename std::decay_t< TProcess > >, typename std::decay_t< TProcess > > > >
 ProcessTraits specialization to flag StackProcess objects. More...
 
class  IVolume
 
class  LayeredSphericalAtmosphereBuilder
 Helper class to setup concentric spheres of layered atmosphere with spcified density profiles (exponential, linear, ...). More...
 
class  LeapFrogTrajectory
 The LeapFrogTrajectory stores information on one leap-frog step. More...
 
class  Line
 A Line describes a movement in three dimensional space. More...
 
class  LinearApproximationIntegrator
 Helper class to integrate 1D density functions. More...
 
class  LongitudinalProfile
 
class  LongitudinalProfileWriterParquet
 The actual writer to save longitudinal profile data to disk. More...
 
class  LongitudinalWriter
 The LongitudinalWriter can be used to pool the particle counts of several longitudinal profile processes into one output file/stream. More...
 
struct  make_layered_spherical_atmosphere_builder
 make_layered_spherical_atmosphere_builder. More...
 
struct  MediumData
 Enum for all known Media types. More...
 
class  MediumPropertyModel
 A model for the energy loss property of a medium. More...
 
struct  NameModel
 
class  NoOutput
 This is the base class for all outputs so that they can be stored in homogeneous containers. More...
 
class  NuclearComposition
 Describes the composition of matter Allowes and handles the creation of custom matter compositions. More...
 
class  NullModel
 Process that does nothing. More...
 
class  NumericalIntegratingPropagator
 This class implements a basic propagator that uses the straight-line (vector) between the particle location and the antenna as the trajectory. More...
 
class  ObservationPlane
 The ObservationPlane writes PDG codes, energies, and distances of particles to the central point of the plane into its output file. More...
 
class  ObservationVolume
 The ObservationVolume writes PDG codes, kinetic energy, position, and direction of particles in the observation frame into its output file. More...
 
class  ObservationVolumeWriterParquet
 
class  OnShellCheck
 
class  OutputManager
 
class  ParquetStreamer
 This class automates the construction of simple tabular Parquet files using the parquet::StreamWriter. More...
 
class  ParticleBase
 The base class to define the readout of particle properties from a particle stack. More...
 
class  ParticleCut
 ParticleCut process to kill particles. More...
 
class  ParticleInterface
 Example of a particle object on the stack. More...
 
class  ParticleWriterParquet
 
class  Path
 This class represents a (potentially) curved path between two points using N >= 1 straight-line segments. More...
 
class  Plane
 
class  Point
 
class  ProcessSequence
 Definition of a static process list/sequence. More...
 
class  QuantityVector
 
class  RadioProcess
 The base interface for radio emission processes. More...
 
class  RadioPropagator
 Radio propagators are used to calculate the propagation paths from particles to antennas. More...
 
class  RNGManager
 
class  SecondariesProcess
 Processes acting on the secondaries produced by other processes. More...
 
class  SecondaryView
 SecondaryView can only be constructed by giving a valid Projectile particle, following calls to addSecondary will populate the original Stack, but will be directly accessible via the SecondaryView, e.g.StackViewPr. More...
 
class  ShowerAxis
 The environment::ShowerAxis is created from a Point and a Vector and inside an Environment. More...
 
struct  SignalPath
 Store the photon signal path between two points. More...
 
class  Singleton
 Curiously Recurring Template Pattern (CRTP) for Meyers singleton. More...
 
class  SlidingPlanarExponential
 The SlidingPlanarExponential models mass density as:

\[ \varrho(r) = \varrho_0 \exp\left( \frac{|p_0 - r|}{\lambda} \right). \]

For grammage/length conversion, the density distribution is approximated as locally flat at the starting point \( r_0 \) of the trajectory with the axis pointing from \( p_0 \) to \( r_0 \). More...

 
class  SlidingPlanarTabular
 The SlidingPlanarTabular models mass density as

\[ \varrho(r) = \varrho_0 \rho\left( |p_0 - r| \right). \]

For grammage/length conversion, the density distribution is approximated as locally flat at the starting point \( r_0 \) of the trajectory with the axis pointing rom \( p_0 \) to \( r_0 \) defining the local height. More...

 
class  Sphere
 Describes a sphere in space. More...
 
class  Stack
 The Stack class provides (and connects) the main particle data storage machinery. More...
 
class  StackInspector
 StackProcess that will act each \(n_{step}\) steps to perform diagnostics on the full stack. More...
 
class  StackIteratorInterface
 The StackIteratorInterface is the main interface to iterator over particles on a stack. More...
 
class  StackProcess
 Process to act on the entire particle stack. More...
 
class  Step
 
class  StraightTrajectory
 This implements a straight trajectory between two points. More...
 
class  SubWriter
 
class  SwitchProcessSequence
 Class to switch between two process branches. More...
 
class  TabulatedFlatAtmospherePropagator
 This class implements a tabulated propagator that approximates the Earth's atmosphere as flat. More...
 
class  TimeCut
 Simple TimeCut process, removes particles older than specified cut time. More...
 
class  TimeDomainAntenna
 An implementation of a time-domain antenna that has a customized start time, sampling rate, and waveform duration. More...
 
class  Timer
 
class  TrackWriter
 To write 3D track data to disk. More...
 
class  TrackWriterParquet
 
class  UniformMagneticField
 A uniform (constant) magnetic field. More...
 
class  UniformRealDistribution
 
class  UniformRefractiveIndex
 A uniform refractive index. More...
 
struct  Universe
 
class  Vector
 
class  VectorStackImpl
 Memory implementation of the most simple particle stack object. More...
 
class  VolumeTreeNode
 
class  WeightProviderIterator
 Double Iterator Iterator that allowes the iteration of two individual lists at the same time. More...
 
class  WriterOff
 Generic class to switch off any output. More...
 
class  YAMLStreamer
 This class automates the construction of simple tabular YAML files using the YAML::StreamWriter. More...
 
class  ZHS
 A concrete implementation of the ZHS algorithm. More...
 

Typedefs

using MomentumVector = Vector< hepmomentum_d >
 A 3D vector defined in a specific coordinate system with units HEPMomentumType.
 
using DirectionVector = Vector< dimensionless_d >
 A 3D vector defined in a specific coordinate system with no units. More...
 
using VelocityVector = Vector< SpeedType::dimension_type >
 A 3D vector defined in a specific coordinate system with units "velocity_t".
 
using LengthVector = Vector< length_d >
 A 3D vector defined in a specific coordinate system with units "length_t".
 
typedef Vector< ElectricFieldType::dimension_type > ElectricFieldVector
 A 3D vector defined in a specific coordinate system with units ElectricFieldType.
 
typedef Vector< VectorPotentialType::dimension_type > VectorPotential
 A 3D vector defined in a specific coordinate system with units VectorPotentialType.
 
typedef Eigen::Transform< double, 3, Eigen::Affine > EigenTransform
 
typedef Eigen::Translation< double, 3 > EigenTranslation
 
using CoordinateSystemPtr = std::shared_ptr< CoordinateSystem const >
 To refer to CoordinateSystems, only the CoordinateSystemPtr must be used.
 
typedef FourVector< HEPEnergyType, MomentumVectorFourMomentum
 
typedef Vector< magnetic_flux_density_dMagneticFieldVector
 
typedef RNGManager ::prng_type default_prng_type
 
template<typename Stack1Impl , typename Stack2Impl , template< typename > typename _PI, template< typename T1, template< class > class T2 > class _MSecondaryProducer = DefaultSecondaryProducer>
using CombinedStack = Stack< CombinedStackImpl< Stack1Impl, Stack2Impl >, _PI, _MSecondaryProducer >
 Helper template alias CombinedStack to construct new combined stack from two stack data objects and a particle readout interface. More...
 
typedef Stack< VectorStackImpl, ParticleInterfaceVectorStack
 

Enumerations

enum  AtmosphereId : uint8_t {
  LinsleyUSStd = 0, MiddleEuropeJan, MiddleEuropeFeb, MiddleEuropeMay,
  MiddleEuropeJun, MiddleEuropeAug, MiddleEuropeOct, MiddleEuropeDec,
  SouthPoleMar, SouthPoleJul, SouthPoleOct, SouthPoleDec,
  SouthPoleJan, SouthPoleAug, MalargueWinterI, MalargueWinterII,
  MalargueSpring, MalargueSummer, MalargueAutumn, USStdBK,
  LastAtmosphere
}
 Atmosphere Ids following the CORSIKA 7 5-layered atmosphere models. More...
 
enum  MediumType {
  Unknown, Element, RadioactiveElement, InorganicCompound,
  OrganicCompound, Polymer, Mixture, BiologicalDosimetry
}
 General type of medium.
 
enum  StateOfMatter {
  Unknown, Solid, Liquid, Gas,
  DiatomicGas
}
 Physical state of medium.
 

Functions

std::false_type is_timer_impl (...)
 
template<typename T , typename U >
std::true_type is_timer_impl (Timer< T, U > const volatile &)
 
auto constexpr calculate_mass_sqr (HEPEnergyType const E, HEPMomentumType const p)
 

\[m^2=E_{tot}^2-p^2\]

More...
 
HEPEnergyType constexpr calculate_mass (HEPEnergyType const E, HEPMomentumType const p)
 

\[m=sqrt(E_{tot}^2-p^2) \]

More...
 
auto constexpr calculate_momentum_sqr (HEPEnergyType const E, HEPMassType const m)
 

\[p^2=E_{tot}^2-m^2\]

More...
 
HEPEnergyType constexpr calculate_momentum (HEPEnergyType const E, HEPMassType const m)
 

\[p=sqrt(E_{tot}^2-m^2) \]

More...
 
auto constexpr calculate_total_energy_sqr (HEPMomentumType const p, HEPMassType const m)
 

\[E_{tot}^2=p^2+m^2\]

More...
 
HEPEnergyType constexpr calculate_total_energy (HEPMomentumType const p, HEPMassType const m)
 

\[E_{tot}=sqrt(p^2+m^2)\]

More...
 
HEPEnergyType constexpr calculate_kinetic_energy (HEPMomentumType const p, HEPMassType const m)
 

\[E_{kin}=sqrt(p^2+m^2) - m \]

More...
 
HEPEnergyType constexpr calculate_lab_energy (detail::HEPEnergyTypeSqr sqrtS_sqr, HEPMassType const m_proj, HEPMassType const m_targ)
 

\[E_{lab}=(\sqrt{s}^2 - m_{proj}^2 - m_{targ}^2) / (2 m_{targ}) \]

More...
 
HEPEnergyType constexpr calculate_com_energy (HEPEnergyType Elab, HEPMassType const m_proj, HEPMassType const m_targ)
 

\[E_{com}=sqrt{2 * m_{proj} * m_{targ} * E_{lab} + m_{proj}^2 + m_{targ}^2} \]

More...
 
std::shared_ptr< spdlog::logger > create_logger (std::string const &name, bool const defaultlog=false)
 Create a new C8-style logger. More...
 
std::shared_ptr< spdlog::logger > get_logger (std::string const &name, bool const defaultlog=false)
 Get a smart pointer to an existing logger. More...
 
int16_t constexpr get_charge_number (Code const)
 electric charge in units of e
 
ElectricChargeType constexpr get_charge (Code const)
 electric charge
 
HEPMassType constexpr get_mass (Code const)
 mass
 
HEPEnergyType get_kinetic_energy_propagation_threshold (Code const)
 Get the kinetic energy propagation threshold. More...
 
void set_kinetic_energy_propagation_threshold (Code const, HEPEnergyType const)
 Set the kinetic energy propagation threshold object.
 
HEPEnergyType get_energy_production_threshold (Code const)
 Get the particle production energy threshold. More...
 
void set_energy_production_threshold (Code const, HEPEnergyType const)
 Set the particle production energy threshold in total energies.
 
PDGCode constexpr get_PDG (Code const)
 Particle code according to PDG, "Monte Carlo Particle Numbering Scheme".
 
PDGCode constexpr get_PDG (unsigned int const A, unsigned int const Z)
 
std::string_view constexpr get_name (Code const)
 name of the particle as string
 
std::string get_name (Code, full_name)
 get name of particle, including (A,Z) for nuclei
 
TimeType constexpr get_lifetime (Code const)
 lifetime
 
bool constexpr is_hadron (Code const)
 true if particle is hadron
 
bool constexpr is_em (Code const)
 true if particle is electron, positron or photon
 
bool constexpr is_muon (Code const)
 true if particle is mu+ or mu-
 
bool constexpr is_neutrino (Code const)
 true if particle is (anti-) neutrino
 
bool constexpr is_charged (Code const)
 true if particle is charged
 
Code constexpr get_nucleus_code (size_t const A, size_t const Z)
 Creates the Code for a nucleus of type 10LZZZAAAI. More...
 
bool constexpr is_nucleus (Code const)
 Checks if Code corresponds to a nucleus. More...
 
size_t constexpr get_nucleus_A (Code const)
 Get the mass number A for nucleus. More...
 
size_t constexpr get_nucleus_Z (Code const)
 Get the charge number Z for nucleus. More...
 
HEPMassType constexpr get_nucleus_mass (Code const code)
 Calculates the mass of nucleus. More...
 
HEPMassType constexpr get_nucleus_mass (unsigned int const A, unsigned int const Z)
 Calculates the mass of nucleus. More...
 
std::string get_nucleus_name (Code const code)
 Get the nucleus name. More...
 
Code convert_from_PDG (PDGCode const)
 convert PDG code to CORSIKA 8 internal code. More...
 
std::initializer_list< Code > constexpr get_all_particles ()
 Returns list of all non-nuclei particles. More...
 
std::ostream & operator<< (std::ostream &, corsika::Code)
 Code output operator. More...
 
CoordinateSystemPtr const & get_root_CoordinateSystem ()
 this is the only way to create ONE unique root CS More...
 
CoordinateSystemPtr make_translation (CoordinateSystemPtr const &cs, QuantityVector< length_d > const &vector)
 Creates new CoordinateSystemPtr by translation along vector.
 
template<typename TDim >
CoordinateSystemPtr make_rotationToZ (CoordinateSystemPtr const &cs, Vector< TDim > const &vVec)
 creates a new CoordinateSystem in which vVec points in direction of the new z-axis, vVec
 
template<typename TDim >
CoordinateSystemPtr make_rotation (CoordinateSystemPtr const &cs, QuantityVector< TDim > const &axis, double const angle)
 creates a new CoordinateSystem, rotated around axis by angle.
 
template<typename TDim >
CoordinateSystemPtr make_translationAndRotation (CoordinateSystemPtr const &cs, QuantityVector< length_d > const &translation, QuantityVector< TDim > const &axis, double const angle)
 creates a new CoordinateSystem, translated by translation and rotated around axis by angle.
 
EigenTransform get_transformation (CoordinateSystem const &c1, CoordinateSystem const &c2)
 Transformation matrix from one reference system to another. More...
 
template<typename TTimeType , typename TSpaceVecType >
std::ostream & operator<< (std::ostream &os, corsika::FourVector< TTimeType, TSpaceVecType > const &qv)
 streaming operator
 
LengthType distance (Point const &p1, Point const &p2)
 
template<typename TDimension >
std::ostream & operator<< (std::ostream &os, corsika::QuantityVector< TDimension > const &qv)
 streaming operator
 
template<typename TDimension , typename UDimension >
Vector< phys::units::detail::product_d< TDimension, UDimension > > operator* (quantity< UDimension > const n, Vector< TDimension > const &vec)
 Free operator to allow commutative multiplications of quantities and Vector. More...
 
template<typename TDimension >
Vector< TDimension > operator* (double const n, Vector< TDimension > const &vec)
 Free operator to allow commutative multiplications of normal double with Vector. More...
 
template<typename... TProcesses, typename TProcess1 >
ProcessSequence< TProcess1, decltype(make_sequence(std::declval< TProcesses >)...))> make_sequence (TProcess1 &&vA, TProcesses &&... vBs)
 
template<typename TProcess1 , typename TProcess2 >
ProcessSequence< TProcess1, TProcess2 > make_sequence (TProcess1 &&vA, TProcess2 &&vB)
 
template<typename TProcess >
ProcessSequence< TProcess, NullModelmake_sequence (TProcess &&vA)
 
std::vector< double > solve_linear_real (double a, double b)
 
std::vector< std::complex< double > > solve_linear (double a, double b)
 
std::vector< std::complex< double > > solve_quadratic (long double a, long double b, long double c, double const epsilon=1e-12)
 
std::vector< double > solve_quadratic_real (long double a, long double b, long double c, double const epsilon=1e-12)
 
template<class Axes , class Storage >
void save_hist (boost::histogram::histogram< Axes, Storage > const &h, std::string const &filename, bool overwrite=true)
 
template<typename TEnvironmentInterface , template< typename > typename TExtraEnv = detail::NoExtraModel, typename TEnvironment , typename... TArgs>
void create_5layer_atmosphere (TEnvironment &env, AtmosphereId const atmId, Point const &center, TArgs... args)
 Function to create a CORSIKA 7 5-layer atmosphere. More...
 
template<typename TEnvironment >
DummyTestPropagator< TEnvironment > make_dummy_test_radio_propagator (TEnvironment const &env)
 
template<typename TEnvironment >
NumericalIntegratingPropagator< TEnvironment > make_numerical_integrating_radio_propagator (TEnvironment const &env, LengthType const stepsize)
 
template<typename TEnvironment >
TabulatedFlatAtmospherePropagator< TEnvironment > make_tabulated_flat_atmosphere_radio_propagator (TEnvironment const &env, Point const &upperLimit, Point const &lowerLimit, LengthType const step)
 
template<typename TCondition , typename TSequence , typename USequence , typename = std::enable_if_t<is_process_v<typename std::decay_t<TSequence>> && is_process_v<typename std::decay_t<USequence>>>>
SwitchProcessSequence< TCondition, TSequence, USequence > make_select (TCondition &&selector, TSequence &&vA, USequence &&vB)
 the functin make_select(select, proc1, proc1) assembles many BaseProcesses, and ProcessSequences into a SwitchProcessSequence, all combinatorics are allowed. More...
 
boost::filesystem::path corsika_data (boost::filesystem::path const &filename)
 
std::vector< double > solve_cubic_depressed_disciminant_real (long double p, long double q, long double const disc, double const epsilon=1e-12)
 Solve depressed cubic: x^3 + p x + q = 0.
 
std::vector< double > solve_cubic_depressed_real (long double p, long double q, double const epsilon=1e-12)
 
std::vector< double > solve_cubic_real_analytic (long double a, long double b, long double c, long double d, double const epsilon=1e-12)
 Solve a x^3 + b x^2 + c x + d = 0. More...
 
template<typename T >
cubic_function (T x, T a, T b, T c, T d)
 Cubic function. More...
 
template<typename T >
cubic_function_dfdx (T x, T a, T b, T c)
 
template<typename T >
cubic_function_d2fd2x (T x, T a, T b)
 
std::vector< double > solve_cubic_real (long double a, long double b, long double c, long double d, double const epsilon=1e-12)
 Iterative approach to solve: a x^3 + b x^2 + c x + d = 0. More...
 
std::vector< double > solve_quartic_real (long double a, long double b, long double c, long double d, long double e, double const epsilon=1e-12)
 solve quartic equation a*x^4 + b*x^3 + c*x^2 + d*x + e
 
constexpr MediumData const & mediumData (Medium const m)
 

Variables

template<class TProcess , typename TReturn , typename TParticle >
bool constexpr has_method_doBoundaryCrossing_v
 
template<class TProcess , typename TReturn , typename... TArg>
bool constexpr has_method_doCascadeEquations_v
 value traits type. More...
 
template<class TProcess , typename TReturn , typename TArg1 , typename TArg2 >
bool constexpr has_method_doContinuous_v
 
template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr has_method_getMaxStepLength_v
 value traits type More...
 
template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr has_method_doDecay_v
 
template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr has_method_getLifetime_v
 value traits type More...
 
template<class TProcess , typename TReturn , typename TTemplate , typename... TArgs>
bool constexpr has_method_doInteract_v
 value traits type More...
 
template<class TProcess , typename TReturn , typename TTemplate , typename... TArgs>
bool constexpr has_method_getCrossSectionTemplate_v
 value traits type shortcut More...
 
template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr has_method_getCrossSection_v
 value traits type shortcut More...
 
template<class TProcess , typename TReturn , typename... TArg>
bool constexpr has_method_doSecondaries_v
 
template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr has_method_doStack_v
 
template<typename T >
constexpr bool is_timer_v
 
const std::string minimal_pattern {"[%n:%^%-8l%$] %v"}
 
const std::string default_pattern {"[%n:%^%-8l%$(%s:%#)] %v"}
 
const std::string source_pattern {"[%n:%^%-8l%$(%s:%!:%#)] %v"}
 
template<typename TProcess >
bool constexpr is_process_v = is_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_continuous_process_v = is_continuous_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_decay_process_v = is_decay_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_stack_process_v = is_stack_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_cascade_equations_process_v
 
template<typename TProcess >
bool constexpr is_secondaries_process_v = is_secondaries_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_boundary_process_v = is_boundary_process<TProcess>::value
 
template<typename TProcess >
bool constexpr is_interaction_process_v = is_interaction_process<TProcess>::value
 
template<typename TClass >
bool constexpr contains_stack_process_v = contains_stack_process<TClass>::value
 
enum  ProcessReturn : int { Ok = (1 << 0), ParticleAbsorbed = (1 << 2), Interacted = (1 << 3), Decayed = (1 << 4) }
 since in a process sequence many status updates can accumulate for a single particle, this enum should define only bit-flags that can be accumulated easily with "|="
 
ProcessReturn operator| (ProcessReturn a, ProcessReturn b)
 
ProcessReturnoperator|= (ProcessReturn &a, const ProcessReturn b)
 
ProcessReturn operator & (const ProcessReturn a, const ProcessReturn b)
 
bool operator== (const ProcessReturn a, const ProcessReturn b)
 
bool isOk (const ProcessReturn a)
 
bool isAbsorbed (const ProcessReturn a)
 
bool isDecayed (const ProcessReturn a)
 
bool isInteracted (const ProcessReturn a)
 

Detailed Description

`, since they are used everywhere as integral part of the framework.

With this class modules can register streams of random numbers.

Typedef Documentation

◆ CombinedStack

template<typename Stack1Impl , typename Stack2Impl , template< typename > typename _PI, template< typename T1, template< class > class T2 > class _MSecondaryProducer = DefaultSecondaryProducer>
using corsika::CombinedStack = typedef Stack<CombinedStackImpl<Stack1Impl, Stack2Impl>, _PI, _MSecondaryProducer>

Helper template alias CombinedStack to construct new combined stack from two stack data objects and a particle readout interface.

Note that the Stack2Impl provides only /additional/ data to Stack1Impl. This is important (see above) since tuple data for initialization are forwarded to Stack1Impl (first).

Definition at line 135 of file CombinedStack.hpp.

◆ DirectionVector

A 3D vector defined in a specific coordinate system with no units.

But, note, this is not automatically normaliyed! It is not a "NormalVector".

Definition at line 32 of file PhysicalGeometry.hpp.

Enumeration Type Documentation

◆ AtmosphereId

enum corsika::AtmosphereId : uint8_t
strong

Atmosphere Ids following the CORSIKA 7 5-layered atmosphere models.

Each model corresponds to a standard 5-layered atmosphere model. 4 Layers are exponential, the outer layer is with constant density.

All atmospheres are valid for heights (above Earth sea level) up to 112.8 km.

Definition at line 29 of file CORSIKA7Atmospheres.hpp.

Function Documentation

◆ calculate_com_energy()

HEPEnergyType constexpr corsika::calculate_com_energy ( HEPEnergyType  Elab,
HEPMassType const  m_proj,
HEPMassType const  m_targ 
)

\[E_{com}=sqrt{2 * m_{proj} * m_{targ} * E_{lab} + m_{proj}^2 + m_{targ}^2} \]

Parameters
Elab. energy.
mparticle mass.
Returns
HEPEnergyType

Definition at line 127 of file EnergyMomentumOperations.hpp.

◆ calculate_kinetic_energy()

HEPEnergyType constexpr corsika::calculate_kinetic_energy ( HEPMomentumType const  p,
HEPMassType const  m 
)

\[E_{kin}=sqrt(p^2+m^2) - m \]

Parameters
pmomentum.
mparticle mass.
Returns
HEPEnergyType

Definition at line 102 of file EnergyMomentumOperations.hpp.

◆ calculate_lab_energy()

HEPEnergyType constexpr corsika::calculate_lab_energy ( detail::HEPEnergyTypeSqr  sqrtS_sqr,
HEPMassType const  m_proj,
HEPMassType const  m_targ 
)

\[E_{lab}=(\sqrt{s}^2 - m_{proj}^2 - m_{targ}^2) / (2 m_{targ}) \]

Parameters
pmomentum.
mparticle mass.
Returns
HEPEnergyType

Definition at line 114 of file EnergyMomentumOperations.hpp.

◆ calculate_mass()

HEPEnergyType constexpr corsika::calculate_mass ( HEPEnergyType const  E,
HEPMomentumType const  p 
)

\[m=sqrt(E_{tot}^2-p^2) \]

Parameters
Etotal energy.
pparticle momentum.
Returns
HEPEnergyType

Definition at line 45 of file EnergyMomentumOperations.hpp.

◆ calculate_mass_sqr()

auto constexpr corsika::calculate_mass_sqr ( HEPEnergyType const  E,
HEPMomentumType const  p 
)

\[m^2=E_{tot}^2-p^2\]

Parameters
Etotal energy.
pparticle momentum.
Returns
HEPEnergyType-squared

Definition at line 34 of file EnergyMomentumOperations.hpp.

◆ calculate_momentum()

HEPEnergyType constexpr corsika::calculate_momentum ( HEPEnergyType const  E,
HEPMassType const  m 
)

\[p=sqrt(E_{tot}^2-m^2) \]

Parameters
Etotal energy.
mparticle mass.
Returns
HEPEnergyType

Definition at line 67 of file EnergyMomentumOperations.hpp.

◆ calculate_momentum_sqr()

auto constexpr corsika::calculate_momentum_sqr ( HEPEnergyType const  E,
HEPMassType const  m 
)

\[p^2=E_{tot}^2-m^2\]

Parameters
Etotal energy.
mparticle mass.
Returns
HEPEnergyType-squared

Definition at line 56 of file EnergyMomentumOperations.hpp.

◆ calculate_total_energy()

HEPEnergyType constexpr corsika::calculate_total_energy ( HEPMomentumType const  p,
HEPMassType const  m 
)

\[E_{tot}=sqrt(p^2+m^2)\]

Parameters
pmomentum.
mparticle mass.
Returns
HEPEnergyType

Definition at line 90 of file EnergyMomentumOperations.hpp.

◆ calculate_total_energy_sqr()

auto constexpr corsika::calculate_total_energy_sqr ( HEPMomentumType const  p,
HEPMassType const  m 
)

\[E_{tot}^2=p^2+m^2\]

Parameters
pmomentum.
mparticle mass.
Returns
HEPEnergyType-squared

Definition at line 78 of file EnergyMomentumOperations.hpp.

◆ create_5layer_atmosphere()

template<typename TEnvironmentInterface , template< typename > typename TExtraEnv = detail::NoExtraModel, typename TEnvironment , typename... TArgs>
void corsika::create_5layer_atmosphere ( TEnvironment &  env,
AtmosphereId const  atmId,
Point const &  center,
TArgs...  args 
)

Function to create a CORSIKA 7 5-layer atmosphere.

Template Parameters
TEnvironmentInterface
TExtraEnv
TEnvironment
TArgs
Parameters
env
atmId
center
args

◆ create_logger()

std::shared_ptr<spdlog::logger> corsika::create_logger ( std::string const &  name,
bool const  defaultlog = false 
)

Create a new C8-style logger.

Use this if you are explicitly (and can guarantee) that you are creating a logger for the first time. It is recommended that for regular usage, the get_logger function is used instead as that will also create the logger if it has not yet been created.

Calling create_logger twice to create the same logger will result in an spdlog duplicate exception.

Parameters
nameThe unique name of the logger.
defaultlogIf True, set this as the default logger.
Returns
The constructed and formatted logger.

◆ cubic_function()

template<typename T >
T corsika::cubic_function ( x,
a,
b,
c,
d 
)

Cubic function.

T must be a floating point type.

Returns
a x^3 + b x^2 + c x + d

◆ cubic_function_d2fd2x()

template<typename T >
T corsika::cubic_function_d2fd2x ( x,
a,
b 
)
Returns
6 a x + 2 b

◆ cubic_function_dfdx()

template<typename T >
T corsika::cubic_function_dfdx ( x,
a,
b,
c 
)
Returns
3 a x^2 + 2 b x + c

◆ get_logger()

std::shared_ptr<spdlog::logger> corsika::get_logger ( std::string const &  name,
bool const  defaultlog = false 
)

Get a smart pointer to an existing logger.

This should be the default method for code to obtain a logger. If the logger does not exist, it is created and returned to the caller.

This should be preferred over create_logger.

Parameters
nameThe name of the logger to get.
defaultlogIf True, make this the default logger.
Returns
The constructed and formatted logger.

◆ get_root_CoordinateSystem()

CoordinateSystemPtr const & corsika::get_root_CoordinateSystem ( )
inline

this is the only way to create ONE unique root CS

Singleton factory function to produce the root CoordinateSystem

This is the only way to get a root-coordinate system, and it is a singleton. All other CoordinateSystems must be relative to the RootCoordinateSystem

Definition at line 30 of file RootCoordinateSystem.hpp.

◆ get_transformation()

EigenTransform corsika::get_transformation ( CoordinateSystem const &  c1,
CoordinateSystem const &  c2 
)

Transformation matrix from one reference system to another.

returns the transformation matrix necessary to transform primitives with coordinates in pFrom to pTo, e.g. \( \vec{v}^{\text{(to)}} = \mathcal{M} \vec{v}^{\text{(from)}} \) ( \( \vec{v}^{(.)} \) denotes the coordinates/components of the component in the indicated CoordinateSystem).

Todo:
make this a protected member of CoordinateSystem

◆ make_select()

template<typename TCondition , typename TSequence , typename USequence , typename = std::enable_if_t<is_process_v<typename std::decay_t<TSequence>> && is_process_v<typename std::decay_t<USequence>>>>
SwitchProcessSequence<TCondition, TSequence, USequence> corsika::make_select ( TCondition &&  selector,
TSequence &&  vA,
USequence &&  vB 
)

the functin make_select(select, proc1, proc1) assembles many BaseProcesses, and ProcessSequences into a SwitchProcessSequence, all combinatorics are allowed.

Parameters
selectormust provide bool operator()(Particle const&) const
vAneeds to derive from BaseProcess or ProcessSequence
vBneeds to derive from BaseProcess or ProcessSequence

Definition at line 210 of file SwitchProcessSequence.hpp.

◆ operator*() [1/2]

template<typename TDimension , typename UDimension >
Vector<phys::units::detail::product_d<TDimension, UDimension> > corsika::operator* ( quantity< UDimension > const  n,
Vector< TDimension > const &  vec 
)

Free operator to allow commutative multiplications of quantities and Vector.

Template Parameters
TDimension
UDimension
Parameters
n
vec
Returns
auto

◆ operator*() [2/2]

template<typename TDimension >
Vector<TDimension> corsika::operator* ( double const  n,
Vector< TDimension > const &  vec 
)

Free operator to allow commutative multiplications of normal double with Vector.

Template Parameters
TDimension
UDimension
Parameters
n
vec
Returns
auto

◆ solve_cubic_real()

std::vector<double> corsika::solve_cubic_real ( long double  a,
long double  b,
long double  c,
long double  d,
double const  epsilon = 1e-12 
)

Iterative approach to solve: a x^3 + b x^2 + c x + d = 0.

This is often fastest and most precise.

◆ solve_cubic_real_analytic()

std::vector<double> corsika::solve_cubic_real_analytic ( long double  a,
long double  b,
long double  c,
long double  d,
double const  epsilon = 1e-12 
)

Solve a x^3 + b x^2 + c x + d = 0.

Analytical approach. Not very stable in all conditions.

Variable Documentation

◆ has_method_doBoundaryCrossing_v

template<class TProcess , typename TReturn , typename TParticle >
bool constexpr corsika::has_method_doBoundaryCrossing_v
Initial value:
=
has_method_doBoundaryCrossing<TProcess, TReturn, TParticle>::value

Definition at line 57 of file BoundaryCrossingProcess.hpp.

◆ has_method_doCascadeEquations_v

template<class TProcess , typename TReturn , typename... TArg>
bool constexpr corsika::has_method_doCascadeEquations_v
Initial value:
=
has_method_doCascadeEquations<TProcess, TReturn, TArg...>::value

value traits type.

Definition at line 57 of file CascadeEquationsProcess.hpp.

◆ has_method_doContinuous_v

template<class TProcess , typename TReturn , typename TArg1 , typename TArg2 >
bool constexpr corsika::has_method_doContinuous_v
Initial value:
=
has_method_doContinuous<TProcess, TReturn, TArg1, TArg2>::value

Definition at line 52 of file ContinuousProcess.hpp.

◆ has_method_doDecay_v

template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr corsika::has_method_doDecay_v
Initial value:
=
has_method_doDecay<TProcess, TReturn, TArgs...>::value

Definition at line 54 of file DecayProcess.hpp.

◆ has_method_doInteract_v

template<class TProcess , typename TReturn , typename TTemplate , typename... TArgs>
bool constexpr corsika::has_method_doInteract_v
Initial value:
=
has_method_doInteract<TProcess, TReturn, TTemplate, TArgs...>::value

value traits type

Definition at line 51 of file InteractionProcess.hpp.

◆ has_method_doSecondaries_v

template<class TProcess , typename TReturn , typename... TArg>
bool constexpr corsika::has_method_doSecondaries_v
Initial value:
=
has_method_doSecondaries<TProcess, TReturn, TArg...>::value

Definition at line 55 of file SecondariesProcess.hpp.

◆ has_method_doStack_v

template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr corsika::has_method_doStack_v
Initial value:
=
has_method_doStack<TProcess, TReturn, TArgs...>::value

Definition at line 55 of file StackProcess.hpp.

◆ has_method_getCrossSection_v

template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr corsika::has_method_getCrossSection_v
Initial value:
=
has_method_getCrossSection<TProcess, TReturn, TArgs...>::value

value traits type shortcut

Definition at line 129 of file InteractionProcess.hpp.

◆ has_method_getCrossSectionTemplate_v

template<class TProcess , typename TReturn , typename TTemplate , typename... TArgs>
bool constexpr corsika::has_method_getCrossSectionTemplate_v
Initial value:
=
has_method_getCrossSectionTemplate<TProcess, TReturn, TTemplate, TArgs...>::value

value traits type shortcut

Definition at line 90 of file InteractionProcess.hpp.

◆ has_method_getLifetime_v

template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr corsika::has_method_getLifetime_v
Initial value:
=
has_method_getLifetime<TProcess, TReturn, TArgs...>::value

value traits type

Definition at line 92 of file DecayProcess.hpp.

◆ has_method_getMaxStepLength_v

template<class TProcess , typename TReturn , typename... TArgs>
bool constexpr corsika::has_method_getMaxStepLength_v
Initial value:
=
has_method_getMaxStepLength<TProcess, TReturn, TArgs...>::value

value traits type

Definition at line 91 of file ContinuousProcess.hpp.

◆ is_cascade_equations_process_v

template<typename TProcess >
bool constexpr corsika::is_cascade_equations_process_v
Initial value:
=
is_cascade_equations_process<TProcess>::value

Definition at line 63 of file ProcessTraits.hpp.

◆ is_timer_v

template<typename T >
constexpr bool corsika::is_timer_v
Initial value:
=
std::is_same_v<decltype(is_timer_impl(std::declval<T&>())), std::true_type>

Definition at line 59 of file Timer.hpp.