1 #ifndef __JAANET__JEVTWEIGHTTOOLKIT__
2 #define __JAANET__JEVTWEIGHTTOOLKIT__
49 namespace JPP {
using namespace JAANET; }
89 for (const_iterator
i = this->begin();
i != this->end(); ++
i) {
91 if ((*i)->check(header)) {
119 void put(
const int identifier)
125 identifiers.push_back(identifier);
141 return identifiers.size();
152 return identifiers.cbegin();
163 return identifiers.cend();
176 for (
int identifier; in >> identifier; ) {
177 collection.
put(identifier);
251 multiFlux.insert(*
i, atmFluxFunction);
265 return getMultiParticleFlux();
307 template<
class JFluxMap_t>
360 using namespace JPHYSICS;
363 const double year = 60*60*24*365;
friend std::istream & operator>>(std::istream &in, JFluxMap &fluxMap)
Stream input.
static JProperties getProperties(JFluxMap_t &object)
Get properties of this class.
JEvtWeighter getEventWeighter
Function object for mapping header to event weighter.
JNeutrinoTypeCollection()
Default constructor.
bool read(const JEquation &equation)
Read equation.
void insert(const int type, const JEvtWeightFactor_t &factor)
Insert pair of particle code and event-weight factor.
Implementation of event weighing for DAQ data.
JFluxMap()
Default constructor.
friend std::istream & operator>>(std::istream &in, JNeutrinoTypeCollection &collection)
Stream input.
std::vector< int >::const_iterator cbegin() const noexcept
Get constant iterator to the first element of the collection.
JFluxMultiParticle getMultiParticleFlux() const
Get multiparticle flux function.
JProperties & getProperties(T &object, const JEquationParameters ¶meters=JEquationParameters(), const int debug=1)
Get properties of a given object.
std::vector< int > identifiers
Container for identifiers.
double getVolume(const JType< JEvtWeightGSeaGen > &type, const Evt &evt)
Get volume of given event according given weighter.
Implementation of event weighting for Genhen data.
friend std::ostream & operator<<(std::ostream &out, const JNeutrinoTypeCollection &collection)
Stream output.
#define gmake_property(A)
macros to convert (template) parameter to JPropertiesElement object
static const int W2LIST_KM3BUU_WATER_INT_LEN
Interaction length in pure water in m.
static const int W2LIST_GENHEN_P_EARTH
Transmission probability in the Earth.
Low-level interface for oscillation probability calculators.
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
JEvtWeightFactorMultiParticle< JFlux > JFluxMultiParticle
Type-definition of multi-particle event-weight factor for fluxes.
Utility class to parse parameter values.
Implementation of event-weight factor interface.
static const double AVOGADRO
Avogadro's number.
Helper class for oscillation probabilities.
std::vector< double > w
MC: Weights w[0]=w1, w[1]=w2, w[2]=w3 (see e.g. Tag list or km3net-dataformat/definitions) ...
Implementation of event weighing for miscellaneous data such as a merged offline file containing neut...
static const double DENSITY_SEA_WATER
Fixed environment values.
Auxiliary class for parsing a vector of neutrino PDG identifiers.
Auxiliary class for a type holder.
JEvtWeightFactorFunction< JFunction_t, JFlux > make_fluxFunction(const JFunction_t &flux)
Auxiliary method for creating an interface to a flux function.
std::map< int, JPowerLawFlux > powerLawFluxes
Power-law flux functions.
std::vector< int >::const_iterator cend() const noexcept
Get constant iterator to the last element of the collection.
Utility class to parse parameter values.
std::ostream & write(std::ostream &out) const
Write the current parameter values.
Abstract base class for event weighing.
Implementation of atmospheric neutrino flux using official KM3NeT atmospheric flux function...
Implementation of event-weight factor for multiple particle types.
friend std::ostream & operator<<(std::ostream &out, const JFluxMap &fluxMap)
Stream output.
Implementation of event weighting for GSeaGen data.
size_t size() const
Get size of this collection.
static const int W2LIST_KM3BUU_P_EARTH
Transmission probability in the Earth.
Auxiliary class for parsing multiparticle fluxes.
Exception for cast operation.
JNeutrinoTypeCollection atmosphericFluxes
Atmospheric neutrino flux functions.
Implementation of event weighting for KM3BUU data.
static const int W2LIST_GSEAGEN_WATER_INT_LEN
Interaction length in pure water in m.
std::map< int, JFlatFlux > flatFluxes
Uniform flux functions.
Implementation of event weighing for MUPAGE data.
static const int W2LIST_GSEAGEN_P_EARTH
Transmission probability in the Earth (XSEC_MEAN and COLUMN_DEPTH used to compute PEarth) ...
Look-up table for event weighters.
static const double NUCLEON_MOLAR_MASS
nucleon molar mass [g/mol]
then fatal The output file must have the wildcard in the e g root fi eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS for EMITTER in
JEvtWeighter()
Constructor.
static const int WEIGHTLIST_DIFFERENTIAL_EVENT_RATE
Event rate per unit of flux (c.f. taglist document) [GeV m2 sr].
Definition of particle types.
Implementation of event weighting for Corsika data.
then set_variable DETECTOR set_variable OUTPUT_FILE set_variable DAQ_FILE set_variable PMT_FILE else fatal Wrong number of arguments fi JPrintTree f $DAQ_FILE type
Exception for accessing a value in a collection that is outside of its range.
static const int W2LIST_GENHEN_SIG
Cross section of the neutrion interaction.
void put(const int identifier)
Add identifier.
std::vector< double > w2list
MC: factors that make up w[1]=w2 (see e.g. Tag list or km3net-dataformat/definitions) ...
const JEvtWeight & operator()(const JHead &header) const
Get event weighter corresponding to given header.
The Evt class respresent a Monte Carlo (MC) event as well as an offline event.