16 #include <corsika/framework/geometry/Point.hpp> 17 #include <corsika/framework/geometry/Vector.hpp> 18 #include <corsika/framework/geometry/PhysicalGeometry.hpp> 30 template <
typename TStackIterator>
42 typedef std::tuple<Code, HEPEnergyType, DirectionVector, Point, TimeType>
57 typedef std::tuple<Code, HEPEnergyType, DirectionVector, Vector<length_d>,
TimeType>
60 std::string asString()
const;
77 secondary_data_type
const& v);
177 typedef std::vector<Code> code_vector_type;
178 typedef std::vector<HEPEnergyType> kinetic_energy_vector_type;
179 typedef std::vector<Point> point_vector_type;
180 typedef std::vector<TimeType> time_vector_type;
181 typedef std::vector<DirectionVector> direction_vector_type;
197 unsigned int getSize()
const {
return dataPID_.size(); }
198 unsigned int getCapacity()
const {
return dataPID_.size(); }
200 void setPID(
size_t i, Code
const id) { dataPID_[i] = id; }
206 Code
getPID(
size_t i)
const {
return dataPID_[i]; }
215 void copy(
size_t const i1,
size_t const i2);
220 void swap(
size_t const i1,
size_t const i2);
222 void incrementSize();
223 void decrementSize();
227 code_vector_type dataPID_;
228 kinetic_energy_vector_type dataEkin_;
229 direction_vector_type direction_;
230 point_vector_type position_;
231 time_vector_type time_;
239 #include <corsika/detail/stack/VectorStack.inl> Memory implementation of the most simple particle stack object.
int16_t getChargeNumber() const
Get charge number.
std::tuple< Code, HEPEnergyType, DirectionVector, Vector< length_d >, TimeType > secondary_extended_data_type
secondary particle data information content with position and time update.
std::tuple< Code, HEPEnergyType, DirectionVector > secondary_data_type
secondary particle data information content.
Import and extend the phys::units package.
DirectionVector const & getDirection() const
Get direction.
void setKineticEnergy(HEPEnergyType const &ekin)
! Set kinetic energy
The Stack class provides (and connects) the main particle data storage machinery. ...
void setDirection(DirectionVector const &v)
Set direction.
void setTime(TimeType const &v)
Set time.
HEPMassType getMass() const
Get mass of particle.
Description of particle stacks.
HEPEnergyType constexpr calculate_momentum(HEPEnergyType const E, HEPMassType const m)
Code getPID() const
Get corsika::Code.
Example of a particle object on the stack.
`, since they are used everywhere as integral part of the framework.
std::size_t getIndex() const
return the index number of the underlying iterator object
Point const & getPosition() const
Get position.
void setPID(Code const id)
! Set particle corsika::Code
ElectricChargeType constexpr get_charge(Code const)
electric charge
HEPEnergyType getEnergy() const
Get total energy.
ElectricChargeType getCharge() const
Get electric charge.
Relativistic energy momentum calculations.
TimeType getTime() const
Get time.
PDGCode getPDG() const
Get PDG code.
void setParticleData(particle_data_type const &v)
Set data of new particle.
int16_t constexpr get_charge_number(Code const)
electric charge in units of e
void setEnergy(HEPEnergyType const &e)
! Set energy
HEPMassType constexpr get_mass(Code const)
mass
Interface to particle properties.
void setPosition(Point const &v)
Set position.
PDGCode constexpr get_PDG(Code const)
Particle code according to PDG, "Monte Carlo Particle Numbering Scheme".
HEPEnergyType getKineticEnergy() const
Get kinetic energy.
The base class to define the readout of particle properties from a particle stack.
VelocityVector getVelocity() const
Get velocity.
std::tuple< Code, HEPEnergyType, DirectionVector, Point, TimeType > particle_data_type
particle data information content.
MomentumVector getMomentum() const
Get momentum.