StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SANCtable.h
1 #include <iostream>
2 #include <fstream>
3 #include <complex>
4 using namespace std;
5 
6 extern "C"
7 {
8  void upup_(int *L1,int *L2, int *L3,int *L4,double *s,double *t,double *u,int *iz,double *har,double *hai);
9  void downdown_(int *L1,int *L2, int *L3,int *L4,double *s,double *t,double *u,int *iz,double *har,double *hai);
10  void flagset_(int *iqedx,int *iewx,int *ibornx,int *gfschemex,int *ifggx,double *ncx,double *fcx,double *tlmu2x);
11  void paraget_(double *mtax, double *conhcx, double *pix);
12  void printconsts_(int *pmg);
13 }
14 
15 class SANCtable
16 {
17 //-----------------------------------------------------------------------------
18 //-STATIC PART-----------------------------------------------------------------
19 //-----------------------------------------------------------------------------
20 public:
21  static void setDimensions(int n1, int n2, int n3, int nc);
22  static void setRanges(double sn1, double sx1, double sn2, double sx2, double sn3, double sx3);
23  static void setFlags();
24 private:
25  static int ns1,ns2,ns3,ncos;
26  static double smin1,smax1,smin2,smax2,smin3,smax3;
27  static int iqed,iew,iborn,gfscheme,ifgg;
28  static double nc,fc,tlmu2;
29 //-----------------------------------------------------------------------------
30 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
32 public:
33  SANCtable():flav(1),born(false),isOpen(false) {}
34  SANCtable(char *filename):flav(1),born(false) { open(filename); }
35  void setFixedLength(int prc=8);
36  void setBornLevel(bool bn) { born=bn; }
37  void setFlavor(int flv) { flav=flv; }
38  bool addHeader();
39  bool addFile(char *name);
40  void addRange(int rangeNo,bool isLog=false);
41  void open(char *name);
42  void close();
43  ~SANCtable() { if(isOpen) close(); }
44 protected:
45  bool isOpen,born;
46  int flav;
47 private:
48  double Rcalc(int flav, double sloop,double costhetloop);
49  double R[4][4];
50  ofstream f;
51 };