Coding convention ...
[u/mrichter/AliRoot.git] / STRUCT / AliPIPEv0.cxx
CommitLineData
4c039060 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
16/*
17$Log$
43ea1292 18Revision 1.24 2002/10/22 15:02:47 alibrary
19Introducing Riostream.h
20
b16a1b1e 21Revision 1.23 2002/10/14 14:57:39 hristov
22Merging the VirtualMC branch to the main development branch (HEAD)
23
b9d0a01d 24Revision 1.19.4.2 2002/10/11 08:04:28 hristov
25Updating VirtualMC to v3-09-02
26
27Revision 1.22 2002/09/02 15:29:20 morsch
28Gsbool calls to resolve MANY added (I. Hrivnacova).
29
fddcf8f7 30Revision 1.19.4.1 2002/06/10 15:13:48 hristov
31Merged with v3-08-02
32
33Revision 1.21 2002/05/11 19:14:44 morsch
34PCONE QBEU had last z defined twice.
35
13a638e8 36Revision 1.20 2002/05/02 12:36:43 morsch
37New version of beam-pipe geometry. Ref. AL502206PL
38(used in production readiness report).
39
614dff1c 40Revision 1.19 2002/03/25 12:34:40 morsch
41Obsolete support rollers removed.
42
4a7308f7 43Revision 1.18 2002/02/01 18:02:41 morsch
44Material of beam pipe between inner Be piece and forward detectors
45can be set by SetPipeMaterial(mat), mat = kInox, kAlu, kBe ...
46
765e9e1a 47Revision 1.17 2001/09/24 13:11:50 morsch
48Ion pump and bellows moved out by 15 cm to make space for forward
49detectors.
50
22811e34 51Revision 1.16 2001/05/16 14:57:22 alibrary
52New files for folders and Stack
53
9e1a0ddb 54Revision 1.15 2001/05/02 11:50:18 morsch
55New layout of the non-absorber side provided by Y. Viyogi. Not the final design
56but the prsent most realistic.
57
cd9c4f3a 58Revision 1.14 2001/01/20 16:56:33 morsch
59Put air in connecting tubes and flanges of vacuum pump.
60
14b75006 61Revision 1.13 2001/01/20 16:35:27 morsch
62Increase mother volume for bellows.
63
1416b7f3 64Revision 1.12 2000/12/21 16:41:06 morsch
65Coding convention clean-up (RS3)
66
13391c3e 67Revision 1.11 2000/11/28 16:06:57 morsch
68Undulated beam-pipe replaced by Al-Be (40,60) pipe 1.5 mm thick.
69
2196bc42 70Revision 1.10 2000/11/24 13:00:37 morsch
71- Geometry and materials imported from euclid output
72- include comments
73- better struturing of volume tree
74- improved version of flange close to front absorber
75- more realistic pump materials
76- undulated beam pipe imported from v3.
77
7bd7faf8 78Revision 1.9 2000/10/02 21:28:15 fca
79Removal of useless dependecies via forward declarations
80
94de3818 81Revision 1.8 2000/06/11 12:37:01 morsch
82Coding rule violations corrected
83
b43eb0dc 84Revision 1.7 2000/02/23 16:25:24 fca
85AliVMC and AliGeant3 classes introduced
86ReadEuclid moved from AliRun to AliModule
87
b13db077 88Revision 1.6 1999/09/29 09:24:30 fca
89Introduction of the Copyright and cvs Log
90
4c039060 91*/
92
fe4da5cc 93////////////////////////////////////////////////
94// Beam pipe class /
95////////////////////////////////////////////////
96
fe4da5cc 97#include "AliPIPEv0.h"
98#include "AliRun.h"
7bd7faf8 99#include "AliConst.h"
100#include "AliMagF.h"
fe4da5cc 101#include "TSystem.h"
22811e34 102
b16a1b1e 103#include <Riostream.h>
fe4da5cc 104
105ClassImp(AliPIPEv0)
106
107//_____________________________________________________________________________
b8032157 108AliPIPEv0::AliPIPEv0()
fe4da5cc 109{
b43eb0dc 110// Constructor
765e9e1a 111 SetPipeMaterial();
fe4da5cc 112}
113
114//_____________________________________________________________________________
115AliPIPEv0::AliPIPEv0(const char *name, const char *title)
116 : AliPIPE(name,title)
117{
b43eb0dc 118// Constructor
765e9e1a 119 SetPipeMaterial();
fe4da5cc 120}
121
122
123//___________________________________________
124void AliPIPEv0::CreateGeometry()
125{
fe4da5cc 126//Begin_Html
127/*
1439f98e 128<img src="picts/pipe.gif">
fe4da5cc 129*/
130//End_Html
131
132
133//Begin_Html
134/*
1439f98e 135<img src="picts/tree_pipe.gif">
fe4da5cc 136*/
137//End_Html
138
9e1a0ddb 139 if(fDebug) printf("%s: Create PIPEv0 geometry \n",ClassName());
fe4da5cc 140
fe4da5cc 141
7bd7faf8 142 Int_t *idtmed = fIdtmed->GetArray();
22811e34 143 Float_t ppcon[84], ptube[3], pbox[3];
7bd7faf8 144 Int_t i=0;
145
7bd7faf8 146
147 Int_t idrotm[2099];
148 AliMatrix(idrotm[2001],90.,240., 0., 0., 90.,150.);
149 AliMatrix(idrotm[2002],90., 0., 0., 0., 90.,270.);
150 AliMatrix(idrotm[2003],90.,120., 0., 0., 90., 30.);
151 AliMatrix(idrotm[2004],90.,315., 90., 45., 0., 0.);
152 AliMatrix(idrotm[2005],90.,270., 90., 0., 0., 0.);
153 AliMatrix(idrotm[2006],90.,225., 90.,315., 0., 0.);
154 AliMatrix(idrotm[2007],90.,180., 90.,270., 0., 0.);
155 AliMatrix(idrotm[2008],90.,135., 90.,225., 0., 0.);
156 AliMatrix(idrotm[2009],90., 90., 90.,180., 0., 0.);
157 AliMatrix(idrotm[2010],90., 45., 90.,135., 0., 0.);
158 idrotm[2011] = 0;
159 AliMatrix(idrotm[2012],90.,180., 90., 90.,180., 0.);
160 AliMatrix(idrotm[2013],90., 0., 90., 90.,180., 0.);
614dff1c 161//
162// Bellow
163//
22811e34 164// distance between bellows
614dff1c 165 const Float_t dzbb = 9.0;
166// total size of bellow section
167 const Float_t dzb = 15.0;
168// size of undulated region
169 const Float_t dzub = 2.0;
170
171// half-lengths of various beam pipe sections
172// central Be-Pipe
173 Float_t hlenQbbe1 = 40.;
174 Float_t hlenQbbe2 = 36.5;
175 Float_t hlenQbbe = (hlenQbbe1+hlenQbbe2)/2.;
176//
177//
178// Float_t hlenQbt1 = 5.5/2.;
179//
180// Pipe outside central region (non-absober side)
181 Float_t hlenQbab = 157.5;
182//
183// Flange non-absorber side
184 Float_t hlenQb29 = 11.5/2.+1.75 + 5.0;
185//
186// Bellow element
187 Float_t hlenQbe0 = dzb;
188//
189// Inox pipe between Be and Bellow (absorber side)
190 Float_t hlenQb24[3] = {10.5/2., 1.8, 3.3};
191//
192//
193 Float_t hlenQb28 = (800.-hlenQbbe1-2.*hlenQbab-4.*hlenQb29-2.*hlenQbe0)/2.;
194//
195// Position of the pump
196 Float_t zPump = hlenQbbe1+2.*hlenQbab+2.*hlenQb29+dzb;
197//
198// Inner beam pipe radius
199 Float_t RinBe = 2.9;
200 Float_t RinSt = 2.92;
201//
202//
203 Float_t RoutBe = 2.98;
204 Float_t RoutSt = 3.00;
22811e34 205
614dff1c 206
207//
208 Float_t dz;
7bd7faf8 209
fe4da5cc 210//
211// The peam pipe up to the Front Absorber
fe4da5cc 212//
7bd7faf8 213// Mother Volume QBPM
614dff1c 214 ppcon[0] = 0;
215 ppcon[1] = 360;
216 ppcon[2] = 18;
7bd7faf8 217// 1:
614dff1c 218 ppcon[3] = -90.;
219 ppcon[4] = 0.;
220 ppcon[5] = 4.4;
7bd7faf8 221// 2
614dff1c 222 ppcon[6] = -90+2.*hlenQb24[2]+2.8+2.*hlenQb24[1];
223 ppcon[7] = 0.;
224 ppcon[8] = 4.4;
7bd7faf8 225// 3
614dff1c 226 ppcon[9] = ppcon[6];
227 ppcon[10] = 0.;
228 ppcon[11] = 4.1;
22811e34 229// 4
614dff1c 230 ppcon[12] = ppcon[9] + 2. + 2.*dzub+0.2;
231 ppcon[13] = 0.;
232 ppcon[14] = 4.1;
22811e34 233// 5
614dff1c 234 ppcon[15] = ppcon[12];
235 ppcon[16] = 0.;
236 ppcon[17] = 3.2;
22811e34 237// 6
614dff1c 238 ppcon[18] = ppcon[15] + 2.* dzbb-0.4;
239 ppcon[19] = 0.;
240 ppcon[20] = 3.2;
7bd7faf8 241// 7
614dff1c 242 ppcon[21] = ppcon[18];
243 ppcon[22] = 0.;
244 ppcon[23] = 4.1;
7bd7faf8 245// 8
614dff1c 246 ppcon[24] = -44.;
247 ppcon[25] = 0.;
248 ppcon[26] = 4.1;
7bd7faf8 249// 9
614dff1c 250 ppcon[27] = -44.;
7bd7faf8 251 ppcon[28] = 0;
614dff1c 252 ppcon[29] = 3.0;
22811e34 253// 10
614dff1c 254 ppcon[30] = 38.;
7bd7faf8 255 ppcon[31] = 0;
614dff1c 256 ppcon[32] = 3.0;
22811e34 257// 11
614dff1c 258 ppcon[33] = 38.;
7bd7faf8 259 ppcon[34] = 0;
614dff1c 260 ppcon[35] = 3.6;
22811e34 261// 12
614dff1c 262 ppcon[36] = hlenQbbe1+2.*hlenQbab-0.1;
263 ppcon[37] = 0.;
264 ppcon[38] = 3.6;
265// 13
266 ppcon[39] = ppcon[36];
267 ppcon[40] = 0.;
268 ppcon[41] = 3.6;
22811e34 269// 14
614dff1c 270 ppcon[42] = ppcon[39]+2.*hlenQb29-5.;
271 ppcon[43] = 0.;
272 ppcon[44] = 3.6;
273// 15
274 ppcon[45] = ppcon[42];
275 ppcon[46] = 0.;
276 ppcon[47] = 56.;
22811e34 277// 16
614dff1c 278 ppcon[48] = ppcon[45]+2.*dzb+10.;
279 ppcon[49] = 0.;
280 ppcon[50] = 56.;
22811e34 281// 17
614dff1c 282 ppcon[51] = ppcon[48];
22811e34 283 ppcon[52] = 0.;
614dff1c 284 ppcon[53] = 3.6;
22811e34 285// 18
614dff1c 286 ppcon[54] = 800.;
22811e34 287 ppcon[55] = 0.;
614dff1c 288 ppcon[56] = 3.6;
7bd7faf8 289
614dff1c 290 gMC->Gsvolu("QBPM", "PCON", idtmed[kAir], ppcon,57);
291
292
7bd7faf8 293//
cd9c4f3a 294// volume definitions of various sections
295//
cd9c4f3a 296
614dff1c 297//
298// The Vacuum
299 gMC->Gsvolu("QBVA","TUBE", idtmed[kVac], ptube, 0);
300 ptube[0] = 0.0;
301 ptube[1] = RinSt;
302 ptube[2] = (90.-hlenQbbe2)/2.;
303 dz = -90. + ptube[2];
304 gMC->Gsposp ("QBVA", 1, "QBPM", 0., 0., dz , 0, "ONLY", ptube, 3);
305 dz = dz + ptube[2];
306
307 ptube[1] = RinBe;
308 ptube[2] = hlenQbbe+hlenQbab;
309 dz = dz + ptube[2];
310 gMC->Gsposp ("QBVA", 2, "QBPM", 0., 0., dz , 0, "ONLY", ptube, 3);
311 dz = dz + ptube[2];
312
313 ptube[1] = RinSt;
314 ptube[2] = (800.-hlenQbbe1-2.*hlenQbab)/2.;
315 dz = dz + ptube[2];
316 gMC->Gsposp ("QBVA", 3, "QBPM", 0., 0., dz , 0, "ONLY", ptube, 3);
cd9c4f3a 317
614dff1c 318//
319// Be Pipe in central Alice
320 ptube[0] = RinBe;
321 ptube[1] = RoutBe;
cd9c4f3a 322 ptube[2] = hlenQbbe;
7bd7faf8 323
324 gMC->Gsvolu("QBBE","TUBE", idtmed[kBe], ptube, 3);
7bd7faf8 325
326//
614dff1c 327// Support Ring
7bd7faf8 328//
614dff1c 329 // Mother
330 ppcon[0] = 0;
331 ppcon[1] = 360;
332 ppcon[2] = 6;
333// 1:
334 ppcon[3] = -1.;
335 ppcon[4] = 3.0;
336 ppcon[5] = 3.4;
337// 2
338 ppcon[6] = -0.8;
339 ppcon[7] = 3.0;
340 ppcon[8] = 3.4;
341// 3
342 ppcon[9] = -0.8;
343 ppcon[10] = 3.0;
344 ppcon[11] = 3.2;
345// 4
346 ppcon[12] = 0.8;
347 ppcon[13] = 3.0;
348 ppcon[14] = 3.2;
349// 5
350 ppcon[15] = 0.8;
351 ppcon[16] = 3.0;
352 ppcon[17] = 3.4;
353// 6
354 ppcon[18] = 1.0;
355 ppcon[19] = 3.0;
356 ppcon[20] = 3.4;
7bd7faf8 357
7bd7faf8 358
614dff1c 359 gMC->Gsvolu("QBSR", "PCON", idtmed[kC], ppcon,21);
360 gMC->Gspos("QBSR", 1, "QBPM", 0.0, 0.0, 40., 0, "ONLY");
361 gMC->Gspos("QBSR", 2, "QBPM", 0.0, 0.0, 150., 0, "ONLY");
362 gMC->Gspos("QBSR", 3, "QBPM", 0.0, 0.0, 260., 0, "ONLY");
363 gMC->Gspos("QBSR", 4, "QBPM", 0.0, 0.0,- 46., 0, "ONLY");
7bd7faf8 364//
614dff1c 365// Flange and Fixed Point: non absorber side
7bd7faf8 366//
614dff1c 367// ---------->
368//
369// Mother
370 ppcon[0] = 0;
371 ppcon[1] = 360;
372 ppcon[2] = 4;
373// 1:
374 ppcon[3] = -hlenQb29;
375 ppcon[4] = RinSt;
376 ppcon[5] = 5.8;
377// 2
378 ppcon[6] = ppcon[3]+3.6;
379 ppcon[7] = RinSt;
380 ppcon[8] = 5.8;
381// 3
382 ppcon[9] = ppcon[6];
383 ppcon[10] = RinSt;
384 ppcon[11] = 3.6;
385// 4
386 ppcon[12] = hlenQb29;
387 ppcon[13] = RinSt;
388 ppcon[14] = 3.6;
7bd7faf8 389
614dff1c 390 gMC->Gsvolu("QB29", "PCON", idtmed[kAir], ppcon,15);
7bd7faf8 391
7bd7faf8 392
614dff1c 393// Flange
394 ptube[0] = RinSt;
395 ptube[1] = 5.7;
396 ptube[2] = 1.75;
397 gMC->Gsvolu("QF29","TUBE", idtmed[kInox], ptube, 3);
398 gMC->Gspos("QF29", 1, "QB29", 0.0, 0.0, -hlenQb29+1.75, 0, "ONLY");
399// Pipe
400 ptube[0] = RinSt;
401 ptube[1] = 3.0;
cd9c4f3a 402 ptube[2] = hlenQb29;
614dff1c 403 gMC->Gsvolu("QS29","TUBE", idtmed[kInox], ptube, 3);
404 gMC->Gspos("QS29", 1, "QB29", 0.0, 0.0, 0., 0, "ONLY");
405// Fixed point
406 ptube[0] = RinSt;
407 ptube[1] = 3.5;
408 ptube[2] = 0.3;
409 gMC->Gsvolu("QP29","TUBE", idtmed[kInox], ptube, 3);
410 gMC->Gspos("QP29", 1, "QB29", 0.0, 0.0, -hlenQb29+9.75+3., 0, "ONLY");
22811e34 411
614dff1c 412//
7bd7faf8 413//
cd9c4f3a 414// Inox beam pipe: final section on non-absorber side
7bd7faf8 415
614dff1c 416 ptube[0] = RinSt;
417 ptube[1] = RoutSt;
cd9c4f3a 418 ptube[2] = hlenQb28;
7bd7faf8 419
420 gMC->Gsvolu("QB28","TUBE", idtmed[kInox], ptube, 3);
7bd7faf8 421
2196bc42 422
423// Al-Be (40-60 wgt%, rho=2.7 g/cm**3) beam pipe
424//
614dff1c 425// This section is under study (A.M. 1/2/2002)
765e9e1a 426//
427
614dff1c 428 ptube[0] = RinBe;
765e9e1a 429 if (fPipeMaterial == kAlu) {
430 ptube[1] = 3.0;
431 } else if (fPipeMaterial == kBe) {
614dff1c 432 ptube[1] = RoutBe;
765e9e1a 433 } else if (fPipeMaterial == kInox){
614dff1c 434 ptube[1] = RoutSt;
765e9e1a 435 }
cd9c4f3a 436 ptube[2] = hlenQbab;
2196bc42 437
765e9e1a 438 gMC->Gsvolu("QBAB","TUBE", idtmed[fPipeMaterial], ptube, 3);
2196bc42 439
cd9c4f3a 440// 2.5 mm thick SS tube for hanging pump
614dff1c 441/*
442 ptube[0] = Rin;
7bd7faf8 443 ptube[1] = 3.15;
cd9c4f3a 444 ptube[2] = hlenQb26;
7bd7faf8 445
cd9c4f3a 446 gMC->Gsvolu("QB26","TUBE", idtmed[kInox], ptube, 3);
614dff1c 447*/
7bd7faf8 448//
449// Bellows
fe4da5cc 450//
22811e34 451//
7bd7faf8 452// Mother Volume
614dff1c 453 Float_t pconQBE0[33];
454 pconQBE0[ 0]= 0;
455 pconQBE0[ 1]= 360;
456 pconQBE0[ 2]= 10;
457// 1
458 pconQBE0[ 3]= -dzb;
459 pconQBE0[ 4]= RinSt;
460 pconQBE0[ 5]= RoutSt;
461// 2
462 pconQBE0[ 6]= -dzb+2.;
463 pconQBE0[ 7]= RinSt;
464 pconQBE0[ 8]= RoutSt;
465// 3
466 pconQBE0[ 9]= -dzb+2.;
467 pconQBE0[10]= RinSt;
468 pconQBE0[11]= 4.00;
469// 4
470 pconQBE0[12]= -dzb+2.+2.*dzub;
471 pconQBE0[13]= RinSt;
472 pconQBE0[14]= 4.00;
473// 5
474 pconQBE0[15]= -dzb+2.+2.*dzub;
475 pconQBE0[16]= RinSt;
476 pconQBE0[17]= RoutSt;
477// 6
478 pconQBE0[18]= -dzb+2.+2.*dzub+2.*dzbb;
479 pconQBE0[19]= RinSt;
480 pconQBE0[20]= RoutSt;
481// 7
482 pconQBE0[21]= -dzb+2.+2.*dzub+2.*dzbb;
483 pconQBE0[22]= RinSt;
484 pconQBE0[23]= 4.00;
485// 8
486 pconQBE0[24]= -dzb+2.+4.*dzub+2.*dzbb;
487 pconQBE0[25]= RinSt;
488 pconQBE0[26]= 4.00;
489// 9
490 pconQBE0[27]= -dzb+2.+4.*dzub+2.*dzbb;
491 pconQBE0[28]= RinSt;
492 pconQBE0[29]= RoutSt;
493// 10
494 pconQBE0[30]= +dzb;
495 pconQBE0[31]= RinSt;
496 pconQBE0[32]= RoutSt;
497 gMC->Gsvolu("QBE0", "PCON", idtmed[kAir], pconQBE0, 33);
498//
499// Undulated piece mother
500 ptube[0] = RinSt;
501 ptube[1] = 4.00;
502 ptube[2] = dzub;
7bd7faf8 503 gMC->Gsvolu("QBEM","TUBE", idtmed[kAir], ptube, 3);
614dff1c 504 dz = -dzb+2.+dzub;
505 gMC->Gspos("QBEM", 2 ,"QBE0", 0.0, 0.0, dz, 0 , "ONLY");
506 gMC->Gspos("QBEM", 1 ,"QBE0", 0.0, 0.0, -dz, idrotm[2012], "ONLY");
507//
508 Float_t pund[30];
509 Float_t uw = 0.02;
510 Float_t ur = 2.*dzub-12.*uw;
511 Float_t uz = ur/13.;
512 Float_t ut = uz+uw;
513
514 pund[ 0] = 0;
515 pund[ 1] = 360;
13a638e8 516 pund[ 2] = 8;
614dff1c 517
518 pund[ 3] = -ut;
519 pund[ 4] = RinSt;
520 pund[ 5] = RinSt+uw;
521
522 pund[ 6] = -ut+uz;
523 pund[ 7] = pund[4];
524 pund[ 8] = pund[5];
525
526 pund[ 9] = pund[6];
527 pund[10] = pund[4];
528 pund[11] = 4.0;
529
530 pund[12] = pund[9]+uw;
531 pund[13] = pund[10];
532 pund[14] = pund[11];
533
534 pund[15] = pund[12];
535 pund[16] = 4.0-uw;
536 pund[17] = pund[14];
537
538 pund[18] = pund[12]+uz;
539 pund[19] = pund[16];
540 pund[20] = pund[17];
541
542 pund[21] = pund[18];
543 pund[22] = RinSt;
544 pund[23] = pund[20];
545
546 pund[24] = pund[21]+uw;
547 pund[25] = pund[22];
548 pund[26] = pund[23];
614dff1c 549
13a638e8 550 gMC->Gsvolu("QBEU", "PCON", idtmed[kInox], pund, 27);
614dff1c 551
552 for (i = 0; i < 6; i++)
553 {
554 dz = -dzub+(1+2*i)*ut;
555 gMC->Gspos("QBEU", i+1 ,"QBEM", 0.0, 0.0, dz, 0 , "ONLY");
7bd7faf8 556 }
614dff1c 557 ptube[0] = RinSt;
558 ptube[1] = RinSt+uw;
559 ptube[2] = uz;
560 gMC->Gsvolu("QBEW","TUBE", idtmed[kInox], ptube, 3);
561 gMC->Gspos("QBEW", 1 ,"QBEM", 0.0, 0.0, dzub-uz, 0 , "ONLY");
7bd7faf8 562//
614dff1c 563// BeamPipe
564 gMC->Gsvolu("QBEP","TUBE", idtmed[kInox], ptube, 0);
565 ptube[0] = RinSt;
566 ptube[1] = RoutSt;
567 ptube[2] = 1.;
568 gMC->Gsposp("QBEP", 1 ,"QBE0", 0.0, 0.0, -dzb+1., 0 , "ONLY", ptube, 3);
569 gMC->Gsposp("QBEP", 2 ,"QBE0", 0.0, 0.0, dzb-1., 0 , "ONLY", ptube, 3);
570 ptube[2] = dzbb;
571 gMC->Gsposp("QBEP", 3 ,"QBE0", 0.0, 0.0, 0., 0 , "ONLY", ptube, 3);
572//
573// End undulated part
574//
575//
576// ----> End Bellow
577//
578// **** Placement of various sections on non-absorber side ****
7bd7faf8 579//
cd9c4f3a 580 //
614dff1c 581 // first the beryllium section
582 Float_t zpos = -(hlenQbbe2-hlenQbbe1)/2;
cd9c4f3a 583 gMC->Gspos("QBBE", 1, "QBPM", 0., 0., zpos, 0, "ONLY");
584
585 // next meta-metal transition QBT1 on on-absorber side
614dff1c 586// zpos = zpos + hlenQbbe + hlenQbt1;
587// gMC->Gspos("QBT1", 1, "QBPM", 0., 0., zpos, 0, "ONLY");
cd9c4f3a 588
589 // Aluminium OR Al-be alloy section
614dff1c 590 zpos = hlenQbbe1+hlenQbab;
cd9c4f3a 591 gMC->Gspos("QBAB", 1, "QBPM", 0.0, 0.0, zpos, 0, "ONLY");
614dff1c 592 //
cd9c4f3a 593 // inox flange at the start of bellow
cd9c4f3a 594 zpos = zpos + hlenQbab + hlenQb29;
614dff1c 595 gMC->Gspos("QB29", 1, "QBPM", 0.0, 0.0, zpos, idrotm[2012], "ONLY");
596 //
cd9c4f3a 597 // bellow section
cd9c4f3a 598 zpos = zpos + hlenQb29 + hlenQbe0;
614dff1c 599 gMC->Gspos("QBE0", 2 ,"QBPM", 0.0, 0.0, zpos, 0, "ONLY");
600 //
cd9c4f3a 601 // inox flange at the end of bellow and start of thick inox for pump
cd9c4f3a 602 zpos = zpos + hlenQbe0 + hlenQb29;
614dff1c 603 gMC->Gspos("QB29", 2, "QBPM", 0.0, 0.0, zpos, 0, "ONLY");
604 //
cd9c4f3a 605 //last inox section till 800 cm
cd9c4f3a 606 zpos = zpos + hlenQb29 + hlenQb28;
607 gMC->Gspos("QB28", 1, "QBPM", 0.0, 0.0, zpos, 0, "ONLY");
614dff1c 608
cd9c4f3a 609//******** end of placement on no-absorber side *********
610
611 //
612 // **** Absorber side *****
613 //
614 //
614dff1c 615/*
cd9c4f3a 616 // metal-metal transition : Be-Alu on absorber side
617 // Mother Volume
618 ptube[0] = 2.900;
619 ptube[1] = 4.200;
620 ptube[2] = 2.750;
621 gMC->Gsvolu("QBT2","TUBE", idtmed[kAir], ptube, 3);
622 // z = 43.3 - 48.8
623 gMC->Gspos("QBT2", 1, "QBPM", 0., 0., -hlenQbbe-ptube[2], idrotm[2012], "ONLY");
624
625 ptube[0] = 2.900;
626 ptube[1] = 3.150;
627 ptube[2] = 0.375;
628 //
629 // Be-part
630 gMC->Gsvolu("QB02","TUBE", idtmed[kAlu], ptube, 3);
631
632 ptube[1] = 3.000;
633 gMC->Gsvolu("QBA2","TUBE", idtmed[kBe], ptube, 3);
634
635 gMC->Gspos("QBA2", 1, "QB02", 0., 0., 0, 0, "ONLY");
636// z = -2.75 -> -2.00
637 gMC->Gspos("QB02", 1, "QBT2", 0., 0.,-2.75+ptube[2], 0, "ONLY");
638
639 // Alu part
640 ptube[0] = 2.900;
641 ptube[1] = 3.150;
642 ptube[2] = 2.375;
643// z = -2.00 -> 2.75
644 gMC->Gsvolu("QB04","TUBE", idtmed[kAlu], ptube, 3);
645 gMC->Gspos("QB04", 1, "QBT2", 0., 0.,-2.+ptube[2], 0, "ONLY");
646
647
648 ptube[0] = 3.15;
649 ptube[1] = 3.50;
650 ptube[2] = 0.10;
651// z = 2.55 -> 2.75
652 gMC->Gsvolu("QB06","TUBE", idtmed[kAlu], ptube, 3);
653 gMC->Gspos("QB06", 1, "QBT2", 0., 0., 2.55+ptube[2], 0, "ONLY");
654
655
656 // Fixation
657 ptube[0] = 0.0;
658 ptube[1] = 0.1;
659 ptube[2] = 0.5;
660
661 gMC->Gsvolu("QBA8","TUBE", idtmed[kInox], ptube, 3);
662 gMC->Gspos("QBA8", 1 ,"QBT2", 0.000, 3.650, -1.25, idrotm[2002], "ONLY");
663 gMC->Gspos("QBA8", 2 ,"QBT2", 3.161, -1.825, -1.25, idrotm[2001], "ONLY");
664 gMC->Gspos("QBA8", 3 ,"QBT2", -3.161, -1.825, -1.25, idrotm[2003], "ONLY");
665
666 // Carbon ring
667 ptube[0] = 3.15;
668 ptube[1] = 4.10;
669 ptube[2] = 0.55;
670
671 gMC->Gsvolu("QB77","TUBE", idtmed[kC], ptube, 3);
672
673 ptube[0] = 3.15;
674 ptube[1] = 3.50;
675 ptube[2] = 0.10;
676 gMC->Gsvolu("QBB7","TUBE", idtmed[kInox], ptube, 3);
677 gMC->Gspos("QBB7", 1, "QB77", 0.0, 0.0, 0.55-0.2, 0, "ONLY");
678 gMC->Gspos("QB77", 1, "QBT2", 0.0, 0.0, 2., 0, "ONLY");
614dff1c 679 */
680//
681// Beam pipes between elements
682//
cd9c4f3a 683
614dff1c 684 gMC->Gsvolu("QB24","TUBE", idtmed[kInox], ptube, 0);
685 ptube[0] = RinSt;
686 ptube[1] = RoutSt;
687 ptube[2] = hlenQb24[0];
688 dz = hlenQbbe2 + ptube[2];
689 gMC->Gsposp("QB24", 1 ,"QBPM", 0.0, 0.0, -dz, 0, "ONLY", ptube, 3);
690//
691// Bellow on absorber side
692 dz = dz+hlenQb24[0] + dzb;
693 gMC->Gspos("QBE0", 1 ,"QBPM", 0.0, 0.0, -dz, 0, "ONLY");
694//
695 ptube[2] = hlenQb24[1];
696 dz = dz + dzb + ptube[2];
697 gMC->Gsposp("QB24", 2 ,"QBPM", 0.0, 0.0, -dz, 0, "ONLY", ptube, 3);
698 dz = dz + ptube[2];
7bd7faf8 699
7bd7faf8 700//
7bd7faf8 701// Flange
702//
703// Mother Volume
614dff1c 704 ptube[0] = RinSt;
7bd7faf8 705 ptube[1] = 4.300;
614dff1c 706 ptube[2] = 1.4;
7bd7faf8 707
614dff1c 708 gMC->Gsvolu("QFA0","TUBE", idtmed[kInox], ptube, 3);
709 dz = dz + ptube[2];
710 gMC->Gspos("QFA0", 1 ,"QBPM", 0.0, 0.0, -dz, 0, "ONLY");
711 dz = dz + ptube[2];
7bd7faf8 712//
614dff1c 713//
714 ptube[0] = RinSt;
715 ptube[1] = RoutSt;
716 ptube[2] = hlenQb24[2];
717 dz = dz + ptube[2];
718 gMC->Gsposp("QB24", 3 ,"QBPM", 0.0, 0.0, -dz, 0, "ONLY", ptube, 3);
cd9c4f3a 719
720
fe4da5cc 721// --- Place the PIPE ghost volume (QBPM) in its mother volume (ALIC)
cd9c4f3a 722// by rotating it to 180 deg. and make it invisible
fe4da5cc 723//
7bd7faf8 724 gMC->Gspos("QBPM",1,"ALIC",0,0,0,idrotm[2013], "ONLY");
fddcf8f7 725 gMC->Gsbool("QBPM", "L3DX");
726 gMC->Gsbool("QBPM", "L3O3");
727 gMC->Gsbool("QBPM", "L3O4");
7bd7faf8 728
cd9c4f3a 729
7bd7faf8 730//
cd9c4f3a 731// ******** Ion Pump volume description starts here ******
7bd7faf8 732//
7bd7faf8 733 //
734 // Getters ->
735 pbox[0] = 6.50;
736 pbox[1] = 6.75;
737 pbox[2] = 15.60;
738 gMC->Gsvolu("QI32","BOX", idtmed[kInox], pbox, 3);
739
740 pbox[0] = 5.90;
741 pbox[1] = 6.15;
742 pbox[2] = 15.00;
743 gMC->Gsvolu("QI42","BOX", idtmed[kGetter], pbox, 3);
744 gMC->Gspos("QI42", 1, "QI32", 0.0, 0.0, 0.0, 0, "ONLY");
745// <-
746
747 ptube[0] = 0.0;
748 ptube[1] = 19.0;
749 ptube[2] = 2.5;
750 gMC->Gsvolu("QI33","TUBE", idtmed[kInox], ptube, 3);
751
752
753 ptube[0] = 0.0;
754 ptube[1] = 15.0;
755 ptube[2] = 2.5;
14b75006 756 gMC->Gsvolu("QI43","TUBE", idtmed[kAir], ptube, 3);
7bd7faf8 757 gMC->Gspos("QI43", 1, "QI33", 0.0, 0.0, 0.0, 0, "ONLY");
758//
759// Connecting tube ->
760 ptube[0] = 0.0;
761 ptube[1] = 5.4;
cd9c4f3a 762 ptube[2] = 14.6;
7bd7faf8 763 gMC->Gsvolu("QI34","TUBE", idtmed[kInox], ptube, 3);
764
765 ptube[0] = 0.0;
766 ptube[1] = 4.8;
cd9c4f3a 767 ptube[2] = 14.6;
14b75006 768 gMC->Gsvolu("QI44","TUBE", idtmed[kAir], ptube, 3);
7bd7faf8 769 gMC->Gspos("QI44", 1, "QI34", 0.0, 0.0, 0.0, 0, "ONLY");
770// <-
771
772 //
773 // Flange ->
cd9c4f3a 774 ptube[0] = 5.41;
7bd7faf8 775 ptube[1] = 7.30;
776 ptube[2] = 2.15;
777 gMC->Gsvolu("QI35","TUBE", idtmed[kInox], ptube, 3);
7bd7faf8 778// <-
cd9c4f3a 779 gMC->Gspos("QI32", 1, "QBPM", 0.0, -44.25, zPump, 0, "ONLY");
780 gMC->Gspos("QI33", 1, "QBPM", 0.0, -35.00, zPump,idrotm[2002], "ONLY");
781 gMC->Gspos("QI34", 1, "QBPM", 0.0, -17.90, zPump,idrotm[2002], "ONLY");
782 gMC->Gspos("QI35", 1, "QBPM", 0.0, -24.35, zPump,idrotm[2002], "ONLY");
fe4da5cc 783
22811e34 784 gMC->Gsatt("QBPM", "SEEN", 1);
785 gMC->Gsatt("QBEM", "SEEN", 1);
fe4da5cc 786}
787
cd9c4f3a 788
fe4da5cc 789
790//___________________________________________
791void AliPIPEv0::CreateMaterials()
792{
7bd7faf8 793 //
13391c3e 794 // Define materials for beam pipe
7bd7faf8 795 //
13391c3e 796
9e1a0ddb 797 if(fDebug) printf("%s: Create PIPEv0 materials \n",ClassName());
7bd7faf8 798 Int_t isxfld = gAlice->Field()->Integ();
799 Float_t sxmgmx = gAlice->Field()->Max();
2196bc42 800 // Steel (Inox)
7bd7faf8 801 Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
802 Float_t zsteel[4] = { 26.,24.,28.,14. };
803 Float_t wsteel[4] = { .715,.18,.1,.005 };
2196bc42 804 // AlBe - alloy
805 Float_t aAlBe[2] = { 26.98, 9.01};
806 Float_t zAlBe[2] = { 13.00, 4.00};
807 Float_t wAlBe[2] = { 0.4, 0.6};
808
7bd7faf8 809 //
810 // Berillium
811 AliMaterial(5, "BERILLIUM$", 9.01, 4., 1.848, 35.3, 36.7);
812 //
813 // Carbon
814 AliMaterial(6, "CARBON$ ", 12.01, 6., 2.265, 18.8, 49.9);
815 //
816 // Aluminum
817 AliMaterial(9, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
818 //
819 // Air
820 AliMaterial(15, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500.);
821 //
822 // Vacuum
823 AliMaterial(16, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
824 //
825 // stainless Steel
826 AliMixture(19, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
827 //
828 // reduced density steel to approximate pump getter material
829 AliMixture(20, "GETTER$", asteel, zsteel, 1.00, 4, wsteel);
2196bc42 830 // Al-Be alloy
831 //
832 AliMixture(21, "AlBe$", aAlBe, zAlBe, 2.07, 2, wAlBe);
7bd7faf8 833 //
834 // ****************
835 // Defines tracking media parameters.
836 //
837 Float_t epsil = .001; // Tracking precision,
838 Float_t stemax = -0.01; // Maximum displacement for multiple scat
839 Float_t tmaxfd = -20.; // Maximum angle due to field deflection
840 Float_t deemax = -.3; // Maximum fractional energy loss, DLS
841 Float_t stmin = -.8;
842 // ***************
843 //
844 // Beryllium
845
846 AliMedium(5, "BE", 5, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
847
848 // Carbon
849 AliMedium(6, "C", 6, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
850 //
851 // Aluminum
852 AliMedium(9, "ALU", 9, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
853 //
854 // Air
855 AliMedium(15, "AIR", 15, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
856 //
857 // Vacuum
858 AliMedium(16, "VACUUM", 16, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
859 //
860 // Steel
861 AliMedium(19, "INOX", 19, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
862 //
863 // Getter
864 AliMedium(20, "GETTER", 20, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
2196bc42 865 //
866 // AlBe - Aloy
867 AliMedium(21, "AlBe" , 21, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
868
fe4da5cc 869}
870
871
fe4da5cc 872
873
874
875
876
877
878
879