19 #include <TRootIOCtor.h> 28 using namespace genie;
32 using std::ostringstream;
40 interaction.
Print(stream);
64 this->
Copy(interaction);
142 LOG(
"Interaction",
pDEBUG) <<
"Probe PDG code: " << pdgc;
169 <<
"Could not figure out the final state primary lepton pdg code!!";
196 assert(struck_is_nuc && (is_weak || is_em || is_dm));
200 recoil_nuc = struck_nuc;
208 assert(struck_is_2nuc_cluster && (is_weak || is_em));
213 int dQ = (isnu) ? +1 : -1;
217 recoil_nuc = struck_nuc;
221 LOG(
"Interaction",
pDEBUG) <<
"Recoil nucleon PDG = " << recoil_nuc;
262 interaction <<
"dm;";
265 interaction <<
"dmb;";
270 interaction <<
"tgt:" << tgt.
Pdg() <<
";";
273 interaction <<
"N:" << tgt.
HitNucPdg() <<
";";
277 << (tgt.
HitSeaQrk() ?
"(s)" :
"(v)") <<
";";
285 if(xcls.size()>0) interaction <<
";";
287 return interaction.str();
292 const string line(110,
'-');
295 stream << line <<
endl;
297 stream <<
"GENIE Interaction Summary" <<
endl;
298 stream << line <<
endl;
305 stream << line <<
endl;
310 this->
Copy(interaction);
341 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
double E)
346 tgt -> SetHitQrkPdg (hitqrk);
347 tgt -> SetHitSeaQrk (fromsea);
353 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int fqrk,
int probe,
double E)
358 tgt -> SetHitQrkPdg (hitqrk);
359 tgt -> SetHitSeaQrk (fromsea);
368 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
381 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
382 const TLorentzVector & p4probe)
387 tgt -> SetHitQrkPdg (hitqrk);
388 tgt -> SetHitSeaQrk (fromsea);
406 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
double E)
411 tgt -> SetHitQrkPdg (hitqrk);
412 tgt -> SetHitSeaQrk (fromsea);
418 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int fqrk,
int probe,
double E)
423 tgt -> SetHitQrkPdg (hitqrk);
424 tgt -> SetHitSeaQrk (fromsea);
433 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
446 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
447 const TLorentzVector & p4probe)
452 tgt -> SetHitQrkPdg (hitqrk);
453 tgt -> SetHitSeaQrk (fromsea);
471 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
double E)
476 tgt -> SetHitQrkPdg (hitqrk);
477 tgt -> SetHitSeaQrk (fromsea);
483 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
496 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
497 const TLorentzVector & p4probe)
502 tgt -> SetHitQrkPdg (hitqrk);
503 tgt -> SetHitSeaQrk (fromsea);
521 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
546 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
571 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
596 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
621 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
646 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
671 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
696 int tgt,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
726 int tgt,
int probe,
unsigned int prod_pdg,
const TLorentzVector & p4probe)
749 if (
pdg::IsPion( prod_pdg ) ) xcl -> SetNPions( 0,1,0 ) ;
750 else if ( prod_pdg ==
kPdgGamma ) xcl -> SetNSingleGammas(1) ;
759 int tgt,
int probe,
unsigned int prod_pdg,
const TLorentzVector & p4probe)
765 if (
pdg::IsPion( prod_pdg ) ) xcl -> SetNPions( 0,1,0 ) ;
766 else if ( prod_pdg ==
kPdgGamma ) xcl -> SetNSingleGammas(1) ;
786 int tgt,
int probe,
const TLorentzVector & p4probe)
832 int tgt,
int nuc,
int probe,
const TLorentzVector & p4probe)
857 int tgt,
int ncluster,
int probe,
const TLorentzVector & p4probe)
881 int tgt,
int probe,
const TLorentzVector & p4probe)
906 int tgt,
int ncluster,
int probe,
const TLorentzVector & p4probe)
943 int tgt,
int ncluster,
int probe,
const TLorentzVector & p4probe)
1023 int tgt,
int probe,
const TLorentzVector & p4probe)
1048 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
1074 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
double E)
1079 tgt -> SetHitQrkPdg (hitqrk);
1080 tgt -> SetHitSeaQrk (fromsea);
1086 int target,
int hitnuc,
int probe,
const TLorentzVector & p4probe)
1099 int target,
int hitnuc,
int hitqrk,
bool fromsea,
int probe,
1100 const TLorentzVector & p4probe)
1105 tgt -> SetHitQrkPdg (hitqrk);
1106 tgt -> SetHitSeaQrk (fromsea);
static Interaction * IMD(int tgt, double E=0)
bool IsWeakMix(void) const
bool HitSeaQrk(void) const
bool IsWeakCC(void) const
int FinalLeptonPdg(void) const
bool IsNeutrino(int pdgc)
void SetProbeP4(const TLorentzVector &P4)
THE MAIN GENIE PROJECT NAMESPACE
static Interaction * DME(int tgt, int nuc, int probe, double E=0)
string ScatteringTypeAsString(void) const
static Interaction * GLR(int tgt, double E=0)
int HitNucPdg(void) const
TParticlePDG * RecoilNucleon(void) const
recoil nucleon
bool IsDarkNeutralCurrent(void) const
int RecoilNucleonPdg(void) const
recoil nucleon pdg
int HitQrkPdg(void) const
InitialState * fInitialState
Initial State info.
bool IsQuasiElastic(void) const
static Interaction * CEvNS(int tgt, int probe, double E=0)
Generated/set kinematical variables for an event.
int SwitchProtonNeutron(int pdgc)
void Copy(const XclsTag &xcls)
copy input XclsTag object
bool IsInverseBetaDecay(void) const
TParticlePDG * Probe(void) const
static Interaction * IBD(int tgt, int nuc, int probe, double E=0)
static Interaction * NDecay(int tgt, int decay_mode=-1, int decayed_nucleon=0)
bool IsIMDAnnihilation(void) const
void SetKine(const Kinematics &kine)
XclsTag * fExclusiveTag
Additional info for exclusive channels.
static Interaction * QELCC(int tgt, int nuc, int probe, double E=0)
static Interaction * MECNC(int tgt, int nuccluster, int probe, double E=0)
string AsString(void) const
static Interaction * RESNC(int tgt, int nuc, int probe, double E=0)
static Interaction * COHCC(int tgt, int probe, unsigned int prod_pdg, double E=0)
Contains minimal information for tagging exclusive processes.
int FSPrimLeptonPdg(void) const
final state primary lepton pdg
int ModifyNucleonCluster(int pdgc, int dQ)
Summary information for an interaction.
static Interaction * DMDI(int tgt, int nuc, int probe, double E=0)
static Interaction * RESEM(int tgt, int nuc, int probe, double E=0)
bool IsWeakNC(void) const
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE...
bool IsNuElectronElastic(void) const
void Copy(const InitialState &init_state)
const int kPdgAntiDarkMatter
string AsString(void) const
pack into a string code
static Interaction * MECEM(int tgt, int nuccluster, int probe, double E=0)
static Interaction * QELNC(int tgt, int nuc, int probe, double E=0)
A class encapsulating an enumeration of interaction types (EM, Weak-CC, Weak-NC) and scattering types...
void Copy(const Kinematics &kine)
bool IsAntiNeutrino(int pdgc)
A Neutrino Interaction Target. Is a transparent encapsulation of quite different physical systems suc...
string InteractionTypeAsString(void) const
bool IsDarkMatterElastic(void) const
void Copy(const Interaction &i)
void SetDecayMode(int decay_mode)
TParticlePDG * FSPrimLepton(void) const
final state primary lepton
XclsTag * ExclTagPtr(void) const
bool Is2NucleonCluster(int pdgc)
void SetExclTag(const XclsTag &xcls)
Kinematics * fKinematics
kinematical variables
static PDGLibrary * Instance(void)
static Interaction * ASK(int tgt, int probe, double E=0)
bool HitNucIsSet(void) const
bool HitQrkIsSet(void) const
void Print(ostream &stream) const
static Interaction * QELEM(int tgt, int nuc, int probe, double E=0)
enum genie::EScatteringType ScatteringType_t
ostream & operator<<(ostream &stream, const AlgConfigPool &config_pool)
bool IsDarkMatter(void) const
void SetHitNucPdg(int pdgc)
const XclsTag & ExclTag(void) const
void line(double t, double *p, double &x, double &y, double &z)
static Interaction * DISCC(int tgt, int nuc, int probe, double E=0)
Target * TgtPtr(void) const
static Interaction * DFRCC(int tgt, int nuc, int probe, double E=0)
int Neutrino2ChargedLepton(int pdgc)
InitialState * InitStatePtr(void) const
const InitialState & InitState(void) const
const ProcessInfo & ProcInfo(void) const
ClassImp(Interaction) namespace genie
Interaction & operator=(const Interaction &i)
copy
TParticlePDG * Find(int pdgc, bool must_exist=true)
ProcessInfo * fProcInfo
Process info (scattering, weak current,...)
const Target & Tgt(void) const
static Interaction * NHL(double E=0, int decayed_mode=-1)
static Interaction * RESCC(int tgt, int nuc, int probe, double E=0)
bool IsGlashowResonance(void) const
static Interaction * MECCC(int tgt, int nuccluster, int probe, double E=0)
static Interaction * COHNC(int tgt, int probe, unsigned int prod_pdg, double E=0)
void SetFinalQuark(int finalquark_pdgc=0)
static Interaction * DISEM(int tgt, int nuc, int probe, double E=0)
static Interaction * Create(int tgt, int probe, ScatteringType_t st, InteractionType_t it)
const int kPdgDarkNeutrino
Most commonly used PDG codes. A set of utility functions to handle PDG codes is provided in PDGUtils...
enum genie::EInteractionType InteractionType_t
void SetInitState(const InitialState &init)
static Interaction * AMNuGamma(int tgt, int nuc, int probe, double E=0)
void SetProcInfo(const ProcessInfo &proc)
void Copy(const ProcessInfo &proc)
bool IsElectron(int pdgc)
QTextStream & endl(QTextStream &s)
KPhaseSpace * fKinePhSp
Kinematic phase space.
static Interaction * NOsc(int tgt, int annihilation_mode=-1)
static Interaction * DISNC(int tgt, int nuc, int probe, double E=0)
Initial State information.