00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef STAR_StFgtSlowSimuMaker
00010 #define STAR_StFgtSlowSimuMaker
00011
00012 #ifndef StMaker_H
00013 #include "StMaker.h"
00014 #endif
00015
00016 #include "StFgtGeom.h"
00017 #include "StFgtContainers.h"
00018
00019 #include "TGeoManager.h"
00020 #include "TROOT.h"
00021
00022 class St_g2t_fgt_hit;
00023 class TH2F;
00024 class TH1F;
00025 class TRandom3;
00026 class HexLatice;
00027
00028 class StFgtSlowSimuMaker : public StMaker {
00029 private:
00030 enum {mxH=32,eLossDim=10000};
00031 TH1 *hA[mxH];
00032 TObjArray *HList;
00033 StFgtGeom *geom;
00034 HexLatice *hexLat;
00035 double *mRadStripRelativeGain;
00036 double *mPhiStripRelativeGain;
00037
00038
00039 TH2F *digXY;
00040 TH1F *digPhi;
00041 TH1F *digRad;
00042
00043
00044 TH2F *digXYAll;
00045 TH1F *digPhiAll;
00046 TH1F *digRadAll;
00047
00048 int mInpEve;
00049 double par_2DpixAmplThres;
00050 double par_stripAmplThres;
00051 double par_XYamplSigma;
00052 double par_radStripGainMean,par_radStripGainSigma;
00053 double par_phiStripGainMean,par_phiStripGainSigma;
00054
00055 bool par_forcePerp;
00056 int par_useOnlyDisk;
00057 int par_cutoffOfBichel;
00058 double par_hexLaticePitch, par_hexLaticePhi1deg;
00059 double par_transDiffusionPerPath;
00060 TF1 *amplF;
00061 TRandom3* mRnd;
00062 void addHit(TVector3 rLocal, double ampl=1.) ;
00063 void responseLinearModel(TVector3 Rloc, TVector3 Dloc);
00064 void responseFrankModel(TVector3 Rloc, TVector3 Dloc);
00065 double meLossTab[eLossDim];
00066
00067 void InitHisto1();
00068 void InitHisto2();
00069 void CloseHisto();
00070 void sort_g2t_hits(St_g2t_fgt_hit *);
00071 bool projectQuadrant( int iquad);
00072 void exportStripPlane(TH1F *h, vector<fgt_strip> &L);
00073
00074 public:
00075 vector<fgt_g2t_auxil> mG2tHitList[kFgtMxDisk+1][kFgtMxQuad];
00076 vector<fgt_strip> mRadAdcList[kFgtMxDisk];
00077 vector<fgt_strip> mPhiAdcList[kFgtMxDisk];
00078 void setRadStripGain(double g, double s){ par_radStripGainMean=g; par_radStripGainSigma=s;}
00079 void setPhiStripGain(double g, double s){ par_phiStripGainMean=g; par_phiStripGainSigma=s;}
00080 void setTransDiffusion(double x) {par_transDiffusionPerPath=x;}
00081
00082 StFgtSlowSimuMaker(const char *name="FgtSlowSimu");
00083 virtual ~StFgtSlowSimuMaker();
00084 virtual Int_t Init();
00085 virtual Int_t Finish();
00086 virtual Int_t Make();
00087 virtual void Clear(Option_t *option="");
00088 void setHList(TObjArray * x){HList=x;}
00089 void saveHisto(TString fname);
00090 void setStripThresh(double x) {par_stripAmplThres=x;}
00091 void setHexGemLatice(double x, double y) {par_hexLaticePitch=x; par_hexLaticePhi1deg=y;}
00092 void initFrankModel(TString fname="xBichselELossProbHighBG.dat");
00093 void forcePerpTracks(bool x=true) {par_forcePerp=x;}
00094 void useOnlyDisk(int x){par_useOnlyDisk=x;}
00095 virtual const char *GetCVS() const {
00096 static const char cvs[]="Tag $Name: $ $Id: StFgtSlowSimuMaker.h,v 1.2 2011/04/08 22:18:42 balewski Exp $ built "__DATE__" "__TIME__ ;
00097 return cvs;
00098 }
00099 private:
00100
00101 ClassDef(StFgtSlowSimuMaker,0)
00102 };
00103
00104 #endif
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114