Introduction of the Copyright and cvs Log
[u/mrichter/AliRoot.git] / STRUCT / AliDIPOv1.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$
18*/
19
fe4da5cc 20///////////////////////////////////////////////////////////////////////////////
21// //
22// Magnetic Dipole version 1 //
23// //
24//Begin_Html
25/*
1439f98e 26<img src="picts/AliDIPOv1Class.gif">
fe4da5cc 27</pre>
28<br clear=left>
29<font size=+2 color=red>
30<p>The responsible person for this module is
31<a href="mailto:andreas.morsch@cern.ch">Andreas Morsch</a>.
32</font>
33<pre>
34*/
35//End_Html
36// //
37// //
38///////////////////////////////////////////////////////////////////////////////
39
40#include "AliDIPOv1.h"
41#include "AliRun.h"
fe4da5cc 42
43ClassImp(AliDIPOv1)
44
45//_____________________________________________________________________________
b8032157 46AliDIPOv1::AliDIPOv1()
fe4da5cc 47{
48 //
49 // Default constructor for the magnetic dipole version 1
50 //
51}
52
53//_____________________________________________________________________________
54AliDIPOv1::AliDIPOv1(const char *name, const char *title)
55 : AliDIPO(name,title)
56{
57 //
58 // Standard constructor for magnetic dipole version 1
59 //
60 SetMarkerColor(7);
61 SetMarkerStyle(2);
62 SetMarkerSize(0.4);
63}
64
65//_____________________________________________________________________________
66void AliDIPOv1::CreateGeometry()
67{
68 //
69 // Creation of the geometry of the magnetic DIPOLE version 1
70 //
71 //Begin_Html
72 /*
1439f98e 73 <img src="picts/AliDIPOv1Tree.gif">
fe4da5cc 74 */
75 //End_Html
76 //Begin_Html
77 /*
1439f98e 78 <img src="picts/AliDIPOv1.gif">
fe4da5cc 79 */
80 //End_Html
81
fe4da5cc 82 Float_t par[5];
83
ad51aeb0 84 Int_t *idtmed = fIdtmed->GetArray()-1799;
fe4da5cc 85
86 //abs_d = 90.; // DEFINES DRIFT LENGTH
87 //z_nose = 102.;
88 //z_cone = 285.;
89 //theta1 = 24.; // 1. angle defining the front absorber
90 //theta2 = 5.; // 2. angle defining the front absorbe
91 //acc_max = 9.; // ANGLE POLAIRE MAXIMUM
92 //acc_min = 2.; // ANGLE POLAIRE MINIMUM DE DETECTION
93 //abs_l = 503.;
94 //d_steel = 1.; // THICKNESS OF STEEL SUPPORT
95 //d_poly = 7.5;
96 //d_pb = 2.5;
97 //abs_cc = 315.; // DEFINES LENGTH OF CARBON
98 //abs_c = 358.;
99 //abs_s = 150.; // DEFINES W-SHIELD LENGTH
100 //abs_n = 80.; // START OF NOSE
101 //r_abs = 4.;
102 //r_pb = .1;
103 //epsilon = .01;
104 //theta_r = 3.;
105 //d_rear = 35.;
106 //theta_open = .75;
107
108 //z_l3 = 700.;
109 //zmag_in = 725.;
110 //zmag_out = 1225.;
111 //zfil_in = 1471.;
112 //zfil_out = 1591.;
113 //zcon_in = 1900.;
114 //zcon_out = 2e3;
115 //zcone_e = 859.0875;
116 //spec_l = 1800.;
117 //zplug_in = 1780.;
118 //zplug_out = 1900.;
119
120 // Chamber position
121 // CZ1=515.5
122 //cz1 = 511.;
123 //cz2 = 686.;
124 //cz3 = 971.;
125 //cz4 = 1245.;
126 //cz5 = 1445.;
127 //cz6 = 1610.;
128 //cz7 = 1710.;
129
130
131 // DIPOLE MAGNET
132 par[0] = 0.;
133 par[1] = 280.;
134 par[2] = 250.;
cfce8870 135 gMC->Gsvolu("DDIP", "TUBE", idtmed[1801], par, 3);
fe4da5cc 136
137 // COIL
138 par[0] = 250.;
139 par[1] = 125.;
140 par[2] = 165.;
141 par[3] = 204.;
142 par[4] = 244.;
143
cfce8870 144 gMC->Gsvolu("DIPC", "CONE", idtmed[1810], par, 5);
145 gMC->Gspos("DIPC", 1, "DDIP", 0., 0., 0., 0, "ONLY");
fe4da5cc 146 par[0] = 250.;
147 par[1] = 115.;
148 par[2] = 125.;
149 par[3] = 194.;
150 par[4] = 204.;
cfce8870 151 gMC->Gsvolu("DIIC", "CONE", idtmed[1807], par, 5);
152 gMC->Gspos("DIIC", 1, "DDIP", 0., 0., 0., 0, "ONLY");
fe4da5cc 153
154 // YOKE
155 par[0] = 250.;
156 par[1] = 165.;
157 par[2] = 195.;
158 par[3] = 244.;
159 par[4] = 274.;
160
cfce8870 161 gMC->Gsvolu("DIPY", "CONE", idtmed[1834], par, 5);
162 gMC->Gspos("DIPY", 1, "DDIP", 0., 0., 0., 0, "ONLY");
163 gMC->Gspos("DDIP", 1, "ALIC", 0., 0., 725.+250, 0, "ONLY");
fe4da5cc 164}
165
166//_____________________________________________________________________________
b8032157 167void AliDIPOv1::DrawModule()
fe4da5cc 168{
169 //
170 // Draw a shaded view of the muon absorber
171 //
172
fe4da5cc 173 // Set everything unseen
cfce8870 174 gMC->Gsatt("*", "seen", -1);
fe4da5cc 175 //
176 // Set ALIC mother transparent
cfce8870 177 gMC->Gsatt("ALIC","SEEN",0);
fe4da5cc 178 //
179 // Set the volumes visible
cfce8870 180 gMC->Gsatt("DDIP","seen",1);
181 gMC->Gsatt("DIPC","seen",1);
182 gMC->Gsatt("DIIC","seen",1);
183 gMC->Gsatt("DIPY","seen",1);
fe4da5cc 184 //
cfce8870 185 gMC->Gdopt("hide", "on");
186 gMC->Gdopt("shad", "on");
187 gMC->Gsatt("*", "fill", 7);
188 gMC->SetClipBox(".");
189 gMC->SetClipBox(".");
190 gMC->DefaultRange();
191 gMC->Gdraw("alic", 30, 30, 0, 17, 13.5, .019, .019);
192 gMC->Gdhead(1111, "Magnetic Dipole Version 1");
193 gMC->Gdman(16, 4, "MAN");
fe4da5cc 194}
195
196//_____________________________________________________________________________
197void AliDIPOv1::CreateMaterials()
198{
199 //
200 // Create Materials for Dipole Magnet version 1
201 //
202
203 Int_t ISXFLD = gAlice->Field()->Integ();
204 Float_t SXMGMX = gAlice->Field()->Max();
205
206 Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
207 Float_t zsteel[4] = { 26.,24.,28.,14. };
208 Float_t wsteel[4] = { .715,.18,.1,.005 };
209 Float_t epsil, stmin, deemax, tmaxfd, stemax;
210
211 // STEEL
212
213
214 // --- Define the various materials for GEANT ---
ad51aeb0 215 AliMaterial(9, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
216 AliMaterial(15, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500);
217 AliMaterial(10, "IRON$ ", 55.85, 26., 7.87, 0, 17.1);
218 AliMaterial(16, "VACUUM$ ", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
219 AliMixture(24, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
fe4da5cc 220
221 // ****************
222 // Defines tracking media parameters.
223 // Les valeurs sont commentees pour laisser le defaut
224 // a GEANT (version 3-21, page CONS200), f.m.
225 epsil = .001; // Tracking precision,
226 stemax = -1.; // Maximum displacement for multiple scat
227 tmaxfd = -20.; // Maximum angle due to field deflection
228 deemax = -.3; // Maximum fractional energy loss, DLS
229 stmin = -.8;
230 // ***************
231
232 // Air
233
ad51aeb0 234 AliMedium(1, "AIR_DI_US ", 15, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
235 AliMedium(2, "AIR_DI_US ", 15, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
236 AliMedium(3, "AIR_L3_US ", 15, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
fe4da5cc 237
238 // Aluminum
239
ad51aeb0 240 AliMedium(8, "ALU_DI_US ", 9, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
241 AliMedium(11, "ALU_DI_SH ", 9, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
fe4da5cc 242
243 // Iron
244
ad51aeb0 245 AliMedium(31, "FE_NF_US ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
246 AliMedium(32, "FE_DI_US ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
247 AliMedium(33, "FE_L3_US ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
248 AliMedium(34, "FE_NF_SH ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
249 AliMedium(35, "FE_DI_SH ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
250 AliMedium(36, "FE_L3_SH ", 10, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
fe4da5cc 251
252 // Vacuum
253
ad51aeb0 254 AliMedium(37, "VA_NF_US ", 16, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
255 AliMedium(38, "VA_DI_US ", 16, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
256 AliMedium(39, "VA_L3_US ", 16, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
fe4da5cc 257
258 // Steel
259
ad51aeb0 260 AliMedium(75, "ST_L3_US ", 24, 0, ISXFLD, SXMGMX, tmaxfd, stemax, deemax, epsil, stmin);
fe4da5cc 261}
262