|
GENIEGenerator
|
A GENIE flux driver encapsulating the NuMI neutrino flux. It reads-in the official GNUMI neutrino flux ntuples. Supports both geant3 and geant4 formats. More...
#include <GNuMIFlux.h>
Public Types | |
| enum | EStdFluxWindow { kMinosNearDet , kMinosFarDet , kMinosNearRock , kMinosFarRock , kMinosNearCenter , kMinosFarCenter } |
| typedef enum genie::flux::GNuMIFlux::EStdFluxWindow | StdFluxWindow_t |
Public Member Functions | |
| GNuMIFlux () | |
| ~GNuMIFlux () | |
| const PDGCodeList & | FluxParticles (void) |
| declare list of flux neutrinos that can be generated (for init. purposes) | |
| double | MaxEnergy (void) |
| declare the max flux neutrino energy that can be generated (for init. purposes) | |
| bool | GenerateNext (void) |
| generate the next flux neutrino (return false in err) | |
| int | PdgCode (void) |
| returns the flux neutrino pdg code | |
| double | Weight (void) |
| returns the flux neutrino weight (if any) | |
| const TLorentzVector & | Momentum (void) |
| returns the flux neutrino 4-momentum | |
| const TLorentzVector & | Position (void) |
| returns the flux neutrino 4-position (note: expect SI rather than physical units) | |
| bool | End (void) |
| true if no more flux nu's can be thrown (eg reaching end of beam sim ntuples) | |
| long int | Index (void) |
| returns corresponding index for current flux neutrino (e.g. for a flux ntuple returns the current entry number) | |
| void | Clear (Option_t *opt) |
| reset state variables based on opt | |
| void | GenerateWeighted (bool gen_weighted) |
| set whether to generate weighted or unweighted neutrinos | |
| const GNuMIFluxPassThroughInfo & | PassThroughInfo (void) |
| GNuMIFluxPassThroughInfo. | |
| Long64_t | GetEntryNumber () |
| index in chain | |
| double | GetDecayDist () const |
| dist (user units) from dk to current pos | |
| void | MoveToZ0 (double z0) |
| move ray origin to user coord Z0 | |
| virtual double | GetTotalExposure () const |
| virtual long int | NFluxNeutrinos () const |
| double | POT_curr (void) |
| current average POT (RWH?) | |
| double | UsedPOTs (void) const |
| double | SumWeight (void) const |
| integrated weight for flux neutrinos looped so far | |
| void | PrintCurrent (void) |
| print current entry from leaves | |
| void | PrintConfig () |
| print the current configuration | |
| std::vector< std::string > | GetFileList () |
| list of files currently part of chain | |
| virtual void | LoadBeamSimData (const std::vector< std::string > &filenames, const std::string &det_loc) |
| virtual void | GetBranchInfo (std::vector< std::string > &branchNames, std::vector< std::string > &branchClassNames, std::vector< void ** > &branchObjPointers) |
| virtual TTree * | GetMetaDataTree () |
| bool | LoadConfig (string cfg) |
| load a named configuration | |
| void | SetMaxEnergy (double Ev) |
| specify maximum flx neutrino energy | |
| void | SetGenWeighted (bool genwgt=false) |
| toggle whether GenerateNext() returns weight=1 flux (initial default false) | |
| void | SetEntryReuse (long int nuse=1) |
| void | SetTreeName (string name) |
| set input tree name (default: "h10") | |
| void | ScanForMaxWeight (void) |
| scan for max flux weight (before generating unweighted flux neutrinos) | |
| void | SetMaxWgtScan (double fudge=1.05, long int nentries=2500000) |
| void | SetMaxEFudge (double fudge=1.05) |
| void | SetApplyWindowTiltWeight (bool apply=true) |
| void | SetLengthUnits (double user_units) |
| Set units assumed by user. | |
| double | LengthUnits (void) const |
| Return user units. | |
| void | SetBeamRotation (TRotation beamrot) |
| < beam (0,0,0) relative to user frame, beam direction in user frame | |
| void | SetBeamCenter (TVector3 beam0) |
| TRotation | GetBeamRotation () const |
| rotation to apply from beam->user | |
| TVector3 | GetBeamCenter () const |
| beam origin in user frame | |
| bool | SetFluxWindow (StdFluxWindow_t stdwindow, double padding=0) |
| return false if unhandled | |
| void | SetFluxWindow (TVector3 p1, TVector3 p2, TVector3 p3) |
| 3 points define a plane (by default in user coordinates) | |
| void | GetFluxWindow (TVector3 &p1, TVector3 &p2, TVector3 &p3) const |
| 3 points define a plane in beam coordinate | |
| void | UseFluxAtNearDetCenter (void) |
| force weights at MINOS detector "center" as found in ntuple | |
| void | UseFluxAtFarDetCenter (void) |
| void | Beam2UserPos (const TLorentzVector &beamxyz, TLorentzVector &usrxyz) const |
| void | Beam2UserDir (const TLorentzVector &beamdir, TLorentzVector &usrdir) const |
| void | Beam2UserP4 (const TLorentzVector &beamp4, TLorentzVector &usrp4) const |
| void | User2BeamPos (const TLorentzVector &usrxyz, TLorentzVector &beamxyz) const |
| void | User2BeamDir (const TLorentzVector &usrdir, TLorentzVector &beamdir) const |
| void | User2BeamP4 (const TLorentzVector &usrp4, TLorentzVector &beamp4) const |
| TVector3 | FluxWindowNormal () |
| virtual void | LoadBeamSimData (const std::set< std::string > &filenames, const std::string &det_loc) |
| virtual void | LoadBeamSimData (const std::string &filename, const std::string &det_loc) |
| Public Member Functions inherited from genie::GFluxI | |
| virtual | ~GFluxI () |
| Public Member Functions inherited from genie::flux::GFluxExposureI | |
| GFluxExposureI (genie::flux::Exposure_t etype) | |
| virtual | ~GFluxExposureI () |
| const char * | GetExposureUnits () const |
| what units are returned by GetTotalExposure? | |
| genie::flux::Exposure_t | GetExposureType () const |
| Public Member Functions inherited from genie::flux::GFluxFileConfigI | |
| GFluxFileConfigI () | |
| virtual | ~GFluxFileConfigI () |
| virtual void | SetXMLFileBase (std::string xmlbasename="") |
| virtual std::string | GetXMLFileBase () const |
| virtual void | SetFluxParticles (const PDGCodeList &particles) |
| specify list of flux neutrino species | |
| virtual void | SetUpstreamZ (double z0) |
| virtual void | SetNumOfCycles (long int ncycle) |
| limit cycling through input files | |
Private Member Functions | |
| bool | GenerateNext_weighted (void) |
| void | Initialize (void) |
| void | SetDefaults (void) |
| void | CleanUp (void) |
| void | ResetCurrent (void) |
| void | AddFile (TTree *tree, string fname) |
| void | CalcEffPOTsPerNu (void) |
Private Attributes | |
| double | fMaxEv |
| maximum energy | |
| bool | fEnd |
| end condition reached | |
| std::vector< string > | fNuFluxFilePatterns |
| (potentially wildcarded) path(s) | |
| string | fNuFluxTreeName |
| Tree name "h10" (g3) or "nudata" (g4) | |
| TChain * | fNuFluxTree |
| TTree in g3numi or g4numi // REF ONLY! | |
| string | fNuFluxGen |
| "g3numi" "g4numi" or "flugg" | |
| g3numi * | fG3NuMI |
| g3numi ntuple | |
| g4numi * | fG4NuMI |
| g4numi ntuple | |
| flugg * | fFlugg |
| flugg ntuple | |
| int | fNFiles |
| number of files in chain | |
| Long64_t | fNEntries |
| number of flux ntuple entries | |
| Long64_t | fIEntry |
| current flux ntuple entry | |
| Long64_t | fNuTot |
| cummulative # of entries (=fNEntries) | |
| Long64_t | fFilePOTs |
| double | fWeight |
| current neutrino weight, =1 if generating unweighted entries | |
| double | fMaxWeight |
| max flux neutrino weight in input file | |
| double | fMaxWgtFudge |
| fudge factor for estimating max wgt | |
| long int | fMaxWgtEntries |
| double | fMaxEFudge |
| fudge factor for estmating max enu (0=> use fixed 120GeV) | |
| long int | fNUse |
| how often to use same entry in a row | |
| long int | fIUse |
| current # of times an entry has been used | |
| double | fSumWeight |
| sum of weights for nus thrown so far | |
| long int | fNNeutrinos |
| number of flux neutrinos thrown so far | |
| double | fEffPOTsPerNu |
| what a entry is worth ... | |
| double | fAccumPOTs |
| POTs used so far. | |
| bool | fGenWeighted |
| does GenerateNext() give weights? | |
| bool | fApplyTiltWeight |
| wgt due to window normal not || beam | |
| bool | fDetLocIsSet |
| is a flux location (near/far) set? | |
| int | fUseFluxAtDetCenter |
| use flux at near (-1) or far (+1) det center from ntuple? | |
| double | fLengthUnits |
| units for coord in user exchanges | |
| double | fLengthScaleB2U |
| scale factor beam (cm) --> user | |
| double | fLengthScaleU2B |
| scale factor beam user --> (cm) | |
| TLorentzVector | fBeamZero |
| beam origin in user coords | |
| TLorentzRotation | fBeamRot |
| rotation applied beam --> user coord | |
| TLorentzRotation | fBeamRotInv |
| TVector3 | fFluxWindowPtUser [3] |
| user points of flux window | |
| TLorentzVector | fFluxWindowBase |
| base point for flux window - beam coord | |
| TLorentzVector | fFluxWindowDir1 |
| extent for flux window (direction 1) | |
| TLorentzVector | fFluxWindowDir2 |
| extent for flux window (direction 2) | |
| double | fFluxWindowLen1 |
| double | fFluxWindowLen2 |
| TVector3 | fWindowNormal |
| normal direction for flux window | |
| TLorentzVector | fgX4dkvtx |
| decay 4-position beam coord | |
| GNuMIFluxPassThroughInfo * | fCurEntry |
| copy of current ntuple entry info (owned structure) | |
Additional Inherited Members | |
| Static Public Member Functions inherited from genie::flux::GFluxExposureI | |
| static const char * | AsString (genie::flux::Exposure_t etype) |
| static genie::flux::Exposure_t | StringToEnum (const char *chars, int maxChar=0) |
| Protected Member Functions inherited from genie::GFluxI | |
| GFluxI () | |
| Protected Attributes inherited from genie::flux::GFluxFileConfigI | |
| PDGCodeList * | fPdgCList |
| list of neutrino pdg-codes to generate | |
| PDGCodeList * | fPdgCListRej |
| list of nu pdg-codes seen but rejected | |
| std::string | fXMLbasename |
| XML file that might hold config param_sets. | |
| long int | fNCycles |
| long int | fICycle |
| double | fZ0 |
A GENIE flux driver encapsulating the NuMI neutrino flux. It reads-in the official GNUMI neutrino flux ntuples. Supports both geant3 and geant4 formats.
An implementation of the GFluxI interface that provides NuMI flux
Definition at line 217 of file GNuMIFlux.h.
| Enumerator | |
|---|---|
| kMinosNearDet | |
| kMinosFarDet | |
| kMinosNearRock | |
| kMinosFarRock | |
| kMinosNearCenter | |
| kMinosFarCenter | |
Definition at line 330 of file GNuMIFlux.h.
| GNuMIFlux::GNuMIFlux | ( | ) |
Definition at line 113 of file GNuMIFlux.cxx.
References genie::flux::GFluxExposureI::GFluxExposureI(), Initialize(), and genie::flux::kPOTs.
| GNuMIFlux::~GNuMIFlux | ( | ) |
|
private |
Definition at line 1133 of file GNuMIFlux.cxx.
References fFilePOTs, fNFiles, fNuFluxGen, fNuFluxTree, fNuFluxTreeName, fNuTot, LOG, and pNOTICE.
Referenced by LoadBeamSimData().
| void GNuMIFlux::Beam2UserDir | ( | const TLorentzVector & | beamdir, |
| TLorentzVector & | usrdir ) const |
Definition at line 976 of file GNuMIFlux.cxx.
References fBeamRot, and fLengthScaleB2U.
| void GNuMIFlux::Beam2UserP4 | ( | const TLorentzVector & | beamp4, |
| TLorentzVector & | usrp4 ) const |
Definition at line 981 of file GNuMIFlux.cxx.
References fBeamRot.
Referenced by GenerateNext_weighted().
| void GNuMIFlux::Beam2UserPos | ( | const TLorentzVector & | beamxyz, |
| TLorentzVector & | usrxyz ) const |
Definition at line 971 of file GNuMIFlux.cxx.
References fBeamRot, fBeamZero, and fLengthScaleB2U.
Referenced by GenerateNext_weighted(), and SetFluxWindow().
|
private |
Definition at line 439 of file GNuMIFlux.cxx.
References fEffPOTsPerNu, fFilePOTs, fFluxWindowDir1, fFluxWindowDir2, fNEntries, fNuFluxTree, kRDET, LOG, pNOTICE, and pWARN.
Referenced by LoadBeamSimData(), SetFluxWindow(), and SetFluxWindow().
|
private |
Definition at line 1115 of file GNuMIFlux.cxx.
References fCurEntry, fFlugg, fG3NuMI, fG4NuMI, genie::flux::GFluxFileConfigI::fICycle, fIEntry, fIUse, genie::flux::GFluxFileConfigI::fNCycles, fNUse, genie::flux::GFluxFileConfigI::fPdgCList, genie::flux::GFluxFileConfigI::fPdgCListRej, LOG, and pNOTICE.
Referenced by ~GNuMIFlux().
|
virtual |
reset state variables based on opt
Implements genie::GFluxI.
Definition at line 1009 of file GNuMIFlux.cxx.
References fAccumPOTs, genie::flux::GFluxFileConfigI::fICycle, fNNeutrinos, fSumWeight, LOG, and pWARN.
|
inlinevirtual |
true if no more flux nu's can be thrown (eg reaching end of beam sim ntuples)
Implements genie::GFluxI.
Definition at line 237 of file GNuMIFlux.h.
References fEnd.
Referenced by GenerateNext().
|
inlinevirtual |
declare list of flux neutrinos that can be generated (for init. purposes)
Implements genie::GFluxI.
Definition at line 230 of file GNuMIFlux.h.
References genie::flux::GFluxFileConfigI::fPdgCList.
|
inline |
Definition at line 368 of file GNuMIFlux.h.
References fWindowNormal.
Referenced by GenerateNext_weighted().
|
virtual |
generate the next flux neutrino (return false in err)
Implements genie::GFluxI.
Definition at line 139 of file GNuMIFlux.cxx.
References End(), fCurEntry, fGenWeighted, fMaxWeight, fMaxWgtFudge, fWeight, GenerateNext_weighted(), genie::RandomGen::Instance(), LOG, genie::utils::print::P4AsShortString(), PassThroughInfo(), pERROR, pNOTICE, genie::RandomGen::RndFlux(), Weight(), and genie::utils::print::X4AsString().
|
private |
user might modify list via SetFluxParticles() in order to reject certain flavors, even if they're found in the file. So don't make a big fuss. Spit out a single message and then stop reporting that flavor as problematic.
Definition at line 204 of file GNuMIFlux.cxx.
References Beam2UserP4(), Beam2UserPos(), fAccumPOTs, fApplyTiltWeight, fCurEntry, fEffPOTsPerNu, fEnd, fFlugg, fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fG3NuMI, fG4NuMI, fgX4dkvtx, genie::flux::GFluxFileConfigI::fICycle, fIEntry, fIUse, FluxWindowNormal(), fMaxEv, fMaxWeight, genie::flux::GFluxFileConfigI::fNCycles, fNEntries, fNNeutrinos, genie::flux::GFluxFileConfigI::fPdgCList, genie::flux::GFluxFileConfigI::fPdgCListRej, fSumWeight, fUseFluxAtDetCenter, fWeight, genie::flux::GFluxFileConfigI::fZ0, genie::RandomGen::Instance(), LOG, MoveToZ0(), genie::utils::print::P4AsShortString(), pDEBUG, pERROR, pFATAL, pINFO, pWARN, ResetCurrent(), genie::RandomGen::RndFlux(), Weight(), and genie::utils::print::X4AsString().
Referenced by GenerateNext(), and ScanForMaxWeight().
|
virtual |
set whether to generate weighted or unweighted neutrinos
Implements genie::GFluxI.
Definition at line 1023 of file GNuMIFlux.cxx.
References fGenWeighted.
| TVector3 GNuMIFlux::GetBeamCenter | ( | ) | const |
| TRotation GNuMIFlux::GetBeamRotation | ( | ) | const |
rotation to apply from beam->user
Definition at line 928 of file GNuMIFlux.cxx.
References fBeamRot.
|
virtual |
allow caller to copy current status / ntuple entry info in the output file by providing copies of internal info
Assumes that branch object pointers will not change which may require either a copy be made or, if using the class directly for reading the branch, one must force ROOT to not autodelete: myns::MyClassType* fCurrMyClass = new myns::MyClassType; myTree->SetBranchAddress("bname",&fCurMyClass); //? TBranch* b = myTree->GetBranch("bname"); //? b->SetAutoDelete(false);
ensure vectors are sized sufficiently (or use .push_back()) branchNames[i] = "bname" branchClassNames[i] = "myns::MyClassType" branchObjPointers[i] = (void**)&fCurMyClass;
Reimplemented from genie::flux::GFluxFileConfigI.
Definition at line 663 of file GNuMIFlux.cxx.
References fCurEntry.
| double GNuMIFlux::GetDecayDist | ( | ) | const |
dist (user units) from dk to current pos
Definition at line 395 of file GNuMIFlux.cxx.
References fCurEntry, fgX4dkvtx, and fLengthScaleB2U.
|
inline |
| std::vector< std::string > GNuMIFlux::GetFileList | ( | ) |
list of files currently part of chain
Definition at line 2436 of file GNuMIFlux.cxx.
References fNuFluxTree.
Referenced by PrintConfig().
| void GNuMIFlux::GetFluxWindow | ( | TVector3 & | p1, |
| TVector3 & | p2, | ||
| TVector3 & | p3 ) const |
3 points define a plane in beam coordinate
Definition at line 904 of file GNuMIFlux.cxx.
References fFluxWindowPtUser.
|
virtual |
Reimplemented from genie::flux::GFluxFileConfigI.
Definition at line 677 of file GNuMIFlux.cxx.
|
virtual |
Implements genie::flux::GFluxExposureI.
Definition at line 125 of file GNuMIFlux.cxx.
References UsedPOTs().
|
inlinevirtual |
returns corresponding index for current flux neutrino (e.g. for a flux ntuple returns the current entry number)
Implements genie::GFluxI.
Definition at line 238 of file GNuMIFlux.h.
References fIEntry.
|
private |
Definition at line 1030 of file GNuMIFlux.cxx.
References fAccumPOTs, fApplyTiltWeight, fCurEntry, fDetLocIsSet, fEffPOTsPerNu, fEnd, fFilePOTs, fFlugg, fG3NuMI, fG4NuMI, fGenWeighted, genie::flux::GFluxFileConfigI::fICycle, fIEntry, fIUse, fMaxEFudge, fMaxEv, fMaxWeight, fMaxWgtEntries, fMaxWgtFudge, fNEntries, fNFiles, fNNeutrinos, fNuFluxGen, fNuFluxTree, fNuFluxTreeName, fNUse, fNuTot, fSumWeight, fUseFluxAtDetCenter, LOG, pNOTICE, ResetCurrent(), SetDefaults(), SetLengthUnits(), and genie::utils::units::UnitFromString().
Referenced by GNuMIFlux().
| double GNuMIFlux::LengthUnits | ( | void | ) | const |
Return user units.
Definition at line 1240 of file GNuMIFlux.cxx.
References fLengthScaleB2U, and genie::utils::units::UnitFromString().
|
virtual |
Reimplemented from genie::flux::GFluxFileConfigI.
Definition at line 49 of file GFluxFileConfigI.cxx.
|
virtual |
Reimplemented from genie::flux::GFluxFileConfigI.
Definition at line 52 of file GFluxFileConfigI.cxx.
|
virtual |
first is primary method for loading root flux ntuple files and config others are alternatives that can be overloaded but have sensible defaults to fall back to calling the vector version
Implements genie::flux::GFluxFileConfigI.
Definition at line 484 of file GNuMIFlux.cxx.
References AddFile(), CalcEffPOTsPerNu(), fAccumPOTs, fDetLocIsSet, fFlugg, fG3NuMI, fG4NuMI, genie::flux::GFluxFileConfigI::fICycle, fIEntry, fIUse, fMaxWeight, fNEntries, fNNeutrinos, fNuFluxFilePatterns, fNuFluxGen, fNuFluxTree, fNuFluxTreeName, fSumWeight, genie::RandomGen::Instance(), LoadConfig(), LOG, pERROR, pFATAL, pINFO, pNOTICE, genie::RandomGen::RndFlux(), ScanForMaxWeight(), and SetTreeName().
| bool GNuMIFlux::LoadConfig | ( | string | cfg | ) |
load a named configuration
Definition at line 2324 of file GNuMIFlux.cxx.
References genie::flux::GNuMIFluxXMLHelper::LoadConfig(), and genie::flux::GFluxFileConfigI::SetXMLFileBase().
Referenced by LoadBeamSimData().
|
inlinevirtual |
declare the max flux neutrino energy that can be generated (for init. purposes)
Implements genie::GFluxI.
Definition at line 231 of file GNuMIFlux.h.
References fMaxEv.
|
inlinevirtual |
returns the flux neutrino 4-momentum
Implements genie::GFluxI.
Definition at line 235 of file GNuMIFlux.h.
References fCurEntry.
| void GNuMIFlux::MoveToZ0 | ( | double | z0 | ) |
move ray origin to user coord Z0
Definition at line 403 of file GNuMIFlux.cxx.
References fCurEntry, fLengthScaleU2B, LOG, genie::utils::print::P4AsShortString(), pNOTICE, pWARN, and genie::utils::print::X4AsString().
Referenced by GenerateNext_weighted().
|
virtual |
number of flux neutrinos ray generated so far
Implements genie::flux::GFluxExposureI.
Definition at line 132 of file GNuMIFlux.cxx.
References fNNeutrinos.
|
inline |
|
inlinevirtual |
returns the flux neutrino pdg code
Implements genie::GFluxI.
Definition at line 233 of file GNuMIFlux.h.
References fCurEntry.
|
inlinevirtual |
returns the flux neutrino 4-position (note: expect SI rather than physical units)
Implements genie::GFluxI.
Definition at line 236 of file GNuMIFlux.h.
References fCurEntry.
| double GNuMIFlux::POT_curr | ( | void | ) |
current average POT (RWH?)
Definition at line 477 of file GNuMIFlux.cxx.
References UsedPOTs().
|
virtual |
print the current configuration
Implements genie::flux::GFluxFileConfigI.
Definition at line 2336 of file GNuMIFlux.cxx.
References fAccumPOTs, fBeamRot, fBeamRotInv, fBeamZero, fDetLocIsSet, fEffPOTsPerNu, fFilePOTs, fFlugg, fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fFluxWindowLen1, fFluxWindowLen2, fFluxWindowPtUser, fG3NuMI, fG4NuMI, fGenWeighted, genie::flux::GFluxFileConfigI::fICycle, fIEntry, fIUse, fLengthScaleB2U, fLengthScaleU2B, fLengthUnits, fMaxEv, fMaxWeight, fMaxWgtEntries, fMaxWgtFudge, genie::flux::GFluxFileConfigI::fNCycles, fNEntries, fNFiles, fNNeutrinos, fNuFluxFilePatterns, fNuFluxGen, fNuFluxTreeName, fNUse, genie::flux::GFluxFileConfigI::fPdgCList, genie::flux::GFluxFileConfigI::fPdgCListRej, fSumWeight, fUseFluxAtDetCenter, fWindowNormal, genie::flux::GFluxFileConfigI::fZ0, GetFileList(), LOG, pNOTICE, User2BeamPos(), genie::utils::print::Vec3AsString(), and genie::utils::print::X4AsString().
| void GNuMIFlux::PrintCurrent | ( | void | ) |
|
private |
Definition at line 1106 of file GNuMIFlux.cxx.
References fCurEntry.
Referenced by GenerateNext_weighted(), and Initialize().
| void GNuMIFlux::ScanForMaxWeight | ( | void | ) |
scan for max flux weight (before generating unweighted flux neutrinos)
Definition at line 680 of file GNuMIFlux.cxx.
References fCurEntry, fDetLocIsSet, fFluxWindowBase, fG4NuMI, fMaxEFudge, fMaxEv, fMaxWeight, fMaxWgtEntries, fMaxWgtFudge, fNEntries, fNuFluxTree, fUseFluxAtDetCenter, GenerateNext_weighted(), LOG, pERROR, pFATAL, pNOTICE, and Weight().
Referenced by LoadBeamSimData().
|
inline |
| apply | apply wgt due to tilt of flux window relative to beam |
Definition at line 302 of file GNuMIFlux.h.
References fApplyTiltWeight.
| void GNuMIFlux::SetBeamCenter | ( | TVector3 | beam0 | ) |
Definition at line 920 of file GNuMIFlux.cxx.
References fBeamZero.
| void GNuMIFlux::SetBeamRotation | ( | TRotation | beamrot | ) |
< beam (0,0,0) relative to user frame, beam direction in user frame
Definition at line 913 of file GNuMIFlux.cxx.
References fBeamRot, and fBeamRotInv.
|
private |
Definition at line 1077 of file GNuMIFlux.cxx.
References genie::kPdgAntiNuE, genie::kPdgAntiNuMu, genie::kPdgNuE, genie::kPdgNuMu, LOG, pNOTICE, genie::PDGCodeList::push_back(), SetEntryReuse(), genie::flux::GFluxFileConfigI::SetFluxParticles(), SetMaxEnergy(), genie::flux::GFluxFileConfigI::SetNumOfCycles(), genie::flux::GFluxFileConfigI::SetUpstreamZ(), and genie::flux::GFluxFileConfigI::SetXMLFileBase().
Referenced by Initialize().
| void GNuMIFlux::SetEntryReuse | ( | long int | nuse = 1 | ) |
Definition at line 768 of file GNuMIFlux.cxx.
References fNUse.
Referenced by SetDefaults().
| bool GNuMIFlux::SetFluxWindow | ( | GNuMIFlux::StdFluxWindow_t | stdwindow, |
| double | padding = 0 ) |
return false if unhandled
Definition at line 801 of file GNuMIFlux.cxx.
References Beam2UserPos(), CalcEffPOTsPerNu(), fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fFluxWindowLen1, fFluxWindowLen2, fFluxWindowPtUser, fLengthScaleB2U, kMinosFarCenter, kMinosFarRock, kMinosNearCenter, kMinosNearDet, kMinosNearRock, kPosCenterFarBeam(), LOG, pERROR, pNOTICE, SetLengthUnits(), and genie::utils::units::UnitFromString().
| void GNuMIFlux::SetFluxWindow | ( | TVector3 | p1, |
| TVector3 | p2, | ||
| TVector3 | p3 ) |
3 points define a plane (by default in user coordinates)
Definition at line 867 of file GNuMIFlux.cxx.
References CalcEffPOTsPerNu(), fDetLocIsSet, fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fFluxWindowLen1, fFluxWindowLen2, fFluxWindowPtUser, fUseFluxAtDetCenter, fWindowNormal, LOG, pNOTICE, pWARN, and User2BeamPos().
|
inline |
toggle whether GenerateNext() returns weight=1 flux (initial default false)
Definition at line 292 of file GNuMIFlux.h.
References fGenWeighted.
| void GNuMIFlux::SetLengthUnits | ( | double | user_units | ) |
Set units assumed by user.
Definition at line 1206 of file GNuMIFlux.cxx.
References fBeamZero, fCurEntry, fFluxWindowPtUser, fLengthScaleB2U, fLengthScaleU2B, fLengthUnits, and genie::utils::units::UnitFromString().
Referenced by Initialize(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
inline |
| fudge | extra fudge factor in estimating maximum energy |
Definition at line 300 of file GNuMIFlux.h.
References fMaxEFudge.
| void GNuMIFlux::SetMaxEnergy | ( | double | Ev | ) |
specify maximum flx neutrino energy
Definition at line 760 of file GNuMIFlux.cxx.
References fMaxEv, LOG, and pINFO.
Referenced by SetDefaults().
|
inline |
| nentries | configuration when estimating max weight |
Definition at line 298 of file GNuMIFlux.h.
References fMaxWgtEntries, and fMaxWgtFudge.
| void GNuMIFlux::SetTreeName | ( | string | name | ) |
set input tree name (default: "h10")
Definition at line 776 of file GNuMIFlux.cxx.
References fNuFluxTreeName.
Referenced by LoadBeamSimData().
|
inline |
integrated weight for flux neutrinos looped so far
Definition at line 267 of file GNuMIFlux.h.
References fSumWeight.
| double GNuMIFlux::UsedPOTs | ( | void | ) | const |
Definition at line 464 of file GNuMIFlux.cxx.
References fAccumPOTs, fNuFluxTree, LOG, and pWARN.
Referenced by GetTotalExposure(), and POT_curr().
| void GNuMIFlux::UseFluxAtFarDetCenter | ( | void | ) |
Definition at line 791 of file GNuMIFlux.cxx.
References fDetLocIsSet, fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fUseFluxAtDetCenter, kPosCenterFarBeam(), SetLengthUnits(), and genie::utils::units::UnitFromString().
| void GNuMIFlux::UseFluxAtNearDetCenter | ( | void | ) |
force weights at MINOS detector "center" as found in ntuple
Definition at line 781 of file GNuMIFlux.cxx.
References fDetLocIsSet, fFluxWindowBase, fFluxWindowDir1, fFluxWindowDir2, fUseFluxAtDetCenter, SetLengthUnits(), and genie::utils::units::UnitFromString().
| void GNuMIFlux::User2BeamDir | ( | const TLorentzVector & | usrdir, |
| TLorentzVector & | beamdir ) const |
Definition at line 992 of file GNuMIFlux.cxx.
References fBeamRotInv, and fLengthScaleU2B.
| void GNuMIFlux::User2BeamP4 | ( | const TLorentzVector & | usrp4, |
| TLorentzVector & | beamp4 ) const |
Definition at line 997 of file GNuMIFlux.cxx.
References fBeamRotInv.
| void GNuMIFlux::User2BeamPos | ( | const TLorentzVector & | usrxyz, |
| TLorentzVector & | beamxyz ) const |
Definition at line 987 of file GNuMIFlux.cxx.
References fBeamRotInv, fBeamZero, and fLengthScaleU2B.
Referenced by PrintConfig(), and SetFluxWindow().
|
inlinevirtual |
returns the flux neutrino weight (if any)
Implements genie::GFluxI.
Definition at line 234 of file GNuMIFlux.h.
References fWeight.
Referenced by GenerateNext(), GenerateNext_weighted(), and ScanForMaxWeight().
|
private |
POTs used so far.
Definition at line 411 of file GNuMIFlux.h.
Referenced by Clear(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), PrintConfig(), and UsedPOTs().
|
private |
wgt due to window normal not || beam
Definition at line 414 of file GNuMIFlux.h.
Referenced by GenerateNext_weighted(), Initialize(), and SetApplyWindowTiltWeight().
|
private |
rotation applied beam --> user coord
Definition at line 423 of file GNuMIFlux.h.
Referenced by Beam2UserDir(), Beam2UserP4(), Beam2UserPos(), GetBeamRotation(), PrintConfig(), and SetBeamRotation().
|
private |
Definition at line 424 of file GNuMIFlux.h.
Referenced by PrintConfig(), SetBeamRotation(), User2BeamDir(), User2BeamP4(), and User2BeamPos().
|
private |
beam origin in user coords
Definition at line 422 of file GNuMIFlux.h.
Referenced by Beam2UserPos(), GetBeamCenter(), PrintConfig(), SetBeamCenter(), SetLengthUnits(), and User2BeamPos().
|
private |
copy of current ntuple entry info (owned structure)
Definition at line 436 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext(), GenerateNext_weighted(), GetBranchInfo(), GetDecayDist(), Initialize(), Momentum(), MoveToZ0(), PassThroughInfo(), PdgCode(), Position(), PrintCurrent(), ResetCurrent(), ScanForMaxWeight(), and SetLengthUnits().
|
private |
is a flux location (near/far) set?
Definition at line 415 of file GNuMIFlux.h.
Referenced by Initialize(), LoadBeamSimData(), PrintConfig(), ScanForMaxWeight(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
private |
what a entry is worth ...
Definition at line 410 of file GNuMIFlux.h.
Referenced by CalcEffPOTsPerNu(), GenerateNext_weighted(), Initialize(), and PrintConfig().
|
private |
end condition reached
Definition at line 385 of file GNuMIFlux.h.
Referenced by End(), GenerateNext_weighted(), and Initialize().
|
private |
Definition at line 398 of file GNuMIFlux.h.
Referenced by AddFile(), CalcEffPOTsPerNu(), Initialize(), and PrintConfig().
|
private |
flugg ntuple
Definition at line 393 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), and PrintConfig().
|
private |
base point for flux window - beam coord
Definition at line 427 of file GNuMIFlux.h.
Referenced by GenerateNext_weighted(), PrintConfig(), ScanForMaxWeight(), SetFluxWindow(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
private |
extent for flux window (direction 1)
Definition at line 428 of file GNuMIFlux.h.
Referenced by CalcEffPOTsPerNu(), GenerateNext_weighted(), PrintConfig(), SetFluxWindow(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
private |
extent for flux window (direction 2)
Definition at line 429 of file GNuMIFlux.h.
Referenced by CalcEffPOTsPerNu(), GenerateNext_weighted(), PrintConfig(), SetFluxWindow(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
private |
Definition at line 430 of file GNuMIFlux.h.
Referenced by PrintConfig(), SetFluxWindow(), and SetFluxWindow().
|
private |
Definition at line 431 of file GNuMIFlux.h.
Referenced by PrintConfig(), SetFluxWindow(), and SetFluxWindow().
|
private |
user points of flux window
Definition at line 426 of file GNuMIFlux.h.
Referenced by GetFluxWindow(), PrintConfig(), SetFluxWindow(), SetFluxWindow(), and SetLengthUnits().
|
private |
g3numi ntuple
Definition at line 391 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), and PrintConfig().
|
private |
g4numi ntuple
Definition at line 392 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), PrintConfig(), and ScanForMaxWeight().
|
private |
does GenerateNext() give weights?
Definition at line 413 of file GNuMIFlux.h.
Referenced by GenerateNext(), GenerateWeighted(), Initialize(), PrintConfig(), and SetGenWeighted().
|
private |
decay 4-position beam coord
Definition at line 434 of file GNuMIFlux.h.
Referenced by GenerateNext_weighted(), and GetDecayDist().
|
private |
current flux ntuple entry
Definition at line 396 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext_weighted(), GetEntryNumber(), Index(), Initialize(), LoadBeamSimData(), and PrintConfig().
|
private |
current # of times an entry has been used
Definition at line 407 of file GNuMIFlux.h.
Referenced by CleanUp(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), and PrintConfig().
|
private |
scale factor beam (cm) --> user
Definition at line 419 of file GNuMIFlux.h.
Referenced by Beam2UserDir(), Beam2UserPos(), GetDecayDist(), LengthUnits(), PrintConfig(), SetFluxWindow(), and SetLengthUnits().
|
private |
scale factor beam user --> (cm)
Definition at line 420 of file GNuMIFlux.h.
Referenced by MoveToZ0(), PrintConfig(), SetLengthUnits(), User2BeamDir(), and User2BeamPos().
|
private |
units for coord in user exchanges
Definition at line 418 of file GNuMIFlux.h.
Referenced by PrintConfig(), and SetLengthUnits().
|
private |
fudge factor for estmating max enu (0=> use fixed 120GeV)
Definition at line 404 of file GNuMIFlux.h.
Referenced by Initialize(), ScanForMaxWeight(), and SetMaxEFudge().
|
private |
maximum energy
Definition at line 384 of file GNuMIFlux.h.
Referenced by GenerateNext_weighted(), Initialize(), MaxEnergy(), PrintConfig(), ScanForMaxWeight(), and SetMaxEnergy().
|
private |
max flux neutrino weight in input file
Definition at line 401 of file GNuMIFlux.h.
Referenced by GenerateNext(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), PrintConfig(), and ScanForMaxWeight().
|
private |
Definition at line 403 of file GNuMIFlux.h.
Referenced by Initialize(), PrintConfig(), ScanForMaxWeight(), and SetMaxWgtScan().
|
private |
fudge factor for estimating max wgt
Definition at line 402 of file GNuMIFlux.h.
Referenced by GenerateNext(), Initialize(), PrintConfig(), ScanForMaxWeight(), and SetMaxWgtScan().
|
private |
number of flux ntuple entries
Definition at line 395 of file GNuMIFlux.h.
Referenced by CalcEffPOTsPerNu(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), PrintConfig(), and ScanForMaxWeight().
|
private |
number of files in chain
Definition at line 394 of file GNuMIFlux.h.
Referenced by AddFile(), Initialize(), and PrintConfig().
|
private |
number of flux neutrinos thrown so far
Definition at line 409 of file GNuMIFlux.h.
Referenced by Clear(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), NFluxNeutrinos(), and PrintConfig().
|
private |
(potentially wildcarded) path(s)
Definition at line 387 of file GNuMIFlux.h.
Referenced by LoadBeamSimData(), and PrintConfig().
|
private |
"g3numi" "g4numi" or "flugg"
Definition at line 390 of file GNuMIFlux.h.
Referenced by AddFile(), Initialize(), LoadBeamSimData(), and PrintConfig().
|
private |
TTree in g3numi or g4numi // REF ONLY!
Definition at line 389 of file GNuMIFlux.h.
Referenced by AddFile(), CalcEffPOTsPerNu(), GetFileList(), Initialize(), LoadBeamSimData(), ScanForMaxWeight(), and UsedPOTs().
|
private |
Tree name "h10" (g3) or "nudata" (g4)
Definition at line 388 of file GNuMIFlux.h.
Referenced by AddFile(), Initialize(), LoadBeamSimData(), PrintConfig(), and SetTreeName().
|
private |
how often to use same entry in a row
Definition at line 406 of file GNuMIFlux.h.
Referenced by CleanUp(), Initialize(), PrintConfig(), and SetEntryReuse().
|
private |
cummulative # of entries (=fNEntries)
Definition at line 397 of file GNuMIFlux.h.
Referenced by AddFile(), and Initialize().
|
private |
sum of weights for nus thrown so far
Definition at line 408 of file GNuMIFlux.h.
Referenced by Clear(), GenerateNext_weighted(), Initialize(), LoadBeamSimData(), PrintConfig(), and SumWeight().
|
private |
use flux at near (-1) or far (+1) det center from ntuple?
Definition at line 416 of file GNuMIFlux.h.
Referenced by GenerateNext_weighted(), Initialize(), PrintConfig(), ScanForMaxWeight(), SetFluxWindow(), UseFluxAtFarDetCenter(), and UseFluxAtNearDetCenter().
|
private |
current neutrino weight, =1 if generating unweighted entries
Definition at line 400 of file GNuMIFlux.h.
Referenced by GenerateNext(), GenerateNext_weighted(), and Weight().
|
private |
normal direction for flux window
Definition at line 432 of file GNuMIFlux.h.
Referenced by FluxWindowNormal(), PrintConfig(), and SetFluxWindow().