|
||||
File indexing completed on 2024-11-15 09:00:20
0001 ///////////////////////////////////////////////////////////////////// 0002 // Class header file for MSTW PDFs. 0003 // Original C++ version by Jeppe Andersen. 0004 // Modified by Graeme Watt <Graeme.Watt(at)cern.ch>. 0005 // Updated 25/06/2010: Enlarge allowed range for m_c and m_b. 0006 // 0007 // Usage: 0008 // Initialising an instance of the class: 0009 // c_mstwpdf pdf("filename.dat") 0010 // with "filename.dat" being the data file to interpolate. 0011 // 0012 // A call to the method 0013 // c_mstwpdf::update(x,q) 0014 // updates the parton content to the values at (x,q^2). 0015 // The parton contents can then be accessed in 0016 // c_mstwpdf::cont.upv etc. 0017 // This method is faster if all the flavours need to be evaluated. 0018 // 0019 // A call to the method 0020 // c_mstwpdf::parton(f,x,q) 0021 // will return the value of the PDF with flavour 'f' at (x,q^2). 0022 // Now use PDG notation for parton flavour (apart from gluon=0, not 21): 0023 // f = -6, -5, -4, -3, -2, -1,0,1,2,3,4,5,6 0024 // = tbar,bbar,cbar,sbar,ubar,dbar,g,d,u,s,c,b,t. 0025 // Can also get valence quarks directly: 0026 // f = 7, 8, 9,10,11,12 0027 // = dv,uv,sv,cv,bv,tv. 0028 // Photon: f = 13. 0029 // This method is faster if only one flavour needs to be evaluated. 0030 ///////////////////////////////////////////////////////////////////// 0031 0032 #include <istream> 0033 0034 #ifndef _MSTWPDF_H_INCLUDED_ 0035 #define _MSTWPDF_H_INCLUDED_ 0036 0037 namespace mstw { 0038 0039 class c_mstwpdf { 0040 private: 0041 const static int np=12; // number of parton flavours 0042 const static int nx=64; // number of x grid points 0043 const static int nq=48; // number of q^2 grid points 0044 int nqc0; // number of q^2 bins below charm threshold 0045 int nqb0; // number of q^2 bins below bottom threshold 0046 static double xx[nx+1]; // grid points in x 0047 static double qq[nq+1]; // grid points in q^2 0048 double c[np+1][nx][nq][5][5]; // coefficients used for interpolation 0049 double parton_interpolate(int flavour,double xxx,double qqq) const; 0050 double parton_extrapolate(int flavour,double xxx,double qqq) const; 0051 bool extrapolate; 0052 bool fatal; 0053 void init(std::istream& data_file,bool extrapolate,bool fatal,char const* filename); 0054 public: 0055 struct s_partoncontent { 0056 double upv,dnv,usea,dsea,str,sbar,chm,cbar,bot,bbar,glu,phot; 0057 } cont; 0058 double xmin,xmax,qsqmin,qsqmax; 0059 double mCharm,mBottom,alphaSQ0,alphaSMZ; 0060 double distance,tolerance; 0061 int alphaSorder,alphaSnfmax; 0062 void update(double x,double q); // update cont 0063 double parton(int flavour,double x,double q) const; 0064 // The constructor (initialises the functions): 0065 c_mstwpdf(char const* filename,bool extrapolate=false,bool fatal=true); 0066 c_mstwpdf(std::istream& data_file, bool extrapolate=false, bool fatal=true); 0067 }; 0068 0069 } 0070 0071 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |