IAP GITLAB

Skip to content
Snippets Groups Projects
Commit bc9e9845 authored by Maximilian Reininghaus's avatar Maximilian Reininghaus :vulcan:
Browse files

Merge branch 'cs' into 'master'

SIBYLL coding style

See merge request !111
parents 6f2ab230 6501af37
No related branches found
No related tags found
1 merge request!111SIBYLL coding style
Pipeline #547 passed
...@@ -24,9 +24,8 @@ using std::vector; ...@@ -24,9 +24,8 @@ using std::vector;
using namespace corsika; using namespace corsika;
using namespace corsika::setup; using namespace corsika::setup;
using Projectile = corsika::setup::StackView::ParticleType; using SetupProjectile = corsika::setup::StackView::ParticleType;
using Particle = corsika::setup::Stack::ParticleType; using SetupParticle = corsika::setup::Stack::ParticleType;
using Track = Trajectory;
namespace corsika::process::sibyll { namespace corsika::process::sibyll {
...@@ -104,7 +103,7 @@ namespace corsika::process::sibyll { ...@@ -104,7 +103,7 @@ namespace corsika::process::sibyll {
} }
template <> template <>
units::si::TimeType Decay::GetLifetime(Particle const& vP) { units::si::TimeType Decay::GetLifetime(SetupParticle const& vP) const {
using namespace units::si; using namespace units::si;
HEPEnergyType E = vP.GetEnergy(); HEPEnergyType E = vP.GetEnergy();
...@@ -133,7 +132,7 @@ namespace corsika::process::sibyll { ...@@ -133,7 +132,7 @@ namespace corsika::process::sibyll {
} }
template <> template <>
void Decay::DoDecay(Projectile& vP) { void Decay::DoDecay(SetupProjectile& vP) {
using geometry::Point; using geometry::Point;
using namespace units::si; using namespace units::si;
......
...@@ -22,7 +22,7 @@ namespace corsika::process { ...@@ -22,7 +22,7 @@ namespace corsika::process {
namespace sibyll { namespace sibyll {
class Decay : public corsika::process::DecayProcess<Decay> { class Decay : public corsika::process::DecayProcess<Decay> {
std::vector<particles::Code> fTrackedParticles; std::vector<particles::Code> const fTrackedParticles;
int fCount = 0; int fCount = 0;
public: public:
...@@ -36,11 +36,11 @@ namespace corsika::process { ...@@ -36,11 +36,11 @@ namespace corsika::process {
void SetAllStable(); void SetAllStable();
void SetHadronsUnstable(); void SetHadronsUnstable();
template <typename Particle> template <typename TParticle>
corsika::units::si::TimeType GetLifetime(Particle const&); corsika::units::si::TimeType GetLifetime(TParticle const&) const;
template <typename Projectile> template <typename TProjectile>
void DoDecay(Projectile&); void DoDecay(TProjectile&);
}; };
} // namespace sibyll } // namespace sibyll
} // namespace corsika::process } // namespace corsika::process
......
...@@ -118,7 +118,8 @@ namespace corsika::process::sibyll { ...@@ -118,7 +118,8 @@ namespace corsika::process::sibyll {
} }
template <> template <>
units::si::GrammageType Interaction::GetInteractionLength(SetupParticle& vP, Track&) const { units::si::GrammageType Interaction::GetInteractionLength(SetupParticle& vP,
Track&) const {
using namespace units; using namespace units;
using namespace units::si; using namespace units::si;
......
...@@ -49,12 +49,11 @@ namespace corsika::process::sibyll { ...@@ -49,12 +49,11 @@ namespace corsika::process::sibyll {
} }
std::tuple<corsika::units::si::CrossSectionType, corsika::units::si::CrossSectionType> std::tuple<corsika::units::si::CrossSectionType, corsika::units::si::CrossSectionType>
GetCrossSection(const corsika::particles::Code BeamId, GetCrossSection(const corsika::particles::Code, const corsika::particles::Code,
const corsika::particles::Code TargetId, const corsika::units::si::HEPEnergyType) const;
const corsika::units::si::HEPEnergyType CoMenergy) const;
template <typename Particle, typename Track> template <typename TParticle, typename TTrack>
corsika::units::si::GrammageType GetInteractionLength(Particle&, Track&) const; corsika::units::si::GrammageType GetInteractionLength(TParticle&, TTrack&) const;
/** /**
In this function SIBYLL is called to produce one event. The In this function SIBYLL is called to produce one event. The
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment