LwlynSmithFF.cxx
Go to the documentation of this file.
1 //____________________________________________________________________________
2 /*
3  Copyright (c) 2003-2019, The GENIE Collaboration
4  For the full text of the license visit http://copyright.genie-mc.org
5  or see $GENIE/LICENSE
6 
7  Author: Costas Andreopoulos <costas.andreopoulos \at stfc.ac.uk>
8  University of Liverpool & STFC Rutherford Appleton Lab
9 
10  For the class documentation see the corresponding header file.
11 
12  Important revisions after version 2.0.0 :
13  @ Sep 19, 2009 - CA
14  Renamed LlewellynSmithModel -> LwlynSmithFF
15  @ Aug 27, 2013 - AM
16  Implemented Axial Form Factor Model structure
17 
18 */
19 //____________________________________________________________________________
20 
21 #include <TMath.h>
22 
35 
36 using namespace genie;
37 using namespace genie::constants;
38 
39 //____________________________________________________________________________
42 {
43 
44 }
45 //____________________________________________________________________________
48 {
49 
50 }
51 //____________________________________________________________________________
53 QELFormFactorsModelI(name, config)
54 {
55 
56 }
57 //____________________________________________________________________________
59 {
60  if (fCleanUpfElFFModel) {
61  delete fElFFModel;
62  }
63 }
64 //____________________________________________________________________________
65 double LwlynSmithFF::StrangeF1V(const Interaction * interaction) const
66 {
67  double f1p = this->F1P(interaction);
68  double f1n = this->F1N(interaction);
69  double value = 0.;
70 
71  const XclsTag & xcls = interaction->ExclTag();
72  int pdgc = xcls.StrangeHadronPdg();
73 
74  if (pdgc == kPdgSigmaM) value = -1.* (f1p + 2 * f1n);
75  else if (pdgc == kPdgLambda) value = -kSqrt3 / kSqrt2 * f1p;
76  else if (pdgc == kPdgSigma0) value = -1.* kSqrt2 / 2 * (f1p + 2 * f1n);
77 
78  return value;
79 }
80 //____________________________________________________________________________
81 double LwlynSmithFF::StrangexiF2V(const Interaction * interaction) const
82 {
83  const XclsTag & xcls = interaction->ExclTag();
84  int pdgc = xcls.StrangeHadronPdg();
85 
86  double f2p = this->F2P(interaction);
87  double f2n = this->F2N(interaction);
88  double value = 0.;
89 
90  if (pdgc == kPdgSigmaM)
91  value = -1.*(f2p + 2.* f2n) ;
92  else if (pdgc == kPdgLambda)
93  value = (-kSqrt3 / kSqrt2 * f2p) ;
94  else if (pdgc == kPdgSigma0)
95  value = -1.* kSqrt2 / 2 * (f2p + 2.* f2n) ;
96 
97  return value;
98 }
99 
100 //____________________________________________________________________________
101 double LwlynSmithFF::StrangeFA(const Interaction * interaction) const
102 {
103  double value = 0.;
104 
105  const XclsTag & xcls = interaction->ExclTag();
106  int pdgc = xcls.StrangeHadronPdg();
107 
108  if (pdgc == kPdgSigmaM) value = +1 * (1 - 2 * fFDratio);
109  else if (pdgc == kPdgLambda) value = -1 / kSqrt6 * (1 + 2 * fFDratio);
110  else if (pdgc == kPdgSigma0) value = +1 * kSqrt2 / 2 * (1 - 2 * fFDratio);
111 
112  fAxFF.Calculate(interaction);
113  value *= fAxFF.FA();
114 
115  return value;
116 }
117 //____________________________________________________________________________
118 double LwlynSmithFF::F1P(const Interaction * interaction) const
119 {
120  fELFF.Calculate(interaction);
121  double t = this->tau(interaction);
122  double T = 1 / (1 - t);
123  return T * (fELFF.Gep() - t * fELFF.Gmp());
124 }
125 //____________________________________________________________________________
126 double LwlynSmithFF::F2P(const Interaction * interaction) const
127 {
128  fELFF.Calculate(interaction);
129  double t = this->tau(interaction);
130  double T = 1 / (1 - t);
131  return T * (fELFF.Gmp() - fELFF.Gep());
132 }
133 //____________________________________________________________________________
134 double LwlynSmithFF::F1N(const Interaction * interaction) const
135 {
136  fELFF.Calculate(interaction);
137  double t = this->tau(interaction);
138  double T = 1 / (1 - t);
139  return T * (fELFF.Gen() - t * fELFF.Gmn());
140 }
141 //____________________________________________________________________________
142 double LwlynSmithFF::F2N(const Interaction * interaction) const
143 {
144  fELFF.Calculate(interaction);
145  double t = this->tau(interaction);
146  double T = 1 / (1 - t);
147  return T * (fELFF.Gmn() - fELFF.Gen());
148 }
149 //____________________________________________________________________________
150 double LwlynSmithFF::F1V(const Interaction * interaction) const
151 {
152  double t = this->tau(interaction);
153  double gve = this->GVE(interaction);
154  double gvm = this->GVM(interaction);
155 
156  double _F1V = (gve - t*gvm) / (1-t);
157  return _F1V;
158 }
159 //____________________________________________________________________________
160 double LwlynSmithFF::xiF2V(const Interaction * interaction) const
161 {
162  double t = this->tau(interaction);
163  double gve = this->GVE(interaction);
164  double gvm = this->GVM(interaction);
165 
166  double _xiF2V = (gvm-gve) / (1-t);
167  return _xiF2V;
168 }
169 //____________________________________________________________________________
170 double LwlynSmithFF::FA(const Interaction * interaction) const
171 {
172  //-- compute FA(q2)
173 
174  fAxFF.Calculate(interaction);
175  return fAxFF.FA();
176 }
177 //____________________________________________________________________________
178 double LwlynSmithFF::Fp(const Interaction * interaction) const
179 {
180  // get momentum transfer
181  const Kinematics & kine = interaction->Kine();
182  double q2 = kine.q2();
183 
184  // get struck nucleon mass & set pion mass
185  const InitialState & init_state = interaction->InitState();
186  double MN = init_state.Tgt().HitNucMass();
187  double MN2 = TMath::Power(MN, 2);
188  double Mpi = kPionMass;
189  double Mpi2 = TMath::Power(Mpi, 2);
190 
191  // calculate FA
192  double fa = this->FA(interaction);
193 
194  // calculate Fp
195  double _Fp = 2. * MN2 * fa/(Mpi2-q2);
196  return _Fp;
197 }
198 //____________________________________________________________________________
200 {
201  Algorithm::Configure(config);
202  this->LoadConfig();
203 }
204 //____________________________________________________________________________
206 {
207  Algorithm::Configure(config);
208  this->LoadConfig();
209 }
210 //____________________________________________________________________________
212 {
213 // Load configuration data from its configuration Registry (or global defaults)
214 // to private data members
215  fElFFModel =
216  dynamic_cast<const ELFormFactorsModelI *> (this->SubAlg("ElasticFormFactorsModel"));
218 
219  fCleanUpfElFFModel = false;
220  bool useElFFTE = false;
221  GetParam( "UseElFFTransverseEnhancement", useElFFTE ) ;
222  if( useElFFTE ) {
223  const ELFormFactorsModelI* sub_alg = fElFFModel;
224  fElFFModel =
225  dynamic_cast<const ELFormFactorsModelI *> (this->SubAlg("TransverseEnhancement"));
226  dynamic_cast<const TransverseEnhancementFFModel*>(fElFFModel)->SetElFFBaseModel(
227  sub_alg);
228  fCleanUpfElFFModel = true;
229  }
230 
232 
233  fAxFFModel =
234  dynamic_cast<const AxialFormFactorModelI *> (this->SubAlg("AxialFormFactorModel"));
235 
238 
239  // anomalous magnetic moments
240  GetParam( "AnomMagnMoment-P", fMuP ) ;
241  GetParam( "AnomMagnMoment-N", fMuN ) ;
242 
243  // weinberg angle
244  double thw ;
245  GetParam( "WeinbergAngle", thw ) ;
246  fSin28w = TMath::Power(TMath::Sin(thw), 2);
247 
248  double d,f ;
249  GetParam( "SU3-D", d ) ;
250  GetParam( "SU3-F", f ) ;
251  fFDratio = f/(d+f);
252 }
253 //____________________________________________________________________________
254 double LwlynSmithFF::tau(const Interaction * interaction) const
255 {
256 // computes q^2 / (4 * MNucl^2)
257 
258  //-- get kinematics & initial state parameters
259  const Kinematics & kinematics = interaction->Kine();
260  const InitialState & init_state = interaction->InitState();
261  double q2 = kinematics.q2();
262  double Mnucl = init_state.Tgt().HitNucMass();
263  double Mnucl2 = TMath::Power(Mnucl, 2);
264 
265  //-- calculate q^2 / (4*Mnuc^2)
266  return q2/(4*Mnucl2);
267 }
268 //____________________________________________________________________________
269 double LwlynSmithFF::GVE(const Interaction * interaction) const
270 {
271  //-- compute GVE using CVC
272 
273  fELFF.Calculate(interaction);
274  double gve = fELFF.Gep() - fELFF.Gen();
275  return gve;
276 }
277 //____________________________________________________________________________
278 double LwlynSmithFF::GVM(const Interaction * interaction) const
279 {
280  //-- compute GVM using CVC
281 
282  fELFF.Calculate(interaction);
283  double gvm = fELFF.Gmp() - fELFF.Gmn();
284  return gvm;
285 }
286 //____________________________________________________________________________
287 
virtual double StrangeF1V(const Interaction *interaction) const
ELFormFactors fELFF
Definition: LwlynSmithFF.h:81
AxialFormFactor fAxFF
Definition: LwlynSmithFF.h:82
const XML_Char * name
Definition: expat.h:151
static const double kSqrt3
Definition: Constants.h:117
virtual double StrangeFA(const Interaction *interaction) const
Basic constants.
virtual double tau(const Interaction *interaction) const
static const double kSqrt2
Definition: Constants.h:116
THE MAIN GENIE PROJECT NAMESPACE
Definition: GeneratorBase.h:8
const int kPdgLambda
Definition: PDGCodes.h:69
Pure abstract base class. Defines the AxialFormFactorModelI interface to be implemented by LlewellynS...
virtual double GVM(const Interaction *interaction) const
double HitNucMass(void) const
Definition: Target.cxx:250
static const double kSqrt6
Definition: Constants.h:120
Generated/set kinematical variables for an event.
Definition: Kinematics.h:40
virtual double StrangexiF2V(const Interaction *interaction) const
const int kPdgSigma0
Definition: PDGCodes.h:72
virtual double GVE(const Interaction *interaction) const
Definition: config.py:1
void Calculate(const Interaction *interaction)
Calculate the form factors for the input interaction using the attached algorithm.
void SetModel(const AxialFormFactorModelI *model)
Attach an algorithm.
double Gen(void) const
Get the computed form factor Gen.
Definition: ELFormFactors.h:57
Contains minimal information for tagging exclusive processes.
Definition: XclsTag.h:37
Double_t q2[12][num]
Definition: f2_nu.C:137
Summary information for an interaction.
Definition: Interaction.h:56
double q2(bool selected=false) const
Definition: Kinematics.cxx:151
int StrangeHadronPdg(void) const
Definition: XclsTag.h:53
Pure abstract base class. Defines the QELFormFactorsModelI interface to be implemented by any algorit...
virtual void Configure(const Registry &config)
const XML_Char int const XML_Char * value
Definition: expat.h:331
Pure abstract base class. Defines the ELFormFactorsModelI interface to be implemented by any algorith...
const Kinematics & Kine(void) const
Definition: Interaction.h:71
virtual void Configure(const Registry &config)
Definition: Algorithm.cxx:70
double FA(void) const
Get the computed axial form factor.
Float_t d
Definition: plot.C:236
virtual double F1N(const Interaction *interaction) const
virtual double F2N(const Interaction *interaction) const
virtual double xiF2V(const Interaction *interaction) const
Compute the form factor xi*F2V for the input interaction.
const AxialFormFactorModelI * fAxFFModel
Definition: LwlynSmithFF.h:79
void Calculate(const Interaction *interaction)
Calculate the form factors for the input interaction using the attached algorithm.
const int kPdgSigmaM
Definition: PDGCodes.h:73
virtual double FA(const Interaction *interaction) const
Compute the form factor FA for the input interaction.
double Gmn(void) const
Get the computed form factor Gmn.
Definition: ELFormFactors.h:60
virtual void LoadConfig(void)
virtual double F1P(const Interaction *interaction) const
static const double kPionMass
Definition: Constants.h:74
A registry. Provides the container for algorithm configuration parameters.
Definition: Registry.h:66
virtual double F2P(const Interaction *interaction) const
const XclsTag & ExclTag(void) const
Definition: Interaction.h:72
double Gmp(void) const
Get the computed form factor Gmp.
Definition: ELFormFactors.h:54
assert(nhit_max >=nhit_nbins)
double Gep(void) const
Get the computed form factor Gep.
Definition: ELFormFactors.h:51
const InitialState & InitState(void) const
Definition: Interaction.h:69
double T
Definition: Xdiff_gwt.C:5
const ELFormFactorsModelI * fElFFModel
Definition: LwlynSmithFF.h:78
bool GetParam(const RgKey &name, T &p, bool is_top_call=true) const
const Target & Tgt(void) const
Definition: InitialState.h:67
void SetModel(const ELFormFactorsModelI *model)
Attach an algorithm.
Modification of magnetic form factors to match observed enhancement in transverse cross section of th...
void kinematics()
Definition: kinematics.C:10
Most commonly used PDG codes. A set of utility functions to handle PDG codes is provided in PDGUtils...
virtual double F1V(const Interaction *interaction) const
Compute the form factor F1V for the input interaction.
Initial State information.
Definition: InitialState.h:49
TFile fa("Li7.root")
const Algorithm * SubAlg(const RgKey &registry_key) const
Definition: Algorithm.cxx:353
virtual double Fp(const Interaction *interaction) const
Compute the form factor Fp for the input interaction.