]> git.uio.no Git - u/mrichter/AliRoot.git/blob - STRUCT/AliABSO.cxx
Modified radius of compensator dipole.
[u/mrichter/AliRoot.git] / STRUCT / AliABSO.cxx
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 /* $Id$ */
17
18 ///////////////////////////////////////////////////////////////////////////////
19 //                                                                           //
20 //  Muon ABSOrber                                                            //
21 //  This class contains the description of the muon absorber geometry        //
22 //                                                                           //
23 //Begin_Html
24 /*
25 <img src="picts/AliABSOClass.gif">
26 </pre>
27 <br clear=left>
28 <font size=+2 color=red>
29 <p>The responsible person for this module is
30 <a href="mailto:andreas.morsch@cern.ch">Andreas Morsch</a>.
31 </font>
32 <pre>
33 */
34 //End_Html
35 //                                                                           //
36 //                                                                           //
37 ///////////////////////////////////////////////////////////////////////////////
38
39 #include "AliABSO.h"
40 #include "AliRun.h"
41 #include "AliMagF.h"
42 #include "AliConst.h"
43  
44 ClassImp(AliABSO)
45  
46 //_____________________________________________________________________________
47 AliABSO::AliABSO()
48 {
49   //
50   // Default constructor
51   //
52 }
53  
54 //_____________________________________________________________________________
55 AliABSO::AliABSO(const char *name, const char *title)
56        : AliModule(name,title)
57 {
58   //
59   // Standard constructor
60   //
61   SetMarkerColor(7);
62   SetMarkerStyle(2);
63   SetMarkerSize(0.4);
64 }
65  
66 //_____________________________________________________________________________
67 void AliABSO::CreateGeometry()
68 {
69   //
70   // Creation of the geometry of the muon absorber
71   //
72 }
73
74 //_____________________________________________________________________________
75 void AliABSO::DrawModule()
76 {
77   //
78   // Draw a shaded view of the muon absorber
79   //
80 }
81
82
83 //_____________________________________________________________________________
84 void AliABSO::CreateMaterials()
85 {
86   //
87   // Define materials for muon absorber
88   //
89   Int_t   isxfld = gAlice->Field()->Integ();
90   Float_t sxmgmx = gAlice->Field()->Max();
91   
92   Float_t apoly[2]  = { 12.01,1. };
93   Float_t zpoly[2]  = { 6.,1. };
94   Float_t wpoly[2]  = { .33,.67 };
95   Float_t aconc[10] = { 1.,12.01,15.994,22.99,24.305,26.98,
96                         28.086,39.1,40.08,55.85 };
97   Float_t zconc[10] = { 1.,6.,8.,11.,12.,13.,14.,19.,20.,26. };
98   Float_t wconc[10] = { .01,.001,.529107,.016,.002,.033872,
99                         .337021,.013,.044,.014 };
100   Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
101   Float_t zsteel[4] = { 26.,24.,28.,14. };
102   Float_t wsteel[4] = { .715,.18,.1,.005 };
103 //
104 //
105 // Ni-Cu-W alloy
106   Float_t aniwcu[3] ={58.6934, 183.84, 63.546};
107   Float_t zniwcu[3] ={28., 74., 29};
108   Float_t wniwcu[3] ={0.015,0.95,0.035};
109 // Poly Concrete
110 //                      H     Li     F       C      Al     Si      Ca      Pb     O
111   Float_t aPolyCc[9] = {1. ,  6.941, 18.998, 12.01, 26.98, 28.086, 40.078, 207.2, 15.999};
112   Float_t zPolyCc[9] = {1. ,  3.   ,  9.   ,  6.  , 13.  , 14.   , 20.   ,  82. ,  8.   };
113   Float_t wPolyCc[9] = {4.9,  1.2  ,  1.3  ,  1.1 ,  0.15,  0.02 ,  0.06 ,   0.7,  1.1  };
114   Float_t wtot=0;
115   Int_t   i=0;
116
117   for (i=0; i<9; i++) wtot+=wPolyCc[i];
118   for (i=0; i<9; i++) wPolyCc[i]/=wtot;  
119
120 //
121 // Insulation powder
122 //                    Si         O       Ti     Al
123   Float_t ains[4] ={28.0855, 15.9994, 47.867,  26.982};
124   Float_t zins[4] ={14.,      8.    , 22.   ,  13.   };
125   Float_t wins[4] ={ 0.3019,  0.4887,  0.1914,  0.018};
126 //
127   Float_t epsil, stmin, tmaxfd, deemax, stemax;
128   //
129   //     Carbon 
130   AliMaterial( 6, "CARBON$   ", 12.01, 6., 1.75, 24.4, 49.9);
131   AliMaterial(26, "CARBON$   ", 12.01, 6., 1.75, 24.4, 49.9);
132   AliMaterial(46, "CARBON$   ", 12.01, 6., 1.75, 24.4, 49.9);
133   //
134   //     Aluminum 
135   AliMaterial(9,  "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
136   AliMaterial(29, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
137   AliMaterial(49, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
138   //
139   //     Iron 
140   AliMaterial(10, "IRON$     ", 55.85, 26., 7.87, 1.76, 17.1);
141   AliMaterial(30, "IRON$     ", 55.85, 26., 7.87, 1.76, 17.1);
142   AliMaterial(50, "IRON$     ", 55.85, 26., 7.87, 1.76, 17.1);
143   //
144   //     Copper
145   AliMaterial(11, "COPPER$   ", 63.55, 29., 8.96, 1.43, 15.1);
146   AliMaterial(31, "COPPER$   ", 63.55, 29., 8.96, 1.43, 15.1);
147   AliMaterial(51, "COPPER$   ", 63.55, 29., 8.96, 1.43, 15.1);
148   //
149   //     Tungsten 
150   AliMaterial(12, "TUNGSTEN$ ", 183.85, 74., 19.3, .35, 10.3);
151   AliMaterial(32, "TUNGSTEN$ ", 183.85, 74., 19.3, .35, 10.3);
152   AliMaterial(52, "TUNGSTEN$ ", 183.85, 74., 19.3, .35, 10.3);
153   //
154   //     Ni-W-Cu 
155   AliMixture(21, "Ni-W-Cu$", aniwcu, zniwcu, 18.78, 3, wniwcu);
156   AliMixture(41, "Ni-W-Cu$", aniwcu, zniwcu, 18.78, 3, wniwcu);
157   AliMixture(61, "Ni-W-Cu$", aniwcu, zniwcu, 18.78, 3, wniwcu);
158   //
159   //     Lead 
160   AliMaterial(13, "LEAD$     ", 207.19, 82., 11.35, .56, 18.5);
161   AliMaterial(33, "LEAD$     ", 207.19, 82., 11.35, .56, 18.5);
162   AliMaterial(53, "LEAD$     ", 207.19, 82., 11.35, .56, 18.5);
163   //
164   //     Air 
165   AliMaterial(15, "AIR$      ", 14.61, 7.3, .001205, 30423.24, 67500.);
166   AliMaterial(35, "AIR$      ", 14.61, 7.3, .001205, 30423.24, 67500.);
167   AliMaterial(55, "AIR$      ", 14.61, 7.3, .001205, 30423.24, 67500.);
168   //
169   //     Vacuum 
170   AliMaterial(16, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
171   AliMaterial(36, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
172   AliMaterial(56, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
173   //
174   //     Concrete 
175   AliMixture(17, "CONCRETE$", aconc, zconc, 2.35, 10, wconc);
176   AliMixture(37, "CONCRETE$", aconc, zconc, 2.35, 10, wconc);
177   AliMixture(57, "CONCRETE$", aconc, zconc, 2.35, 10, wconc);
178   //
179   //     Poly CH2 
180   AliMixture(18, "POLYETHYLEN$", apoly, zpoly, .95, -2, wpoly);
181   //
182   // After a call with ratios by number (negative number of elements), 
183   // the ratio array is changed to the ratio by weight, so all successive 
184   // calls with the same array must specify the number of elements as 
185   // positive 
186   //
187   AliMixture(38, "POLYETHYLEN$", apoly, zpoly, .95, 2, wpoly);
188   AliMixture(58, "POLYETHYLEN$", apoly, zpoly, .95, 2, wpoly);
189   //
190   //     stainless Steel 
191   AliMixture(19, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
192   AliMixture(39, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
193   AliMixture(59, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
194   //
195   //     Insulation powder 
196   AliMixture(14, "INSULATION$", ains, zins, 0.41, 4, wins);
197   AliMixture(34, "INSULATION$", ains, zins, 0.41, 4, wins);
198   AliMixture(54, "INSULATION$", ains, zins, 0.41, 4, wins);
199   // Polymere Concrete 
200   AliMixture(20, "Poly Concrete$", aPolyCc, zPolyCc, 3.53, -9, wPolyCc);
201   AliMixture(40, "Poly Concrete$", aPolyCc, zPolyCc, 3.53,  9, wPolyCc);
202   AliMixture(60, "Poly Concrete$", aPolyCc, zPolyCc, 3.53,  9, wPolyCc);
203
204   //
205   // **************** 
206   //     Defines tracking media parameters. 
207   //
208   epsil  = .001;    // Tracking precision, 
209   stemax = -0.01;   // Maximum displacement for multiple scat 
210   tmaxfd = -20.;    // Maximum angle due to field deflection 
211   deemax = -.3;     // Maximum fractional energy loss, DLS 
212   stmin  = -.8;
213   // *************** 
214   //
215   //    Carbon 
216   AliMedium(6,  "C_C0             ",  6, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
217   AliMedium(26, "C_C1             ", 26, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
218   AliMedium(46, "C_C2             ", 46, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
219   //
220   //    Aluminum 
221   AliMedium(9,  "ALU_C0          ",  9, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
222   AliMedium(29, "ALU_C1          ", 29, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
223   AliMedium(49, "ALU_C2          ", 49, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
224   //
225   //    Iron 
226   AliMedium(10, "FE_C0           ", 10, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
227   AliMedium(30, "FE_C1           ", 30, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
228   AliMedium(50, "FE_C2           ", 50, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
229   //
230   //    Copper
231   AliMedium(11, "Cu_C0            ", 11, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
232   AliMedium(31, "Cu_C1            ", 31, 0, isxfld, sxmgmx, tmaxfd, -stemax, deemax, epsil, stmin);
233   AliMedium(51, "Cu_C2            ", 51, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
234   //
235   //    Tungsten 
236   AliMedium(12, "W_C0            ", 12, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
237   AliMedium(32, "W_C1            ", 32, 0, isxfld, sxmgmx, tmaxfd, -stemax, deemax, epsil, stmin);
238   AliMedium(52, "W_C2            ", 52, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
239   //    Ni/Tungsten 
240   AliMedium(21, "Ni/W0           ", 21, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
241   AliMedium(41, "Ni/W1           ", 41, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
242   AliMedium(61, "Ni/W3           ", 61, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
243   //
244   //    Lead 
245   AliMedium(13, "PB_C0           ", 13, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
246   AliMedium(33, "PB_C1           ", 33, 0, isxfld, sxmgmx, tmaxfd, -stemax, deemax, epsil, stmin);
247   AliMedium(53, "PB_C2           ", 53, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
248   //
249   //    Insulation Powder 
250   AliMedium(14, "INS_C0          ", 14, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
251   AliMedium(34, "INS_C1          ", 34, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
252   AliMedium(54, "INS_C2          ", 54, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
253   //
254   //    Air 
255   AliMedium(15, "AIR_C0          ", 15, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
256   AliMedium(35, "AIR_C1          ", 35, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
257   AliMedium(55, "AIR_C2          ", 55, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
258   //
259   //    Vacuum 
260   AliMedium(16, "VA_C0           ", 16, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
261   AliMedium(36, "VA_C1           ", 36, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
262   AliMedium(56, "VA_C2           ", 56, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
263   //
264   //    Concrete 
265   AliMedium(17, "CC_C0           ", 17, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
266   AliMedium(37, "CC_C1           ", 37, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
267   AliMedium(57, "CC_C2           ", 57, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
268   //
269   //    Polyethilene 
270   AliMedium(18, "CH2_C0          ", 18, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
271   AliMedium(38, "CH2_C1          ", 38, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
272   AliMedium(58, "CH2_C2          ", 58, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
273   //
274   //    Steel 
275   AliMedium(19, "ST_C0           ", 19, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
276   AliMedium(39, "ST_C1           ", 39, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
277   AliMedium(59, "ST_C3           ", 59, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
278   //
279   // Polymer Concrete 
280   AliMedium(20, "PCc_C0           ", 20, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
281   AliMedium(40, "PCc_C1           ", 40, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
282   AliMedium(60, "PCc_C3           ", 60, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
283 }
284
285 //_____________________________________________________________________________
286 void AliABSO::Init()
287 {
288   //
289   // Initialisation of the muon absorber after it has been built
290   Int_t i;
291   //
292   printf("\n");
293   for(i=0;i<35;i++) printf("*");
294   printf(" ABSO_INIT ");
295   for(i=0;i<35;i++) printf("*");
296   printf("\n");
297   //
298   for(i=0;i<80;i++) printf("*");
299   printf("\n");
300 }
301  
302 Int_t  AliABSO::GetMatId(Int_t imat) const 
303 {
304 // Get geant material number
305     Int_t kmat=(*fIdmate)[imat]; 
306     return kmat;
307 }