Class ParticleMapsContainer

Class Documentation

class ParticleMapsContainer

Container for particlemaps The maps are stored with discrete energies on a logarithmic scale. The default energy width is 0.02 with an energy bin from 10**17.99 - 10**18.01 eV.

Public Functions

ParticleMapsContainer(double deltaLogE = 0.02, double bin0lowerEdge = 17.99)
~ParticleMapsContainer()
size_t getNumberOfPixels()
double *getMap(const int particleId, double energy)

returns the map for the particleId with the given energy,. energy in Joule

void addParticle(const int particleId, double energy, double galacticLongitude, double galacticLatitude, double weight = 1)

adds a particle to the map container particleId is HEP particleId, energy [Joule], galacticLongitude and galacticLatitude in [rad]

void addParticle(const int particleId, double energy, const Vector3d &v, double weight = 1)
std::vector<int> getParticleIds()
std::vector<double> getEnergies(int pid)
void applyLens(MagneticLens &lens)
void getRandomParticles(size_t N, vector<int> &particleId, vector<double> &energy, vector<double> &galacticLongitudes, vector<double> &galacticLatitudes)
bool placeOnMap(int pid, double energy, double &galacticLongitude, double &galacticLatitude)
void forceWeightUpdate()
double getSumOfWeights()
double getWeight(int pid, double energy)