BOSS 7.0.9
BESIII Offline Software System
Loading...
Searching...
No Matches
BesEvtGen-00-04-08/src/EvtGen/EvtGenBase/EvtHis2F.hh
Go to the documentation of this file.
1//--------------------------------------------------------------------------
2//
3// Environment:
4//
5// Module: EvtGen/EvtHis2F.hh
6//
7// Description: Class to handle H2F histogram
8//
9// Modification history:
10//
11// PING RG September 8, 2010 Module created
12//
13//------------------------------------------------------------------------
14
15#ifndef EvtHis2F_HH
16#define EvtHis2F_HH
17
18#include "TH1.h"
19#include "TAxis.h"
20#include "TH2.h"
21#include "TH3.h"
22#include "TFile.h"
23#include "TApplication.h"
24#include "TROOT.h"
25#include "TChain.h"
26#include "TDirectory.h"
27#include "EvtGenBase/EvtRandom.hh"
28
29class EvtHis2F {
30
31public:
32
34 virtual ~EvtHis2F();
35 void init();
36 void setFile(const char* dtfile);
37 void setHTitle(const char* htitle);
38 const char* getFile();
39 const char* getHTitle();
40 void HFill(double xmass2, double ymass2);
41 double getZvalue(double m12_square, double m13_square);
42 void HReweight();
43 bool AR(double xmass2,double ymass2); // major function: judge to accept or reject an event
44 bool AR(double xmass2,double ymass2, double zmax, TH2F *h2);
45 void setZmax( );
46 void setZmax(TH2F *H2);
47 double getZmax();
48 void setHmc(TH2F *H2);
49 void setHdt(TH2F *H2);
50 void setHwt(TH2F *H2){ HWT=(TH2F*) H2->Clone("HWT");}
51
52 TH2F* getHmc( );
53 TH2F* getHdt( );
54 TH2F* getHwt( );
55
56 void setBINSx(int bx){BINSx=bx;}
57 void setBINSy(int by){BINSy=by;}
58 void setXlow (double xl){xlow=xl;}
59 void setXup(double xu){xup=xu;}
60 void setYlow (double yl){ylow=yl;}
61 void setYup(double yu){yup=yu;}
62
63 void setBins(TH2F *h2);
64 int getBINSx(){return BINSx;}
65 int getBINSy(){return BINSy;}
66 double getXlow(){return xlow;}
67 double getYlow(){return ylow;}
68 double getXup(){return xup;}
69 double getYup(){return yup;}
70
71 void show(TH2F *h2);
72 void showFrame(TH2F *h2);
73
74 void init(TH2F *hmc, TH2F *hdt, TH2F *hwt);
75
76private:
77 TH2F *HDATA, *HMC, *HWT; //input DATA, MC AND RE-WEIGHTED DALITIZ PLOT
78 TFile *dataf;
79 double zmax; //maxium value at the reweight diagram
80 int BINSx, BINSy;
81 double xlow,xup,ylow,yup;
82 const char *datafile, *datatitle;
83 TDirectory dir;
84 int icount;
85 double max1,max2,max3;
86 TH2F *WT1,*WT2,*WT3;
87};
88
89
90#endif
91
void show(TH2F *h2)
const char * getHTitle()
void setZmax(TH2F *H2)
void HReweight()
void setBins(TH2F *h2)
bool AR(double xmass2, double ymass2, double zmax, TH2F *h2)
TH2F * getHmc()
void setHdt(TH2F *H2)
void init()
void init(TH2F *hmc, TH2F *hdt, TH2F *hwt)
double getZmax()
const char * getFile()
void setHmc(TH2F *H2)
bool AR(double xmass2, double ymass2)
TH2F * getHwt()
void HFill(double xmass2, double ymass2)
void setHTitle(const char *htitle)
void setZmax()
virtual ~EvtHis2F()
double getZvalue(double m12_square, double m13_square)
TH2F * getHdt()
void setFile(const char *dtfile)
void showFrame(TH2F *h2)