1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 Revision 1.6 1999/09/29 09:24:30 fca
19 Introduction of the Copyright and cvs Log
23 ///////////////////////////////////////////////////////////////////////////////
25 // Magnetic Dipole version 1 //
29 <img src="picts/AliDIPOv2Class.gif">
32 <font size=+2 color=red>
33 <p>The responsible person for this module is
34 <a href="mailto:andreas.morsch@cern.ch">Andreas Morsch</a>.
41 ///////////////////////////////////////////////////////////////////////////////
43 #include "AliDIPOv2.h"
49 //_____________________________________________________________________________
50 AliDIPOv2::AliDIPOv2()
53 // Default constructor for magnetic dipole version 2
57 //_____________________________________________________________________________
58 AliDIPOv2::AliDIPOv2(const char *name, const char *title)
62 // Standard constructor for the magnetic dipole version 2
68 //_____________________________________________________________________________
69 void AliDIPOv2::CreateGeometry()
72 // Creation of the geometry of the magnetic DIPOLE version 2
76 <img src="picts/AliDIPOv2Tree.gif">
81 <img src="picts/AliDIPOv2.gif">
85 Float_t cpar[5], tpar[3], ypar[4];
88 Float_t acc_max, the1, phi1, the2, phi2, the3, phi3;
90 Int_t *idtmed = fIdtmed->GetArray()-1799;
92 //abs_d = 90.; // DEFINES DRIFT LENGTH
95 //theta1 = 24.; // 1. angle defining the front absorber
96 //theta2 = 5.; // 2. angle defining the front absorbe
97 acc_max = 9.; // ANGLE POLAIRE MAXIMUM
98 //acc_min = 2.; // ANGLE POLAIRE MINIMUM DE DETECTION
100 //d_steel = 1.; // THICKNESS OF STEEL SUPPORT
103 //abs_cc = 315.; // DEFINES LENGTH OF CARBON
105 //abs_s = 150.; // DEFINES W-SHIELD LENGTH
106 //abs_n = 80.; // START OF NOSE
121 //zcone_e = 859.0875;
142 gMC->Gsvolu("DDIP", "BOX ", idtmed[1814], tpar, 3);
152 gMC->Gsvolu("DC1 ", "TUBS", idtmed[1813], cpar, 5);
155 gMC->Gsvolu("DC2 ", "TUBS", idtmed[1813], cpar, 5);
156 // ... define regions for higher cuts
162 gMC->Gsvolu("DC3 ", "TUBS", idtmed[1833], cpar, 5);
163 gMC->Gspos("DC3 ", 1, "DC1 ", 0., 0., 0., 0, "ONLY");
166 gMC->Gsvolu("DC4 ", "TUBS", idtmed[1833], cpar, 5);
167 gMC->Gspos("DC4 ", 1, "DC2 ", 0., 0., 0., 0, "ONLY");
170 gMC->Gspos("DC1 ", 1, "DDIP", 0., 0., dz, 0, "ONLY");
171 gMC->Gspos("DC1 ", 2, "DDIP", 0., 0., -dz, 0, "ONLY");
172 gMC->Gspos("DC2 ", 1, "DDIP", 0., 0., dz, 0, "ONLY");
173 gMC->Gspos("DC2 ", 2, "DDIP", 0., 0., -dz, 0, "ONLY");
180 AliMatrix(idrotm[1800], the1, phi1, the2, phi2, the3, phi3);
184 AliMatrix(idrotm[1801], the1, phi1, the2, phi2, the3, phi3);
191 AliMatrix(idrotm[1802], the1, phi1, the2, phi2, the3, phi3);
195 AliMatrix(idrotm[1803], the1, phi1, the2, phi2, the3, phi3);
201 gMC->Gsvolu("DC11", "TUBS", idtmed[1813], cpar, 5);
206 gMC->Gsvolu("DC21", "TUBS", idtmed[1833], cpar, 5);
207 gMC->Gspos("DC21", 1, "DC11", 0., 0., 0., 0, "ONLY");
209 dx = TMath::Sin(30*kDegrad) * -236.5;
210 dy = TMath::Cos(30*kDegrad) * -236.5;
211 dz = cpar[1] + 10. - 250.;
212 gMC->Gspos("DC11", 1, "DDIP", dx, dy, dz, idrotm[1800], "ONLY");
213 gMC->Gspos("DC11", 2, "DDIP", dx, dy, -dz, idrotm[1802], "ONLY");
214 gMC->Gspos("DC11", 3, "DDIP", -dx, dy, dz, idrotm[1801], "ONLY");
215 gMC->Gspos("DC11", 4, "DDIP", -dx, dy, -dz, idrotm[1803], "ONLY");
221 gMC->Gsvolu("DC12", "TUBS", idtmed[1813], cpar, 5);
226 gMC->Gsvolu("DC22", "TUBS", idtmed[1833], cpar, 5);
227 gMC->Gspos("DC22", 1, "DC12", 0., 0., 0., 0, "ONLY");
229 dx = TMath::Sin(30*kDegrad) * -236.5;
230 dy = TMath::Cos(30*kDegrad) * 236.5;
231 dz = cpar[1] + 10. - 250.;
232 gMC->Gspos("DC12", 1, "DDIP", dx, dy, dz, idrotm[1801], "ONLY");
233 gMC->Gspos("DC12", 2, "DDIP", dx, dy, -dz, idrotm[1803], "ONLY");
234 gMC->Gspos("DC12", 3, "DDIP", -dx, dy, dz, idrotm[1800], "ONLY");
235 gMC->Gspos("DC12", 4, "DDIP", -dx, dy, -dz, idrotm[1802], "ONLY");
242 AliMatrix(idrotm[1804], the1, phi1, the2, phi2, the3, phi3);
249 AliMatrix(idrotm[1805], the1, phi1, the2, phi2, the3, phi3);
253 gMC->Gsvolu("DL1 ", "BOX ", idtmed[1813], tpar, 3);
257 gMC->Gsvolu("DL2 ", "BOX ", idtmed[1833], tpar, 3);
258 gMC->Gspos("DL2 ", 1, "DL1 ", 0., 0., 0., 0, "ONLY");
263 gMC->Gspos("DL1 ", 1, "DDIP", dx, dy, dz, idrotm[1804], "ONLY");
264 gMC->Gspos("DL1 ", 2, "DDIP", dx, -dy, dz, idrotm[1805], "ONLY");
265 gMC->Gspos("DL1 ", 3, "DDIP",-dx, dy, dz, idrotm[1805], "ONLY");
266 gMC->Gspos("DL1 ", 4, "DDIP",-dx, -dy, dz, idrotm[1804], "ONLY");
273 ypar[0] = ypar[1] - ypar[3] * 2. * TMath::Tan(acc_max * kDegrad);
274 gMC->Gsvolu("DY1 ", "TRD1", idtmed[1809], ypar, 4);
278 gMC->Gspos("DY1 ", 1, "DDIP", 0., dy, 0., 0, "ONLY");
279 gMC->Gspos("DY1 ", 2, "DDIP", 0., -dy, 0., 0, "ONLY");
281 gMC->Gsvolu("DY2 ", "TRD1", idtmed[1829], ypar, 4);
284 gMC->Gspos("DY2 ", 1, "DDIP", 0., dy, 0., 0, "ONLY");
285 gMC->Gspos("DY2 ", 2, "DDIP", 0., -dy, 0., 0, "ONLY");
292 AliMatrix(idrotm[1806], the1, phi1, the2, phi2, the3, phi3);
296 AliMatrix(idrotm[1807], the1, phi1, the2, phi2, the3, phi3);
300 gMC->Gsvolu("DYL ", "BOX ", idtmed[1814], tpar, 3);
303 gMC->Gsvolu("DY3 ", "BOX ", idtmed[1809], tpar, 3);
306 gMC->Gspos("DY3 ", 1, "DYL ", dx, dy, 0., 0, "ONLY");
307 gMC->Gspos("DY3 ", 2, "DYL ", dx, -dy, 0., 0, "ONLY");
309 gMC->Gsvolu("DY4 ", "BOX ", idtmed[1829], tpar, 3);
310 dx = dx + 5. + tpar[0];
311 gMC->Gspos("DY4 ", 1, "DYL ", dx, dy, 0., 0, "ONLY");
312 gMC->Gspos("DY4 ", 2, "DYL ", dx, -dy, 0., 0, "ONLY");
315 gMC->Gsvolu("DY5 ", "BOX ", idtmed[1829], tpar, 3);
317 gMC->Gspos("DY5 ", 1, "DYL ", dx, 0., 0., 0, "ONLY");
319 gMC->Gsvolu("DY6 ", "BOX ", idtmed[1809], tpar, 3);
320 dx = dx - 37.7 - tpar[0];
321 gMC->Gspos("DY6 ", 1, "DYL ", dx, 0., 0., 0, "ONLY");
324 gMC->Gsvolu("DY7 ", "BOX ", idtmed[1809], tpar, 3);
327 gMC->Gspos("DY7 ", 1, "DYL ", dx, dy, 0., 0, "ONLY");
328 gMC->Gspos("DY7 ", 2, "DYL ", dx, -dy, 0., 0, "ONLY");
330 dx = ypar[0] + ypar[3] * TMath::Tan(acc_max * kDegrad) - 60.;
331 gMC->Gspos("DYL ", 1, "DDIP", dx, 0., 0., idrotm[1806], "ONLY");
332 gMC->Gspos("DYL ", 2, "DDIP",-dx, 0., 0., idrotm[1807], "ONLY");
333 gMC->Gspos("DDIP", 1, "ALIC", 0., 0., 725.+250., 0, "MANY");
334 gMC->Gsatt("DDIP", "SEEN", 0);
335 gMC->Gsatt("DC21", "SEEN", 0);
336 gMC->Gsatt("DC22", "SEEN", 0);
337 gMC->Gsatt("DC3 ", "SEEN", 0);
338 gMC->Gsatt("DC4 ", "SEEN", 0);
341 //_____________________________________________________________________________
342 void AliDIPOv2::DrawModule()
345 // Draw a shaded view of the muon absorber
348 // Set everything unseen
349 gMC->Gsatt("*", "seen", -1);
351 // Set ALIC mother transparent
352 gMC->Gsatt("ALIC","SEEN",0);
354 // Set the volumes visible
355 gMC->Gsatt("DDIP","seen",0);
356 gMC->Gsatt("DC1 ","seen",1);
357 gMC->Gsatt("DC2 ","seen",1);
358 gMC->Gsatt("DC3 ","seen",1);
359 gMC->Gsatt("DC4 ","seen",1);
360 gMC->Gsatt("DC11","seen",1);
361 gMC->Gsatt("DC21","seen",1);
362 gMC->Gsatt("DC12","seen",1);
363 gMC->Gsatt("DC22","seen",1);
364 gMC->Gsatt("DL1 ","seen",1);
365 gMC->Gsatt("DL2 ","seen",1);
366 gMC->Gsatt("DY1 ","seen",1);
367 gMC->Gsatt("DY2 ","seen",1);
368 gMC->Gsatt("DYL ","seen",1);
369 gMC->Gsatt("DY3 ","seen",1);
370 gMC->Gsatt("DY4 ","seen",1);
371 gMC->Gsatt("DY5 ","seen",1);
372 gMC->Gsatt("DY6 ","seen",1);
373 gMC->Gsatt("DY7 ","seen",1);
375 gMC->Gdopt("hide", "on");
376 gMC->Gdopt("shad", "on");
377 gMC->Gsatt("*", "fill", 7);
378 gMC->SetClipBox(".");
379 gMC->SetClipBox(".");
381 gMC->Gdraw("alic", 30, 30, 0, 17, 13.5, .019, .019);
382 gMC->Gdhead(1111, "Magnetic Dipole Version 2");
383 gMC->Gdman(16, 4, "MAN");
386 //_____________________________________________________________________________
387 void AliDIPOv2::CreateMaterials()
390 // Create Materials for Magnetic Dipole version 2
393 Int_t ISXFLD = gAlice->Field()->Integ();
394 Float_t SXMGMX = gAlice->Field()->Max();
396 Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
397 Float_t zsteel[4] = { 26.,24.,28.,14. };
398 Float_t wsteel[4] = { .715,.18,.1,.005 };
399 Float_t acoil[3] = { 26.98,1.01,16. };
400 Float_t zcoil[3] = { 13.,1.,8. };
401 Float_t wcoil[3] = { .66,.226,.114 };
403 Float_t epsil, stmin, deemax, tmaxfd, stemax;
405 // --- Define the various materials for GEANT ---
407 AliMaterial(9, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
408 AliMaterial(29, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
409 AliMaterial(49, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
412 AliMaterial(10, "IRON$ ", 55.85, 26., 7.87, 1.76, 17.1);
413 AliMaterial(30, "IRON$ ", 55.85, 26., 7.87, 1.76, 17.1);
414 AliMaterial(50, "IRON$ ", 55.85, 26., 7.87, 1.76, 17.1);
417 AliMaterial(15, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500);
418 AliMaterial(35, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500);
419 AliMaterial(55, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500);
422 AliMaterial(16, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
423 AliMaterial(36, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
424 AliMaterial(56, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
427 AliMixture(19, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
428 AliMixture(39, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
429 AliMixture(59, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
432 AliMixture(14, "Al$", acoil, zcoil, 2.122, 3, wcoil);
433 AliMixture(34, "Al$", acoil, zcoil, 2.122, 3, wcoil);
434 AliMixture(54, "Al$", acoil, zcoil, 2.122, 3, wcoil);
437 // Defines tracking media parameters.
438 // Les valeurs sont commentees pour laisser le defaut
439 // a GEANT (version 3-21, page CONS200), f.m.
440 epsil = .001; // Tracking precision,
441 stemax = -1.; // Maximum displacement for multiple scat
442 tmaxfd = -20.; // Maximum angle due to field deflection
443 deemax = -.3; // Maximum fractional energy loss, DLS
448 AliMedium(9, "ALU_C0 ", 9, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
449 AliMedium(29, "ALU_C1 ", 29, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
450 AliMedium(49, "ALU_C2 ", 49, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
453 AliMedium(10, "FE_C0 ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
454 AliMedium(30, "FE_C1 ", 30, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
455 AliMedium(50, "FE_C2 ", 50, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
458 AliMedium(15, "AIR_C0 ", 15, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
459 AliMedium(35, "AIR_C1 ", 35, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
460 AliMedium(55, "AIR_C2 ", 55, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
463 AliMedium(16, "VA_C0 ", 16, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
464 AliMedium(36, "VA_C1 ", 36, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
465 AliMedium(56, "VA_C2 ", 56, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
468 AliMedium(19, "ST_C0 ", 19, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
469 AliMedium(39, "ST_C1 ", 39, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
470 AliMedium(59, "ST_C3 ", 59, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
473 AliMedium(14, "Coil_C1 ", 14, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
474 AliMedium(34, "Coil_C2 ", 34, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
475 AliMedium(54, "Coil_C3 ", 54, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);