20 #include "Framework/Conventions/GBuild.h"
37 using std::ostringstream;
39 using namespace genie;
40 using namespace genie::constants;
68 const Kinematics & kinematics = interaction -> Kine();
69 const InitialState & init_state = interaction -> InitState();
70 const ProcessInfo & proc_info = interaction -> ProcInfo();
75 double x = kinematics.
x();
76 double y = kinematics.
y();
80 double ml4 = ml2 * ml2;
81 double Mnuc2 = Mnuc * Mnuc;
83 #ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
85 <<
"Computing d2xsec/dxdy @ E = " << E <<
", x = " << x <<
", y = " << y;
92 int sign = (is_nubar_cc) ? -1 : 1;
97 #ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
118 if(proc_info.
IsEM()) {
126 double front_factor = (g2*Mnuc*E) /
kPi;
129 double term1 = y * ( x*y + ml2/(2*E*Mnuc) );
130 double term2 = 1 - y - Mnuc*x*y/(2*E) - ml2/(4*E2);
131 double term3 = sign * (x*y*(1-y/2) - y*ml2/(4*Mnuc*E));
132 double term4 = x*y*ml2/(2*Mnuc*E) + ml4/(4*Mnuc2*E2);
133 double term5 = -1.*ml2/(2*Mnuc*E);
135 #ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
137 <<
"\nd2xsec/dxdy ~ (" << term1 <<
")*F1+(" << term2 <<
")*F2+("
138 << term3 <<
")*F3+(" << term4 <<
")*F4+(" << term5 <<
")*F5";
147 double xsec = front_factor * (term1 + term2 + term3 + term4 + term5);
148 xsec = TMath::Max(xsec,0.);
150 #ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
152 <<
"d2xsec/dxdy[FreeN] (E= " << E
153 <<
", x= " << x <<
", y= " << y <<
") = " << xsec;
168 const Target & target = init_state.
Tgt();
182 #ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
184 <<
"Subtracting charm piece: " << xsec_charm <<
" / out of " << xsec;
186 xsec = TMath::Max(0., xsec-xsec_charm);
203 const InitialState & init_state = interaction -> InitState();
204 int probe_pdg = init_state.
ProbePdg();
225 Registry r(
"QPMDISPXSec_specific",
false ) ;
227 RgKey xdefkey =
"XSecModel@genie::EventGenerator/DIS-CC-CHARM";
228 RgKey local_key =
"CharmXSec" ;
255 fSin48w = TMath::Power( TMath::Sin(thw), 4 );
264 string keysubstr = this->
Id().
Key() +
"/DIS-RES-Join";
275 RgKey local_key =
"CharmXSec" ;
279 <<
"Loading the cross section model: " << xalg;
void SetModel(const DISStructureFuncModelI *model)
Attach an algorithm.
Cross Section Calculation Interface.
Pure Abstract Base Class. Defines the DISStructureFuncModelI interface to be implemented by any algor...
bool IsWeakCC(void) const
double F2(void) const
Get the computed structure function F2.
double J(double q0, double q3, double Enu, double ml)
Cross Section Integrator Interface.
double Q2(const Interaction *const i)
int HitNucPdg(void) const
const DISStructureFuncModelI * fDISSFModel
SF model.
double HitNucMass(void) const
Generated/set kinematical variables for an event.
double x(bool selected=false) const
double fNCScale
cross section scaling factor
enum genie::EKinePhaseSpace KinePhaseSpace_t
double fSin48w
sin^4(Weingberg angle)
void SetCharm(int charm_pdgc=0)
double y(bool selected=false) const
double F4(void) const
Get the computed structure function F4.
Summary information for an interaction.
double F1(void) const
Get the computed structure function F1.
virtual bool ValidKinematics(const Interaction *i) const
Is the input kinematical point a physically allowed one?
double fCCScale
cross section scaling factor
bool IsWeakNC(void) const
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE...
const XSecIntegratorI * fXSecIntegrator
diff. xsec integrator
static const double kAem2
void Configure(const Registry &config)
A class encapsulating an enumeration of interaction types (EM, Weak-CC, Weak-NC) and scattering types...
double XYtoQ2(double Ev, double M, double x, double y)
bool IsAntiNeutrino(int pdgc)
A Neutrino Interaction Target. Is a transparent encapsulation of quite different physical systems suc...
virtual void Configure(const Registry &config)
bool ValidProcess(const Interaction *i) const
Can this cross section algorithm handle the input process?
virtual double XSec(const Interaction *i, KinePhaseSpace_t k=kPSfE) const =0
Compute the cross section for the input interaction.
TParticlePDG * FSPrimLepton(void) const
final state primary lepton
double F5(void) const
Get the computed structure function F5.
bool IsDeepInelastic(void) const
XclsTag * ExclTagPtr(void) const
const XSecAlgorithmI * fCharmProdModel
double F3(void) const
Get the computed structure function F3.
virtual const AlgId & Id(void) const
Get algorithm ID.
bool HitNucIsSet(void) const
A registry. Provides the container for algorithm configuration parameters.
const UInt_t kIAssumeFreeNucleon
bool IsNeutronOrProton(int pdgc)
double XSec(const Interaction *i, KinePhaseSpace_t k) const
Compute the cross section for the input interaction.
double Jacobian(const Interaction *const i, KinePhaseSpace_t f, KinePhaseSpace_t t)
const ProcessInfo & ProcInfo(void) const
void Calculate(const Interaction *interaction)
Calculate the S/F's for the input interaction using the attached algorithm.
void RmMatchedCacheBranches(string key_substring)
bool GetParam(const RgKey &name, T &p, bool is_top_call=true) const
const Target & Tgt(void) const
static Cache * Instance(void)
virtual double Integrate(const XSecAlgorithmI *model, const Interaction *interaction) const =0
double Integral(const Interaction *i) const
double fEMScale
cross section scaling factor
void Set(RgIMapPair entry)
double ProbeE(RefFrame_t rf) const
Most commonly used PDG codes. A set of utility functions to handle PDG codes is provided in PDGUtils...
const UInt_t kISkipProcessChk
if set, skip process validity checks
static AlgConfigPool * Instance()
Initial State information.
const Algorithm * SubAlg(const RgKey ®istry_key) const