GENIEGenerator
Loading...
Searching...
No Matches
genie::RosenbluthPXSec Class Reference

Differential cross section for charged lepton elastic scattering.
Is a concrete implementation of the XSecAlgorithmI interface.
. More...

#include <RosenbluthPXSec.h>

Inheritance diagram for genie::RosenbluthPXSec:
[legend]
Collaboration diagram for genie::RosenbluthPXSec:
[legend]

Public Member Functions

 RosenbluthPXSec ()
 RosenbluthPXSec (string config)
virtual ~RosenbluthPXSec ()
double XSec (const Interaction *i, KinePhaseSpace_t k) const
 Compute the cross section for the input interaction.
double Integral (const Interaction *i) const
bool ValidProcess (const Interaction *i) const
 Can this cross section algorithm handle the input process?
void Configure (const Registry &config)
void Configure (string param_set)
Public Member Functions inherited from genie::XSecAlgorithmI
virtual ~XSecAlgorithmI ()
virtual bool ValidKinematics (const Interaction *i) const
 Is the input kinematical point a physically allowed one?
Public Member Functions inherited from genie::Algorithm
virtual ~Algorithm ()
virtual void FindConfig (void)
virtual const RegistryGetConfig (void) const
RegistryGetOwnedConfig (void)
virtual const AlgIdId (void) const
 Get algorithm ID.
virtual AlgStatus_t GetStatus (void) const
 Get algorithm status.
virtual bool AllowReconfig (void) const
virtual AlgCmp_t Compare (const Algorithm *alg) const
 Compare with input algorithm.
virtual void SetId (const AlgId &id)
 Set algorithm ID.
virtual void SetId (string name, string config)
const AlgorithmSubAlg (const RgKey &registry_key) const
void AdoptConfig (void)
void AdoptSubstructure (void)
virtual void Print (ostream &stream) const
 Print algorithm info.

Private Member Functions

void LoadConfig (void)

Private Attributes

const XSecIntegratorIfXSecIntegrator
const ELFormFactorsModelIfElFFModel
ELFormFactors fELFF
bool fCleanUpfElFFModel
double fXSecEMScale

Additional Inherited Members

Static Public Member Functions inherited from genie::Algorithm
static string BuildParamVectKey (const std::string &comm_name, unsigned int i)
static string BuildParamVectSizeKey (const std::string &comm_name)
static string BuildParamMatKey (const std::string &comm_name, unsigned int i, unsigned int j)
static string BuildParamMatRowSizeKey (const std::string &comm_name)
static string BuildParamMatColSizeKey (const std::string &comm_name)
Protected Member Functions inherited from genie::XSecAlgorithmI
 XSecAlgorithmI ()
 XSecAlgorithmI (string name)
 XSecAlgorithmI (string name, string config)
Protected Member Functions inherited from genie::Algorithm
 Algorithm ()
 Algorithm (string name)
 Algorithm (string name, string config)
void Initialize (void)
void DeleteConfig (void)
void DeleteSubstructure (void)
RegistryExtractLocalConfig (const Registry &in) const
RegistryExtractLowerConfig (const Registry &in, const string &alg_key) const
 Split an incoming configuration Registry into a block valid for the sub-algo identified by alg_key.
template<class T>
bool GetParam (const RgKey &name, T &p, bool is_top_call=true) const
template<class T>
bool GetParamDef (const RgKey &name, T &p, const T &def) const
template<class T>
int GetParamVect (const std::string &comm_name, std::vector< T > &v, bool is_top_call=true) const
 Handle to load vectors of parameters.
int GetParamVectKeys (const std::string &comm_name, std::vector< RgKey > &k, bool is_top_call=true) const
template<class T>
int GetParamMat (const std::string &comm_name, TMatrixT< T > &mat, bool is_top_call=true) const
 Handle to load matrix of parameters.
template<class T>
int GetParamMatSym (const std::string &comm_name, TMatrixTSym< T > &mat, bool is_top_call=true) const
int GetParamMatKeys (const std::string &comm_name, std::vector< RgKey > &k, bool is_top_call=true) const
int AddTopRegistry (Registry *rp, bool owns=true)
 add registry with top priority, also update ownership
int AddLowRegistry (Registry *rp, bool owns=true)
 add registry with lowest priority, also update ownership
int MergeTopRegistry (const Registry &r)
int AddTopRegisties (const vector< Registry * > &rs, bool owns=false)
 Add registries with top priority, also udated Ownerships.
Protected Attributes inherited from genie::Algorithm
bool fAllowReconfig
bool fOwnsSubstruc
 true if it owns its substructure (sub-algs,...)
AlgId fID
 algorithm name and configuration set
vector< Registry * > fConfVect
vector< bool > fOwnerships
 ownership for every registry in fConfVect
AlgStatus_t fStatus
 algorithm execution status
AlgMapfOwnedSubAlgMp
 local pool for owned sub-algs (taken out of the factory pool)

Detailed Description

Differential cross section for charged lepton elastic scattering.
Is a concrete implementation of the XSecAlgorithmI interface.
.

References:\n See for example:
R.Bradford, A.Bodek, H.Budd, J.Arrington, Nucl.Phys.B159 (2006) 127
Author
Costas Andreopoulos <c.andreopoulos \at cern.ch> University of Liverpool
Created:\n Sep 15, 2009
License:\n Copyright (c) 2003-2025, The GENIE Collaboration
For the full text of the license visit http://copyright.genie-mc.org

Definition at line 32 of file RosenbluthPXSec.h.

Constructor & Destructor Documentation

◆ RosenbluthPXSec() [1/2]

RosenbluthPXSec::RosenbluthPXSec ( )

Definition at line 31 of file RosenbluthPXSec.cxx.

31 :
32XSecAlgorithmI("genie::RosenbluthPXSec")
33{
34
35}

References genie::XSecAlgorithmI::XSecAlgorithmI().

◆ RosenbluthPXSec() [2/2]

RosenbluthPXSec::RosenbluthPXSec ( string config)

Definition at line 37 of file RosenbluthPXSec.cxx.

37 :
38XSecAlgorithmI("genie::RosenbluthPXSec", config)
39{
40
41}

References genie::XSecAlgorithmI::XSecAlgorithmI().

◆ ~RosenbluthPXSec()

RosenbluthPXSec::~RosenbluthPXSec ( )
virtual

Definition at line 43 of file RosenbluthPXSec.cxx.

44{
46 delete fElFFModel;
47 }
48}
const ELFormFactorsModelI * fElFFModel

References fCleanUpfElFFModel, and fElFFModel.

Member Function Documentation

◆ Configure() [1/2]

void RosenbluthPXSec::Configure ( const Registry & config)
virtual

Configure the algorithm with an external registry The registry is merged with the top level registry if it is owned, Otherwise a copy of it is added with the highest priority

Reimplemented from genie::Algorithm.

Definition at line 165 of file RosenbluthPXSec.cxx.

166{
167 Algorithm::Configure(config);
168 this->LoadConfig();
169}
virtual void Configure(const Registry &config)
Definition Algorithm.cxx:62

References genie::Algorithm::Configure(), and LoadConfig().

◆ Configure() [2/2]

void RosenbluthPXSec::Configure ( string config)
virtual

Configure the algorithm from the AlgoConfigPool based on param_set string given in input An algorithm contains a vector of registries coming from different xml configuration files, which are loaded according a very precise prioriy This methods will load a number registries in order of priority: 1) "Tunable" parameter set from CommonParametes. This is loaded with the highest prioriry and it is designed to be used for tuning procedure Usage not expected from the user. 2) For every string defined in "CommonParame" the corresponding parameter set will be loaded from CommonParameter.xml 3) parameter set specified by the config string and defined in the xml file of the algorithm 4) if config is not "Default" also the Default parameter set from the same xml file will be loaded Effectively this avoids the repetion of a parameter when it is not changed in the requested configuration

Reimplemented from genie::Algorithm.

Definition at line 171 of file RosenbluthPXSec.cxx.

172{
173 Algorithm::Configure(config);
174 this->LoadConfig();
175}

References genie::Algorithm::Configure(), and LoadConfig().

◆ Integral()

double RosenbluthPXSec::Integral ( const Interaction * i) const
virtual

Integrate the model over the kinematic phase space available to the input interaction (kinematical cuts can be included)

Implements genie::XSecAlgorithmI.

Definition at line 137 of file RosenbluthPXSec.cxx.

138{
139 double xsec = fXSecIntegrator->Integrate(this,interaction);
140 return xsec;
141}
const XSecIntegratorI * fXSecIntegrator

References fXSecIntegrator.

◆ LoadConfig()

void RosenbluthPXSec::LoadConfig ( void )
private

Definition at line 177 of file RosenbluthPXSec.cxx.

178{
179 fElFFModel = 0;
180
181 // Cross section scaling factor
182 GetParam( "QEL-EM-XSecScale", fXSecEMScale ) ;
183
184 // load elastic form factors model
185 fElFFModel = dynamic_cast<const ELFormFactorsModelI *> ( this -> SubAlg("ElasticFormFactorsModel" ) ) ;
186
187 assert(fElFFModel);
188
189 fCleanUpfElFFModel = false;
190 bool useFFTE = false ;
191 GetParam( "UseElFFTransverseEnhancement", useFFTE ) ;
192 if( useFFTE ) {
193 const ELFormFactorsModelI* sub_alg = fElFFModel;
194 fElFFModel = dynamic_cast<const ELFormFactorsModelI *> ( this -> SubAlg("TransverseEnhancement") ) ;
195 dynamic_cast<const TransverseEnhancementFFModel*>(fElFFModel)->SetElFFBaseModel( sub_alg );
196 fCleanUpfElFFModel = true;
197 }
198 fELFF.SetModel(fElFFModel);
199
200 // load XSec Integrator
202 dynamic_cast<const XSecIntegratorI *> (this->SubAlg("XSec-Integrator"));
203 assert(fXSecIntegrator);
204}
bool GetParam(const RgKey &name, T &p, bool is_top_call=true) const
const Algorithm * SubAlg(const RgKey &registry_key) const

References fCleanUpfElFFModel, fELFF, fElFFModel, fXSecEMScale, fXSecIntegrator, genie::Algorithm::GetParam(), and genie::Algorithm::SubAlg().

Referenced by Configure(), and Configure().

◆ ValidProcess()

bool RosenbluthPXSec::ValidProcess ( const Interaction * i) const
virtual

Can this cross section algorithm handle the input process?

Implements genie::XSecAlgorithmI.

Definition at line 143 of file RosenbluthPXSec.cxx.

144{
145 if(interaction->TestBit(kISkipProcessChk)) return true;
146
147 const ProcessInfo & proc_info = interaction->ProcInfo();
148
149 if(!proc_info.IsQuasiElastic()) return false;
150 if(!proc_info.IsEM()) return false;
151
152 const InitialState & init_state = interaction->InitState();
153
154 int hitnuc = init_state.Tgt().HitNucPdg();
155 bool is_pn = (pdg::IsProton(hitnuc) || pdg::IsNeutron(hitnuc));
156 if (!is_pn) return false;
157
158 int probe = init_state.ProbePdg();
159 bool is_chgl = pdg::IsChargedLepton(probe);
160 if (!is_chgl) return false;
161
162 return true;
163}
const Target & Tgt(void) const
int ProbePdg(void) const
bool IsQuasiElastic(void) const
bool IsEM(void) const
int HitNucPdg(void) const
Definition Target.cxx:304
bool IsProton(int pdgc)
Definition PDGUtils.cxx:336
bool IsChargedLepton(int pdgc)
Definition PDGUtils.cxx:101
bool IsNeutron(int pdgc)
Definition PDGUtils.cxx:341
const UInt_t kISkipProcessChk
if set, skip process validity checks
Definition Interaction.h:47

References genie::Target::HitNucPdg(), genie::Interaction::InitState(), genie::pdg::IsChargedLepton(), genie::ProcessInfo::IsEM(), genie::pdg::IsNeutron(), genie::pdg::IsProton(), genie::ProcessInfo::IsQuasiElastic(), genie::kISkipProcessChk, genie::InitialState::ProbePdg(), genie::Interaction::ProcInfo(), and genie::InitialState::Tgt().

Referenced by XSec().

◆ XSec()

double RosenbluthPXSec::XSec ( const Interaction * i,
KinePhaseSpace_t k ) const
virtual

Compute the cross section for the input interaction.

Implements genie::XSecAlgorithmI.

Definition at line 50 of file RosenbluthPXSec.cxx.

52{
53 if(! this -> ValidProcess (interaction) ) return 0.;
54 if(! this -> ValidKinematics (interaction) ) return 0.;
55
56 // Get interaction information
57 const InitialState & init_state = interaction -> InitState();
58 const Kinematics & kinematics = interaction -> Kine();
59 const Target & target = init_state.Tgt();
60 const ProcessInfo & proc_info = interaction->ProcInfo();
61
62 int nucpdgc = target.HitNucPdg();
63 double E = init_state.ProbeE(kRfHitNucRest);
64 double Q2 = kinematics.Q2();
65 double M = target.HitNucMass();
66
67 double E2 = E*E;
68 double E3 = E*E2;
69 double M2 = M*M;
70
71 // Calculate scattering angle
72 //
73 // Q^2 = 4 * E^2 * sin^2 (theta/2) / ( 1 + 2 * (E/M) * sin^2(theta/2) ) =>
74 // sin^2 (theta/2) = MQ^2 / (4ME^2 - 2EQ^2)
75
76 double sin2_halftheta = M*Q2 / (4*M*E2 - 2*E*Q2);
77 double sin4_halftheta = TMath::Power(sin2_halftheta, 2.);
78 double cos2_halftheta = 1.-sin2_halftheta;
79 //unused double cos_halftheta = TMath::Sqrt(cos2_halftheta);
80 double tan2_halftheta = sin2_halftheta/cos2_halftheta;
81
82 // Calculate the elastic nucleon form factors
83 fELFF.Calculate(interaction);
84 double Gm = pdg::IsProton(nucpdgc) ? fELFF.Gmp() : fELFF.Gmn();
85 double Ge = pdg::IsProton(nucpdgc) ? fELFF.Gep() : fELFF.Gen();
86 double Ge2 = Ge*Ge;
87 double Gm2 = Gm*Gm;
88
89 // Calculate tau and the virtual photon polarization (epsilon)
90 double tau = Q2/(4*M2);
91 double epsilon = 1. / (1. + 2.*(1.+tau)*tan2_halftheta);
92
93 // Calculate the scattered lepton energy
94 double Ep = E / (1. + 2.*(E/M)*sin2_halftheta);
95 double Ep2 = Ep*Ep;
96
97 // Calculate the Mott cross section dsigma/dOmega
98 double xsec_mott = (0.25 * kAem2 * Ep / E3) * (cos2_halftheta/sin4_halftheta);
99
100 // Calculate the electron-nucleon elastic cross section dsigma/dOmega
101 double xsec = xsec_mott * (Ge2 + (tau/epsilon)*Gm2) / (1+tau);
102
103 // Convert dsigma/dOmega --> dsigma/dQ2
104 // xsec *= (kPi/(Ep*E)); // bug introduced in v3.0.6
105 xsec *= (kPi/(Ep2)); // fixed before v3.2
106
107 // The algorithm computes dxsec/dQ2
108 // Check whether variable tranformation is needed
109 if(kps!=kPSQ2fE) {
110 double J = utils::kinematics::Jacobian(interaction,kPSQ2fE,kps);
111#ifdef __GENIE_LOW_LEVEL_MESG_ENABLED__
112 LOG("Rosenbluth", pDEBUG)
113 << "Jacobian for transformation to: "
114 << KinePhaseSpace::AsString(kps) << ", J = " << J;
115#endif
116 xsec *= J;
117 }
118
119 // If requested, return the free nucleon xsec even for input nuclear tgt
120 if( interaction->TestBit(kIAssumeFreeNucleon) ) return xsec;
121
122 // Take into account the number of nucleons/tgt
123 int NNucl = (pdg::IsProton(nucpdgc)) ? target.Z() : target.N();
124 xsec *= NNucl;
125
126 // Compute & apply nuclear suppression factor
127 // (R(Q2) is adapted from NeuGEN - see comments therein)
128 double R = nuclear::NuclQELXSecSuppression("Default", 0.5, interaction);
129 xsec *= R;
130
131 // Apply given overall scaling factor
132 xsec *= fXSecEMScale ;
133
134 return xsec;
135}
#define pDEBUG
Definition Messenger.h:63
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE,...
Definition Messenger.h:96
double ProbeE(RefFrame_t rf) const
static string AsString(KinePhaseSpace_t kps)
double Q2(bool selected=false) const
bool ValidProcess(const Interaction *i) const
Can this cross section algorithm handle the input process?
int N(void) const
Definition Target.h:69
int Z(void) const
Definition Target.h:68
double HitNucMass(void) const
Definition Target.cxx:233
virtual bool ValidKinematics(const Interaction *i) const
Is the input kinematical point a physically allowed one?
const double epsilon
double Q2(const Interaction *const i)
double Jacobian(const Interaction *const i, KinePhaseSpace_t f, KinePhaseSpace_t t)
double J(double q0, double q3, double Enu, double ml)
Definition MECUtils.cxx:147
double NuclQELXSecSuppression(string kftable, double pmax, const Interaction *in)
@ kRfHitNucRest
Definition RefFrame.h:30
const UInt_t kIAssumeFreeNucleon
Definition Interaction.h:49

References genie::KinePhaseSpace::AsString(), epsilon, fELFF, fXSecEMScale, genie::Target::HitNucMass(), genie::Target::HitNucPdg(), genie::pdg::IsProton(), genie::utils::kinematics::Jacobian(), genie::constants::kAem2, genie::kIAssumeFreeNucleon, genie::constants::kPi, genie::kPSQ2fE, genie::kRfHitNucRest, LOG, genie::Target::N(), genie::utils::nuclear::NuclQELXSecSuppression(), pDEBUG, genie::InitialState::ProbeE(), genie::Interaction::ProcInfo(), genie::InitialState::Tgt(), genie::XSecAlgorithmI::ValidKinematics(), ValidProcess(), and genie::Target::Z().

Member Data Documentation

◆ fCleanUpfElFFModel

bool genie::RosenbluthPXSec::fCleanUpfElFFModel
private

Definition at line 56 of file RosenbluthPXSec.h.

Referenced by LoadConfig(), and ~RosenbluthPXSec().

◆ fELFF

ELFormFactors genie::RosenbluthPXSec::fELFF
mutableprivate

Definition at line 55 of file RosenbluthPXSec.h.

Referenced by LoadConfig(), and XSec().

◆ fElFFModel

const ELFormFactorsModelI* genie::RosenbluthPXSec::fElFFModel
private

Definition at line 54 of file RosenbluthPXSec.h.

Referenced by LoadConfig(), and ~RosenbluthPXSec().

◆ fXSecEMScale

double genie::RosenbluthPXSec::fXSecEMScale
private

Definition at line 57 of file RosenbluthPXSec.h.

Referenced by LoadConfig(), and XSec().

◆ fXSecIntegrator

const XSecIntegratorI* genie::RosenbluthPXSec::fXSecIntegrator
private

Definition at line 53 of file RosenbluthPXSec.h.

Referenced by Integral(), and LoadConfig().


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