00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00071 #ifndef STAR_StPixelFastSimMaker
00072 #define STAR_StPixelFastSimMaker
00073 #ifndef StMaker_H
00074 #include "StMaker.h"
00075 #endif
00076 #include "StThreeVectorF.hh"
00077 #include "StThreeVectorD.hh"
00078 #include <vector>
00079 class StEvent;
00080 class StMcEvent;
00081 class StRandom;
00082 class StMcPixelHitCollection;
00083 class St_g2t_ist_hit;
00084 class St_g2t_pix_hit;
00085
00086 class StPixelFastSimMaker : public StMaker {
00087 public:
00088
00089
00090
00091 StPixelFastSimMaker(const char *name="PixelFastSim") :StMaker(name){}
00092
00093
00094
00095
00096 virtual ~StPixelFastSimMaker();
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107 virtual Int_t Make();
00108
00109
00110 virtual int Init();
00111
00112
00113 virtual int InitRun( int);
00114
00115
00116 virtual Bool_t accept(StEvent* event);
00117
00118
00119 virtual Bool_t accept(StMcEvent* event);
00120
00121
00122 void LoadPixPileUpHits();
00123
00124
00125 void AddPixPileUpHit(StMcPixelHitCollection* pixHitCol);
00126
00127
00128 double distortHit(double x, double res, double detLength);
00129
00130
00131 void smearGaus(StThreeVectorD &mError, double sigma1, double sigma2);
00132
00133
00134
00135
00136 virtual const char *GetCVS() const
00137 {
00138 static const char cvs[]="Tag $Name: $ $Id: StPixelFastSimMaker.h,v 1.13 2009/02/06 20:48:48 wleight Exp $ built "__DATE__" "__TIME__ ;
00139 return cvs;
00140 }
00141
00142 void shiftHit(StThreeVectorF &pos, StThreeVectorF &mom, int, int);
00143 int sector(int,int);
00144 int secLadder(int,int);
00145 double phiForLadder(int,int);
00146
00147
00148 protected:
00149 StRandom* myRandom;
00150
00151 double resXIst1;
00152 double resZIst1;
00153 double resXIst2;
00154 double resZIst2;
00155 double resXIst3;
00156 double resZIst3;
00157 double resZPix;
00158 double resXPix;
00159 int mSmear;
00160
00161 protected:
00162 vector<double> pileup_x;
00163 vector<double> pileup_y;
00164 vector<double> pileup_z;
00165
00166 vector<float> pileup_px;
00167 vector<float> pileup_py;
00168 vector<float> pileup_pz;
00169
00170 vector<int> pileup_key;
00171 vector<int> pileup_vid;
00172
00173 vector<float> pileup_de;
00174 vector<float> pileup_ds;
00175
00176 bool pileup_on;
00177
00178
00179
00180
00181
00182 ClassDef(StPixelFastSimMaker,1)
00183 };
00184
00185 struct stripHit{
00186 double localX;
00187 double e;
00188 };
00189
00190 struct istStrip{
00191 vector<stripHit> stripHits;
00192 double intercept;
00193 };
00194
00195 #endif
00196
00197
00198