CMS 3D CMS Logo

CSCDriftParamHighB.cc
Go to the documentation of this file.
2 #include <cmath>
3 
5  /* Initialized data */
6 
7  static const double coeff[18] = {.16916627,
8  .11057547,
9  .054287448,
10  .01179527,
11  .0062073273,
12  -.013570915,
13  -.0027121772,
14  -.0053792764,
15  -.0027452986,
16  -.0020556715,
17  .0021511659,
18  .0011376412,
19  .0026183373,
20  .0017980602,
21  -.0012975418,
22  -.0010798782,
23  -.0012322628,
24  -8.3635924e-4};
25 
26  /* Local variables */
27  double x10, x11, x12, x13, x14, x20, x21, x22, x23, x24, x25;
28 
29  /* ! Parameterization of drift path length - high field chambers */
30  /* ***********************************************************************
31  */
32  /* DOC MC_BHGH_SLEN *
33  */
34  /* *
35  */
36  /* DOC Function : Parameterization of the drift path length *
37  */
38  /* DOC in the muon endcap CSCs. *
39  */
40  /* *
41  */
42  /* DOC References : None *
43  */
44  /* *
45  */
46  /* DOC Arguments : YCELL - distance from the anode wire in the *
47  */
48  /* anode-cathode coordinate plane *
49  */
50  /* DOC ZCELL - distance from the anode wire in the wire *
51  */
52  /* plane coordinate *
53  */
54  /* DOC Errors : None *
55  */
56  /* *
57  */
58  /* DOC Returns : Drift path length for high field CSC chambers *
59  */
60  /* *
61  */
62  /* DOC Created : 15-OCT-1996 Author : Jeff Rowe *
63  */
64  /* ***********************************************************************
65  */
66 
67  x10 = 1.;
68  x11 = fabs(ycell) * 2. - 1.;
69  x12 = x11 * 2. * x11 - x10;
70  x13 = x11 * 2. * x12 - x11;
71  x14 = x11 * 2. * x13 - x12;
72  x20 = 1.;
73  x21 = fabs(zcell) * 2. - 1.;
74  x22 = x21 * 2. * x21 - x20;
75  x23 = x21 * 2. * x22 - x21;
76  x24 = x21 * 2. * x23 - x22;
77  x25 = x21 * 2. * x24 - x23;
78 
79  return coeff[0] + coeff[1] * x11 + coeff[2] * x21 + coeff[3] * x22 + coeff[4] * x12 + coeff[5] * x11 * x21 +
80  coeff[6] * x13 + coeff[7] * x12 * x22 + coeff[8] * x12 * x23 + coeff[9] * x11 * x24 + coeff[10] * x12 * x21 +
81  coeff[11] * x14 + coeff[12] * x11 * x22 + coeff[13] * x13 * x22 + coeff[14] * x13 * x21 +
82  coeff[15] * x12 * x24 + coeff[16] * x11 * x25 + coeff[17] * x11 * x23;
83 }
84 
86  /* Initialized data */
87 
88  static const double coeff[9] = {.0049089564,
89  .0091482062,
90  .0024036507,
91  .0065285652,
92  .0041487742,
93  -.0038102526,
94  -.0043923587,
95  .0019230151,
96  .0013543258};
97 
98  /* System generated locals */
99  float ret_val;
100 
101  /* Local variables */
102  double /*x10,*/ x11, x12, x13, x14, x15, x16, /*x20,*/ x21, x22, x23, x24, x25, x26, x27, x28, x29;
103 
104  /* ! Parameterization of path length dispersion- high field chambers */
105  /* ***********************************************************************
106  */
107  /* DOC MC_BHGH_SSIG *
108  */
109  /* *
110  */
111  /* DOC Function : Parameterization of the drift path length *
112  */
113  /* DOC dispersion in the muon endcap CSCs. *
114  */
115  /* *
116  */
117  /* DOC References : None *
118  */
119  /* *
120  */
121  /* DOC Arguments : YCELL - distance from the anode wire in the *
122  */
123  /* anode-cathode coordinate plane *
124  */
125  /* DOC ZCELL - distance from the anode wire in the wire *
126  */
127  /* plane coordinate *
128  */
129  /* **NOTE** Both distances normalize to cell dim=1x1 *
130  */
131  /* DOC Errors : None *
132  */
133  /* *
134  */
135  /* DOC Returns : Path length dispersion for high field CSC chambers *
136  */
137  /* *
138  */
139  /* DOC Created : 15-OCT-1996 Author : Jeff Rowe *
140  */
141  /* ***********************************************************************
142  */
143 
144  // x10 = 1.; //not used later
145  x11 = fabs(ycell) * 2. - 1.;
146  x12 = x11 * x11;
147  x13 = x11 * x12;
148  x14 = x11 * x13;
149  x15 = x11 * x14;
150  x16 = x11 * x15;
151  // x20 = 1.; //not used later
152  x21 = fabs(zcell) * 2. - 1.;
153  x22 = x21 * x21;
154  x23 = x21 * x22;
155  x24 = x21 * x23;
156  x25 = x21 * x24;
157  x26 = x21 * x25;
158  x27 = x21 * x26;
159  x28 = x21 * x27;
160  x29 = x21 * x28;
161 
162  ret_val = coeff[0] + coeff[1] * x21 + coeff[2] * x11 + coeff[3] * x22 + coeff[4] * x11 * x21 + coeff[5] * x16 * x22 +
163  coeff[6] * x16 * x23 + coeff[7] * x11 * x22 + coeff[8] * x29;
164 
165  return ret_val;
166 }
167 
169  /* Initialized data */
170 
171  static const double coeff[27] = {22.384492, 10.562894, 14.032961, 7.06233, 3.5523289, -5.0176704, 1.999075,
172  1.0635552, -3.2770096, -2.7384958, .98411495, -2.0963696, -1.4006525, -.47542728,
173  .64179451, -.80308436, .42964647, -.4153324, .50423068, .35049792, -.42595896,
174  -.30947641, .16671267, -.21336584, .22979164, .23481052, .32550435};
175 
176  /* System generated locals */
177  float ret_val;
178 
179  /* Local variables */
180  double x10, x11, x12, x13, x14, x15, x16, x17, x20, x21, x22, x23, x24, x25, x26, x27;
181 
182  /* ! Parameterization of drift time - high field chambers */
183  /* ***********************************************************************
184  */
185  /* DOC MC_BHGH_TIME *
186  */
187  /* *
188  */
189  /* DOC Function : Parameterization of the drift time *
190  */
191  /* DOC in the muon endcap CSCs. *
192  */
193  /* *
194  */
195  /* DOC References : None *
196  */
197  /* *
198  */
199  /* DOC Arguments : YCELL - distance from the anode wire in the *
200  */
201  /* anode-cathode coordinate plane *
202  */
203  /* (ycell=1 > d_acat) *
204  */
205  /* DOC ZCELL - distance from the anode wire in the wire *
206  */
207  /* plane coordinate (zcell=1 > d_anod/2.) *
208  */
209  /* DOC Errors : None *
210  */
211  /* *
212  */
213  /* DOC Returns : Drift time for high field CSC chambers *
214  */
215  /* *
216  */
217  /* DOC Created : 15-OCT-1996 Author : Jeff Rowe *
218  */
219  /* ***********************************************************************
220  */
221 
222  x10 = 1.;
223  x11 = fabs(ycell) * 2. - 1.;
224  x12 = x11 * 2. * x11 - x10;
225  x13 = x11 * 2. * x12 - x11;
226  x14 = x11 * 2. * x13 - x12;
227  x15 = x11 * 2. * x14 - x13;
228  x16 = x11 * 2. * x15 - x14;
229  x17 = x11 * 2. * x16 - x15;
230  x20 = 1.;
231  x21 = fabs(zcell) * 2. - 1.;
232  x22 = x21 * 2. * x21 - x20;
233  x23 = x21 * 2. * x22 - x21;
234  x24 = x21 * 2. * x23 - x22;
235  x25 = x21 * 2. * x24 - x23;
236  x26 = x21 * 2. * x25 - x24;
237  x27 = x21 * 2. * x26 - x25;
238 
239  ret_val = coeff[0] + coeff[1] * x11 + coeff[2] * x21 + coeff[3] * x22 + coeff[4] * x23 + coeff[5] * x11 * x21 +
240  coeff[6] * x24 + coeff[7] * x12 + coeff[8] * x11 * x22 + coeff[9] * x11 * x23 + coeff[10] * x25 +
241  coeff[11] * x11 * x24 + coeff[12] * x11 * x25 + coeff[13] * x13 + coeff[14] * x12 * x21 +
242  coeff[15] * x11 * x26 + coeff[16] * x26 + coeff[17] * x11 * x27 + coeff[18] * x17 * x21 +
243  coeff[19] * x15 * x21 + coeff[20] * x12 * x22 + coeff[21] * x12 * x23 + coeff[22] * x27 +
244  coeff[23] * x14 * x22 + coeff[24] * x16 * x21 + coeff[25] * x17 + coeff[26] * x17 * x22;
245 
246  return ret_val;
247 }
248 
250  /* Initialized data */
251 
252  static const double coeff[17] = {5.5533465,
253  3.3733352,
254  3.776603,
255  2.2673355,
256  1.3401485,
257  .84209333,
258  -.71621378,
259  .57572407,
260  -.52313936,
261  -.78790514,
262  -.71786066,
263  .43370011,
264  .29223306,
265  -.37791975,
266  .21121024,
267  .31513644,
268  .25382701};
269 
270  /* System generated locals */
271  float ret_val;
272 
273  /* Local variables */
274  double x10, x11, x12, x13, x14, x15, x16, x17, x18, /*x19,*/ x20, x21, x22, x23, x24, x25, x26, x27, x28, x29;
275 
276  /* ! Parameterization of drift time dispersion- high field chambers */
277  /* ***********************************************************************
278  */
279  /* DOC MC_BHGH_TSIG *
280  */
281  /* *
282  */
283  /* DOC Function : Parameterization of the drift time dispersion *
284  */
285  /* DOC in the muon endcap CSCs. *
286  */
287  /* *
288  */
289  /* DOC References : None *
290  */
291  /* *
292  */
293  /* DOC Arguments : YCELL - distance from the anode wire in the *
294  */
295  /* anode-cathode coordinate plane *
296  */
297  /* (ycell=1 > d_acat) *
298  */
299  /* DOC ZCELL - distance from the anode wire in the wire *
300  */
301  /* plane coordinate (zcell=1 > d_anod/2.) *
302  */
303  /* DOC Errors : None *
304  */
305  /* *
306  */
307  /* DOC Returns : Drift time dispersion for high field CSC chambers *
308  */
309  /* *
310  */
311  /* DOC Created : 15-OCT-1996 Author : Jeff Rowe *
312  */
313  /* ***********************************************************************
314  */
315 
316  x10 = 1.;
317  x11 = fabs(ycell) * 2. - 1.;
318  x12 = x11 * 2. * x11 - x10;
319  x13 = x11 * 2. * x12 - x11;
320  x14 = x11 * 2. * x13 - x12;
321  x15 = x11 * 2. * x14 - x13;
322  x16 = x11 * 2. * x15 - x14;
323  x17 = x11 * 2. * x16 - x15;
324  x18 = x11 * 2. * x17 - x16;
325  // x19 = x11 * 2. * x18 - x17; //not used later
326  x20 = 1.;
327  x21 = fabs(zcell) * 2. - 1.;
328  x22 = x21 * 2. * x21 - x20;
329  x23 = x21 * 2. * x22 - x21;
330  x24 = x21 * 2. * x23 - x22;
331  x25 = x21 * 2. * x24 - x23;
332  x26 = x21 * 2. * x25 - x24;
333  x27 = x21 * 2. * x26 - x25;
334  x28 = x21 * 2. * x27 - x26;
335  x29 = x21 * 2. * x28 - x27;
336 
337  ret_val = coeff[0] * x21 + coeff[1] + coeff[2] * x22 + coeff[3] * x23 + coeff[4] * x24 + coeff[5] * x25 +
338  coeff[6] * x11 * x23 + coeff[7] * x26 + coeff[8] * x11 * x25 + coeff[9] * x11 * x24 +
339  coeff[10] * x11 * x22 + coeff[11] * x27 + coeff[12] * x28 + coeff[13] * x11 * x26 + coeff[14] * x29 +
340  coeff[15] * x16 * x21 + coeff[16] * x18 * x21;
341 
342  return ret_val;
343 }
double zcell
Definition: CSCDriftSim.h:67
double pathSigmaHighB()
double avgPathLengthHighB()
double driftTimeSigmaHighB()
double avgDriftTimeHighB()
double ycell
Definition: CSCDriftSim.h:67