GENIEGenerator
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Member Functions | List of all members
genie::IBDHadronicSystemGenerator Class Reference

Generates the final state hadronic system in v IBD interactions. Is a concrete implementation of the EventRecordVisitorI interface. More...

#include <IBDHadronicSystemGenerator.h>

Inheritance diagram for genie::IBDHadronicSystemGenerator:
Inheritance graph
[legend]
Collaboration diagram for genie::IBDHadronicSystemGenerator:
Collaboration graph
[legend]

Public Member Functions

 IBDHadronicSystemGenerator ()
 
 IBDHadronicSystemGenerator (string config)
 
virtual ~IBDHadronicSystemGenerator ()
 
void ProcessEventRecord (GHepRecord *event_rec) const
 
- Public Member Functions inherited from genie::HadronicSystemGenerator
void AddTargetNucleusRemnant (GHepRecord *event_rec) const
 
void AddFinalHadronicSyst (GHepRecord *event_rec) const
 
void PreHadronTransportDecays (GHepRecord *event_rec) const
 
TLorentzVector Hadronic4pLAB (GHepRecord *event_rec) const
 
TLorentzVector MomentumTransferLAB (GHepRecord *event_rec) const
 
TVector3 HCM2LAB (GHepRecord *event_rec) const
 
int HadronShowerCharge (GHepRecord *event_rec) const
 
int ResonanceCharge (GHepRecord *event_rec) const
 
- Public Member Functions inherited from genie::EventRecordVisitorI
virtual ~EventRecordVisitorI ()
 
- Public Member Functions inherited from genie::Algorithm
virtual ~Algorithm ()
 
virtual void Configure (const Registry &config)
 
virtual void Configure (string config)
 
virtual void FindConfig (void)
 
virtual const RegistryGetConfig (void) const
 
RegistryGetOwnedConfig (void)
 
virtual const AlgIdId (void) const
 Get algorithm ID. More...
 
virtual AlgStatus_t GetStatus (void) const
 Get algorithm status. More...
 
virtual bool AllowReconfig (void) const
 
virtual AlgCmp_t Compare (const Algorithm *alg) const
 Compare with input algorithm. More...
 
virtual void SetId (const AlgId &id)
 Set algorithm ID. More...
 
virtual void SetId (string name, string config)
 
const AlgorithmSubAlg (const RgKey &registry_key) const
 
void AdoptConfig (void)
 
void AdoptSubstructure (void)
 
virtual void Print (ostream &stream) const
 Print algorithm info. More...
 

Private Member Functions

void AddRecoilBaryon (GHepRecord *event_rec) const
 

Additional Inherited Members

- Static Public Member Functions inherited from genie::Algorithm
static string BuildParamVectKey (const std::string &comm_name, unsigned int i)
 
static string BuildParamVectSizeKey (const std::string &comm_name)
 
static string BuildParamMatKey (const std::string &comm_name, unsigned int i, unsigned int j)
 
static string BuildParamMatRowSizeKey (const std::string &comm_name)
 
static string BuildParamMatColSizeKey (const std::string &comm_name)
 
- Protected Member Functions inherited from genie::HadronicSystemGenerator
 HadronicSystemGenerator ()
 
 HadronicSystemGenerator (string name)
 
 HadronicSystemGenerator (string name, string config)
 
 ~HadronicSystemGenerator ()
 
- Protected Member Functions inherited from genie::EventRecordVisitorI
 EventRecordVisitorI ()
 
 EventRecordVisitorI (string name)
 
 EventRecordVisitorI (string name, string config)
 
- Protected Member Functions inherited from genie::Algorithm
 Algorithm ()
 
 Algorithm (string name)
 
 Algorithm (string name, string config)
 
void Initialize (void)
 
void DeleteConfig (void)
 
void DeleteSubstructure (void)
 
RegistryExtractLocalConfig (const Registry &in) const
 
RegistryExtractLowerConfig (const Registry &in, const string &alg_key) const
 Split an incoming configuration Registry into a block valid for the sub-algo identified by alg_key. More...
 
template<class T >
bool GetParam (const RgKey &name, T &p, bool is_top_call=true) const
 
template<class T >
bool GetParamDef (const RgKey &name, T &p, const T &def) const
 
template<class T >
int GetParamVect (const std::string &comm_name, std::vector< T > &v, bool is_top_call=true) const
 Handle to load vectors of parameters. More...
 
int GetParamVectKeys (const std::string &comm_name, std::vector< RgKey > &k, bool is_top_call=true) const
 
template<class T >
int GetParamMat (const std::string &comm_name, TMatrixT< T > &mat, bool is_top_call=true) const
 Handle to load matrix of parameters. More...
 
template<class T >
int GetParamMatSym (const std::string &comm_name, TMatrixTSym< T > &mat, bool is_top_call=true) const
 
int GetParamMatKeys (const std::string &comm_name, std::vector< RgKey > &k, bool is_top_call=true) const
 
int AddTopRegistry (Registry *rp, bool owns=true)
 add registry with top priority, also update ownership More...
 
int AddLowRegistry (Registry *rp, bool owns=true)
 add registry with lowest priority, also update ownership More...
 
int MergeTopRegistry (const Registry &r)
 
int AddTopRegisties (const vector< Registry * > &rs, bool owns=false)
 Add registries with top priority, also udated Ownerships. More...
 
- Protected Attributes inherited from genie::HadronicSystemGenerator
const EventRecordVisitorIfPreINukeDecayer
 
- Protected Attributes inherited from genie::Algorithm
bool fAllowReconfig
 
bool fOwnsSubstruc
 true if it owns its substructure (sub-algs,...) More...
 
AlgId fID
 algorithm name and configuration set More...
 
vector< Registry * > fConfVect
 
vector< bool > fOwnerships
 ownership for every registry in fConfVect More...
 
AlgStatus_t fStatus
 algorithm execution status More...
 
AlgMapfOwnedSubAlgMp
 local pool for owned sub-algs (taken out of the factory pool) More...
 

Detailed Description

Generates the final state hadronic system in v IBD interactions. Is a concrete implementation of the EventRecordVisitorI interface.

Author
Corey Reed <cjreed nikhef.nl> - October 29, 2009 using code from the QELKinematicGenerator written by Costas Andreopoulos <c.andreopoulos cern.ch> University of Liverpool
Created:
October 29, 2009
License:
Copyright (c) 2003-2024, The GENIE Collaboration For the full text of the license visit http://copyright.genie-mc.org

Definition at line 29 of file IBDHadronicSystemGenerator.h.

Constructor & Destructor Documentation

IBDHadronicSystemGenerator::IBDHadronicSystemGenerator ( )

Definition at line 29 of file IBDHadronicSystemGenerator.cxx.

29  :
30 HadronicSystemGenerator("genie::IBDHadronicSystemGenerator")
31 {
32 
33 }
IBDHadronicSystemGenerator::IBDHadronicSystemGenerator ( string  config)

Definition at line 35 of file IBDHadronicSystemGenerator.cxx.

35  :
36 HadronicSystemGenerator("genie::IBDHadronicSystemGenerator", config)
37 {
38 
39 }
IBDHadronicSystemGenerator::~IBDHadronicSystemGenerator ( )
virtual

Definition at line 41 of file IBDHadronicSystemGenerator.cxx.

42 {
43 
44 }

Member Function Documentation

void IBDHadronicSystemGenerator::AddRecoilBaryon ( GHepRecord event_rec) const
private

Definition at line 57 of file IBDHadronicSystemGenerator.cxx.

References genie::GHepRecord::AddParticle(), genie::HadronicSystemGenerator::Hadronic4pLAB(), genie::GHepRecord::HitNucleonPosition(), genie::Interaction::InitState(), genie::Target::IsNucleus(), genie::kIStHadronInTheNucleus, genie::kIStStableFinalState, LOG, genie::GHepRecord::Particle(), pINFO, genie::GHepRecord::Probe(), genie::Interaction::RecoilNucleonPdg(), genie::GHepParticle::RemovalEnergy(), genie::GHepParticle::SetRemovalEnergy(), genie::GHepRecord::Summary(), genie::InitialState::Tgt(), and genie::GHepParticle::X4().

Referenced by ProcessEventRecord().

58 {
59  //-- Determine the pdg & status code of the recoil baryon
60  Interaction * interaction = evrec->Summary();
61  const int pdgc = interaction->RecoilNucleonPdg();
62  assert(pdgc!=0);
63 
64  //-- Determine the status code
65  const Target & tgt = interaction->InitState().Tgt();
66  const GHepStatus_t ist = (tgt.IsNucleus()) ?
68 
69  //-- Get the vtx position
70  const GHepParticle * neutrino = evrec->Probe();
71  const TLorentzVector & vtx = *(neutrino->X4());
72 
73  //-- Get nucleon 4-momentum (in the LAB frame) & position
74  const TLorentzVector p4 = this->Hadronic4pLAB(evrec);
75 
76  //-- Get mother position
77  const int mom = evrec->HitNucleonPosition();
78 
79  //-- Add the final state recoil baryon at the EventRecord
80  LOG("IBD", pINFO)
81  << "Adding recoil baryon [pdgc = " << pdgc << "]";
82 
83  GHepParticle p(pdgc, ist, mom,-1,-1,-1, p4, vtx);
84  const double w = evrec->Particle(mom)->RemovalEnergy();
85  p.SetRemovalEnergy(w);
86  evrec->AddParticle(p);
87 }
TLorentzVector Hadronic4pLAB(GHepRecord *event_rec) const
int RecoilNucleonPdg(void) const
recoil nucleon pdg
bool IsNucleus(void) const
Definition: Target.cxx:272
Summary information for an interaction.
Definition: Interaction.h:56
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE...
Definition: Messenger.h:96
A Neutrino Interaction Target. Is a transparent encapsulation of quite different physical systems suc...
Definition: Target.h:40
#define pINFO
Definition: Messenger.h:62
const TLorentzVector * X4(void) const
Definition: GHepParticle.h:79
const InitialState & InitState(void) const
Definition: Interaction.h:69
const Target & Tgt(void) const
Definition: InitialState.h:66
STDHEP-like event record entry that can fit a particle or a nucleus.
Definition: GHepParticle.h:39
enum genie::EGHepStatus GHepStatus_t
void IBDHadronicSystemGenerator::ProcessEventRecord ( GHepRecord event_rec) const
virtual

Implements genie::EventRecordVisitorI.

Definition at line 46 of file IBDHadronicSystemGenerator.cxx.

References AddRecoilBaryon().

47 {
48 // This method generates the final state hadronic system
49 
50  // Add the recoil baryon
51  // (p or n)
52  // Its 4-momentum is computed by requiring the energy + momentum to be
53  // conserved.
54  this->AddRecoilBaryon(evrec);
55 }
void AddRecoilBaryon(GHepRecord *event_rec) const

The documentation for this class was generated from the following files: