3 #include "Randomize.hh" 29 Z_1stlayer = 305.250-0.005-0.200-2.000-0.200-0.005-0.050-0.020-0.128-0.030-2.500;
74 vector<double> strip_id;
76 Nel = (int) (1e6*Edep/
w_i);
77 if(z-
Z0[layer]>0.5001*
hDrift || z-
Z0[layer]<-0.5001*
hDrift) cout <<
"Warning! z position of the FMT hit is not in the sensitive volume: " << z-
Z0[layer]<< endl;
83 for(
int iel=0;iel<
Nel;iel++)
89 ClosestStrip = (int) (floor((84.1-
y_real)/
pitch)+1);
91 else if(y_real < -84.1 && y_real > -184.9){
92 ClosestStrip = (int) (floor((-
y_real-84.1)/
pitch)+1) + 320;
94 else if(
y_real > -84.1 && y_real < 84.1 && x_real > 0){
95 ClosestStrip = (int) (floor((
y_real+84.1)/
pitch)+1) + 512;
98 ClosestStrip = (int) (floor((
y_real-84.1)/
pitch)+1) + 832;
101 if(sqrt(x*x+y*y)<
R_max && sqrt(x*x+y*y)>
R_min && ClosestStrip>=1 && ClosestStrip<=
N_str)
103 for(
int istrip=0;istrip< (int) (strip_id.size()/2);istrip++)
105 if(strip_id[2*istrip]==ClosestStrip)
107 strip_id[2*istrip+1]=strip_id[2*istrip+1]+1./((double) Nel);
113 strip_id.push_back(ClosestStrip);
114 strip_id.push_back(1./((
double) Nel));
119 strip_id.push_back(-1);
120 strip_id.push_back(1);
126 strip_id.push_back(-1);
127 strip_id.push_back(1);
vector< double > FindStrip(int layer, int sector, double x, double y, double z, double Edep)