24#define LOG_BEGIN(a,b) LOG(a,b)
130 "No GenerateWeighted(bool gen_weighted) method implemented for " <<
131 "gen_weighted: " << gen_weighted;
164 for (
size_t indx = 0; indx <
fNPDGOut; ++indx ) {
166 double prob =
fFlavorMixer->Probability(pdg_init,pdg_test,energy,dist);
168 sumprob +=
fProb[indx];
170 if ( ! isset &&
fRndm < sumprob ) {
185 <<
" fRealGFluxI is a \""
190 <<
" fRealGFluxI is not initialized" <<
LOG_END;
194 <<
" fFlavorMixer is a \""
199 <<
" fFlavorMixer is not initialized" <<
LOG_END;
206 <<
"PDG List after mixing (n=" <<
fNPDGOut <<
")"
221 for (
size_t indx = 0; indx <
fNPDGOut; ++indx ) {
223 <<
" [" << indx <<
"] "
226 <<
" p = " << std::setw(10) <<
fProb[indx]
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE,...
Most commonly used PDG codes. A set of utility functions to handle PDG codes is provided in PDGUtils.
static RandomGen * Instance()
Access instance.
TRandom3 & RndFlux(void) const
rnd number generator used by flux drivers
GENIE interface for flavor modification.
bool GenerateNext(void)
generate the next flux neutrino (return false in err)
std::vector< double > fSumProb
cummulative probability
double fDistance
current neutrino's travel distance
int ChooseFlavor(int pdg_init, double energy, double dist)
double fRndm
random # used to make choice
double fBaselineDist
travel dist for mixing (if flux doesn't support GetDecayDist())
GSimpleNtpFlux * fGSimpleFlux
ref to avoid repeat dynamic_cast
std::vector< double > fProb
individual transition probs
const PDGCodeList & FluxParticles(void)
declare list of flux neutrinos that can be generated (for init. purposes)
int fPdgCMixed
current neutrino's new flavor
void GenerateWeighted(bool gen_weighted)
set whether to generate weighted or unweighted neutrinos
void PrintState(bool verbose=true)
GFluxI * fRealGFluxI
actual flux generator
PDGCodeList fPDGListMixed
possible flavors after mixing
void Clear(Option_t *opt)
reset state variables based on opt
long int Index(void)
returns corresponding index for current flux neutrino (e.g. for a flux ntuple returns the current ent...
double fEnergy
current neutrino's energy
GFluxI * AdoptFluxGenerator(GFluxI *generator)
return previous
GNuMIFlux * fGNuMIFlux
ref to avoid repeat dynamic_cast
GFlavorMixerI * AdoptFlavorMixer(GFlavorMixerI *mixer)
return previous
PDGCodeList fPDGListGenerator
possible flavors from generator
int fPdgCGenerated
current neutrino's original flavor
GFlavorMixerI * fFlavorMixer
flavor modification schema
A GENIE flux driver encapsulating the NuMI neutrino flux. It reads-in the official GNUMI neutrino flu...
A GENIE flux driver using a simple ntuple format.
THE MAIN GENIE PROJECT NAMESPACE