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

A GENIE flux container specific for HNL containers. Based on the dk2nu flux paradigm and genie::flux::GNuMIFluxPassThroughInfo. More...

#include <HNLFluxContainer.h>

Inheritance diagram for genie::hnl::FluxContainer:
Inheritance graph
[legend]
Collaboration diagram for genie::hnl::FluxContainer:
Collaboration graph
[legend]

Public Member Functions

 FluxContainer ()
 
virtual ~FluxContainer ()
 
void ResetCopy () const
 
void Print (const Option_t *) const
 

Public Attributes

int evtno
 Event number. More...
 
int pdg
 HNL PDG code. More...
 
int parPdg
 parent PDG code More...
 
int lepPdg
 PDG code of lepton produced with HNL on parent decay. More...
 
int nuPdg
 PDG code of SM neutrino that would have been produced. More...
 
int prodChan
 Decay mode that produced HNL. More...
 
int nuProdChan
 Decay mode that would have produced SM neutrino. More...
 
TVector3 startPoint
 parent decay vertex in NEAR coords [m] More...
 
TVector3 targetPoint
 point in detector HNL is forced towards in NEAR coords [m] More...
 
TVector3 startPointUser
 parent decay vertex in USER coords [m] More...
 
TVector3 targetPointUser
 point in detector HNL is forced towards in USER coords [m] More...
 
double delay
 delay HNL would have wrt SMv [ns] More...
 
TVector3 polz
 HNL polarisation vector, in HNL rest frame, in NEAR coords. More...
 
TLorentzVector p4
 HNL momentum in NEAR coords [GeV/c]. More...
 
TLorentzVector parp4
 parent momentum at HNL production in NEAR coords [GeV/c] More...
 
TLorentzVector p4User
 HNL momentum in USER coords [GeV/c]. More...
 
TLorentzVector parp4User
 parent momentum at HNL production in USER coords [GeV/c] More...
 
double Ecm
 Parent rest-frame energy of HNL [GeV]. More...
 
double nuEcm
 Parent rest-frame energy of equivalent SM neutrino [GeV]. More...
 
double XYWgt
 geometric acceptance (angular size of detector in parent rest frame) More...
 
double boostCorr
 boost correction wrt parent rest-frame (ELAB = ECM * boostCorr) More...
 
double accCorr
 acceptance correction (collimation effect. SM v == 1) More...
 
double zetaMinus
 minimum angular deviation from parent momentum to reach detector [deg] More...
 
double zetaPlus
 maximum angular deviation from parent momentum to reach detector [deg] More...
 
double acceptance
 full acceptance == XYWgt * boostCorr^2 * accCorr More...
 
double nimpwt
 Weight of parent. More...
 

Friends

ostream & operator<< (ostream &stream, const FluxContainer &gnmf)
 

Detailed Description

A GENIE flux container specific for HNL containers. Based on the dk2nu flux paradigm and genie::flux::GNuMIFluxPassThroughInfo.

FluxContainer:

A C-struct that is based on the flux::GNuMIFluxPassThroughInfo struct, but which is not GNuMI specific. Accepts enough information about the HNL fluxes and the base flux to pass all the necessary

information to the hnl::FluxCreator class for flux calculations.

      Also see $GENIE/src/contrib/beamhnl/write_dk2nus.C for an example of 
      expected flux-input structure
Author
John Plows
Created:
Feb 16, 2023
License:
Copyright (c) 2003-2024, The GENIE Collaboration For the full text of the license visit http://copyright.genie-mc.org

Definition at line 62 of file HNLFluxContainer.h.

Constructor & Destructor Documentation

FluxContainer::FluxContainer ( )

Definition at line 61 of file HNLFluxContainer.cxx.

References ResetCopy().

62  : TObject()
63 {
64  this->ResetCopy();
65 }
virtual genie::hnl::FluxContainer::~FluxContainer ( )
inlinevirtual

Definition at line 66 of file HNLFluxContainer.h.

66 {};

Member Function Documentation

void FluxContainer::Print ( const Option_t *  ) const

Definition at line 107 of file HNLFluxContainer.cxx.

108 {
109  std::cout << *this << std::endl;
110 }
void FluxContainer::ResetCopy ( ) const

Definition at line 68 of file HNLFluxContainer.cxx.

References accCorr, acceptance, boostCorr, delay, Ecm, evtno, lepPdg, nimpwt, nuEcm, nuPdg, nuProdChan, p4, p4User, parp4, parp4User, parPdg, pdg, polz, prodChan, startPoint, startPointUser, targetPoint, targetPointUser, XYWgt, zetaMinus, and zetaPlus.

Referenced by FluxContainer().

69 {
70  evtno = 0;
71 
72  pdg = 0;
73  parPdg = 0;
74  lepPdg = 0;
75  nuPdg = 0;
76 
77  prodChan = 0;
78  nuProdChan = 0;
79 
80  startPoint.SetXYZ(0.0, 0.0, 0.0);
81  targetPoint.SetXYZ(0.0, 0.0, 0.0);
82  startPointUser.SetXYZ(0.0, 0.0, 0.0);
83  targetPointUser.SetXYZ(0.0, 0.0, 0.0);
84  delay = 0.0;
85 
86  polz.SetXYZ(0.0, 0.0, 0.0);
87 
88  p4.SetPxPyPzE(0.0, 0.0, 0.0, 0.0);
89  parp4.SetPxPyPzE(0.0, 0.0, 0.0, 0.0);
90  p4User.SetPxPyPzE(0.0, 0.0, 0.0, 0.0);
91  parp4User.SetPxPyPzE(0.0, 0.0, 0.0, 0.0);
92 
93  Ecm = 0.0;
94  nuEcm = 0.0;
95 
96  XYWgt = 0.0;
97  boostCorr = 0.0;
98  accCorr = 0.0;
99  zetaMinus = 0.0;
100  zetaPlus = 0.0;
101  acceptance = 0.0;
102 
103  nimpwt = 0.0;
104 }
TLorentzVector parp4
parent momentum at HNL production in NEAR coords [GeV/c]
double Ecm
Parent rest-frame energy of HNL [GeV].
double zetaMinus
minimum angular deviation from parent momentum to reach detector [deg]
double nuEcm
Parent rest-frame energy of equivalent SM neutrino [GeV].
double delay
delay HNL would have wrt SMv [ns]
TVector3 startPoint
parent decay vertex in NEAR coords [m]
int lepPdg
PDG code of lepton produced with HNL on parent decay.
TVector3 polz
HNL polarisation vector, in HNL rest frame, in NEAR coords.
int parPdg
parent PDG code
double zetaPlus
maximum angular deviation from parent momentum to reach detector [deg]
TVector3 startPointUser
parent decay vertex in USER coords [m]
TLorentzVector parp4User
parent momentum at HNL production in USER coords [GeV/c]
TLorentzVector p4
HNL momentum in NEAR coords [GeV/c].
TLorentzVector p4User
HNL momentum in USER coords [GeV/c].
int prodChan
Decay mode that produced HNL.
double acceptance
full acceptance == XYWgt * boostCorr^2 * accCorr
TVector3 targetPointUser
point in detector HNL is forced towards in USER coords [m]
TVector3 targetPoint
point in detector HNL is forced towards in NEAR coords [m]
double nimpwt
Weight of parent.
double accCorr
acceptance correction (collimation effect. SM v == 1)
int nuPdg
PDG code of SM neutrino that would have been produced.
double XYWgt
geometric acceptance (angular size of detector in parent rest frame)
int nuProdChan
Decay mode that would have produced SM neutrino.
double boostCorr
boost correction wrt parent rest-frame (ELAB = ECM * boostCorr)

Friends And Related Function Documentation

ostream& operator<< ( ostream &  stream,
const FluxContainer gnmf 
)
friend

Definition at line 115 of file HNLFluxContainer.cxx.

117  {
118  // convert some stuff to string
119  HNLProd_t hProdChan = static_cast<HNLProd_t>(info.prodChan);
120 
121  std::string sNuProdChan;
122  int typeMod = (info.pdg > 0) ? 1 : -1;
123  int switchChan = typeMod * info.nuProdChan;
124  switch(switchChan){
125  case 1: sNuProdChan = std::string("K0L -> nue + pi- + e+"); break;
126  case -1: sNuProdChan = std::string("K0L -> nuebar + pi+ + e-"); break;
127  case 2: sNuProdChan = std::string("K0L -> numu + pi- + mu"); break;
128  case -2: sNuProdChan = std::string("K0L -> numubar + pi+ + mu-"); break;
129  case 3: sNuProdChan = std::string("K+ -> numu + mu+"); break;
130  case -3: sNuProdChan = std::string("K- -> numubar + mu-"); break;
131  case 4: sNuProdChan = std::string("K+ -> nue + e+"); break;
132  case -4: sNuProdChan = std::string("K- -> nuebar + e-"); break;
133  case 5: sNuProdChan = std::string("K+ -> numu + pi0 + mu+"); break;
134  case -5: sNuProdChan = std::string("K- -> numubar + pi0 + mu-"); break;
135  case 6: sNuProdChan = std::string("K+ -> nue + pi0 + e+"); break;
136  case -6: sNuProdChan = std::string("K- -> nuebar + pi0 + e-"); break;
137  case 7: sNuProdChan = std::string("pi+ -> numu + mu+"); break;
138  case -7: sNuProdChan = std::string("pi- -> numubar + mu-"); break;
139  case 8: sNuProdChan = std::string("pi+ -> nue + e+"); break;
140  case -8: sNuProdChan = std::string("pi- -> nuebar + e-"); break;
141  case 9: sNuProdChan = std::string("mu- -> numu + nuebar + e-"); break;
142  case -9: sNuProdChan = std::string("mu+ -> numubar + nue + e+"); break;
143  default: sNuProdChan = std::string("Unknown!"); break;
144  }
145 
146  stream << "\nEvent number: " << info.evtno
147  << "\nHNL PDG code: " << info.pdg
148  << "\nParent PDG code: " << info.parPdg
149  << "\nCo-produced lepton PDG code: " << info.lepPdg
150  << "\nParent weight: " << info.nimpwt
151  << "\nHNL polarisation vector [HNL rest frame, NEAR coords]: " << utils::print::Vec3AsString(&info.polz)
152  << "\nPDG code of equivalent SM neutrino: " << info.nuPdg
153  << "\nProduction channel: " << utils::hnl::ProdAsString(hProdChan)
154  << " ; code " << info.prodChan
155  << "\nEquivalent neutrino production channel: " << sNuProdChan
156  << " ; code " << info.nuProdChan
157  << "\nHNL parent rest-frame energy [GeV]: " << info.Ecm
158  << "\nEquivalent neutrino parent rest-frame energy [GeV]: " << info.nuEcm
159  << "\nStart point [NEAR, m]: " << utils::print::Vec3AsString(&info.startPoint)
160  << "\nStart point [USER, m]: " << utils::print::Vec3AsString(&info.startPointUser)
161  << "\nFlux passes through point [NEAR, m]: " << utils::print::Vec3AsString(&info.targetPoint)
162  << "\nFlux passes through point [USER, m]: " << utils::print::Vec3AsString(&info.targetPointUser)
163  << "\nHNL momentum [NEAR, GeV]: " << utils::print::P4AsString(&info.p4)
164  << "\nHNL momentum [USER, GeV]: " << utils::print::P4AsString(&info.p4User)
165  << "\nHNL delay wrt SM neutrino [ns]: " << info.delay
166  << "\nParent momentum [NEAR, GeV]: " << utils::print::P4AsString(&info.parp4)
167  << "\nParent momentum [USER, GeV]: " << utils::print::P4AsString(&info.parp4User)
168  << "\nDeviation angles zeta- = " << info.zetaMinus << ", zeta+ = " << info.zetaPlus
169  << "\nGeometric acceptance: " << info.XYWgt
170  << "\nBoost correction: " << info.boostCorr
171  << "\nAcceptance correction: " << info.accCorr
172  << "\nFull acceptance: " << info.acceptance;
173 
174  return stream;
175  }
enum genie::hnl::t_HNLProd HNLProd_t
string P4AsString(const TLorentzVector *p)
Definition: PrintUtils.cxx:27
string ProdAsString(genie::hnl::HNLProd_t hnlprod)
string Vec3AsString(const TVector3 *vec)
Definition: PrintUtils.cxx:80

Member Data Documentation

double genie::hnl::FluxContainer::accCorr
mutable

acceptance correction (collimation effect. SM v == 1)

Definition at line 104 of file HNLFluxContainer.h.

Referenced by ConvertToGRooTracker(), genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

double genie::hnl::FluxContainer::acceptance
mutable
double genie::hnl::FluxContainer::boostCorr
mutable

boost correction wrt parent rest-frame (ELAB = ECM * boostCorr)

Definition at line 102 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

double genie::hnl::FluxContainer::delay
mutable
double genie::hnl::FluxContainer::Ecm
mutable

Parent rest-frame energy of HNL [GeV].

Definition at line 98 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

int genie::hnl::FluxContainer::evtno
mutable
int genie::hnl::FluxContainer::lepPdg
mutable
double genie::hnl::FluxContainer::nimpwt
mutable
double genie::hnl::FluxContainer::nuEcm
mutable

Parent rest-frame energy of equivalent SM neutrino [GeV].

Definition at line 99 of file HNLFluxContainer.h.

Referenced by ConvertToGRooTracker(), genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

int genie::hnl::FluxContainer::nuPdg
mutable

PDG code of SM neutrino that would have been produced.

Definition at line 80 of file HNLFluxContainer.h.

Referenced by ConvertToGRooTracker(), genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

int genie::hnl::FluxContainer::nuProdChan
mutable

Decay mode that would have produced SM neutrino.

Definition at line 83 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

TLorentzVector genie::hnl::FluxContainer::p4
mutable

HNL momentum in NEAR coords [GeV/c].

Definition at line 93 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

TLorentzVector genie::hnl::FluxContainer::p4User
mutable
TLorentzVector genie::hnl::FluxContainer::parp4
mutable

parent momentum at HNL production in NEAR coords [GeV/c]

Definition at line 94 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

TLorentzVector genie::hnl::FluxContainer::parp4User
mutable

parent momentum at HNL production in USER coords [GeV/c]

Definition at line 96 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

int genie::hnl::FluxContainer::parPdg
mutable
int genie::hnl::FluxContainer::pdg
mutable
TVector3 genie::hnl::FluxContainer::polz
mutable

HNL polarisation vector, in HNL rest frame, in NEAR coords.

Definition at line 91 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

int genie::hnl::FluxContainer::prodChan
mutable
TVector3 genie::hnl::FluxContainer::startPoint
mutable
TVector3 genie::hnl::FluxContainer::startPointUser
mutable

parent decay vertex in USER coords [m]

Definition at line 87 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

TVector3 genie::hnl::FluxContainer::targetPoint
mutable

point in detector HNL is forced towards in NEAR coords [m]

Definition at line 86 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

TVector3 genie::hnl::FluxContainer::targetPointUser
mutable

point in detector HNL is forced towards in USER coords [m]

Definition at line 88 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

double genie::hnl::FluxContainer::XYWgt
mutable

geometric acceptance (angular size of detector in parent rest frame)

Definition at line 101 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

double genie::hnl::FluxContainer::zetaMinus
mutable

minimum angular deviation from parent momentum to reach detector [deg]

Definition at line 105 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().

double genie::hnl::FluxContainer::zetaPlus
mutable

maximum angular deviation from parent momentum to reach detector [deg]

Definition at line 106 of file HNLFluxContainer.h.

Referenced by genie::hnl::FluxCreator::FillNonsense(), genie::hnl::FluxCreator::MakeTupleFluxEntry(), genie::hnl::operator<<(), and ResetCopy().


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