Public Member Functions | Private Attributes | List of all members
genie::utils::gsl::d2XSecRESFast_dWQ2_E Class Reference

#include "/cvmfs/nova.opensciencegrid.org/externals/genie/v3_00_06_p01/Linux64bit+2.6-2.12-e17-debug/GENIE-Generator/src/Physics/Resonance/XSection/ReinSehgalRESXSecWithCacheFast.h"

Inheritance diagram for genie::utils::gsl::d2XSecRESFast_dWQ2_E:

Public Member Functions

 d2XSecRESFast_dWQ2_E (const XSecAlgorithmI *m, const Interaction *i)
 
 ~d2XSecRESFast_dWQ2_E ()
 
unsigned int NDim (void) const
 
double DoEval (const double *xin) const
 
ROOT::Math::IBaseFunctionMultiDim * Clone (void) const
 

Private Attributes

const XSecAlgorithmIfModel
 
const InteractionfInteraction
 
double fWmin
 
double fWmax
 
bool isfWcutLessfWmin
 
KPhaseSpacekps
 

Detailed Description

Definition at line 77 of file ReinSehgalRESXSecWithCacheFast.h.

Constructor & Destructor Documentation

genie::utils::gsl::d2XSecRESFast_dWQ2_E::d2XSecRESFast_dWQ2_E ( const XSecAlgorithmI m,
const Interaction i 
)

Definition at line 229 of file ReinSehgalRESXSecWithCacheFast.cxx.

References genie::Interaction::ExclTag(), fInteraction, fModel, fWmax, fWmin, genie::Registry::GetBool(), genie::Registry::GetBoolDef(), genie::Registry::GetDouble(), genie::Registry::GetDoubleDef(), isfWcutLessfWmin, kps, genie::utils::res::Mass(), genie::Range1D_t::max, genie::Range1D_t::min, genie::Interaction::PhaseSpacePtr(), genie::XclsTag::Resonance(), genie::utils::res::ResonanceIndex(), genie::utils::res::Width(), and genie::KPhaseSpace::WLim().

230  :
231 ROOT::Math::IBaseFunctionMultiDim(),
232 fModel(m),
233 fInteraction(i)
234 {
236  Range1D_t Wl = kps->WLim();
237  fWmin = Wl.min;
238  fWmax = Wl.max;
239  Registry fConfig = (const_cast<XSecAlgorithmI *>(fModel))->GetConfig();
240  bool fUsingDisResJoin = fConfig.GetBool("UseDRJoinScheme");
241  double fWcut = 999999;
242  if(fUsingDisResJoin)
243  {
244  fWcut = fConfig.GetDouble("Wcut");
245  }
246  fWmax=TMath::Min(fWcut, fWmax);
247  if (fWcut<fWmin)
248  isfWcutLessfWmin=true;
249  else
250  isfWcutLessfWmin=false;
251  bool fNormBW = fConfig.GetBoolDef("BreitWignerNorm", true);
252  if (fNormBW)
253  {
254  double fN2ResMaxNWidths = fConfig.GetDoubleDef("MaxNWidthForN2Res", 2.0);
255  double fN0ResMaxNWidths = fConfig.GetDoubleDef("MaxNWidthForN0Res", 6.0);
256  double fGNResMaxNWidths = fConfig.GetDoubleDef("MaxNWidthForGNRes", 4.0);
257  Resonance_t resonance = fInteraction->ExclTag().Resonance();
258  int IR = utils::res::ResonanceIndex (resonance);
259  double MR = utils::res::Mass (resonance);
260  double WR = utils::res::Width (resonance);
261  if (IR==0)
262  fWcut = MR + fN0ResMaxNWidths * WR;
263  else if (IR==2)
264  fWcut = MR + fN2ResMaxNWidths * WR;
265  else
266  fWcut = MR + fGNResMaxNWidths * WR;
267  fWmax=TMath::Min(fWcut, fWmax);
268  if (fWcut<fWmin)
269  isfWcutLessfWmin=true;
270  }
271 
272 }
Cross Section Calculation Interface.
RgDbl GetDoubleDef(RgKey key, RgDbl def_opt, bool set_def=true)
Definition: Registry.cxx:550
A simple [min,max] interval for doubles.
Definition: Range1.h:43
double Mass(Resonance_t res)
resonance mass (GeV)
double Width(Resonance_t res)
resonance width (GeV)
RgDbl GetDouble(RgKey key) const
Definition: Registry.cxx:489
enum genie::EResonance Resonance_t
KPhaseSpace * PhaseSpacePtr(void) const
Definition: Interaction.h:78
Resonance_t Resonance(void) const
Definition: XclsTag.h:62
double max
Definition: Range1.h:54
A registry. Provides the container for algorithm configuration parameters.
Definition: Registry.h:66
const XclsTag & ExclTag(void) const
Definition: Interaction.h:72
RgBool GetBool(RgKey key) const
Definition: Registry.cxx:475
double min
Definition: Range1.h:53
RgBool GetBoolDef(RgKey key, RgBool def_opt, bool set_def=true)
Definition: Registry.cxx:540
Range1D_t WLim(void) const
W limits.
int ResonanceIndex(Resonance_t res)
resonance idx, quark model / SU(6)
genie::utils::gsl::d2XSecRESFast_dWQ2_E::~d2XSecRESFast_dWQ2_E ( )

Definition at line 273 of file ReinSehgalRESXSecWithCacheFast.cxx.

274 {
275 
276 }

Member Function Documentation

ROOT::Math::IBaseFunctionMultiDim * genie::utils::gsl::d2XSecRESFast_dWQ2_E::Clone ( void  ) const
double genie::utils::gsl::d2XSecRESFast_dWQ2_E::DoEval ( const double *  xin) const

Definition at line 281 of file ReinSehgalRESXSecWithCacheFast.cxx.

References genie::units::cm2, E, fInteraction, fModel, fWmax, fWmin, isfWcutLessfWmin, genie::Interaction::KinePtr(), kps, genie::kPSWQ2fE, genie::Range1D_t::max, genie::Range1D_t::min, genie::utils::kinematics::Q2(), genie::KPhaseSpace::Q2Lim_W(), genie::Kinematics::SetQ2(), genie::Kinematics::SetW(), W, genie::XSecAlgorithmI::XSec(), and xsec.

282 {
283 // inputs:
284 // W
285 // Q2
286 // outputs:
287 // differential cross section [10^-38 cm^2/GeV^3] for Resonance production
288 //
289 
290  if (isfWcutLessfWmin)
291  return 0;
292  double W = fWmin+(fWmax-fWmin)*xin[0];
293  fInteraction->KinePtr()->SetW(W);
294  Range1D_t Q2l = kps->Q2Lim_W();
295  if (Q2l.min<0 || Q2l.max<0)
296  return 0.0;
297  double Q2 = Q2l.min+(Q2l.max-Q2l.min)*xin[1];
298  fInteraction->KinePtr()->SetQ2(Q2);
299  double xsec = fModel->XSec(fInteraction, kPSWQ2fE)*(fWmax-fWmin)*(Q2l.max-Q2l.min);
300  return xsec/(1E-38 * units::cm2);
301 }
double Q2(const Interaction *const i)
Definition: KineUtils.cxx:991
void SetQ2(double Q2, bool selected=false)
Definition: Kinematics.cxx:265
Kinematics * KinePtr(void) const
Definition: Interaction.h:76
virtual double XSec(const Interaction *i, KinePhaseSpace_t k=kPSfE) const =0
Compute the cross section for the input interaction.
A simple [min,max] interval for doubles.
Definition: Range1.h:43
Range1D_t Q2Lim_W(void) const
Q2 limits @ fixed W.
static const double cm2
Definition: Units.h:77
Float_t E
Definition: plot.C:20
Double_t xsec[nknots]
Definition: testXsec.C:47
double max
Definition: Range1.h:54
void SetW(double W, bool selected=false)
Definition: Kinematics.cxx:289
double min
Definition: Range1.h:53
#define W(x)
unsigned int genie::utils::gsl::d2XSecRESFast_dWQ2_E::NDim ( void  ) const

Definition at line 277 of file ReinSehgalRESXSecWithCacheFast.cxx.

278 {
279  return 2;
280 }

Member Data Documentation

const Interaction* genie::utils::gsl::d2XSecRESFast_dWQ2_E::fInteraction
private

Definition at line 90 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by Clone(), d2XSecRESFast_dWQ2_E(), and DoEval().

const XSecAlgorithmI* genie::utils::gsl::d2XSecRESFast_dWQ2_E::fModel
private

Definition at line 89 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by Clone(), d2XSecRESFast_dWQ2_E(), and DoEval().

double genie::utils::gsl::d2XSecRESFast_dWQ2_E::fWmax
private

Definition at line 92 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by d2XSecRESFast_dWQ2_E(), and DoEval().

double genie::utils::gsl::d2XSecRESFast_dWQ2_E::fWmin
private

Definition at line 91 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by d2XSecRESFast_dWQ2_E(), and DoEval().

bool genie::utils::gsl::d2XSecRESFast_dWQ2_E::isfWcutLessfWmin
private

Definition at line 93 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by d2XSecRESFast_dWQ2_E(), and DoEval().

KPhaseSpace* genie::utils::gsl::d2XSecRESFast_dWQ2_E::kps
private

Definition at line 94 of file ReinSehgalRESXSecWithCacheFast.h.

Referenced by d2XSecRESFast_dWQ2_E(), and DoEval().


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