]>
Commit | Line | Data |
---|---|---|
7e5caa00 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
3 | * * | |
4 | * Author: The ALICE Off-line Project. * | |
5 | * Contributors are mentioned in the code where appropriate. * | |
6 | * * | |
7 | * Permission to use, copy, modify and distribute this software and its * | |
8 | * documentation strictly for non-commercial purposes is hereby granted * | |
9 | * without fee, provided that the above copyright notice appears in all * | |
10 | * copies and that both the copyright notice and this permission notice * | |
11 | * appear in the supporting documentation. The authors make no claims * | |
12 | * about the suitability of this software for any purpose. It is * | |
13 | * provided "as is" without express or implied warranty. * | |
14 | **************************************************************************/ | |
15 | ||
eeacf08b | 16 | /* $Id$ */ |
6304e7d2 | 17 | |
eeacf08b | 18 | //------------------------------------------------------------------------ |
19 | // AliFRAMEv2.cxx | |
20 | // symmetric space frame with possibility for holes | |
21 | // Author: A.Morsch | |
22 | //------------------------------------------------------------------------ | |
7e5caa00 | 23 | |
88cb7938 | 24 | #include <TSystem.h> |
25 | ||
7e5caa00 | 26 | #include "AliFRAMEv2.h" |
27 | #include "AliMagF.h" | |
28 | #include "AliRun.h" | |
7e5caa00 | 29 | |
30 | ClassImp(AliFRAMEv2) | |
31 | ||
32 | //_____________________________________________________________________________ | |
33 | AliFRAMEv2::AliFRAMEv2() | |
34 | { | |
35 | // Constructor | |
36 | SetHoles(0); | |
37 | } | |
38 | ||
39 | //_____________________________________________________________________________ | |
40 | AliFRAMEv2::AliFRAMEv2(const char *name, const char *title) | |
41 | : AliFRAME(name,title) | |
42 | { | |
43 | // Constructor | |
44 | SetHoles(0); | |
45 | } | |
46 | ||
47 | ||
48 | //___________________________________________ | |
49 | void AliFRAMEv2::CreateGeometry() | |
50 | { | |
51 | //Begin_Html | |
52 | /* | |
53 | <img src="picts/frame.gif"> | |
54 | */ | |
55 | //End_Html | |
56 | ||
57 | ||
58 | //Begin_Html | |
59 | /* | |
60 | <img src="picts/tree_frame.gif"> | |
61 | */ | |
62 | //End_Html | |
63 | ||
4a8eca94 | 64 | Int_t idrotm[2299]; |
7e5caa00 | 65 | Int_t *idtmed = fIdtmed->GetArray()-1999; |
66 | // | |
67 | // The Space frame | |
68 | // | |
69 | // | |
e16311cb | 70 | Float_t pbox[3], ptrap[11], ptrd1[4], ppgon[10]; |
7e5caa00 | 71 | |
72 | Float_t dx, dy, dz; | |
73 | Int_t i, j, jmod; | |
74 | // | |
75 | // Constants | |
76 | const Float_t kEps = 0.01; | |
77 | const Int_t kAir = idtmed[2004]; | |
78 | const Int_t kSteel = idtmed[2064]; | |
79 | ||
80 | const Float_t krad2deg = 180./TMath::Pi(); | |
81 | const Float_t kdeg2rad = 1./krad2deg; | |
82 | ||
4c057bc8 | 83 | Float_t iFrH = 114.40; |
84 | Float_t ringH = 4.00; | |
85 | Float_t ringW = 10.00; | |
86 | Float_t longH = 5.39; | |
87 | Float_t longW = 6.00; | |
88 | Float_t dwl = 3.14; | |
89 | Float_t dwh = 0.96; | |
7e5caa00 | 90 | |
02e42643 | 91 | // |
4a8eca94 | 92 | Float_t dymodU[3] = {70.0, 224.0, 341.}; |
02e42643 | 93 | // new ? |
4a8eca94 | 94 | Float_t dymodL[3] = {54.0, 178.5, 341.}; |
af3fbbe1 | 95 | |
7e5caa00 | 96 | // |
97 | // Frame mother volume | |
98 | // | |
b35d7d26 | 99 | // ptube[0] = 280.; |
100 | // ptube[1] = 430.; | |
101 | // ptube[2] = 376.; | |
102 | ppgon[0] = 0.; | |
103 | ppgon[1] = 360.; | |
104 | ppgon[2] = 18.; | |
105 | ||
106 | ppgon[3] = 2.; | |
b35d7d26 | 107 | ppgon[4] = -376.; |
108 | ppgon[5] = 280.; | |
109 | ppgon[6] = 421.; | |
110 | ||
111 | ppgon[7] = -ppgon[4]; | |
112 | ppgon[8] = ppgon[5]; | |
113 | ppgon[9] = ppgon[6]; | |
114 | ||
115 | gMC->Gsvolu("B077", "PGON", kAir, ppgon, 10); | |
116 | ||
117 | // gMC->Gsvolu("B077", "TUBE", kAir, ptube, 3); | |
7e5caa00 | 118 | gMC->Gspos("B077", 1, "ALIC", 0., 0., 0., 0, "ONLY"); |
119 | // | |
55bdc695 | 120 | // Reference plane for TRD |
121 | // | |
122 | ppgon[6] = ppgon[5] + 0.1; | |
123 | ppgon[9] = ppgon[6]; | |
124 | gMC->Gsvolu("BREF", "PGON", kAir, ppgon, 10); | |
125 | gMC->Gspos("BREF", 1, "B077", 0., 0., 0., 0, "ONLY"); | |
126 | // | |
7e5caa00 | 127 | // The outer Frame |
128 | // | |
129 | ||
130 | Float_t dol = 8.75; | |
131 | Float_t doh = 5.; | |
132 | Float_t ds = 0.35; | |
133 | // | |
134 | // Mother volume | |
135 | // | |
136 | ppgon[0] = 0.; | |
137 | ppgon[1] = 360.; | |
138 | ppgon[2] = 18.; | |
139 | ||
140 | ppgon[3] = 2.; | |
141 | ||
142 | ppgon[4] = -350.; | |
143 | ppgon[5] = 399.; | |
144 | ppgon[6] = 420.7122; | |
145 | ||
146 | ppgon[7] = -ppgon[4]; | |
147 | ppgon[8] = ppgon[5]; | |
148 | ppgon[9] = ppgon[6]; | |
149 | gMC->Gsvolu("B076", "PGON", kAir, ppgon, 10); | |
150 | gMC->Gspos("B076", 1, "B077", 0., 0., 0., 0, "ONLY"); | |
151 | // | |
152 | // Rings | |
153 | // | |
154 | dz = 2.*410.2*TMath::Sin(10.*kdeg2rad)-2.*dol*TMath::Cos(10.*kdeg2rad)- | |
155 | 2.*doh*TMath::Tan(10.*kdeg2rad); | |
156 | Float_t l1 = dz/2.; | |
157 | Float_t l2 = dz/2.+2.*doh*TMath::Tan(10.*kdeg2rad); | |
158 | ||
159 | ptrd1[0] = l1; | |
160 | ptrd1[1] = l2; | |
161 | ||
162 | ptrd1[2] = dol; | |
163 | ptrd1[3] = doh; | |
164 | gMC->Gsvolu("B042", "TRD1", kSteel, ptrd1, 4); | |
165 | ||
166 | ptrd1[0] = ptrd1[0]+ds*(l2-l1)/2./doh; | |
167 | ptrd1[1] = ptrd1[1]-ds*(l2-l1)/2./doh; | |
168 | ptrd1[2] = dol-ds; | |
169 | ptrd1[3] = doh-ds; | |
170 | gMC->Gsvolu("B043", "TRD1", kAir, ptrd1, 4); | |
171 | gMC->Gspos("B043", 1, "B042", 0., 0., 0., 0, "ONLY"); | |
172 | // | |
173 | // longitudinal bars | |
174 | // | |
175 | // 170x200x5 | |
176 | // | |
177 | pbox[0] = dol; | |
178 | pbox[1] = doh; | |
179 | pbox[2] = 350.; | |
180 | gMC->Gsvolu("B033", "BOX", kSteel, pbox, 3); | |
181 | pbox[0] = dol-ds; | |
182 | pbox[1] = doh-ds; | |
183 | gMC->Gsvolu("B034", "BOX", kAir, pbox, 3); | |
184 | gMC->Gspos("B034", 1, "B033", 0., 0., 0., 0, "ONLY"); | |
185 | ||
186 | pbox[0] = 1.0; | |
187 | pbox[1] = 5.0; | |
188 | pbox[2] = 375.5; | |
189 | ||
190 | ||
191 | gMC->Gsvolu("B080", "BOX", kSteel, pbox, 3); | |
b35d7d26 | 192 | gMC->Gspos("B080", 1, "B077", 286.01, 0., 0., 0, "ONLY"); |
193 | gMC->Gspos("B080", 2, "B077", -286.01, 0., 0., 0, "ONLY"); | |
7e5caa00 | 194 | |
195 | // | |
196 | // Diagonal bars (1) | |
197 | // | |
198 | Float_t h, d, dq, x, theta; | |
199 | ||
4a8eca94 | 200 | h = (dymodU[1]-dymodU[0]-2.*dol)*.999; |
7e5caa00 | 201 | d = 2.*dol; |
202 | dq = h*h+dz*dz; | |
203 | ||
204 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
205 | ||
206 | ||
207 | theta = krad2deg * TMath::ACos(x); | |
208 | ||
209 | ptrap[0] = dz/2.; | |
210 | ptrap[1] = theta; | |
211 | ptrap[2] = 0.; | |
212 | ptrap[3] = doh; | |
213 | ptrap[4] = dol/x; | |
214 | ptrap[5] = ptrap[4]; | |
215 | ptrap[6] = 0; | |
216 | ptrap[7] = ptrap[3]; | |
217 | ptrap[8] = ptrap[4]; | |
218 | ptrap[9] = ptrap[4]; | |
219 | ptrap[10] = 0; | |
220 | ||
221 | gMC->Gsvolu("B047", "TRAP", kSteel, ptrap, 11); | |
222 | ptrap[3] = doh-ds; | |
223 | ptrap[4] = (dol-ds)/x; | |
224 | ptrap[5] = ptrap[4]; | |
225 | ptrap[7] = ptrap[3]; | |
226 | ptrap[8] = ptrap[4]; | |
227 | ptrap[9] = ptrap[4]; | |
228 | gMC->Gsvolu("B048", "TRAP", kAir, ptrap, 11); | |
229 | gMC->Gspos("B048", 1, "B047", 0.0, 0.0, 0., 0, "ONLY"); | |
230 | ||
231 | /* | |
232 | Crosses (inner most) | |
233 | \\ // | |
234 | \\// | |
235 | //\\ | |
236 | // \\ | |
237 | */ | |
4a8eca94 | 238 | h = (2.*dymodU[0]-2.*dol)*.999; |
7e5caa00 | 239 | // |
240 | // Mother volume | |
241 | // | |
242 | pbox[0] = h/2; | |
243 | pbox[1] = doh; | |
244 | pbox[2] = dz/2.; | |
245 | gMC->Gsvolu("BM49", "BOX ", kAir, pbox, 3); | |
246 | ||
247 | ||
248 | dq = h*h+dz*dz; | |
249 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
250 | theta = krad2deg * TMath::ACos(x); | |
251 | ||
252 | ptrap[0] = dz/2.-kEps; | |
253 | ptrap[1] = theta; | |
254 | ptrap[2] = 0.; | |
255 | ptrap[3] = doh-kEps; | |
256 | ptrap[4] = dol/x; | |
257 | ptrap[5] = ptrap[4]; | |
258 | ptrap[7] = ptrap[3]; | |
259 | ptrap[8] = ptrap[4]; | |
260 | ptrap[9] = ptrap[4]; | |
261 | ||
262 | gMC->Gsvolu("B049", "TRAP", kSteel, ptrap, 11); | |
263 | ptrap[0] = ptrap[0]-kEps; | |
264 | ptrap[3] = (doh-ds); | |
265 | ptrap[4] = (dol-ds)/x; | |
266 | ptrap[5] = ptrap[4]; | |
267 | ptrap[7] = ptrap[3]; | |
268 | ptrap[8] = ptrap[4]; | |
269 | ptrap[9] = ptrap[4]; | |
270 | gMC->Gsvolu("B050", "TRAP", kAir, ptrap, 11); | |
271 | gMC->Gspos("B050", 1, "B049", 0.0, 0.0, 0., 0, "ONLY"); | |
272 | gMC->Gspos("B049", 1, "BM49", 0.0, 0.0, 0., 0, "ONLY"); | |
273 | ||
274 | ||
275 | Float_t dd1 = d*TMath::Tan(theta*kdeg2rad); | |
276 | Float_t dd2 = d/TMath::Tan(2.*theta*kdeg2rad); | |
277 | Float_t theta2 = TMath::ATan(TMath::Abs(dd2-dd1)/d/2.); | |
278 | ||
279 | ||
280 | ptrap[0] = dol; | |
281 | ptrap[1] = theta2*krad2deg; | |
282 | ptrap[2] = 0.; | |
283 | ptrap[3] = doh; | |
284 | ptrap[4] = (dz/2./x-dd1-dd2)/2.; | |
285 | ptrap[5] = ptrap[4]; | |
286 | ptrap[6] = 0.; | |
287 | ptrap[7] = ptrap[3]; | |
288 | ptrap[8] = dz/4./x; | |
289 | ptrap[9] = ptrap[8]; | |
290 | ||
291 | ||
292 | gMC->Gsvolu("B051", "TRAP", kSteel, ptrap, 11); | |
293 | Float_t ddx0 = ptrap[8]; | |
294 | ||
295 | Float_t dd1s = dd1*(1.-2.*ds/d); | |
296 | Float_t dd2s = dd2*(1.-2.*ds/d); | |
297 | Float_t theta2s = TMath::ATan(TMath::Abs(dd2s-dd1s)/(d-2.*ds)/2.); | |
298 | ||
299 | ||
300 | ptrap[0] = dol-ds; | |
301 | ptrap[1] = theta2s*krad2deg; | |
302 | ptrap[2] = 0.; | |
303 | ptrap[3] = doh-ds; | |
304 | ptrap[4] = ptrap[4]+ds/d/2.*(dd1+dd2); | |
305 | ptrap[5] = ptrap[4]; | |
306 | ptrap[6] = 0.; | |
307 | ptrap[7] = ptrap[3]; | |
308 | ptrap[8] = ptrap[8]-ds/2./d*(dd1+dd2); | |
309 | ptrap[9] = ptrap[8]; | |
310 | ||
311 | gMC->Gsvolu("B052", "TRAP", kAir, ptrap, 11); | |
312 | gMC->Gspos("B052", 1, "B051", 0.0, 0.0, 0., 0, "ONLY"); | |
313 | ||
314 | Float_t ddx, ddz, drx, drz, rtheta; | |
315 | ||
4a8eca94 | 316 | AliMatrix(idrotm[2001], -theta+180, 0.0, 90.0, 90.0, 90.-theta, 0.0); |
7e5caa00 | 317 | rtheta = (90.-theta)*kdeg2rad; |
318 | ddx = -ddx0-dol*TMath::Tan(theta2); | |
319 | ddz = -dol; | |
320 | ||
321 | drx = TMath::Cos(rtheta) * ddx +TMath::Sin(rtheta) *ddz+pbox[0]; | |
322 | drz = -TMath::Sin(rtheta) * ddx +TMath::Cos(rtheta) *ddz-pbox[2]; | |
323 | gMC->Gspos("B051", 1, "BM49", | |
324 | drx, 0.0, drz, | |
4a8eca94 | 325 | idrotm[2001], "ONLY"); |
7e5caa00 | 326 | |
4a8eca94 | 327 | AliMatrix(idrotm[2002], -theta, 0.0, 90.0, 90.0, 270.-theta, 0.0); |
7e5caa00 | 328 | rtheta = (270.-theta)*kdeg2rad; |
329 | ||
330 | drx = TMath::Cos(rtheta) * ddx + TMath::Sin(rtheta) * ddz-pbox[0]; | |
331 | drz = -TMath::Sin(rtheta) * ddx + TMath::Cos(rtheta) * ddz+pbox[2]; | |
332 | gMC->Gspos("B051", 2, "BM49", | |
333 | drx, 0.0, drz, | |
4a8eca94 | 334 | idrotm[2002], "ONLY"); |
7e5caa00 | 335 | |
336 | // | |
337 | // Diagonal bars (3) | |
338 | // | |
4a8eca94 | 339 | h = ((dymodU[2]-dymodU[1])-2.*dol)*.999; |
7e5caa00 | 340 | dq = h*h+dz*dz; |
341 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
342 | theta = krad2deg * TMath::ACos(x); | |
343 | ||
344 | ptrap[0] = dz/2.; | |
345 | ptrap[1] = theta; | |
346 | ptrap[3] = doh; | |
347 | ptrap[4] = dol/x; | |
348 | ptrap[5] = ptrap[4]; | |
349 | ptrap[7] = ptrap[3]; | |
350 | ptrap[8] = ptrap[4]; | |
351 | ptrap[9] = ptrap[4]; | |
352 | ||
353 | gMC->Gsvolu("B045", "TRAP", kSteel, ptrap, 11); | |
354 | ptrap[3] = doh-ds; | |
355 | ptrap[4] = (dol-ds)/x; | |
356 | ptrap[5] = ptrap[4]; | |
357 | ptrap[7] = ptrap[3]; | |
358 | ptrap[8] = ptrap[4]; | |
359 | ptrap[9] = ptrap[4]; | |
360 | gMC->Gsvolu("B046", "TRAP", kAir, ptrap, 11); | |
361 | gMC->Gspos("B046", 1, "B045", 0.0, 0.0, 0., 0, "ONLY"); | |
362 | ||
363 | // | |
364 | // Positioning of diagonal bars | |
365 | // | |
366 | // Matrices have been imported from Euclid. Some simplification | |
367 | // seems possible | |
368 | // | |
4a8eca94 | 369 | AliMatrix(idrotm[2003], 0.0, 0.0, 90.0, 130.0, 90.0, 40.0); |
370 | AliMatrix(idrotm[2004], 180.0, 0.0, 90.0, 130.0, 90.0, 40.0); | |
371 | AliMatrix(idrotm[2005], 180.0, 0.0, 90.0, 150.0, 90.0, 240.0); | |
372 | AliMatrix(idrotm[2006], 0.0, 0.0, 90.0, 150.0, 90.0, 240.0); | |
373 | AliMatrix(idrotm[2007], 0.0, 0.0, 90.0, 170.0, 90.0, 80.0); | |
374 | AliMatrix(idrotm[2008], 180.0, 0.0, 90.0, 190.0, 90.0, 280.0); | |
375 | AliMatrix(idrotm[2009], 180.0, 0.0, 90.0, 170.0, 90.0, 80.0); | |
376 | AliMatrix(idrotm[2010], 0.0, 0.0, 90.0, 190.0, 90.0, 280.0); | |
377 | AliMatrix(idrotm[2011], 0.0, 0.0, 90.0, 350.0, 90.0, 260.0); | |
378 | AliMatrix(idrotm[2012], 180.0, 0.0, 90.0, 350.0, 90.0, 260.0); | |
379 | AliMatrix(idrotm[2013], 180.0, 0.0, 90.0, 10.0, 90.0, 100.0); | |
380 | AliMatrix(idrotm[2014], 0.0, 0.0, 90.0, 10.0, 90.0, 100.0); | |
381 | AliMatrix(idrotm[2015], 0.0, 0.0, 90.0, 30.0, 90.0, 300.0); | |
382 | AliMatrix(idrotm[2016], 180.0, 0.0, 90.0, 30.0, 90.0, 300.0); | |
383 | AliMatrix(idrotm[2017], 180.0, 0.0, 90.0, 50.0, 90.0, 140.0); | |
384 | AliMatrix(idrotm[2018], 0.0, 0.0, 90.0, 50.0, 90.0, 140.0); | |
385 | ||
386 | AliMatrix(idrotm[2019], 180.0, 0.0, 90.0, 130.0, 90.0, 220.0); | |
387 | AliMatrix(idrotm[2020], 180.0, 0.0, 90.0, 50.0, 90.0, 320.0); | |
388 | AliMatrix(idrotm[2021], 180.0, 0.0, 90.0, 150.0, 90.0, 60.0); | |
389 | AliMatrix(idrotm[2022], 180.0, 0.0, 90.0, 30.0, 90.0, 120.0); | |
390 | AliMatrix(idrotm[2023], 180.0, 0.0, 90.0, 170.0, 90.0, 260.0); | |
391 | AliMatrix(idrotm[2024], 180.0, 0.0, 90.0, 190.0, 90.0, 100.0); | |
392 | AliMatrix(idrotm[2025], 180.0, 0.0, 90.0, 350.0, 90.0, 80.0); | |
393 | AliMatrix(idrotm[2026], 180.0, 0.0, 90.0, 10.0, 90.0, 280.0); | |
394 | ||
395 | AliMatrix(idrotm[2027], 0.0, 0.0, 90.0, 50.0, 90.0, 320.0); | |
396 | AliMatrix(idrotm[2028], 0.0, 0.0, 90.0, 150.0, 90.0, 60.0); | |
397 | AliMatrix(idrotm[2029], 0.0, 0.0, 90.0, 30.0, 90.0, 120.0); | |
398 | AliMatrix(idrotm[2030], 0.0, 0.0, 90.0, 10.0, 90.0, 280.0); | |
399 | AliMatrix(idrotm[2031], 0.0, 0.0, 90.0, 170.0, 90.0, 260.0); | |
400 | AliMatrix(idrotm[2032], 0.0, 0.0, 90.0, 190.0, 90.0, 100.0); | |
401 | AliMatrix(idrotm[2033], 0.0, 0.0, 90.0, 350.0, 90.0, 80.0); | |
7e5caa00 | 402 | |
403 | Float_t rd = 410.56; | |
4a8eca94 | 404 | dz = (dymodU[1]+dymodU[0])/2.; |
405 | Float_t dz2 = (dymodU[1]+dymodU[2])/2.; | |
7e5caa00 | 406 | |
407 | // | |
408 | // phi = 40 | |
409 | // | |
410 | Float_t phi = 40; | |
411 | dx = rd * TMath::Sin(phi*kdeg2rad); | |
412 | dy = rd * TMath::Cos(phi*kdeg2rad); | |
413 | ||
7e5caa00 | 414 | |
4a8eca94 | 415 | gMC->Gspos("B045", 1, "B076", -dx, dy, dz2, idrotm[2019], "ONLY"); |
416 | gMC->Gspos("B045", 2, "B076", -dx, dy, -dz2, idrotm[2003], "ONLY"); // ? | |
417 | gMC->Gspos("B045", 3, "B076", dx, dy, dz2, idrotm[2020], "ONLY"); | |
418 | gMC->Gspos("B045", 4, "B076", dx, dy, -dz2, idrotm[2027], "ONLY"); | |
7e5caa00 | 419 | |
7e5caa00 | 420 | |
421 | // | |
422 | // phi = 60 | |
423 | // | |
424 | ||
425 | phi = 60; | |
426 | dx = rd * TMath::Sin(phi*kdeg2rad); | |
427 | dy = rd * TMath::Cos(phi*kdeg2rad); | |
7e5caa00 | 428 | |
4a8eca94 | 429 | gMC->Gspos("B045", 5, "B076", -dx, dy, dz2, idrotm[2021], "ONLY"); |
430 | gMC->Gspos("B045", 6, "B076", -dx, dy, -dz2, idrotm[2028], "ONLY"); | |
431 | gMC->Gspos("B045", 7, "B076", dx, dy, dz2, idrotm[2022], "ONLY"); | |
432 | gMC->Gspos("B045", 8, "B076", dx, dy, -dz2, idrotm[2029], "ONLY"); | |
7e5caa00 | 433 | |
7e5caa00 | 434 | // |
435 | // phi = 80 | |
436 | // | |
437 | ||
438 | phi = 80; | |
439 | dx = rd * TMath::Sin(phi*kdeg2rad); | |
440 | dy = rd * TMath::Cos(phi*kdeg2rad); | |
7e5caa00 | 441 | |
4a8eca94 | 442 | gMC->Gspos("B047", 13, "B076", -dx, -dy, dz, idrotm[2008], "ONLY"); |
443 | gMC->Gspos("B047", 14, "B076", -dx, -dy, -dz, idrotm[2010], "ONLY"); | |
444 | gMC->Gspos("B047", 15, "B076", dx, -dy, dz, idrotm[2012], "ONLY"); | |
445 | gMC->Gspos("B047", 16, "B076", dx, -dy, -dz, idrotm[2011], "ONLY"); | |
7e5caa00 | 446 | |
4a8eca94 | 447 | gMC->Gspos("B045", 9, "B076", -dx, dy, dz2, idrotm[2023], "ONLY"); |
448 | gMC->Gspos("B045", 10, "B076", -dx, dy, -dz2, idrotm[2031], "ONLY"); | |
449 | gMC->Gspos("B045", 11, "B076", dx, dy, dz2, idrotm[2026], "ONLY"); | |
450 | gMC->Gspos("B045", 12, "B076", dx, dy, -dz2, idrotm[2030], "ONLY"); | |
7e5caa00 | 451 | |
4a8eca94 | 452 | gMC->Gspos("B045", 13, "B076", -dx, -dy, dz2, idrotm[2024], "ONLY"); |
453 | gMC->Gspos("B045", 14, "B076", -dx, -dy, -dz2, idrotm[2032], "ONLY"); | |
454 | gMC->Gspos("B045", 15, "B076", dx, -dy, dz2, idrotm[2025], "ONLY"); | |
455 | gMC->Gspos("B045", 16, "B076", dx, -dy, -dz2, idrotm[2033], "ONLY"); | |
7e5caa00 | 456 | |
4a8eca94 | 457 | gMC->Gspos("BM49", 7, "B076", dx, -dy, 0., idrotm[2025], "ONLY"); |
458 | gMC->Gspos("BM49", 8, "B076", -dx, -dy, 0., idrotm[2024], "ONLY"); | |
7e5caa00 | 459 | |
460 | ||
461 | // The internal frame | |
462 | // | |
463 | char* module[3] = {"B071\0", "B074\0", "B075\0"}; | |
464 | // | |
465 | // | |
466 | // Mother Volumes | |
467 | // | |
468 | ptrd1[0] = 50.18; | |
469 | ptrd1[1] = 70.35; | |
470 | // ptrd1[0] = 50.10; | |
471 | // ptrd1[1] = 70.20; | |
472 | ||
473 | ptrd1[2] = 375.5; | |
474 | ptrd1[3] = 57.2; | |
475 | for (jmod = 0; jmod < 3; jmod++) | |
476 | { | |
477 | gMC->Gsvolu(module[jmod], "TRD1", kAir, ptrd1, 4); | |
478 | } | |
5f9c2f9e | 479 | // Position of Holes for PHOS (P) and RICH (R) starting at 6h |
480 | // P P P - - R R R - - - - - - - - P P | |
481 | Int_t mod[18] = {1, 1, 1, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1}; | |
7e5caa00 | 482 | |
483 | ||
484 | Float_t r = 341.8; | |
485 | Float_t rout1 = 410.564; | |
486 | Float_t rout2 = 415.2; | |
487 | Int_t modcount[3] = {0, 0, 0}; | |
488 | ||
489 | for (i=0; i<18; i++) { | |
490 | Float_t phi = i*20.; | |
491 | Float_t phi2 = 270+phi; | |
492 | if (phi2 >= 360.) phi2-=360.; | |
493 | ||
494 | dx = TMath::Sin(phi*kdeg2rad)*r; | |
495 | dy = -TMath::Cos(phi*kdeg2rad)*r; | |
496 | modcount[mod[i]]++; | |
497 | ||
4a8eca94 | 498 | AliMatrix(idrotm[2034+i], 90.0, phi, 0., 0., 90., phi2); |
499 | gMC->Gspos(module[mod[i]], modcount[mod[i]], "B077", dx, dy, 0., idrotm[2034+i], "ONLY"); | |
7e5caa00 | 500 | // |
501 | // Position elements of outer Frame | |
502 | // | |
503 | dx = TMath::Sin(phi*kdeg2rad)*rout1; | |
504 | dy = -TMath::Cos(phi*kdeg2rad)*rout1; | |
505 | for (j = 0; j < 3; j++) | |
506 | { | |
4a8eca94 | 507 | dz = dymodU[j]; |
508 | gMC->Gspos("B042", 6*i+2*j+1, "B076", dx, dy, dz, idrotm[2034+i], "ONLY"); | |
509 | gMC->Gspos("B042", 6*i+2*j+2, "B076", dx, dy, -dz, idrotm[2034+i], "ONLY"); | |
7e5caa00 | 510 | } |
511 | ||
512 | phi = i*20.+10; | |
513 | phi2 = 270+phi; | |
4a8eca94 | 514 | AliMatrix(idrotm[2052+i], 90.0, phi, 90., phi2, 0., 0.); |
7e5caa00 | 515 | |
516 | dx = TMath::Sin(phi*kdeg2rad)*rout2; | |
517 | dy = -TMath::Cos(phi*kdeg2rad)*rout2; | |
4a8eca94 | 518 | gMC->Gspos("B033", i+1, "B076", dx, dy, 0., idrotm[2052+i], "ONLY"); |
7e5caa00 | 519 | // |
520 | } | |
521 | // Internal Frame rings | |
522 | // | |
523 | // | |
524 | // new specs: 40x100x6 for inner rings | |
525 | // 30x135x6 for front and rear rings | |
526 | // | |
527 | // currently no distinction between front/rear and inner rings | |
528 | // | |
529 | // | |
530 | // | |
531 | pbox[0] = 50.; | |
532 | pbox[1] = ringW/2.; | |
533 | pbox[2] = ringH/2.; | |
534 | ||
535 | gMC->Gsvolu("B072", "BOX ", kSteel, pbox, 3); | |
536 | ||
537 | pbox[1] = pbox[1] - 0.6; | |
538 | pbox[2] = pbox[2] - 0.6; | |
539 | gMC->Gsvolu("B073", "BOX ", kAir, pbox, 3); | |
540 | gMC->Gspos("B073", 1, "B072", 0., 0., 0., 0, "ONLY"); | |
541 | ||
542 | // Web frame 0-degree | |
543 | // | |
544 | // h x w x s = 60x40x4 | |
545 | // (attention: element is are half bars, "U" shaped) | |
546 | // | |
4a8eca94 | 547 | dz = 106.2; |
548 | d = 2.*dwl; | |
549 | h = dymodU[0]-dymodL[0]; | |
550 | dq = h*h+dz*dz; | |
551 | ||
552 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
7e5caa00 | 553 | |
4a8eca94 | 554 | theta = TMath::ACos(x); |
555 | Float_t thetaP = (TMath::Pi()-theta)*krad2deg; | |
556 | ||
557 | ptrap[0] = dz/2.; | |
558 | ptrap[1] = thetaP; | |
559 | ptrap[2] = 0.; | |
560 | ptrap[3] = dwh; | |
561 | ptrap[4] = dwl/cos(theta); | |
562 | ptrap[5] = ptrap[4]; | |
563 | ptrap[6] = 0; | |
564 | ptrap[7] = ptrap[3]; | |
565 | ptrap[8] = ptrap[4]; | |
566 | ptrap[9] = ptrap[4]; | |
567 | ptrap[10] = 0; | |
568 | gMC->Gsvolu("B063", "TRAP", kSteel, ptrap, 11); | |
569 | ptrap[3] = dwh - 0.2; | |
570 | ptrap[4] = (dwl-0.4)/cos(theta); | |
571 | ptrap[5] = ptrap[4]; | |
572 | ptrap[7] = ptrap[3]; | |
573 | ptrap[8] = ptrap[4]; | |
574 | ptrap[9] = ptrap[4]; | |
575 | gMC->Gsvolu("B064", "TRAP", kAir, ptrap, 11); | |
576 | gMC->Gspos("B064", 1, "B063", 0.0, -0.2, 0., 0, "ONLY"); | |
577 | ||
578 | ||
579 | h = 106.2; | |
580 | d = 2.*dwl; | |
581 | dz = dymodU[1]-dymodL[1]; | |
582 | dq = h*h+dz*dz; | |
583 | ||
584 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
585 | ||
586 | ||
587 | theta = krad2deg * TMath::ACos(x); | |
588 | ||
589 | ptrap[0] = dz/2.; | |
590 | ptrap[1] = theta; | |
591 | ptrap[2] = 0.; | |
592 | ptrap[3] = dwh; | |
593 | ptrap[4] = dwl/x; | |
594 | ptrap[5] = ptrap[4]; | |
595 | ptrap[6] = 0; | |
596 | ptrap[7] = ptrap[3]; | |
597 | ptrap[8] = ptrap[4]; | |
598 | ptrap[9] = ptrap[4]; | |
599 | ptrap[10] = 0; | |
600 | gMC->Gsvolu("B163", "TRAP", kSteel, ptrap, 11); | |
601 | ptrap[3] = dwh - 0.2; | |
602 | ptrap[4] = (dwl-0.4)/x; | |
603 | ptrap[5] = ptrap[4]; | |
604 | ptrap[7] = ptrap[3]; | |
605 | ptrap[8] = ptrap[4]; | |
606 | ptrap[9] = ptrap[4]; | |
607 | gMC->Gsvolu("B164", "TRAP", kAir, ptrap, 11); | |
608 | gMC->Gspos("B164", 1, "B163", 0.0, -0.2, 0., 0, "ONLY"); | |
609 | ||
610 | ||
7e5caa00 | 611 | pbox[0] = dwh; |
612 | pbox[1] = dwl; | |
613 | pbox[2] = (iFrH-ringH-longH)/2.; | |
4a8eca94 | 614 | gMC->Gsvolu("B263", "BOX ", kSteel, pbox, 3); |
7e5caa00 | 615 | pbox[0] = dwh-0.2; |
616 | pbox[1] = dwl-0.4; | |
617 | ||
4a8eca94 | 618 | gMC->Gsvolu("B264", "BOX ", kAir, pbox, 3); |
619 | gMC->Gspos("B264", 1, "B263", 0.2, 0., 0., 0, "ONLY"); | |
620 | ||
621 | ||
622 | AliMatrix(idrotm[2070], 90.0, 0.0, 90.0, 270.0, 0.0, 0.0); | |
623 | // | |
624 | AliMatrix(idrotm[2071], 100.0, 0.0, 90.0, 270.0, 10.0, 0.0); | |
625 | AliMatrix(idrotm[2072], 100.0, 0.0, 90.0, 90.0, 10.0, 0.0); | |
626 | AliMatrix(idrotm[2073], 100.0, 180.0, 90.0, 270.0, 10.0, 180.0); | |
627 | AliMatrix(idrotm[2074], 100.0, 180.0, 90.0, 90.0, 10.0, 180.0); | |
628 | // | |
629 | AliMatrix(idrotm[2075], 10.0, 0.0, 80.0, 180.0, 90.0, 90.0); | |
630 | AliMatrix(idrotm[2076], 10.0, 0.0, 80.0, 180.0, 90.0, 270.0); | |
631 | AliMatrix(idrotm[2077], 10.0, 180.0, 80.0, 0.0, 90.0, 90.0); | |
632 | AliMatrix(idrotm[2078], 10.0, 180.0, 80.0, 0.0, 90.0, 270.0); | |
633 | // | |
634 | AliMatrix(idrotm[2079], 170.0, 180.0, 80.0, 180.0, 90.0, 90.0); | |
635 | AliMatrix(idrotm[2080], 170.0, 180.0, 80.0, 180.0, 90.0, 270.0); | |
636 | AliMatrix(idrotm[2081], 170.0, 0.0, 80.0, 0.0, 90.0, 90.0); | |
637 | AliMatrix(idrotm[2082], 170.0, 0.0, 80.0, 0.0, 90.0, 270.0); | |
638 | ||
639 | // | |
640 | AliMatrix(idrotm[2083], 170.0, 0.0, 90.0, 90.0, 80.0, 0.0); | |
641 | AliMatrix(idrotm[2084], 170.0, 180.0, 90.0, 90.0, 80.0, 180.0); | |
642 | AliMatrix(idrotm[2085], 90.0, 180.0, 90.0, 90.0, 0.0, 0.0); | |
643 | // | |
644 | AliMatrix(idrotm[2086], 90.0, 90.0, 100.0, 0., 170.0, 180.0); | |
645 | AliMatrix(idrotm[2087], 90.0, 90.0, 100.0, 0., 10.0, 0.0); | |
646 | AliMatrix(idrotm[2088], 90.0, 90.0, 80.0, 0., 170.0, 0.0); | |
647 | AliMatrix(idrotm[2089], 90.0, 90.0, 80.0, 0., -10.0, 0.0); | |
648 | ||
7e5caa00 | 649 | // |
650 | // web frame diagonal (outer) | |
651 | // | |
652 | h = 106.2; | |
653 | d = 2.*dwl; | |
4a8eca94 | 654 | dz = dymodL[2]-dymodU[1]-dwl; |
7e5caa00 | 655 | dq = h*h+dz*dz; |
656 | ||
657 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; | |
658 | ||
659 | ||
660 | theta = krad2deg * TMath::ACos(x); | |
661 | ||
662 | ptrap[0] = dz/2.; | |
663 | ptrap[1] = theta; | |
664 | ptrap[2] = 0.; | |
665 | ptrap[3] = dwh; | |
666 | ptrap[4] = dwl/x; | |
667 | ptrap[5] = ptrap[4]; | |
668 | ptrap[6] = 0; | |
669 | ptrap[7] = ptrap[3]; | |
670 | ptrap[8] = ptrap[4]; | |
671 | ptrap[9] = ptrap[4]; | |
672 | ptrap[10] = 0; | |
673 | gMC->Gsvolu("B065", "TRAP", kSteel, ptrap, 11); | |
674 | ptrap[3] = dwh - 0.2; | |
675 | ptrap[4] = (dwl-0.4)/x; | |
676 | ptrap[5] = ptrap[4]; | |
677 | ptrap[7] = ptrap[3]; | |
678 | ptrap[8] = ptrap[4]; | |
679 | ptrap[9] = ptrap[4]; | |
680 | gMC->Gsvolu("B066", "TRAP", kAir, ptrap, 11); | |
681 | gMC->Gspos("B066", 1, "B065", 0.0, -0.2, 0., 0, "ONLY"); | |
682 | ||
683 | // | |
684 | // web frame diagonal (inner) | |
685 | // | |
4a8eca94 | 686 | dz = dymodL[1]-dymodU[0]; |
7e5caa00 | 687 | dq = h*h+dz*dz; |
4a8eca94 | 688 | x = TMath::Sqrt((dz*dz-d*d)/dq + d*d*h*h/dq/dq)+d*h/dq; |
7e5caa00 | 689 | |
690 | ||
691 | theta = krad2deg * TMath::ACos(x); | |
692 | ||
4a8eca94 | 693 | ptrap[0] = (dymodL[1]-dymodU[0])/2.; |
7e5caa00 | 694 | ptrap[1] = theta; |
695 | ptrap[2] = 0.; | |
696 | ptrap[3] = dwh; | |
697 | ptrap[4] = dwl/x; | |
698 | ptrap[5] = ptrap[4]; | |
699 | ptrap[6] = 0; | |
700 | ptrap[7] = ptrap[3]; | |
701 | ptrap[8] = ptrap[4]; | |
702 | ptrap[9] = ptrap[4]; | |
703 | ptrap[10] = 0; | |
704 | gMC->Gsvolu("B067", "TRAP", kSteel, ptrap, 11); | |
705 | ptrap[3] = dwh-0.2; | |
706 | ptrap[4] = (dwl-0.4)/x; | |
707 | ptrap[5] = ptrap[4]; | |
708 | ptrap[7] = ptrap[3]; | |
709 | ptrap[8] = ptrap[4]; | |
710 | ptrap[9] = ptrap[4]; | |
711 | gMC->Gsvolu("B068", "TRAP", kAir, ptrap, 11); | |
712 | gMC->Gspos("B068", 1, "B067", 0.0, -0.2, 0., 0, "ONLY"); | |
713 | ||
714 | ||
715 | dz = -iFrH/2.+ringH/2.+kEps; | |
716 | ||
717 | for (i = 0; i< 3; i++) | |
718 | { | |
719 | // ring bars | |
720 | for (jmod = 0; jmod<3; jmod++) { | |
4a8eca94 | 721 | gMC->Gspos("B072", 6*i+jmod+1, module[jmod], 0, dymodL[i], dz, 0, "ONLY"); |
722 | gMC->Gspos("B072", 6*i+jmod+4, module[jmod], 0, -dymodL[i], dz, idrotm[2070], "ONLY"); | |
7e5caa00 | 723 | |
724 | // 0-deg web | |
4a8eca94 | 725 | if (i==2) { |
726 | gMC->Gspos("B263", 12*i+jmod+1, module[jmod], 60.0732, dymodU[i], 4.6669, idrotm[2072], "ONLY"); | |
727 | gMC->Gspos("B263", 12*i+jmod+4, module[jmod], 60.0732, -dymodU[i], 4.6669, idrotm[2071], "ONLY"); | |
728 | gMC->Gspos("B263", 12*i+jmod+7, module[jmod], -60.0732, dymodU[i], 4.6669, idrotm[2074], "ONLY"); | |
729 | gMC->Gspos("B263", 12*i+jmod+10, module[jmod], -60.0732, -dymodU[i], 4.6669, idrotm[2073], "ONLY"); | |
730 | } | |
7e5caa00 | 731 | } |
732 | } | |
733 | ||
734 | // outer diagonal web | |
735 | ||
4a8eca94 | 736 | dy = (dymodU[0]+dymodL[0])/2.; |
737 | for (jmod = 0; jmod<3; jmod++) { | |
738 | gMC->Gspos("B063", 4*jmod+1, module[jmod], 60.0732, dy, 4.6669, idrotm[2086], "ONLY"); | |
739 | gMC->Gspos("B063", 4*jmod+2, module[jmod], 60.0732, -dy, 4.6669, idrotm[2087], "ONLY"); | |
740 | gMC->Gspos("B063", 4*jmod+3, module[jmod], -60.0732, dy, 4.6669, idrotm[2088], "ONLY"); | |
741 | gMC->Gspos("B063", 4*jmod+4, module[jmod], -60.0732, -dy, 4.6669, idrotm[2089], "ONLY"); | |
742 | } | |
743 | ||
744 | dy = (dymodU[1]+dymodL[1])/2.; | |
745 | for (jmod = 0; jmod<3; jmod++) { | |
746 | gMC->Gspos("B163", 4*jmod+1, module[jmod], 60.0732, dy, 4.6669, idrotm[2080], "ONLY"); | |
747 | gMC->Gspos("B163", 4*jmod+2, module[jmod], 60.0732, -dy, 4.6669, idrotm[2079], "ONLY"); | |
748 | gMC->Gspos("B163", 4*jmod+3, module[jmod], -60.0732, dy, 4.6669, idrotm[2082], "ONLY"); | |
749 | gMC->Gspos("B163", 4*jmod+4, module[jmod], -60.0732, -dy, 4.6669, idrotm[2081], "ONLY"); | |
750 | } | |
751 | ||
752 | ||
753 | dy = (dymodL[2]+dymodU[1])/2.-dwl/2.; | |
7e5caa00 | 754 | for (jmod = 0; jmod<3; jmod++) { |
4a8eca94 | 755 | gMC->Gspos("B065", 4*jmod+1, module[jmod], 60.0732, dy, 4.6669, idrotm[2076], "ONLY"); |
756 | gMC->Gspos("B065", 4*jmod+2, module[jmod], 60.0732, -dy, 4.6669, idrotm[2075], "ONLY"); | |
757 | gMC->Gspos("B065", 4*jmod+3, module[jmod], -60.0732, dy, 4.6669, idrotm[2078], "ONLY"); | |
758 | gMC->Gspos("B065", 4*jmod+4, module[jmod], -60.0732, -dy, 4.6669, idrotm[2077], "ONLY"); | |
7e5caa00 | 759 | } |
760 | ||
761 | ||
4a8eca94 | 762 | dy = (dymodL[1]+dymodU[0])/2.; |
7e5caa00 | 763 | |
764 | for (jmod = 0; jmod<3; jmod++) { | |
4a8eca94 | 765 | gMC->Gspos("B067", 4*jmod+1, module[jmod], 60.0732, dy, 4.6669, idrotm[2076], "ONLY"); |
766 | gMC->Gspos("B067", 4*jmod+2, module[jmod], 60.0732, -dy, 4.6669, idrotm[2075], "ONLY"); | |
767 | gMC->Gspos("B067", 4*jmod+3, module[jmod], -60.0732, dy, 4.6669, idrotm[2078], "ONLY"); | |
768 | gMC->Gspos("B067", 4*jmod+4, module[jmod], -60.0732, -dy, 4.6669, idrotm[2077], "ONLY"); | |
7e5caa00 | 769 | } |
770 | ||
771 | // longitudinal bars (TPC rails attached) | |
772 | // new specs: | |
773 | // h x w x s = 100 x 75 x 6 | |
774 | // current: | |
775 | // Attention: 2 "U" shaped half rods per cell | |
776 | // | |
777 | // not yet used | |
778 | // | |
779 | ptrap[0] = 2.50; | |
780 | ptrap[1] = 10.00; | |
781 | ptrap[2] = 0.00; | |
782 | ptrap[3] = 350.00; | |
783 | ptrap[4] = 3.75; | |
784 | ptrap[5] = ptrap[4]; | |
785 | ptrap[6] = 0; | |
786 | ptrap[7] = ptrap[3]; | |
787 | ptrap[8] = ptrap[4]; | |
788 | ptrap[9] = ptrap[4]; | |
789 | ptrap[10] = 0; | |
f935f49e | 790 | // gMC->Gsvolu("B059", "TRAP", kSteel, ptrap, 11); |
7e5caa00 | 791 | ptrap[0] = 2.2; |
792 | ptrap[4] = 2.15; | |
793 | ptrap[5] = ptrap[4]; | |
794 | ptrap[7] = ptrap[3]; | |
795 | ptrap[8] = ptrap[4]; | |
796 | ptrap[9] = ptrap[4]; | |
f935f49e | 797 | //gMC->Gsvolu("B062", "TRAP", kAir, ptrap, 11); |
798 | //gMC->Gspos("B062", 1, "B059", 0.0, 0., 0., 0, "ONLY"); | |
799 | ||
7e5caa00 | 800 | // |
801 | // longitudinal bars (no TPC rails attached) | |
802 | // new specs: h x w x s = 60 x 60 x 3 | |
803 | // (was: 75 x 100 x 5?) | |
804 | // | |
805 | // | |
806 | // | |
807 | ptrap[0] = longW/4.; | |
808 | ptrap[4] = longH/2.; | |
809 | ptrap[5] = ptrap[4]; | |
810 | ptrap[7] = ptrap[3]; | |
811 | ptrap[8] = ptrap[4]; | |
812 | ptrap[9] = ptrap[4]; | |
813 | ||
814 | gMC->Gsvolu("BA59", "TRAP", kSteel, ptrap, 11); | |
815 | ptrap[0] = longW/4.-0.15; | |
816 | ptrap[4] = longH/2.-0.30; | |
817 | ptrap[5] = ptrap[4]; | |
818 | ptrap[7] = ptrap[3]; | |
819 | ptrap[8] = ptrap[4]; | |
820 | ptrap[9] = ptrap[4]; | |
821 | gMC->Gsvolu("BA62", "TRAP", kAir, ptrap, 11); | |
822 | gMC->Gspos("BA62", 1, "BA59", 0.0, 0.0, -0.15, 0, "ONLY"); | |
823 | ||
824 | dz = -iFrH/2.+ringH+longH/2.; | |
825 | ||
826 | for (jmod = 0; jmod<3; jmod++) { | |
4a8eca94 | 827 | gMC->Gspos("BA59", 2*jmod+1, module[jmod], 49.6476, 0.0, dz, idrotm[2084], "ONLY"); |
828 | gMC->Gspos("BA59", 2*jmod+2, module[jmod], -49.6476, 0.0, dz, idrotm[2083], "ONLY"); | |
7e5caa00 | 829 | } |
830 | // | |
831 | // | |
832 | // Spacer between TRD and TOF modules | |
833 | ptrap[0] = 0.99; | |
834 | ptrap[1] = 10.00; | |
835 | ptrap[2] = 0.00; | |
836 | ptrap[3] = 350.00; | |
837 | ptrap[4] = 0.9; | |
838 | ptrap[5] = ptrap[4]; | |
839 | ptrap[6] = 0; | |
840 | ptrap[7] = ptrap[3]; | |
841 | ptrap[8] = ptrap[4]; | |
842 | ptrap[9] = ptrap[4]; | |
843 | ptrap[10] = 0; | |
844 | gMC->Gsvolu("B056", "TRAP", kSteel, ptrap, 11); | |
845 | for (jmod = 0; jmod<3; jmod++) { | |
846 | gMC->Gspos("B056", 2*jmod+1, module[jmod], 61.9607, 0.0, 27.2, 0 , "ONLY"); | |
4a8eca94 | 847 | gMC->Gspos("B056", 2*jmod+2, module[jmod], -61.9607, 0.0, 27.2, idrotm[2085], "ONLY"); |
7e5caa00 | 848 | } |
849 | // | |
850 | // Mother volumes for TRD and TOF | |
851 | // | |
852 | if (!fHoles) { | |
d03c72a2 | 853 | printf("\n FRAME Version without Holes !"); |
7e5caa00 | 854 | ptrd1[0] = 49.8065; |
855 | ptrd1[1] = 62.8535; | |
856 | ptrd1[2] = 375.5; | |
857 | ptrd1[3] = 37.; | |
858 | gMC->Gsvolu("BTR1", "TRD1", kAir, ptrd1, 4); | |
859 | gMC->Gsvolu("BTR2", "TRD1", kAir, ptrd1, 4); | |
860 | gMC->Gsvolu("BTR3", "TRD1", kAir, ptrd1, 4); | |
861 | ||
862 | ptrd1[0] = 63.2061; | |
863 | ptrd1[1] = 68.3192; | |
864 | ptrd1[2] = 375.5; | |
865 | ptrd1[3] = 14.5; | |
866 | gMC->Gsvolu("BTO1", "TRD1", kAir, ptrd1, 4); | |
867 | gMC->Gsvolu("BTO2", "TRD1", kAir, ptrd1, 4); | |
868 | gMC->Gsvolu("BTO3", "TRD1", kAir, ptrd1, 4); | |
869 | ||
870 | gMC->Gspos("BTR1", 1, "B071", 0., 0., -10.8, 0, "ONLY"); | |
871 | gMC->Gspos("BTR2", 1, "B074", 0., 0., -10.8, 0, "ONLY"); | |
872 | gMC->Gspos("BTR3", 1, "B075", 0., 0., -10.8, 0, "ONLY"); | |
873 | ||
874 | gMC->Gspos("BTO1", 1, "B071", 0., 0., 42.69, 0, "ONLY"); | |
875 | gMC->Gspos("BTO2", 1, "B074", 0., 0., 42.69, 0, "ONLY"); | |
876 | gMC->Gspos("BTO3", 1, "B075", 0., 0., 42.69, 0, "ONLY"); | |
877 | } else { | |
d03c72a2 | 878 | printf("\n FRAME Version with Holes !"); |
7e5caa00 | 879 | ptrd1[0] = 49.8065; |
880 | ptrd1[1] = 62.8535; | |
881 | ptrd1[2] = 375.5; | |
882 | ptrd1[3] = 37; | |
883 | gMC->Gsvolu("BTR1", "TRD1", kAir, ptrd1, 4); | |
884 | ptrd1[2] = 156.75; | |
885 | gMC->Gsvolu("BTR2", "TRD1", kAir, ptrd1, 4); | |
886 | ptrd1[2] = 79.75; | |
887 | gMC->Gsvolu("BTR3", "TRD1", kAir, ptrd1, 4); | |
888 | ||
889 | ptrd1[0] = 63.2061; | |
890 | ptrd1[1] = 68.3192; | |
891 | ptrd1[2] = 375.5; | |
892 | ptrd1[3] = 14.5; | |
893 | gMC->Gsvolu("BTO1", "TRD1", kAir, ptrd1, 4); | |
894 | ptrd1[2] = 156.75; | |
895 | gMC->Gsvolu("BTO2", "TRD1", kAir, ptrd1, 4); | |
896 | ptrd1[2] = 79.75; | |
897 | gMC->Gsvolu("BTO3", "TRD1", kAir, ptrd1, 4); | |
898 | ||
7e5caa00 | 899 | |
4c057bc8 | 900 | gMC->Gspos("BTR1", 1, "B071", 0., 0.00, -10.8, 0, "ONLY"); |
901 | gMC->Gspos("BTR2", 1, "B074", 0., -218.75, -10.8, idrotm[2070], "ONLY"); | |
902 | gMC->Gspos("BTR2", 2, "B074", 0., 218.75, -10.8, 0, "ONLY"); | |
903 | gMC->Gspos("BTR3", 1, "B075", 0., -295.75, -10.8, idrotm[2070], "ONLY"); | |
904 | gMC->Gspos("BTR3", 2, "B075", 0., 295.75, -10.8, 0, "ONLY"); | |
905 | ||
906 | gMC->Gspos("BTO1", 1, "B071", 0., 0.00, 42.69, 0, "ONLY"); | |
907 | gMC->Gspos("BTO2", 1, "B074", 0., -218.75, 42.69, idrotm[2070], "ONLY"); | |
908 | gMC->Gspos("BTO2", 2, "B074", 0., 218.75, 42.69, 0, "ONLY"); | |
909 | gMC->Gspos("BTO3", 1, "B075", 0., -295.75, 42.69, idrotm[2070], "ONLY"); | |
910 | gMC->Gspos("BTO3", 2, "B075", 0., 295.75, 42.69, 0, "ONLY"); | |
7e5caa00 | 911 | } |
b35d7d26 | 912 | |
913 | // | |
914 | // Geometry of Rails starts here | |
915 | // | |
916 | // | |
917 | // | |
918 | // Rails for space-frame | |
919 | // | |
920 | Float_t rbox[3]; | |
921 | ||
922 | rbox[0] = 25.00; | |
923 | rbox[1] = 27.50; | |
924 | rbox[2] = 600.00; | |
925 | gMC->Gsvolu("BRS1", "BOX", kAir, rbox, 3); | |
926 | ||
927 | rbox[0] = 25.00; | |
928 | rbox[1] = 3.75; | |
929 | gMC->Gsvolu("BRS2", "BOX", kSteel, rbox, 3); | |
930 | ||
931 | rbox[0] = 3.00; | |
932 | rbox[1] = 20.00; | |
933 | gMC->Gsvolu("BRS3", "BOX", kSteel, rbox, 3); | |
934 | ||
935 | gMC->Gspos("BRS2", 1, "BRS1", 0., -27.5+3.75, 0., 0, "ONLY"); | |
936 | gMC->Gspos("BRS2", 2, "BRS1", 0., 27.5-3.75, 0., 0, "ONLY"); | |
937 | gMC->Gspos("BRS3", 1, "BRS1", 0., 0., 0., 0, "ONLY"); | |
938 | gMC->Gspos("BRS1", 1, "ALIC", -430.-3., -180., 0., 0, "ONLY"); | |
939 | gMC->Gspos("BRS1", 2, "ALIC", 430.+3., -180., 0., 0, "ONLY"); | |
940 | ||
941 | rbox[0] = 3.0; | |
e16311cb | 942 | rbox[1] = 145./2.; |
b35d7d26 | 943 | rbox[2] = 25.0; |
944 | gMC->Gsvolu("BRS4", "BOX", kSteel, rbox, 3); | |
945 | ||
946 | gMC->Gspos("BRS4", 1, "ALIC", 430.+3., -180.+55./2.+rbox[1], 224., 0, "ONLY"); | |
947 | gMC->Gspos("BRS4", 2, "ALIC", 430.+3., -180.+55./2.+rbox[1], -224., 0, "ONLY"); | |
948 | gMC->Gspos("BRS4", 3, "ALIC", -430.-3., -180.+55./2.+rbox[1], 224., 0, "ONLY"); | |
949 | gMC->Gspos("BRS4", 4, "ALIC", -430.-3., -180.+55./2.+rbox[1], -224., 0, "ONLY"); | |
950 | ||
951 | // | |
952 | // Rails for EMCAL | |
953 | // | |
954 | /* | |
955 | rbox[0] = 27.50; | |
956 | rbox[1] = 32.50; | |
957 | gMC->Gsvolu("BRE1", "BOX", kAir, rbox, 3); | |
958 | ||
959 | rbox[0] = 27.50; | |
960 | rbox[1] = 2.50; | |
961 | gMC->Gsvolu("BRE2", "BOX", kSteel, rbox, 3); | |
962 | ||
963 | rbox[0] = 0.50; | |
964 | rbox[1] = 27.50; | |
965 | gMC->Gsvolu("BRE3", "BOX", kSteel, rbox, 3); | |
966 | ||
967 | gMC->Gspos("BRE2", 1, "BRE1", 0., -32.5+2.50, 0., 0, "ONLY"); | |
968 | gMC->Gspos("BRE2", 2, "BRE1", 0., 32.5-2.50, 0., 0, "ONLY"); | |
969 | gMC->Gspos("BRE3", 1, "BRE1", -20., 0., 0., 0, "ONLY"); | |
970 | gMC->Gspos("BRE3", 2, "BRE1", 20., 0., 0., 0, "ONLY"); | |
971 | gMC->Gspos("BRE1", 1, "ALIC", -496., -190., 0., 0, "ONLY"); | |
972 | gMC->Gspos("BRE1", 2, "ALIC", 496., -190., 0., 0, "ONLY"); | |
973 | */ | |
7e5caa00 | 974 | } |
975 | ||
976 | ||
977 | //___________________________________________ | |
978 | void AliFRAMEv2::CreateMaterials() | |
979 | { | |
eeacf08b | 980 | // Creates the materials |
7e5caa00 | 981 | Float_t epsil, stemax, tmaxfd, deemax, stmin; |
982 | ||
983 | epsil = 1.e-4; // Tracking precision, | |
984 | stemax = -0.01; // Maximum displacement for multiple scat | |
985 | tmaxfd = -20.; // Maximum angle due to field deflection | |
986 | deemax = -.3; // Maximum fractional energy loss, DLS | |
987 | stmin = -.8; | |
988 | Int_t isxfld = gAlice->Field()->Integ(); | |
989 | Float_t sxmgmx = gAlice->Field()->Max(); | |
990 | ||
991 | Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 }; | |
992 | Float_t zsteel[4] = { 26.,24.,28.,14. }; | |
993 | Float_t wsteel[4] = { .715,.18,.1,.005 }; | |
994 | ||
995 | AliMixture(65, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel); | |
996 | AliMaterial(5, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500.); | |
997 | AliMedium(65, "Stainless Steel", 65, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin); | |
998 | AliMedium( 5, "Air ", 5, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin); | |
999 | } | |
1000 | ||
1001 | //_____________________________________________________________________________ | |
1002 | void AliFRAMEv2::Init() | |
1003 | { | |
1004 | // | |
1005 | // Initialise the module after the geometry has been defined | |
1006 | // | |
0a05c568 | 1007 | if(fDebug) { |
1008 | printf("%s: **************************************" | |
1009 | " FRAME " | |
1010 | "**************************************\n",ClassName()); | |
1011 | printf("\n%s: Version 2 of FRAME initialised, symmetric FRAME\n\n",ClassName()); | |
1012 | printf("%s: **************************************" | |
1013 | " FRAME " | |
1014 | "**************************************\n",ClassName()); | |
1015 | } | |
55bdc695 | 1016 | // |
1017 | // The reference volume id | |
1018 | fRefVolumeId = gMC->VolId("BREF"); | |
7e5caa00 | 1019 | } |
1020 | ||
6304e7d2 | 1021 | Int_t AliFRAMEv2::IsVersion() const |
1022 | { | |
eeacf08b | 1023 | // Returns the version of the FRAME (1 if no holes, 0 otherwise) |
6304e7d2 | 1024 | Int_t version = 0; |
1025 | if (fHoles == 0) version = 1; | |
1026 | return version; | |
1027 | } | |
7e5caa00 | 1028 | |
55bdc695 | 1029 | void AliFRAMEv2::StepManager() |
1030 | { | |
1031 | // | |
1032 | // Stepmanager of AliFRAMEv2.cxx | |
1033 | // Used for recording of reference tracks entering the spaceframe mother volume | |
1034 | // | |
1035 | Int_t copy, id; | |
1036 | ||
1037 | // | |
1038 | // Only charged tracks | |
1039 | if( !(gMC->TrackCharge()) ) return; | |
1040 | // | |
1041 | // Only tracks entering mother volume | |
1042 | // | |
1043 | ||
1044 | id=gMC->CurrentVolID(copy); | |
1045 | ||
1046 | if (id != fRefVolumeId) return; | |
1047 | if(!gMC->IsTrackEntering()) return; | |
1048 | // | |
1049 | // Add the reference track | |
1050 | // | |
642f15cf | 1051 | AddTrackReference(gAlice->GetCurrentTrackNumber()); |
55bdc695 | 1052 | } |
7e5caa00 | 1053 | |
55bdc695 | 1054 | |
7e5caa00 | 1055 | |
1056 | ||
1057 | ||
1058 |