tmdlib is hosted by Hepforge, IPPP Durham
TMDlib  1.0.X
TMDlib.h
Go to the documentation of this file.
1 #ifndef TMDlib_H
2 #define TMDlib_H
3 
4 #include <stdio.h>
5 #include <stdlib.h>
6 #include <string.h>
7 #include <cstring>
8 #include <math.h>
9 #include <vector>
10 #include <iostream>
11 
12 using namespace std;
13 
14 namespace TMDlib {
15 
16  double ipow(double,int);
17  extern int iipow(int,int);
18  // to initialise TMD with name ( and optionally with iset and imode
19  void TMDinit(const string name, int irep, int imode ) ;
20  void TMDinit(const string name, int irep ) ;
21  void TMDinit(const string name) ;
22  void TMDinit(int & iset) ;
23 
24  // TMDpdf 1st to return TMD value at x,xbar,kt,mu as a vector
25  vector<double> TMDpdf( double x, double xbar, double kt, double mu) ;
26  // TMDpdf 2nd to return TMD value at x,xbar,kt,mu as a vector
27  vector<double> TMDpdf(int kf, double x, double xbar, double kt, double mu) ;
28  // TMDpdf 3rd to return TMD value at x,xbar,kt,mu as a vector
29  void TMDpdf( double x, double xbar, double kt, double mu, vector<double>& xpq) ;
30  // TMDpdf 4th to return TMD value at x,xbar,kt,mu as a vector
31  void TMDpdf(int kf, double x, double xbar, double kt, double mu, vector<double>& xpq) ;
32  // TMDpdf 5th to return TMD value at x,xbar,kt,mu for flavor
33  void TMDpdf( double x, double xbar, double kt, double mu, double& uval, double& dval, double& sea, double& charm, double& bottom, double& gluon );
34  // TMDpdf 6th to return TMD value at x,xbar,kt,mu for flavor
35  void TMDpdf(int kf, double x, double xbar, double kt, double mu, double& uval, double& dval, double& sea, double& charm, double& bottom, double& gluon );
36  // TMDpdf 7th to return TMD value at x,xbar,kt,mu for flavor
37  void TMDpdf( double x, double xbar, double kt, double mu, double& up, double& ubar, double& dn, double& dbar, double& strange, double& sbar, double& charm, double& cbar, double& bottom, double& bbar, double& gluon );
38  // TMDpdf 8th to return TMD value at x,xbar,kt,mu for flavor
39  void TMDpdf(int kf, double x, double xbar, double kt, double mu, double& up, double& ubar, double& dn, double& dbar, double& strange, double& sbar, double& charm, double& cbar, double& bottom, double& bbar, double& gluon );
40 
41  double TMDalphas(double mu);
42 
43  double TMDgetLam4( );
44  int TMDgetNf( );
45  int TMDgetOrderAlphaS( );
46  int TMDgetOrderPDF( );
47  double TMDgetXmin();
48  double TMDgetXmax();
49  double TMDgetQ2min();
50  double TMDgetQ2max();
51  int TMDnumberPDF(string name);
52 // tools
53 
54  double Cdhfint(int narg, double arg[500], int nent[500], double ent[500], double table[1000000]);
55  void polint(double xa[], double ya[], int n, double x, double& y, double& dy) ;
56  void polin3(double x1a[], double x2a[], double x3a[], double ya[][1][4], int m, int n, int o, double x1, double x2, double x3, double& y, double& dy);
57 
58 
59 // ccfm stuff
60  void ccfmuPDF(int kf, double x, double kt, double p, double& up, double& ubar, double& dn, double& dbar, double& strange, double& sbar, double& charm, double& cbar, double& bottom, double& bbar, double& top, double& tbar, double& phot, double& gluon ) ;
61  void ccfmuPDFn(int kf, double x, double kt, double p, double& up, double& ubar, double& dn, double& dbar, double& strange, double& sbar, double& charm, double& cbar, double& bottom, double& bbar, double& top, double& tbar, double& phot, double& gluon ) ;
62 
63 // GBW
64  void gbwuPDFlight(double x, double kt, double& gluon ) ;
65  void gbwuPDFcharm(double x, double kt, double& gluon ) ;
66  //double blueml(double x, double kt, double p ) ;
67 
68 
69 // SBRS
70  void sbrsPDF(int irep, int imode, double x, double kt, double p, double& uval, double& dval, double& sea, double& charm);
71 
72 // Kutak Sapeta
73  void ksPDF(double x, double kt, double p, double& upl, double& dn, double& sea, double& charm, double& bottom, double& gluon);
74  void ksuPDFgrid(int kf, double x, double kt , double p, double& up, double& dn, double& sea, double& charm, double& bottom, double& gluon ) ;
75  void ksDLCPDF(double x, double kt, double p, double& up, double& ubar, double& down, double& dbar, double& strange, double& sbar, double& charm,
76  double& cbar, double& bottom, double& bbar, double& gluon);
77  void ksBHKSPDF(double x, double kt, double p, double& up, double& ubar, double& down, double& dbar, double& strange, double& sbar, double& charm,
78  double& cbar, double& bottom, double& bbar, double& gluon);
79 
80 // M. Echevaria TMDgluon
81  void tmd_ME(int kf, double x, double kt , double p, double& uval, double& dval, double& sea, double& charm, double& bottom, double& gluon ) ;
82 
83  extern "C" {
84  // Fortran routines
85  // remember FORTRAN passes pointer (instead of values) to subroutines
86  #define initalphas initalphas_
87  void initalphas(int* iord, double* fr2, double* mur , double* asmur, double* mc, double* mb, double* mt);
88  #define unpol unpol_
89  void unpol(int* in , double* scale, double* scale2, double* bc, double* lam1, double* lam2, double* x_ME, double* kt_ME,double* Qf, double* result );
90  // #define asmur _asmur
91  #define blueml blueml_
92  double blueml(double* x, double* kt, double* p ) ;
93 
94  }
95 
96 
97 
98 
99 }
100 
101 #endif
void gbwuPDFlight(double x, double kt, double &gluon)
Definition: gbwuPDF.cc:14
void ccfmuPDFn(int kf, double x, double kt, double p, double &up, double &ubar, double &dn, double &dbar, double &strange, double &sbar, double &charm, double &cbar, double &bottom, double &bbar, double &top, double &tbar, double &phot, double &gluon)
Definition: ccfmuPDFn.cc:18
void ccfmuPDF(int kf, double x, double kt, double p, double &up, double &ubar, double &dn, double &dbar, double &strange, double &sbar, double &charm, double &cbar, double &bottom, double &bbar, double &top, double &tbar, double &phot, double &gluon)
Definition: ccfmuPDF.cc:18
int TMDnumberPDF(string name)
Definition: TMDutils.cc:205
Definition: TMDlib.h:14
double Cdhfint(int narg, double arg[500], int nent[500], double ent[500], double table[1000000])
Definition: Cdhfint.cc:16
double TMDgetQ2min()
Definition: TMDutils.cc:159
void ksBHKSPDF(double x, double kt, double p, double &up, double &ubar, double &down, double &dbar, double &strange, double &sbar, double &charm, double &cbar, double &bottom, double &bbar, double &gluon)
Definition: ksBHKSPDF.cc:20
void ksPDF(double x, double kt, double p, double &upl, double &dn, double &sea, double &charm, double &bottom, double &gluon)
Definition: ksPDF.cc:20
double TMDgetLam4()
Definition: TMDutils.cc:8
void TMDpdf(int kf, double x, double xbar, double kt, double mu, double &up, double &ubar, double &dn, double &dbar, double &strange, double &sbar, double &charm, double &cbar, double &bottom, double &bbar, double &gluon)
Definition: TMDhandler.cc:759
double ipow(double, int)
double TMDalphas(double mu)
Definition: TMDalphas.cc:10
void gbwuPDFcharm(double x, double kt, double &gluon)
Definition: gbwuPDF.cc:48
int TMDgetNf()
Definition: TMDutils.cc:40
int TMDgetOrderPDF()
Definition: TMDutils.cc:87
void polint(double xa[], double ya[], int n, double x, double &y, double &dy)
Definition: polint.cc:12
int iset
Definition: sbrsPDF.cc:15
#define unpol
Definition: TMDlib.h:88
void tmd_ME(int kf, double x, double kt, double p, double &uval, double &dval, double &sea, double &charm, double &bottom, double &gluon)
Definition: tmd_ME.cc:13
void sbrsPDF(int irep, int imode, double x, double kt, double p, double &uval, double &dval, double &sea, double &charm)
Definition: sbrsPDF.cc:20
void ksDLCPDF(double x, double kt, double p, double &up, double &ubar, double &down, double &dbar, double &strange, double &sbar, double &charm, double &cbar, double &bottom, double &bbar, double &gluon)
Definition: ksDLCPDF.cc:20
double TMDgetXmax()
Definition: TMDutils.cc:135
int imode
Definition: TMDhandler.cc:8
void polin3(double x1a[], double x2a[], double x3a[], double ya[][1][4], int m, int n, int o, double x1, double x2, double x3, double &y, double &dy)
Definition: polint.cc:46
double TMDgetQ2max()
Definition: TMDutils.cc:180
int iipow(int, int)
void TMDinit(int &iset)
Definition: TMDhandler.cc:47
int TMDgetOrderAlphaS()
Definition: TMDutils.cc:59
int irep
Definition: TMDhandler.cc:8
void ksuPDFgrid(int kf, double x, double kt, double p, double &up, double &dn, double &sea, double &charm, double &bottom, double &gluon)
double TMDgetXmin()
Definition: TMDutils.cc:110
#define blueml
Definition: TMDlib.h:91
#define initalphas
Definition: TMDlib.h:86