CCgen Class Reference

Ratpac-two: RAT::CCgen Class Reference
Ratpac-two

Implements the generation of a neutrino-nucleus charged current interaction. More...

#include <CCgen.hh>

Public Member Functions

void GenerateEvent (const G4ThreeVector &nu_dir, G4LorentzVector &neutrino, G4LorentzVector &electron, double &e_nucleus)
 
void SetNuType (const G4String &nutype)
 
const G4String & GetNuType () const
 
void SetNuFlavor (const G4String &nuflavor)
 
const G4String & GetNuFlavor () const
 
G4double GetTotalFlux ()
 Getter for the total neutrino flux. More...
 
G4double GetRatePerTarget ()
 Getter for the SSM event rate per target for this flux. More...
 
const G4String GetDBName () const
 
void SetDBName (const G4String name)
 

Protected Member Functions

G4bool GetGenLoaded ()
 

Protected Attributes

G4String fGenType
 
G4String fNuType
 
G4String fNuFlavor
 
CCCrossSecfXS
 
TGraph * fNuSpectrum
 Spectrum shape to be sampled. More...
 
TF1 * fFermiAngle
 
TF1 * fGTAngle
 
std::vector< double > fEnuTbl
 
std::vector< double > fFluxTbl
 
G4double fEmax
 
G4double fEmin
 
G4double fEnuMax
 
G4double fEnuMin
 
G4double fFluxMax
 
G4bool fGenLoaded
 
G4double fMassElectron
 
G4double fTotalFlux
 
CLHEP::RandGeneral * fSpectrumRndm
 
G4String fDBName
 

Detailed Description

Implements the generation of a neutrino-nucleus charged current interaction.

Author
Max Smiley masmi.nosp@m.ley@.nosp@m.berke.nosp@m.ley..nosp@m.edu – contact person
Date
26-Aug-2019

This class is the workhorse of the generator, separating the Geant4 specific methods from a more physics oriented structure. It is based on the original elastic scattering implementation by Joe Formaggio and the following adaptation by Bill Seligman. However the whole class was re-written later to adapt it for the final use of charged current interactions.

Member Function Documentation

◆ GenerateEvent()

void RAT::CCgen::GenerateEvent ( const G4ThreeVector &  nu_dir,
G4LorentzVector &  neutrino,
G4LorentzVector &  electron,
double &  e_nucleus 
)

Generate random event vectors.

Pass in the neutrino direction (unit vector).

Parameters
[in]nu_dirIncoming neutrino direction (lab coordinates).
[out]neutrinoOutgoing neutrino direction (lab coordinates. Not used).
[out]electronOutgoing electron direction (lab coordinates).
Returns
4-momentum vectors for resulting electron.

! Have to be careful with the line neutrino types (pep) and even more careful with the double line (be7)

◆ GetDBName()

const G4String RAT::CCgen::GetDBName ( ) const
inline

Getter of the DB entry to input the spectrum from.

Returns
name of the DB name.

◆ GetGenLoaded()

G4bool RAT::CCgen::GetGenLoaded ( )
inlineprotected

Private method to check if generator is loaded.

◆ GetNuFlavor()

const G4String& RAT::CCgen::GetNuFlavor ( ) const
inline

Getter for neutrino flavor

◆ GetNuType()

const G4String& RAT::CCgen::GetNuType ( ) const
inline

Getter for the spectrum being used

◆ GetRatePerTarget()

G4double RAT::CCgen::GetRatePerTarget ( )

Getter for the SSM event rate per target for this flux.

The SSM event rate is obtained from the product of the cross section and the flux: $ R_{\nu} = \sigma \times \Phi_{\nu} $

Returns
The event Rate predicted by the SSM (in Hz)

◆ GetTotalFlux()

G4double RAT::CCgen::GetTotalFlux ( )
inline

Getter for the total neutrino flux.

Returns
total neutrino flux in $ s^{-1} cm^{-2} $

◆ SetDBName()

void RAT::CCgen::SetDBName ( const G4String  name)

Setter of the DB name. Defaults to \'SOLAR\'

Parameters
[in]nameof the database entry to look at.

◆ SetNuFlavor()

void RAT::CCgen::SetNuFlavor ( const G4String &  nuflavor)

Setter for the neutrino flavor being generated.

This parameter is passed down into the cross-section to calculate the correct shape.

Parameters
nuflavorFlavor of the neutrino being calculated. Can be one of (nue,numu,nuebar,numubar).
Attention
$ \sigma_{\mu} = \sigma_{\tau}$

◆ SetNuType()

void RAT::CCgen::SetNuType ( const G4String &  nutype)

Setter for the flux to use.

Parameters
[in]nutypeKey to the database to load the flux.

Member Data Documentation

◆ fDBName

G4String RAT::CCgen::fDBName
protected

Name of the database entry to read the input spectrum from. Defaults to SOLAR.

◆ fEmax

G4double RAT::CCgen::fEmax
protected

Recoil upper limit for the electron.

◆ fEmin

G4double RAT::CCgen::fEmin
protected

Recoil lower limit for the electron.

◆ fEnuMax

G4double RAT::CCgen::fEnuMax
protected

Recoil upper limit for the electron.

◆ fEnuMin

G4double RAT::CCgen::fEnuMin
protected

Recoil lower limit for the electron.

◆ fEnuTbl

std::vector<double> RAT::CCgen::fEnuTbl
protected

vector of neutrino energy points in the neutrino spectrum shape.

◆ fFluxMax

G4double RAT::CCgen::fFluxMax
protected

Maximum flux in spectrum shape

◆ fFluxTbl

std::vector<double> RAT::CCgen::fFluxTbl
protected

Normalized flux in the neutrino spectrum shape.

◆ fGenLoaded

G4bool RAT::CCgen::fGenLoaded
protected

Generator loaded flag.

◆ fGenType

G4String RAT::CCgen::fGenType
protected

Generator type

◆ fMassElectron

G4double RAT::CCgen::fMassElectron
protected

electron mass

◆ fNuFlavor

G4String RAT::CCgen::fNuFlavor
protected

Neutrino flavor

◆ fNuSpectrum

TGraph* RAT::CCgen::fNuSpectrum
protected

Spectrum shape to be sampled.

Using ROOT TGraph to make use of it's nice evaluator.

◆ fNuType

G4String RAT::CCgen::fNuType
protected

Neutrino type

◆ fSpectrumRndm

CLHEP::RandGeneral* RAT::CCgen::fSpectrumRndm
protected

Random number generator for the nu spectrum sampler

◆ fTotalFlux

G4double RAT::CCgen::fTotalFlux
protected

Total neutrino flux

◆ fXS

CCCrossSec* RAT::CCgen::fXS
protected

Instance of cross-section class


The documentation for this class was generated from the following files:
  • /home/docs/checkouts/readthedocs.org/user_builds/ratpac/checkouts/latest/src/gen/include/RAT/CCgen.hh
  • /home/docs/checkouts/readthedocs.org/user_builds/ratpac/checkouts/latest/src/gen/src/CCgen.cc