GENIEGenerator
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
HG4BertCascIntranuke.h
Go to the documentation of this file.
1 #include "Framework/Conventions/GBuild.h"
2 #ifdef __GENIE_GEANT4_INTERFACE_ENABLED__
3 //____________________________________________________________________________
4 /*!
5 
6 \class genie::HG4BertCascIntranuke
7 
8 \brief Interface to the Geant4 Bertini intranuclear cascade
9  A concrete implementation of the EventRecordVisitorI interface
10 
11 \ref D.H. Wright and M.H. Kelsey, "The Geant4 Bertini Cascade",
12  Nucl. Inst. & Meth. A804 (2015) 175.
13 
14 \author Dennis Wright <dwright@slac.stanford.edu>
15 
16 \created 31 January 2017
17 
18 */
19 //____________________________________________________________________________
20 
21 #ifndef _HG4BERTCASCINTERNUKE_H_
22 #define _HG4BERTCASCINTERNUKE_H_
23 #include "Framework/Conventions/GBuild.h"
24 
28 
29 
30 #include <TLorentzVector.h>
31 class TVector3;
32 
33 #include <string>
34 using std::string;
35 
36 class G4ParticleDefinition;
37 class G4KineticTrackVector;
38 
39 namespace genie {
40 
41 class AlgFactory;
42 class GHepParticle;
43 class INukeHadroData;
44 
45 
46 class HG4BertCascIntranuke : public EventRecordVisitorI {
47 
48 public :
49  HG4BertCascIntranuke();
50  HG4BertCascIntranuke(string config);
51  int G4BertCascade(GHepRecord * event_rec) const;
52  ~HG4BertCascIntranuke();
53 
54  void ProcessEventRecord(GHepRecord* event_rec) const;
55  virtual string GetINukeMode() const {return "hG4BertCasc";};
56 
57 
58  void Configure(const Registry & config);
59  void Configure(string param_set);
60 
61 private:
62 
63  void LoadConfig (void);
64 
65  void InitG4Particles() const;
66  void TransportHadrons(GHepRecord* ev) const;
67  const G4ParticleDefinition* PDGtoG4Particle(int pdg) const;
68  G4KineticTrackVector* ConvertGenieSecondariesToG4(GHepRecord* evrec) const;
69  G4KineticTrackVector* ConvertGenieSecondariesToG4(std::vector<GHepParticle> partList) const;
70 
71  bool Conserve4Momentum (GHepRecord* ev) const;
72  bool CanRescatter (const GHepParticle* p) const;
73  bool IsBaryon (const GHepParticle* p) const;
74  void GenerateVertex (GHepRecord * ev) const;
75  bool IsInNucleus (const GHepParticle* p) const;
76  void SetTrackingRadius (const GHepParticle* p) const;
77  double GenerateStep (GHepRecord* ev, GHepParticle* p) const;
78  bool NeedsRescattering (const GHepParticle * p) const;
79 
80  // utility objects & params
81  mutable double fTrackingRadius; // tracking radius for nucleus current event
82 
83  const NuclearModelI* fNuclmodel; // nuclear model used to generate fermi momentum
84  mutable int fRemnA; // remnant nucleus A
85  mutable int fRemnZ; // remnant nucleus Z
86  mutable GEvGenMode_t fGMode;
87  // configuration parameters
88  double fR0; // effective nuclear size param
89  double fNR; // param multiplying the nuclear radius,
90  // determining how far to track hadrons
91  // beyond the "nuclear boundary"
92  double fNucRmvE; ///< binding energy to subtract from cascade nucleons
93  double fDelRPion; ///< factor by which Pion Compton wavelength gets multiplied to become nuclear size enhancement
94  double fDelRNucleon; ///< factor by which Nucleon Compton wavelength gets multiplied to become nuclear size enhancement
95  double fHadStep; ///< step size for intranuclear hadron transport
96  double fNucAbsFac; ///< absorption xsec correction factor (hN Mode)
97  double fNucCEXFac; ///< charge exchange xsec correction factor (hN Mode)
98  double fEPreEq; ///< threshold for pre-equilibrium reaction
99  double fFermiFac; ///< testing parameter to modify fermi momentum
100  double fFermiMomentum; ///< whether or not particle collision is pauli blocked
101  bool fUseOset; ///< Oset model for low energy pion in hN
102  bool fAltOset; ///< NuWro's table-based implementation (not recommended)
103  bool fXsecNNCorr; ///< use nuclear medium correction for NN cross section
104  bool fDoFermi;
105  double fPionMFPScale;
106  double fNucleonMFPScale;
107 };
108 
109 } // genie namespace
110 
111 #endif // _HG4BERTCASCINTERNUKE_H_
112 #endif // __GENIE_GEANT4_INTERFACE_ENABLED__
enum genie::EGEvGenMode GEvGenMode_t
void Configure(string mesg)
Definition: gEvServ.cxx:196