GENIEGenerator
Loading...
Searching...
No Matches
gMakeHEDISStrucFunc.cxx
Go to the documentation of this file.
1//____________________________________________________________________________
2/*!
3\program gmkspl
4\brief GENIE utility program building Structure Functions needed for HEDIS
5 package.
6 Syntax :
7 gmksf [-h]
8 --tune genie_tune
9 [--message-thresholds xml_file]
10 Note :
11 [] marks optional arguments.
12 <> marks a list of arguments out of which only one can be
13 selected at any given time.
14 Options :
15 --tune
16 Specifies a GENIE comprehensive neutrino interaction model tune.
17 --message-thresholds
18 Allows users to customize the message stream thresholds.
19 The thresholds are specified using an XML file.
20 See $GENIE/config/Messenger.xml for the XML schema.
21 *** See the User Manual for more details and examples. ***
22\author Alfonso Garcia <alfonsog \at nikhef.nl>
23 NIKHEF (Amsterdam)
24\created July 8, 2019
25\cpright Copyright (c) 2003-2025, The GENIE Collaboration
26 For the full text of the license visit http://copyright.genie-mc.org
27 or see $GENIE/LICENSE
28*/
29//____________________________________________________________________________
30
40
41using namespace genie;
42
43void PrintSyntax (void);
44
45//____________________________________________________________________________
46int main(int argc, char ** argv)
47{
48
50
51 if ( ! RunOpt::Instance()->Tune() ) {
52 LOG("gmkhedissf", pFATAL) << " No TuneId in RunOption";
53 exit(-1);
54 }
56
58
59 GEVGDriver evg_driver;
60 InitialState init_state(1000010020, 14);
61 evg_driver.SetEventGeneratorList("CCHEDIS");
62 evg_driver.Configure(init_state);
63
64 const InteractionList * intlst = evg_driver.Interactions();
65 InteractionList::const_iterator intliter = intlst->begin();
66 Interaction * interaction = *intliter;
67 const XSecAlgorithmI * xsec_alg = evg_driver.FindGenerator(interaction)->CrossSectionAlg();
68 interaction->SetBit(kISkipKinematicChk);
69 xsec_alg->XSec(interaction, kPSxQ2fE);
70
71}//____________________________________________________________________________
72void PrintSyntax(void)
73{
74 LOG("gmkhedissf", pNOTICE)
75 << "\n\n" << "Syntax:" << "\n"
76 << "\n gmkhedissf [-h]"
77 << "\n --tune genie_tune"
78 << "\n --message-thresholds xml_file"
79 << "\n";
80}
#define pNOTICE
Definition Messenger.h:61
#define pFATAL
Definition Messenger.h:56
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE,...
Definition Messenger.h:96
int main()
virtual const XSecAlgorithmI * CrossSectionAlg(void) const =0
GENIE Event Generation Driver. A minimalist user interface object for generating neutrino interaction...
Definition GEVGDriver.h:54
void Configure(int nu_pdgc, int Z, int A)
const InteractionList * Interactions(void) const
void SetEventGeneratorList(string listname)
const EventGeneratorI * FindGenerator(const Interaction *interaction) const
Initial State information.
A vector of Interaction objects.
Summary information for an interaction.
Definition Interaction.h:56
void ReadFromCommandLine(int argc, char **argv)
Definition RunOpt.cxx:99
void BuildTune()
build tune and inform XSecSplineList
Definition RunOpt.cxx:92
static RunOpt * Instance(void)
Definition RunOpt.cxx:54
Cross Section Calculation Interface.
virtual double XSec(const Interaction *i, KinePhaseSpace_t k=kPSfE) const =0
Compute the cross section for the input interaction.
void PrintSyntax(void)
void MesgThresholds(string inpfile)
Definition AppInit.cxx:99
THE MAIN GENIE PROJECT NAMESPACE
Definition AlgCmp.h:25
const UInt_t kISkipKinematicChk
if set, skip kinematic validity checks
Definition Interaction.h:48