//____________________________________________________________________________ /*! \class genie::BinParam, genie::GenParam \brief Data structure for gSeaGen \author Carla Distefano LNS-INFN, Catania Included modifications by Alfonso Garcia NIKHEF, Amsterdam (January 2019) \created May 13, 2012 \cpright Copyright (c) 2012-2019, The KM3NeT Collaboration For the full text of the license see $GSEAGEN/LICENSE */ //____________________________________________________________________________ #ifndef _GBINPARAM_H__ #define _GBINPARAM_H__ #include #include "TGraph.h" #include "TDatime.h" #include "TRotation.h" #include "TSystem.h" #include "libxml/parser.h" #include "libxml/xmlmemory.h" #include "libxml/xmlreader.h" #include #include #define STR_(X) #X #define STR(X) STR_(X) // GENIE #ifdef _GENIEVERSIONGTEQ3__ #include "Framework/Conventions/GVersion.h" #include "Framework/Utils/XmlParserUtils.h" #else #include "Conventions/GVersion.h" #endif #include "SeaEvent/GSeaSystParam.h" #include using namespace std; using namespace genie; struct BinParam { double NEvBin, NEvBinSW, NEvBinSR; int NEvBinScal, NEvBinGen; int NEvBinScalSW, NEvBinGenSW; int NEvBinScalSR, NEvBinGenSR; double EneMin, EneMax, RT, RL; double X0,Y0,Z0; double ProbScale, ProbScaleSW, ProbScaleSR; double RVol, HSeaWater, HRock, RockCenter, SeaCenter, ZminVol, ZmaxVol; string geometry; }; class FluxFileStr : public TObject { public: int NuType; ///< Neutrino type string FluxSimul; ///< Neutrino flux model vector FileNames; ///< List of neutrino flux files FluxFileStr(){}; ~FluxFileStr(){}; ClassDef(FluxFileStr,1); }; // GenParam class contains all inputs used in the simulation. // Some of these inputs are computed by the code itself (e.g. cross sections enetring in the weights) // Members of this class are filled by different classes at initializzation class GenParam : public TObject { public: int RunNu; ///< Run number int RanSeed; ///< Random number seed string EventGeneratorList; ///< List of interaction channels string InpXSecFile; ///< Cross-section splines double NTot; ///< Total number of generated neutrinos double EvMin; ///< Generated neutrino energy: minimum value double EvMax; ///< Generated neutrino energy: maximum value double CtMin; ///< Generated neutrino cosTheta: minimum value double CtMax; ///< Generated neutrino cosTheta: maximum value float Alpha; ///< Generation spectral index int Primary; ///< Primary particle PDG IDs float EPrimMin; ///< [CORSIKA-specific] Generated primary: minimum value float EPrimMax; ///< [CORSIKA-specific] Generated primary: maximum value float PrimCtMin; ///< [CORSIKA-specific] Generated primary cosTheta: minimum value float PrimCtMax; ///< [CORSIKA-specific] Generated primary cosTheta: maximum value float EmuMin; ///< [CORSIKA-specific] muon E threshold string CRModel; ///< [CORSIKA-specific] CR Flux model used for weighting; default: GST3 unsigned int MaxNRec; ///< [CORSIKA-specific] Maximal number of records read from CORSIKA files; default: 2180000 int NBin; ///< Number of energy bins double Can1; ///< Z-level of the detector can bottom double Can2; ///< Z-level of the detector can top double Can3; ///< Radius of detector can double OriginX; ///< X coordinate of orgin of the detector reference system in meters double OriginY; ///< Y coordinate of orgin of the detector reference system in meters double OriginZ; ///< Z coordinate of orgin of the detector reference system in meters double HRock; ///< Interaction volume: height of Rock double HSeaWater; ///< Interaction volume: height in SeaWater double RVol; ///< Interaction volume: radius double ZminVol; ///< Interaction volume: Z-level of the bottom double ZmaxVol; ///< Interaction volume: Z-level of the top double RockCenter; ///< Interaction volume: z level of Rock center double SeaCenter; ///< Interaction volume: z level of SeaWater center double HBedRock; ///< height of the bedrock to add below the can to take into account that some particles may escape into the ocean and create visible Cherenkov light double NAbsLength; ///< number of light absorption lengths used in the definition of the detector can double AbsLength; ///< ight absorption length used in the definition of the detector can double SiteDepth; ///< site depth double SiteLatitude; ///< detector latitude in rad double SiteLongitude; ///< detector longitude in rad double SiteDeclination; ///< detector declination in rad double UTMConvergeAngle; ///< convergence angle of UTM system, in rad bool UseUTMSystem; ///< if true use the UTM reference system double SeaBottomRadius; ///< Earth radius at the sea-bottom double GlobalGenWeight; ///< Constant part of the generation weigths double TGen; ///< Generation time interval in seconds int TrackEvts; ///< if >0 propagator code is initialized int WriteParticlesMode; ///< 0,1,2 for increasingly more particles bool WriteEvt; ///< write .evt file bool WriteKM3NeT; ///< write km3net .root file bool WriteNative; ///< write native .root file bool NativeOutput; ///< if true write the native generator output file vector WriteFormat; ///< list of output formats to be written bool SaveMu; ///< [CORSIKA-specific] save muons for further propagation bool SaveNu; ///< [CORSIKA-specific] save neutrinos for further propagation bool SaveOther; ///< [CORSIKA-specific] save all other particles for further propagation unsigned int ChancesPerShower; ///< [CORSIKA-specific] number of extra chances to hit the can for a shower double CustomRotation[3]; ///< [CORSIKA-specific] custom rotation for sea-level CORSIKA showers int WeightOpt; ///< 0,1,2 wieghting options in GMCJDriver (GENIE) string RTOpt; ///< RT definition opt: can, vol or set by hand string GenCode; ///< if genie or other generator string PropCode; ///< name of the propagater code string PropCodeVer; ///< version of the propagater code double PropagationStep; ///< max depth in propagation step [meters] double DistAfterFirstStep; ///< distance from the can after big first propagation step [meters] string GenMode; ///< DIFFUSE, POINT, EVT or BIN string SourceFile; ///< Input file with astrophysical neutrino source info string SourceName; ///< Astrophysical neutrino source name double Declination; ///< Declination of the astrophysical neutrino source double RightAscension; ///< Right Ascension of the astrophysical neutrino source double SourceRadius; ///< Radius of the astrophysical neutrino source bool GenMJD; ///< True if event time generation is active double MJDStart; ///< Event start time in MJD double MJDStop; ///< Event stop time in MJD unsigned int TimeStampStart; ///< Event start time in UNIX timestamp unsigned int TimeStampStop; ///< Event stop time in UNIX timestamp double RhoSW; ///< Density of SeaWater medium double RhoSR; ///< Density of the Rock medium map SeaWaterComp; ///< Composition of SeaWater medium map RockComp; ///< Composition of Rock medium map MantleComp; ///< Composition of Mantle medium map CoreComp; ///< Composition of Core medium map XSecWater; ///< Cross sections per nucleon in m^2 (pure water) map XSecTotSW; ///< CC cross sections per nucleon in m^2 (seawater) map XSecTotSR; ///< CC cross sections per nucleon in m^2 (rock/crust) map XSecTotMantle; ///< CC cross sections per nucleon in m^2 (mantle) map XSecTotCore; ///< CC cross sections per nucleon in m^2 (core) double MolarMassSW; ///< Molar mass of SeaWater medium double MolarMassSR; ///< Molar mass of Rock medium double MolarMassMantle; ///< Molar mass of Mantle medium double MolarMassCore; ///< Molar mass of Core medium int NNucleonsSW; ///< Number of nucleons in SeaWater medium int NNucleonsSR; ///< Number of nucleons in Rock medium int NNucleonsMantle; ///< Number of nucleons in Mantle medium int NNucleonsCore; ///< Number of nucleons in Core medium int NElectronsSW; ///< Number of electrons in SeaWater medium int NElectronsSR; ///< Number of electrons in Rock medium int NElectronsMantle; ///< Number of electrons in Mantle medium int NElectronsCore; ///< Number of electrons in Core medium TGraph RangeSW; ///< Muon maximum range in SeaWater TGraph RangeSR; ///< Muon maximum range in Rock string detector; ///< Detector geometry file (for can definition) vector NuList; ///< List of generated neutrino type vector FluxFiles; ///< List of neutrino fluxes used in the event weights TRotation Rotation; ///< Coordinate rotation matrix: topocentric horizontal -> user-defined topocentric system string EvFilePrefix; ///< Prefix of the output file names bool PropMode; ///< True if propagation through the Earth string Drawing; ///< If surface or volume drawing string gSeaGenVer; ///< Code version for gSeaGen string GenieVer; ///< Code version for GENIE float CORSIKAVer; ///< Code version for CORSIKA int CORSIKADate; ///< yyddmm date on which the CORSIKA RUN started int CORSIKASeed[2]; ///< Seeds used in CORSIKA string CORSIKAHadronicModelLE; ///< LE hadronic interaction model used in CORSIKA string CORSIKAHadronicModelHE; ///< HE hadronic interaction model used in CORSIKAv bool SilentCORSIKA; ///< Less verbose CORSIKA file driver LOG messages bool NoPropagationCORSIKA; ///< CORSIKA events should not be propagated float MuonRangeTolerance; ///< Tolerance [m] for the muon range estimation (meant to potentially gain statistics at low energies) double PropagationTolerance; ///< Tolerance [m] for the muon propagation string GenTune; ///< Generator tune, required for genie version >=3 time_t RunTime; ///< Running time SystInput SystParams; ///< Input parameters for neutrino interaction systematics GenParam(); ~GenParam(); void SetDefParams(void); ///< Set default class parameters void LoadDefParams(void); ///< Load and re-define default parameters from input file void LoadMediaComp(void); ///< Load and re-define media composition if request by the user ClassDef(GenParam,1); }; #endif // _GBINPARAM_H__