GENIEGenerator
|
#include <cassert>
#include <cstdlib>
#include <string>
#include <vector>
#include <sstream>
#include <TSystem.h>
#include "Framework/Algorithm/AlgFactory.h"
#include "Framework/Conventions/Controls.h"
#include "Framework/EventGen/EventRecord.h"
#include "Framework/EventGen/EventGeneratorI.h"
#include "Framework/EventGen/EventRecordVisitorI.h"
#include "Framework/EventGen/GMCJMonitor.h"
#include "Framework/GHEP/GHepParticle.h"
#include "Framework/Messenger/Messenger.h"
#include "Framework/Ntuple/NtpWriter.h"
#include "Physics/BeamHNL/HNLDecayMode.h"
#include "Physics/BeamHNL/HNLDecayUtils.h"
#include "Physics/BeamHNL/HNLVertexGenerator.h"
#include "Physics/BeamHNL/HNLFluxCreator.h"
#include "Physics/BeamHNL/HNLFluxContainer.h"
#include "Physics/BeamHNL/HNLDecayer.h"
#include "Physics/BeamHNL/HNLProductionMode.h"
#include "Physics/BeamHNL/SimpleHNL.h"
#include "Framework/Numerical/RandomGen.h"
#include "Framework/ParticleData/PDGCodes.h"
#include "Framework/ParticleData/PDGUtils.h"
#include "Framework/ParticleData/PDGLibrary.h"
#include "Framework/Utils/StringUtils.h"
#include "Framework/Utils/UnitUtils.h"
#include "Framework/Utils/PrintUtils.h"
#include "Framework/Utils/AppInit.h"
#include "Framework/Utils/RunOpt.h"
#include "Framework/Utils/CmdLnArgParser.h"
Go to the source code of this file.
Typedefs | |
typedef enum t_HNLValidation | HNLValidation_t |
Enumerations | |
enum | t_HNLValidation { kValNone = 0, kValFluxFromDk2nu = 1, kValDecay = 2, kValGeom = 3, kValFullSim = 4 } |
Functions | |
void | GetCommandLineArgs (int argc, char **argv) |
void | ReadInConfig (void) |
void | PrintSyntax (void) |
const EventRecordVisitorI * | HNLGenerator (void) |
int | TestDecay (void) |
int | main (int argc, char **argv) |
Variables | |
string | kDefOptGeomLUnits = "mm" |
string | kDefOptGeomAUnits = "rad" |
string | kDefOptGeomTUnits = "ns" |
string | kDefOptGeomDUnits = "g_cm3" |
NtpMCFormat_t | kDefOptNtpFormat = kNFGHEP |
string | kDefOptEvFilePrefix = "gntp" |
string | kDefOptFluxFilePath = "./input-flux.root" |
string | kDefOptSName = "genie::EventGenerator" |
string | kDefOptSConfig = "BeamHNL" |
string | kDefOptSTune = "GHNL20_00a_00_000" |
Long_t | gOptRunNu = 1000 |
int | gOptNev = 10 |
HNLValidation_t | gOptValidationMode = kValNone |
double | gCfgMassHNL = -1 |
double | gCfgECoupling = -1 |
double | gCfgMCoupling = -1 |
double | gCfgTCoupling = -1 |
bool | gCfgIsMajorana = false |
int | gCfgHNLKind = 2 |
double | CoMLifetime = -1 |
HNLProd_t | gCfgProdMode = kHNLProdNull |
HNLDecayMode_t | gCfgDecayMode = kHNLDcyNull |
std::vector< HNLDecayMode_t > | gCfgIntChannels |
double | gCfgUserOx = -1 |
double | gCfgUserOy = -1 |
double | gCfgUserOz = -1 |
double | gCfgUserAx1 = -1 |
double | gCfgUserAz = -1 |
double | gCfgUserAx2 = -1 |
double | gCfgBoxLx = -1 |
double | gCfgBoxLy = -1 |
double | gCfgBoxLz = -1 |
double | gCfgParentEnergy = -1 |
double | gCfgParentTheta = -1 |
double | gCfgParentPhi = -1 |
double | gCfgParentOx = -1 |
double | gCfgParentOy = -1 |
double | gCfgParentOz = -1 |
double | gCfgHNLCx = -1 |
double | gCfgHNLCy = -1 |
double | gCfgHNLCz = -1 |
double | gOptEnergyHNL = -1 |
bool | gOptIsMonoEnFlux = true |
string | gOptEvFilePrefix = kDefOptEvFilePrefix |
bool | gOptUsingRootGeom = false |
string | gOptRootGeom |
string | geom |
string | lunits |
string | aunits |
string | tunits |
double | gOptGeomLUnits = 0 |
double | gOptGeomAUnits = 0 |
double | gOptGeomTUnits = 0 |
string | gOptRootGeomTopVol = "" |
double | fdx = 0 |
double | fdy = 0 |
double | fdz = 0 |
double | fox = 0 |
double | foy = 0 |
double | foz = 0 |
long int | gOptRanSeed = -1 |
typedef enum t_HNLValidation HNLValidation_t |
enum t_HNLValidation |
Enumerator | |
---|---|
kValNone | |
kValFluxFromDk2nu | |
kValDecay | |
kValGeom | |
kValFullSim |
Definition at line 134 of file gBeamHNLValidationApp.cxx.
void GetCommandLineArgs | ( | int | argc, |
char ** | argv | ||
) |
const EventRecordVisitorI* HNLGenerator | ( | void | ) |
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 255 of file gBeamHNLValidationApp.cxx.
References GetCommandLineArgs(), gOptRanSeed, gOptValidationMode, genie::RunOpt::Instance(), kValDecay, kValFluxFromDk2nu, kValGeom, LOG, genie::utils::app_init::MesgThresholds(), pFATAL, genie::utils::app_init::RandGen(), ReadInConfig(), and TestDecay().
void PrintSyntax | ( | void | ) |
void ReadInConfig | ( | void | ) |
Definition at line 1421 of file gBeamHNLValidationApp.cxx.
References genie::hnl::selector::__attribute__(), genie::utils::hnl::AsString(), aunits, CoMLifetime, gCfgECoupling, gCfgHNLCx, gCfgHNLCy, gCfgHNLCz, gCfgIntChannels, gCfgIsMajorana, gCfgMassHNL, gCfgMCoupling, gCfgTCoupling, gCfgUserAx1, gCfgUserAx2, gCfgUserAz, gCfgUserOx, gCfgUserOy, gCfgUserOz, genie::AlgFactory::GetAlgorithm(), genie::hnl::FluxCreator::GetB2URotation(), genie::hnl::FluxCreator::GetB2UTranslation(), genie::hnl::Decayer::GetHNLCouplings(), genie::hnl::Decayer::GetHNLInterestingChannels(), genie::hnl::Decayer::GetHNLLifetime(), genie::hnl::Decayer::GetHNLMass(), genie::hnl::Decayer::GetPGunDirection(), genie::hnl::Decayer::GetPGunEnergy(), gOptEnergyHNL, gOptGeomAUnits, gOptGeomLUnits, genie::AlgFactory::Instance(), genie::hnl::Decayer::IsHNLMajorana(), LOG, lunits, genie::units::m, pDEBUG, pFATAL, and genie::units::rad.
Referenced by main().
int TestDecay | ( | void | ) |
Definition at line 545 of file gBeamHNLValidationApp.cxx.
References genie::hnl::selector::__attribute__(), genie::utils::hnl::AsString(), CoMLifetime, genie::XclsTag::DecayMode(), genie::Interaction::ExclTag(), gCfgECoupling, gCfgHNLCx, gCfgHNLCy, gCfgHNLCz, gCfgMassHNL, gCfgMCoupling, gCfgTCoupling, genie::AlgFactory::GetAlgorithm(), genie::hnl::Decayer::GetPGunEnergy(), genie::hnl::Decayer::GetPGunOrigin(), genie::hnl::SimpleHNL::GetValidChannels(), gOptEnergyHNL, gOptNev, gOptRootGeom, genie::Interaction::HNL(), HNLGenerator(), genie::Interaction::InitStatePtr(), genie::RunOpt::Instance(), genie::AlgFactory::Instance(), genie::hnl::kHNLDcyNuEE, genie::hnl::kHNLDcyNull, genie::hnl::kHNLDcyNuMuE, genie::hnl::kHNLDcyNuMuMu, genie::hnl::kHNLDcyNuNuNu, genie::hnl::kHNLDcyPi0Nu, genie::hnl::kHNLDcyPi0Pi0Nu, genie::hnl::kHNLDcyPiE, genie::hnl::kHNLDcyPiMu, genie::hnl::kHNLDcyPiPi0E, genie::hnl::kHNLDcyPiPi0Mu, genie::kIStInitialState, genie::kPdgHNL, genie::kPdgKP, LOG, genie::units::m, genie::units::mm, genie::utils::print::P4AsString(), pDEBUG, pFATAL, pINFO, genie::hnl::Decayer::ProcessEventRecord(), genie::hnl::VertexGenerator::ProcessEventRecord(), genie::hnl::SimpleHNL::SetEnergy(), genie::hnl::VertexGenerator::SetGeomFile(), genie::hnl::SimpleHNL::SetMomentumDirection(), genie::GHepRecord::SetPrintLevel(), and genie::InitialState::SetProbeP4().
Referenced by main().
string aunits |
Definition at line 234 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double CoMLifetime = -1 |
Definition at line 190 of file gBeamHNLValidationApp.cxx.
double fdx = 0 |
Definition at line 245 of file gBeamHNLValidationApp.cxx.
double fdy = 0 |
Definition at line 246 of file gBeamHNLValidationApp.cxx.
double fdz = 0 |
Definition at line 247 of file gBeamHNLValidationApp.cxx.
double fox = 0 |
Definition at line 248 of file gBeamHNLValidationApp.cxx.
double foy = 0 |
Definition at line 249 of file gBeamHNLValidationApp.cxx.
double foz = 0 |
Definition at line 250 of file gBeamHNLValidationApp.cxx.
double gCfgBoxLx = -1 |
Definition at line 204 of file gBeamHNLValidationApp.cxx.
double gCfgBoxLy = -1 |
Definition at line 205 of file gBeamHNLValidationApp.cxx.
double gCfgBoxLz = -1 |
Definition at line 206 of file gBeamHNLValidationApp.cxx.
HNLDecayMode_t gCfgDecayMode = kHNLDcyNull |
Definition at line 194 of file gBeamHNLValidationApp.cxx.
double gCfgECoupling = -1 |
Definition at line 184 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgHNLCx = -1 |
Definition at line 215 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgHNLCy = -1 |
Definition at line 216 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgHNLCz = -1 |
Definition at line 217 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
int gCfgHNLKind = 2 |
Definition at line 188 of file gBeamHNLValidationApp.cxx.
std::vector< HNLDecayMode_t > gCfgIntChannels |
Definition at line 195 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
bool gCfgIsMajorana = false |
Definition at line 187 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgMassHNL = -1 |
Definition at line 183 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgMCoupling = -1 |
Definition at line 185 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgParentEnergy = -1 |
Definition at line 208 of file gBeamHNLValidationApp.cxx.
double gCfgParentOx = -1 |
Definition at line 211 of file gBeamHNLValidationApp.cxx.
double gCfgParentOy = -1 |
Definition at line 212 of file gBeamHNLValidationApp.cxx.
double gCfgParentOz = -1 |
Definition at line 213 of file gBeamHNLValidationApp.cxx.
double gCfgParentPhi = -1 |
Definition at line 210 of file gBeamHNLValidationApp.cxx.
double gCfgParentTheta = -1 |
Definition at line 209 of file gBeamHNLValidationApp.cxx.
HNLProd_t gCfgProdMode = kHNLProdNull |
Definition at line 193 of file gBeamHNLValidationApp.cxx.
double gCfgTCoupling = -1 |
Definition at line 186 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig(), and TestDecay().
double gCfgUserAx1 = -1 |
Definition at line 200 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgUserAx2 = -1 |
Definition at line 202 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgUserAz = -1 |
Definition at line 201 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgUserOx = -1 |
Definition at line 197 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgUserOy = -1 |
Definition at line 198 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gCfgUserOz = -1 |
Definition at line 199 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
string geom |
Definition at line 233 of file gBeamHNLValidationApp.cxx.
Referenced by GetCommandLineArgs(), GetTargetCodes(), and main().
double gOptEnergyHNL = -1 |
Definition at line 221 of file gBeamHNLValidationApp.cxx.
string gOptEvFilePrefix = kDefOptEvFilePrefix |
Definition at line 229 of file gBeamHNLValidationApp.cxx.
double gOptGeomAUnits = 0 |
Definition at line 236 of file gBeamHNLValidationApp.cxx.
Referenced by ReadInConfig().
double gOptGeomLUnits = 0 |
Definition at line 235 of file gBeamHNLValidationApp.cxx.
double gOptGeomTUnits = 0 |
Definition at line 237 of file gBeamHNLValidationApp.cxx.
bool gOptIsMonoEnFlux = true |
Definition at line 227 of file gBeamHNLValidationApp.cxx.
int gOptNev = 10 |
Definition at line 177 of file gBeamHNLValidationApp.cxx.
long int gOptRanSeed = -1 |
Definition at line 252 of file gBeamHNLValidationApp.cxx.
string gOptRootGeom |
Definition at line 231 of file gBeamHNLValidationApp.cxx.
string gOptRootGeomTopVol = "" |
Definition at line 242 of file gBeamHNLValidationApp.cxx.
Long_t gOptRunNu = 1000 |
Definition at line 176 of file gBeamHNLValidationApp.cxx.
bool gOptUsingRootGeom = false |
Definition at line 230 of file gBeamHNLValidationApp.cxx.
HNLValidation_t gOptValidationMode = kValNone |
Definition at line 179 of file gBeamHNLValidationApp.cxx.
Referenced by main().
string kDefOptEvFilePrefix = "gntp" |
Definition at line 168 of file gBeamHNLValidationApp.cxx.
string kDefOptFluxFilePath = "./input-flux.root" |
Definition at line 169 of file gBeamHNLValidationApp.cxx.
string kDefOptGeomAUnits = "rad" |
Definition at line 163 of file gBeamHNLValidationApp.cxx.
string kDefOptGeomDUnits = "g_cm3" |
Definition at line 165 of file gBeamHNLValidationApp.cxx.
string kDefOptGeomLUnits = "mm" |
Definition at line 162 of file gBeamHNLValidationApp.cxx.
string kDefOptGeomTUnits = "ns" |
Definition at line 164 of file gBeamHNLValidationApp.cxx.
NtpMCFormat_t kDefOptNtpFormat = kNFGHEP |
Definition at line 167 of file gBeamHNLValidationApp.cxx.
string kDefOptSConfig = "BeamHNL" |
Definition at line 172 of file gBeamHNLValidationApp.cxx.
string kDefOptSName = "genie::EventGenerator" |
Definition at line 171 of file gBeamHNLValidationApp.cxx.
string kDefOptSTune = "GHNL20_00a_00_000" |
Definition at line 173 of file gBeamHNLValidationApp.cxx.
string lunits |
Definition at line 234 of file gBeamHNLValidationApp.cxx.
Referenced by GetCommandLineArgs(), and ReadInConfig().
string tunits |
Definition at line 234 of file gBeamHNLValidationApp.cxx.