GENIEGenerator
Loading...
Searching...
No Matches
Interaction.h
Go to the documentation of this file.
1//____________________________________________________________________________
2/*!
3
4\class genie::Interaction
5
6\brief Summary information for an interaction.
7
8 It is a container of an InitialState, a ProcessInfo, an XclsTag
9 and a Kinematics object.
10
11\author Costas Andreopoulos <c.andreopoulos \at cern.ch>
12 University of Liverpool
13
14 Changes required to implement the GENIE Boosted Dark Matter module
15 were installed by Josh Berger (Univ. of Wisconsin)
16
17\created April 25, 2004
18
19\cpright Copyright (c) 2003-2025, The GENIE Collaboration
20 For the full text of the license visit http://copyright.genie-mc.org
21*/
22//____________________________________________________________________________
23
24#ifndef _INTERACTION_H_
25#define _INTERACTION_H_
26
27#include <ostream>
28#include <string>
29
30#include <TObject.h>
31
38
39using std::ostream;
40using std::string;
41using std::pair;
42
43class TRootIOCtor;
44
45namespace genie {
46
47const UInt_t kISkipProcessChk = 1<<17; ///< if set, skip process validity checks
48const UInt_t kISkipKinematicChk = 1<<16; ///< if set, skip kinematic validity checks
49const UInt_t kIAssumeFreeNucleon = 1<<15; ///<
50const UInt_t kIAssumeFreeElectron = 1<<15; ///<
51const UInt_t kINoNuclearCorrection = 1<<14; ///< if set, inhibit nuclear corrections
52
53class Interaction;
54ostream & operator << (ostream & stream, const Interaction & i);
55
56class Interaction : public TObject {
57
58public:
59 using TObject::Print; // suppress clang 'hides overloaded virtual function [-Woverloaded-virtual]' warnings
60 using TObject::Copy; //
61
63 Interaction(const InitialState & init, const ProcessInfo & proc);
64 Interaction(const Interaction & i);
65 Interaction(TRootIOCtor*);
67
68 // Methods accessing aggregate/owned objects holding interaction information
69 const InitialState & InitState (void) const { return *fInitialState; }
70 const ProcessInfo & ProcInfo (void) const { return *fProcInfo; }
71 const Kinematics & Kine (void) const { return *fKinematics; }
72 const XclsTag & ExclTag (void) const { return *fExclusiveTag; }
73 const KPhaseSpace & PhaseSpace (void) const { return *fKinePhSp; }
74 InitialState * InitStatePtr (void) const { return fInitialState; }
75 ProcessInfo * ProcInfoPtr (void) const { return fProcInfo; }
76 Kinematics * KinePtr (void) const { return fKinematics; }
77 XclsTag * ExclTagPtr (void) const { return fExclusiveTag; }
78 KPhaseSpace * PhaseSpacePtr (void) const { return fKinePhSp; }
79
80 // Methods to set interaction's properties
81 void SetInitState (const InitialState & init);
82 void SetProcInfo (const ProcessInfo & proc);
83 void SetKine (const Kinematics & kine);
84 void SetExclTag (const XclsTag & xcls);
85
86 // Get the final state primary lepton and recoil nucleon (if) uniquely
87 // determined for the specified interaction
88 int FSPrimLeptonPdg (void) const; ///< final state primary lepton pdg
89 int RecoilNucleonPdg (void) const; ///< recoil nucleon pdg
90 TParticlePDG * FSPrimLepton (void) const; ///< final state primary lepton
91 TParticlePDG * RecoilNucleon (void) const; ///< recoil nucleon
92
93 // Copy, reset, print itself and build string code
94 void Reset (void);
95 void Copy (const Interaction & i);
96 string AsString (void) const;
97 void Print (ostream & stream) const;
98
99 // Overloaded operators
100 Interaction & operator = (const Interaction & i); ///< copy
101 friend ostream & operator << (ostream & stream, const Interaction & i); ///< print
102
103 // Use the "Named Constructor" C++ idiom for fast creation of typical interactions
104 static Interaction * DISCC (int tgt, int nuc, int probe, double E=0);
105 static Interaction * DISCC (int tgt, int nuc, int qrk, bool sea, int probe, double E=0);
106 static Interaction * DISCC (int tgt, int nuc, int qrk, bool sea, int fqrk, int probe, double E=0);
107 static Interaction * DISCC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
108 static Interaction * DISCC (int tgt, int nuc, int qrk, bool sea, int probe, const TLorentzVector & p4probe);
109 static Interaction * DISNC (int tgt, int nuc, int probe, double E=0);
110 static Interaction * DISNC (int tgt, int nuc, int qrk, bool sea, int probe, double E=0);
111 static Interaction * DISNC (int tgt, int nuc, int qrk, bool sea, int fqrk, int probe, double E=0);
112 static Interaction * DISNC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
113 static Interaction * DISNC (int tgt, int nuc, int qrk, bool sea, int probe, const TLorentzVector & p4probe);
114 static Interaction * DISEM (int tgt, int nuc, int probe, double E=0);
115 static Interaction * DISEM (int tgt, int nuc, int qrk, bool sea, int probe, double E=0);
116 static Interaction * DISEM (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
117 static Interaction * DISEM (int tgt, int nuc, int qrk, bool sea, int probe, const TLorentzVector & p4probe);
118 static Interaction * QELCC (int tgt, int nuc, int probe, double E=0);
119 static Interaction * QELCC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
120 static Interaction * QELNC (int tgt, int nuc, int probe, double E=0);
121 static Interaction * QELNC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
122 static Interaction * QELEM (int tgt, int nuc, int probe, double E=0);
123 static Interaction * QELEM (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
124 static Interaction * IBD (int tgt, int nuc, int probe, double E=0);
125 static Interaction * IBD (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
126 static Interaction * RESCC (int tgt, int nuc, int probe, double E=0);
127 static Interaction * RESCC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
128 static Interaction * RESNC (int tgt, int nuc, int probe, double E=0);
129 static Interaction * RESNC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
130 static Interaction * RESEM (int tgt, int nuc, int probe, double E=0);
131 static Interaction * RESEM (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
132 static Interaction * DFRCC (int tgt, int nuc, int probe, double E=0);
133 static Interaction * DFRCC (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
134 static Interaction * COHCC (int tgt, int probe, unsigned int prod_pdg, double E=0);
135 static Interaction * COHCC (int tgt, int probe, unsigned int prod_pdg,
136 const TLorentzVector & p4probe);
137 static Interaction * COHNC (int tgt, int probe, unsigned int prod_pdg, double E=0);
138 static Interaction * COHNC (int tgt, int probe, unsigned int prod_pdg,
139 const TLorentzVector & p4probe);
140 static Interaction * CEvNS (int tgt, int probe, double E=0);
141 static Interaction * CEvNS (int tgt, int probe, const TLorentzVector & p4probe);
142 static Interaction * IMD (int tgt, double E=0);
143 static Interaction * IMD (int tgt, const TLorentzVector & p4probe);
144 static Interaction * AMNuGamma (int tgt, int nuc, int probe, double E=0);
145 static Interaction * AMNuGamma (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
146 static Interaction * MECCC (int tgt, int nuccluster, int probe, double E=0);
147 static Interaction * MECCC (int tgt, int nuccluster, int probe, const TLorentzVector & p4probe);
148 static Interaction * MECCC (int tgt, int probe, double E=0);
149 static Interaction * MECCC (int tgt, int probe, const TLorentzVector & p4probe);
150 static Interaction * MECNC (int tgt, int nuccluster, int probe, double E=0);
151 static Interaction * MECNC (int tgt, int nuccluster, int probe, const TLorentzVector & p4probe);
152 static Interaction * MECEM (int tgt, int nuccluster, int probe, double E=0);
153 static Interaction * MECEM (int tgt, int probe, double E=0);
154 static Interaction * MECEM (int tgt, int nuccluster, int probe, const TLorentzVector & p4probe);
155 static Interaction * GLR (int tgt, double E=0);
156 static Interaction * GLR (int tgt, const TLorentzVector & p4probe);
157 static Interaction * NDecay (int tgt, int decay_mode=-1, int decayed_nucleon = 0);
158 static Interaction * NOsc (int tgt, int annihilation_mode=-1);
159 static Interaction * ASK (int tgt, int probe, double E=0);
160 static Interaction * ASK (int tgt, int probe, const TLorentzVector & p4probe);
161 static Interaction * DME (int tgt, int nuc, int probe, double E=0);
162 static Interaction * DME (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
163 static Interaction * DMDI (int tgt, int nuc, int probe, double E=0);
164 static Interaction * DMDI (int tgt, int nuc, int qrk, bool sea, int probe, double E=0);
165 static Interaction * DMDI (int tgt, int nuc, int probe, const TLorentzVector & p4probe);
166 static Interaction * DMDI (int tgt, int nuc, int qrk, bool sea, int probe, const TLorentzVector & p4probe);
167 static Interaction * HNL (int probe, double E=0, int decayed_mode=-1);
168
169private:
170
171 // Methods for Interaction initialization and clean up
172 void Init (void);
173 void CleanUp (void);
174
175 // Utility method for "named ctor"
176 static Interaction * Create(int tgt, int probe, ScatteringType_t st, InteractionType_t it);
177
178 // Private data members
179 InitialState * fInitialState; ///< Initial State info
180 ProcessInfo * fProcInfo; ///< Process info (scattering, weak current,...)
181 Kinematics * fKinematics; ///< kinematical variables
182 XclsTag * fExclusiveTag; ///< Additional info for exclusive channels
183 KPhaseSpace * fKinePhSp; ///< Kinematic phase space
184
185ClassDef(Interaction,2)
186};
187
188} // genie namespace
189
190#endif // _INTERACTION_H_
Initial State information.
Summary information for an interaction.
Definition Interaction.h:56
string AsString(void) const
void Copy(const Interaction &i)
TParticlePDG * RecoilNucleon(void) const
recoil nucleon
const XclsTag & ExclTag(void) const
Definition Interaction.h:72
static Interaction * MECCC(int tgt, int nuccluster, int probe, double E=0)
static Interaction * MECNC(int tgt, int nuccluster, int probe, double E=0)
static Interaction * DISEM(int tgt, int nuc, int probe, double E=0)
static Interaction * DMDI(int tgt, int nuc, int probe, double E=0)
void SetInitState(const InitialState &init)
ProcessInfo * fProcInfo
Process info (scattering, weak current,...)
ProcessInfo * ProcInfoPtr(void) const
Definition Interaction.h:75
InitialState * InitStatePtr(void) const
Definition Interaction.h:74
const Kinematics & Kine(void) const
Definition Interaction.h:71
static Interaction * DISNC(int tgt, int nuc, int probe, double E=0)
static Interaction * ASK(int tgt, int probe, double E=0)
static Interaction * Create(int tgt, int probe, ScatteringType_t st, InteractionType_t it)
static Interaction * DME(int tgt, int nuc, int probe, double E=0)
void SetProcInfo(const ProcessInfo &proc)
static Interaction * NOsc(int tgt, int annihilation_mode=-1)
int RecoilNucleonPdg(void) const
recoil nucleon pdg
int FSPrimLeptonPdg(void) const
final state primary lepton pdg
static Interaction * RESCC(int tgt, int nuc, int probe, double E=0)
XclsTag * fExclusiveTag
Additional info for exclusive channels.
static Interaction * MECEM(int tgt, int nuccluster, int probe, double E=0)
static Interaction * CEvNS(int tgt, int probe, double E=0)
void SetKine(const Kinematics &kine)
static Interaction * QELCC(int tgt, int nuc, int probe, double E=0)
Interaction & operator=(const Interaction &i)
copy
XclsTag * ExclTagPtr(void) const
Definition Interaction.h:77
Kinematics * fKinematics
kinematical variables
KPhaseSpace * fKinePhSp
Kinematic phase space.
KPhaseSpace * PhaseSpacePtr(void) const
Definition Interaction.h:78
static Interaction * QELEM(int tgt, int nuc, int probe, double E=0)
static Interaction * RESNC(int tgt, int nuc, int probe, double E=0)
static Interaction * DISCC(int tgt, int nuc, int probe, double E=0)
static Interaction * COHNC(int tgt, int probe, unsigned int prod_pdg, double E=0)
static Interaction * IMD(int tgt, double E=0)
static Interaction * NDecay(int tgt, int decay_mode=-1, int decayed_nucleon=0)
const ProcessInfo & ProcInfo(void) const
Definition Interaction.h:70
static Interaction * DFRCC(int tgt, int nuc, int probe, double E=0)
static Interaction * QELNC(int tgt, int nuc, int probe, double E=0)
static Interaction * IBD(int tgt, int nuc, int probe, double E=0)
static Interaction * AMNuGamma(int tgt, int nuc, int probe, double E=0)
static Interaction * RESEM(int tgt, int nuc, int probe, double E=0)
static Interaction * HNL(int probe, double E=0, int decayed_mode=-1)
InitialState * fInitialState
Initial State info.
TParticlePDG * FSPrimLepton(void) const
final state primary lepton
void SetExclTag(const XclsTag &xcls)
const KPhaseSpace & PhaseSpace(void) const
Definition Interaction.h:73
void Print(ostream &stream) const
friend ostream & operator<<(ostream &stream, const Interaction &i)
print
const InitialState & InitState(void) const
Definition Interaction.h:69
static Interaction * GLR(int tgt, double E=0)
Kinematics * KinePtr(void) const
Definition Interaction.h:76
static Interaction * COHCC(int tgt, int probe, unsigned int prod_pdg, double E=0)
Kinematical phase space.
Definition KPhaseSpace.h:33
Generated/set kinematical variables for an event.
Definition Kinematics.h:39
A class encapsulating an enumeration of interaction types (EM, Weak-CC, Weak-NC) and scattering types...
Definition ProcessInfo.h:46
Contains minimal information for tagging exclusive processes.
Definition XclsTag.h:39
THE MAIN GENIE PROJECT NAMESPACE
Definition AlgCmp.h:25
const UInt_t kIAssumeFreeElectron
Definition Interaction.h:50
enum genie::EInteractionType InteractionType_t
const UInt_t kINoNuclearCorrection
if set, inhibit nuclear corrections
Definition Interaction.h:51
const UInt_t kISkipKinematicChk
if set, skip kinematic validity checks
Definition Interaction.h:48
enum genie::EScatteringType ScatteringType_t
const UInt_t kISkipProcessChk
if set, skip process validity checks
Definition Interaction.h:47
ostream & operator<<(ostream &stream, const AlgConfigPool &config_pool)
const UInt_t kIAssumeFreeNucleon
Definition Interaction.h:49