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