StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StFtpcLaser.hh
1 // $Id: StFtpcLaser.hh,v 1.4 2009/10/14 15:59:55 jcs Exp $
2 //
3 // $Log: StFtpcLaser.hh,v $
4 // Revision 1.4 2009/10/14 15:59:55 jcs
5 // changes to be able to vary the gas temperature in addition to varying t0 and
6 // gas composition
7 //
8 // Revision 1.3 2006/04/04 10:57:05 jcs
9 // Fix memory leak
10 //
11 // Revision 1.2 2006/03/15 15:13:56 jcs
12 // add lines for listing CVS update info
13 //
14 
15 #ifndef STAR_StFtpcLaser
16 #define STAR_StFtpcLaser
17 
18 #include <Stiostream.h>
19 #include <fstream>
20 #include <cmath>
21 #include "TROOT.h"
22 #include "TFile.h"
23 #include "TH1.h"
24 #include "TH2.h"
25 #include "TF1.h"
26 #include "TObjArray.h"
27 #include "TString.h"
28 #include "TPostScript.h"
29 #include "TTree.h"
30 #include "TNtuple.h"
31 #include "TBranch.h"
32 #include "TLeaf.h"
33 #include "TLeafI.h"
34 #include "TCanvas.h"
35 #include "TLeaf.h"
36 #include "TStyle.h"
37 #include "TGraph.h"
38 #include "TLegend.h"
39 #include "TLine.h"
40 #include "TLatex.h"
41 #include "TPaveLabel.h"
42 #include "TSpectrum.h"
43 
44 //---------------------------------------------------------------
45 
46 struct RUN
47 {
48  Int_t run;
49  Int_t date;
50  Int_t time;
51  Float_t micropertimebin;
52  Float_t normalizedNowPressure, standardPressure;
53  Float_t baseTemperature, gasTemperatureWest, gasTemperatureEast;
54  Float_t deltapW,deltapE;
55 };
56 
57 struct HIT
58 {
59  Float_t x,y,z;
60  Float_t rad,phi;
61  Float_t raderror,phierror;
62 };
63 
64 struct CLUSTER
65 {
66  Float_t timepos,padpos,timesigma,padsigma;
67  Float_t peakheight, charge;
68  Int_t timebin,pad;
69  Int_t padlength,timelength;
70  Int_t row,sec;
71  Int_t flag;
72  Int_t numpeaks;
73 };
74 
75 struct EVENT
76 {
77  Int_t run;
78  Int_t nevent;
79 };
80 
81 struct TEVENT
82 {
83  Int_t run;
84  Int_t nevent;
85 };
86 
87 
88 struct TCLUSTER
89 {
90  Int_t row,sec, padlength, timelength;
91  Float_t peakheight, charge;
92  Int_t ntracks;
93  Float_t padpos, timepos;
94  Float_t padpossigma, timepossigma;
95 };
96 
97 struct THIT
98 {
99  Float_t x,y,z;
100  Float_t ex,ey,ez;
101 };
102 
103 struct TREVENT
104 {
105  Int_t run;
106  Int_t nevent;
107 };
108 
109 struct TRACK
110 {
111  Float_t px,py,pz;
112  Float_t eta,p,pt;
113  Int_t npoints;
114  Int_t charge;
115 };
116 
117 struct MVERTEX
118 {
119  Float_t x,y,z;
120 };
121 
123 {
124 
125  private:
126 
127  protected:
128 
129  public:
130 
131  TFile *f;
132 
133  RUN Run;
134  CLUSTER cluster;
135  HIT hit;
136  TCLUSTER tcluster;
137  THIT thit;
138  TRACK track;
139  EVENT event;
140  TEVENT tevent;
141  TREVENT trevent;
142  MVERTEX mvertex;
143 
144  TBranch *bRun;
145  TBranch *bhit, *bevent, *bcluster;
146  TBranch *bthit, *btcluster, *btevent;
147  TBranch *btrevent, *btrack,*btrvertex;
148 
149  TTree *drtree;
150  TTree *dtree;
151  TTree *dttree;
152  TTree *dtrtree;
153 
154  StFtpcLaser();
155  virtual void Init(TString filename);
156  virtual ~StFtpcLaser();
157  virtual Float_t zyltrafo(Float_t x,Float_t y, Float_t z);
158  virtual bool laser_sector(int whichftpc,int whichsec,int sec);
159  virtual int laser_straight(float *rad,int max);
160  virtual void readtree(TFile *f);
161  virtual void GetTreeEntry(int k);
162  virtual void GetClusterTreeEntry(int k);
163 
164 };
165 #endif