]>
Commit | Line | Data |
---|---|---|
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 | ||
6edc06da | 20 | /////////////////////////////////////////////////////////////////////////////// |
21 | // // | |
22 | // Photon Multiplicity Detector Version 1 // | |
23 | // // | |
24 | //Begin_Html | |
25 | /* | |
1439f98e | 26 | <img src="picts/AliPMDv1Class.gif"> |
6edc06da | 27 | */ |
28 | //End_Html | |
29 | // // | |
30 | /////////////////////////////////////////////////////////////////////////////// | |
31 | ||
32 | #include "AliPMDv1.h" | |
33 | #include "AliRun.h" | |
34 | #include "AliMC.h" | |
35 | #include "AliConst.h" | |
36 | ||
37 | static Int_t maxbox, kdet; | |
38 | static Float_t thmin,thmax,zdist,zdist1,thlow,thhigh; | |
39 | ||
40 | ClassImp(AliPMDv1) | |
41 | ||
42 | //_____________________________________________________________________________ | |
43 | AliPMDv1::AliPMDv1() | |
44 | { | |
45 | // | |
46 | // Default constructor | |
47 | // | |
48 | fMedSens=0; | |
49 | } | |
50 | ||
51 | //_____________________________________________________________________________ | |
52 | AliPMDv1::AliPMDv1(const char *name, const char *title) | |
53 | : AliPMD(name,title) | |
54 | { | |
55 | // | |
56 | // Standard constructor | |
57 | // | |
58 | fMedSens=0; | |
59 | } | |
60 | //_____________________________________________________________________________ | |
61 | void AliPMDv1::CreateGeometry() | |
62 | { | |
63 | // | |
64 | // Create geometry for Photon Multiplicity Detector Version 1 | |
65 | // | |
66 | //Begin_Html | |
67 | /* | |
1439f98e | 68 | <img src="picts/AliPMDv1.gif"> |
6edc06da | 69 | */ |
70 | //End_Html | |
71 | //Begin_Html | |
72 | /* | |
1439f98e | 73 | <img src="picts/AliPMDv1Tree.gif"> |
6edc06da | 74 | */ |
75 | //End_Html | |
76 | CreatePads(); | |
77 | CreateInside(); | |
78 | } | |
79 | ||
80 | //_____________________________________________________________________________ | |
81 | void AliPMDv1::CreateInside() | |
82 | { | |
83 | // | |
84 | // Create inside of Pads | |
85 | // | |
86 | // -- Author : Y.P. VIYOGI, 07/05/1996. | |
87 | // -- Modified: P.V.K.S.Baba(JU), 15-12-97. | |
88 | // Sipmd, the dimension of TUBE mother volume of PMD, other dimensions | |
89 | // like sip01.. are to place more tubes in the volume at different eta bins. | |
90 | Float_t sipmd[3] = { 40.,270.,15.}; | |
91 | Float_t sip01[3] = { 10.,57.89,25.}; | |
92 | Float_t sip02[3] = { 10.,64.03,25.}; | |
93 | Float_t sip03[3] = { 10.,70.80,25.}; | |
94 | Float_t sip04[3] = { 10.,78.32,25.}; | |
95 | Float_t sip05[3] = { 10.,86.68,25.}; | |
96 | Float_t sip06[3] = { 10.,95.91,25.}; | |
97 | Float_t sip07[3] = { 10.,106.14,25.}; | |
98 | Float_t sip08[3] = { 10.,117.48,25.}; | |
99 | Float_t sip09[3] = { 10.,130.18,25.}; | |
100 | Float_t sip10[3] = { 10.,144.18,25.}; | |
101 | Float_t sip11[3] = { 10.,159.87,25.}; | |
102 | Float_t sip12[3] = { 10.,177.43,25.}; | |
103 | Float_t sip13[3] = { 10.,197.11,25.}; | |
104 | Float_t sip14[3] = { 10.,219.28,25.}; | |
105 | Float_t sipmdl[5] = { 10.,310.,25.,90.,270. }; | |
106 | Float_t sipmdr[5] = { 10.,310.,25.,270.,90. }; | |
107 | ||
108 | const Float_t root3_4 = sqrt(3)/4.; | |
109 | const Float_t root3_2 = sqrt(3)/2.; | |
110 | // Float_t xiqa[4], yiqa[4]; | |
111 | Int_t i; | |
112 | // Float_t siqad[4]; | |
113 | Float_t xp, yp, zp; | |
114 | // Int_t idrotm[100]; | |
115 | Int_t num_mod; | |
116 | Int_t jhrotc,jhrotac; | |
117 | Int_t jhrotd; | |
118 | // const Float_t delx=78.8; | |
119 | const Float_t delx=76.75; | |
120 | // const Float_t dely=delx*root3_2; | |
121 | // const Float_t delz=1.6/2.; | |
122 | AliMatrix(jhrotc, 90., 30., 90., 120., 0., 0.); | |
123 | AliMatrix(jhrotac, 90., 330., 90., 240., 0., 0.); | |
124 | AliMatrix(jhrotd, 90., 90., 90., 180., 90., 0.); | |
125 | Float_t x1= delx*root3_4; | |
126 | Float_t x2= delx*root3_4 + delx*root3_2; | |
127 | Float_t x3= delx*root3_4 + 2*delx*root3_2; | |
128 | Float_t xpos[13]={-x1,-x1,-x1,-x1,-x2,-x2,-x2,-x2,-x2,-x3,-x3,-x3,-x3}; | |
129 | Float_t x4=delx/4.; | |
130 | Float_t ypos[13]={(-70.-x4-delx),-(70.+x4),(70.+x4),(70.+x4+delx),-x4+2*delx,-x4+delx,-x4,-x4-delx,-x4-2*delx,-3*x4-delx,-x4-delx/2.,-3*x4+delx,-3*x4+2*delx}; | |
131 | // Float_t ypos[13]={(-70.-x4-delx),-(70.+x4),(70.+x4),(70.+x4+delx),(4*dely),(2*dely),0.,-(2*dely),-(4*dely),-3*x4-delx,-x4-delx/2.,-3*x4+delx,-3*x4+2*delx}; | |
ad51aeb0 | 132 | Int_t *idtmed = fIdtmed->GetArray()-599; |
6edc06da | 133 | |
134 | // VOLUMES Names : begining with D for all PMD volumes, | |
135 | // The names of SIZE variables begin with S and have more meaningful | |
136 | // characters as shown below. | |
137 | ||
138 | // VOLUME SIZE MEDIUM : REMARKS | |
139 | // ------ ----- ------ : --------------------------- | |
140 | ||
141 | // DPMD SIPMD AIR : INSIDE PMD and its SIZE | |
142 | ||
143 | ||
144 | ||
145 | // *** Define the DPMD Volume and fill with air *** | |
146 | ||
cfce8870 | 147 | gMC->Gsvolu("DPMD", "TUBE", idtmed[698], sipmd, 3); |
148 | gMC->Gsvolu("PM01", "TUBE", idtmed[698], sip01, 3); | |
149 | gMC->Gsvolu("PM02", "TUBE", idtmed[698], sip02, 3); | |
150 | gMC->Gsvolu("PM03", "TUBE", idtmed[698], sip03, 3); | |
151 | gMC->Gsvolu("PM04", "TUBE", idtmed[698], sip04, 3); | |
152 | gMC->Gsvolu("PM05", "TUBE", idtmed[698], sip05, 3); | |
153 | gMC->Gsvolu("PM06", "TUBE", idtmed[698], sip06, 3); | |
154 | gMC->Gsvolu("PM07", "TUBE", idtmed[698], sip07, 3); | |
155 | gMC->Gsvolu("PM08", "TUBE", idtmed[698], sip08, 3); | |
156 | gMC->Gsvolu("PM09", "TUBE", idtmed[698], sip09, 3); | |
157 | gMC->Gsvolu("PM10", "TUBE", idtmed[698], sip10, 3); | |
158 | gMC->Gsvolu("PM11", "TUBE", idtmed[698], sip11, 3); | |
159 | gMC->Gsvolu("PM12", "TUBE", idtmed[698], sip12, 3); | |
160 | gMC->Gsvolu("PM13", "TUBE", idtmed[698], sip13, 3); | |
161 | gMC->Gsvolu("PM14", "TUBE", idtmed[698], sip14, 3); | |
162 | gMC->Gsvolu("PMDL", "TUBS", idtmed[698], sipmdl, 5); | |
163 | gMC->Gsvolu("PMDR", "TUBS", idtmed[698], sipmdr, 5); | |
6edc06da | 164 | // |
165 | const Int_t npad2=72; | |
166 | Float_t hexd1[10] = {0.,360.,6,2,-0.4,0.,0.53,0.4,0.,0.53}; | |
167 | Float_t dpara_sm[6] = {12.5,12.5,0.8,30.,0.,0.}; | |
168 | dpara_sm[0]=(npad2+0.25)*hexd1[6] + 1.2; | |
169 | dpara_sm[1] = dpara_sm[0] *root3_2; | |
170 | Float_t dpara_dm11[6] = {12.5,12.5,0.8,30.,0.,0.}; | |
171 | dpara_dm11[0]=dpara_sm[0]+.01; | |
172 | dpara_dm11[1] = dpara_dm11[0] *root3_2; | |
173 | dpara_dm11[2]= 6.2/2.; | |
174 | // | |
175 | for (i = 0; i < 2; ++i) { | |
176 | num_mod=i+1; | |
cfce8870 | 177 | gMC->Gsposp("DM11", num_mod, "DPMD", xpos[i],ypos[i],0., jhrotac, "ONLY", dpara_dm11, 6); |
178 | gMC->Gsposp("DM11", num_mod+13, "DPMD", TMath::Abs(xpos[i]),ypos[i],0., jhrotc, "ONLY", dpara_dm11, 6); | |
6edc06da | 179 | printf("Num_mod %d\n",num_mod); |
180 | } | |
181 | maxbox=13; | |
182 | for (i = 2; i < maxbox; ++i) { | |
183 | num_mod=i+1; | |
cfce8870 | 184 | gMC->Gsposp("DM11", num_mod, "DPMD", xpos[i],ypos[i],0., jhrotc, "ONLY", dpara_dm11, 6); |
185 | gMC->Gsposp("DM11", num_mod+13, "DPMD", TMath::Abs(xpos[i]),ypos[i],0., jhrotac, "ONLY", dpara_dm11, 6); | |
6edc06da | 186 | printf("Num_mod %d\n",num_mod); |
187 | } | |
cfce8870 | 188 | // gMC->Gspos("PM01", 1, "DPMD", 0.,0.,0., 0, "ONLY"); |
189 | // gMC->Gspos("PM02", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
190 | // gMC->Gspos("PM03", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
191 | // gMC->Gspos("PM04", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
192 | // gMC->Gspos("PM05", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
193 | // gMC->Gspos("PM06", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
194 | // gMC->Gspos("PM07", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
195 | // gMC->Gspos("PM08", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
196 | // gMC->Gspos("PM09", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
197 | // gMC->Gspos("PM10", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
198 | // gMC->Gspos("PM11", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
199 | // gMC->Gspos("PM12", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
200 | // gMC->Gspos("PM13", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
201 | // gMC->Gspos("PM14", 1, "DPMD", 0.,0.,0., 0, "ONLY"); | |
6edc06da | 202 | // --- Place the DPMD in ALICE with front edge 5.8m from vertex --- |
203 | xp = 0.; | |
204 | yp = 0.; | |
205 | zp = zdist1; | |
cfce8870 | 206 | // gMC->Gspos("PMDL", 1, "DPMD", xp,yp,0., 0, "ONLY"); |
207 | // gMC->Gspos("PMDR", 1, "DPMD", xp,yp,0., 0, "ONLY"); | |
208 | gMC->Gspos("DPMD", 1, "ALIC", xp,yp,zp, 0, "ONLY"); | |
6edc06da | 209 | |
210 | } | |
211 | ||
212 | //_____________________________________________________________________________ | |
213 | void AliPMDv1::CreatePads() | |
214 | { | |
215 | // | |
216 | // Create the geometry of the pads | |
217 | // *** DEFINITION OF THE GEOMETRY OF THE PMD *** | |
218 | // *** HEXAGONAL PADS WITH 10 MM SQUARE EQUIVALENT | |
219 | // -- Author : S. Chattopadhyay, 02/04/1999. | |
220 | ||
221 | // Basic unit is DP11, a hexagonal cell, which is placed inside another | |
222 | // hexagonal cell (DS11) of larger radius, compared to DP11. The difference in r// adius gives the dimension of half width of each cell wall. | |
223 | // These cells are placed as 72 x 72 array in a | |
224 | // rhombus shaped supermodule (DW11). The rhombus shaped modules are designed | |
225 | // to have closed packed structure. | |
226 | // Each supermodule (SUPR), made of G10 is filled with following components | |
227 | // SMSS --> SS backing, | |
228 | // SMAR --> Gap between gas hexagonal cells and G10 backing. | |
229 | // DW11 --> Ar-Co2 filled gas hexagonal cells. | |
230 | // SMAR | |
231 | // These supermodules are placed inside the main module (DM11), with Fe and | |
232 | // Pb converter positioned between CPV and PMD. | |
233 | // DM11 made of | |
234 | // SUPR (rotated to place steel on the other side), this works as preshower | |
235 | // when PMD is placed in -ve z. | |
236 | // SUPB --> Pb converter | |
237 | // SUFE --> Fe backing | |
238 | // SUPR --> supermodule without rotation (this acts as CPV). | |
239 | // | |
240 | ||
6edc06da | 241 | const Int_t npad2 = 72; |
242 | Float_t hexd1[10] = {0.,360.,6,2,-0.4,0.,0.53,0.4,0.,0.53}; | |
243 | //total wall thickness=0.2*2 | |
244 | Float_t hexd2[10] = {0.,360.,6,2,-0.4,0.,0.51,0.4,0.,0.51}; | |
245 | Int_t i, j; | |
246 | Float_t xb, yb, zb;//, sw[3]; | |
247 | Int_t number; | |
248 | Int_t ihrotm,irotdm; | |
249 | const Float_t root3_cons = sqrt(3) /2.; | |
ad51aeb0 | 250 | Int_t *idtmed = fIdtmed->GetArray()-599; |
6edc06da | 251 | |
252 | AliMatrix(ihrotm, 90., 30., 90., 120., 0., 0.); | |
253 | AliMatrix(irotdm, 90., 180., 90., 270., 180., 0.); | |
254 | zdist1 = fIn[2]; | |
255 | zdist = TMath::Abs(zdist1); | |
256 | // | |
257 | Int_t xrow=1; | |
258 | Float_t dpara[6] = {12.5,12.5,0.4,30.,0.,0.}; | |
259 | dpara[0]=(npad2+0.25)*hexd1[6]; | |
260 | dpara[1] = dpara[0] *root3_cons; | |
261 | // | |
262 | //Subhasis, dimensional parameters of rhombus (dpara) as given to gsvolu | |
263 | // rhombus to accomodate 72 x 72 hexagons, and with total 1.2cm extension | |
264 | //(1mm tolerance on both side and 5mm thick G10 wall) | |
265 | // | |
266 | ||
267 | // **** PAD SIZE 10 MM SQUARE EQUIVALENT | |
268 | // | |
269 | // Inner hex filled with gas | |
cfce8870 | 270 | gMC->Gsvolu("DP11", "PGON", idtmed[604], hexd2,10); |
271 | gMC->Gsatt("DP11", "SEEN", 1); | |
6edc06da | 272 | |
273 | // Outer hex filled with Plastic | |
cfce8870 | 274 | //plastic gMC->Gsvolu("DS11", "PGON", idtmed[616], hexd1,10); |
6edc06da | 275 | // Iron |
cfce8870 | 276 | gMC->Gsvolu("DS11", "PGON", idtmed[601], hexd1,10); |
277 | gMC->Gsatt("DS11", "SEEN", 1); | |
6edc06da | 278 | // --- place inner hex inside outer hex |
cfce8870 | 279 | gMC->Gsposp("DP11", 1, "DS11", 0., 0., 0., 0, "ONLY", hexd2, 10); |
6edc06da | 280 | // Rhombus shaped supermodules (defined by PARA) |
281 | // volume for SUPERMODULE | |
282 | Float_t dpara_sm[6] = {12.5,12.5,0.8,30.,0.,0.}; | |
283 | dpara_sm[0]=(npad2+0.25)*hexd1[6] + 1.2; | |
284 | dpara_sm[1] = dpara_sm[0] *root3_cons; | |
285 | // | |
cfce8870 | 286 | gMC->Gsvolu("SUPR","PARA", idtmed[607], dpara_sm, 6); |
287 | gMC->Gsatt("SUPR", "SEEN", 1); | |
6edc06da | 288 | // SS |
289 | Float_t dpara_ss[6] = {12.5,12.5,8.,30.,0.,0.}; | |
290 | dpara_ss[0]= dpara[0]; | |
291 | dpara_ss[1]= dpara[1]; | |
292 | dpara_ss[2]= 0.3/2.; | |
293 | // | |
cfce8870 | 294 | gMC->Gsvolu("SMSS","PARA", idtmed[601], dpara_ss, 6); |
295 | gMC->Gsatt("SMSS", "SEEN", 1); | |
6edc06da | 296 | // Air |
297 | Float_t dpara_air[6] = {12.5,12.5,8.,30.,0.,0.}; | |
298 | dpara_air[0]= dpara[0] - 0.5; | |
299 | dpara_air[1]= dpara_air[0] * root3_cons; | |
300 | dpara_air[2]= 0.1/2.; | |
cfce8870 | 301 | // gMC->Gsvolu("SMAR","PARA", idtmed[604], dpara_air, 6); |
302 | gMC->Gsvolu("SMAR","PARA", idtmed[698], dpara_air, 6); | |
303 | gMC->Gsatt("SMAR", "SEEN", 1); | |
6edc06da | 304 | // |
305 | // volume for gas chamber (DW11) | |
306 | // | |
cfce8870 | 307 | // gMC->Gsvolu("DW11","PARA", idtmed[604], dpara, 6); |
308 | gMC->Gsvolu("DW11","PARA", idtmed[698], dpara, 6); | |
309 | gMC->Gsatt("DW11", "SEEN", 1); | |
6edc06da | 310 | // Place outer hex inside DW11 |
311 | yb = -dpara[1] + (1./root3_cons)*hexd1[6]; | |
312 | zb = 0.; | |
313 | for (j = 1; j <= npad2; ++j) { | |
314 | xb =-(dpara[0] + dpara[1]*0.577) + 2*hexd1[6]; | |
315 | if(xrow >= 2){ | |
316 | xb = xb+(xrow-1)*hexd1[6]; | |
317 | } | |
318 | for (i = 1; i <= npad2; ++i) { | |
319 | number = i+(j-1)*npad2; | |
cfce8870 | 320 | gMC->Gsposp("DS11", number, "DW11", xb, yb, zb, ihrotm, "ONLY", hexd1, 10); |
6edc06da | 321 | xb += (hexd1[6]*2.); |
322 | } | |
323 | xrow = xrow+1; | |
324 | yb += (hexd1[6]*sqrt(3.)); | |
325 | } | |
326 | Float_t z_ss,z_air1,z_air2,z_gas; | |
327 | // Place other components inside super module | |
328 | z_ss=-dpara_sm[2]+dpara_ss[2]; | |
cfce8870 | 329 | gMC->Gspos("SMSS", 1, "SUPR", 0., 0., z_ss, 0, "ONLY"); |
6edc06da | 330 | z_air1=z_ss+dpara_ss[2] +dpara_air[2]; |
cfce8870 | 331 | gMC->Gspos("SMAR", 1, "SUPR", 0., 0., z_air1, 0, "ONLY"); |
6edc06da | 332 | z_gas=z_air1+dpara_air[2]+dpara[2]+0.1; |
cfce8870 | 333 | gMC->Gspos("DW11", 1, "SUPR", 0., 0., z_gas, 0, "ONLY"); |
6edc06da | 334 | z_air2=z_gas+dpara[2]+0.1+dpara_air[2]; |
cfce8870 | 335 | gMC->Gspos("SMAR", 2, "SUPR", 0., 0., z_air2, 0, "ONLY"); |
6edc06da | 336 | |
337 | // --- DEFINE MODules, iron, and lead voLUMES | |
338 | ||
339 | ||
340 | // volume for SUPERMODULE | |
341 | // Pb | |
342 | Float_t dpara_pb[6] = {12.5,12.5,8.,30.,0.,0.}; | |
343 | dpara_pb[0]=dpara_sm[0]; | |
344 | dpara_pb[1]=dpara_sm[1]; | |
345 | // dpara_pb[2]=1.1/2.; | |
346 | dpara_pb[2]=1.5/2.; | |
cfce8870 | 347 | gMC->Gsvolu("SUPB","PARA", idtmed[600], dpara_pb, 6); |
348 | gMC->Gsatt("SUPB", "SEEN", 1); | |
6edc06da | 349 | // Fe |
350 | Float_t dpara_fe[6] = {12.5,12.5,8.,30.,0.,0.}; | |
351 | dpara_fe[0]=dpara_sm[0]; | |
352 | dpara_fe[1]=dpara_sm[1]; | |
353 | dpara_fe[2]=0.5/2.; | |
cfce8870 | 354 | gMC->Gsvolu("SUFE","PARA", idtmed[601], dpara_fe, 6); |
355 | gMC->Gsatt("SUFE", "SEEN", 1); | |
6edc06da | 356 | // volume for DM11 |
357 | Float_t dpara_dm11[6] = {12.5,12.5,0.8,30.,0.,0.}; | |
358 | dpara_dm11[0]=dpara_sm[0]+.01; | |
359 | dpara_dm11[1] = dpara_dm11[0] *root3_cons; | |
360 | dpara_dm11[2]= 6.2/2.; | |
361 | ||
362 | // | |
cfce8870 | 363 | gMC->Gsvolu("DM11","PARA", idtmed[698], dpara_dm11, 6); |
364 | gMC->Gsatt("DM11", "SEEN", 1); | |
6edc06da | 365 | // position super module inside DM11 |
366 | Float_t z_ps,z_pb,z_fe,z_cv; | |
367 | z_ps=-dpara_dm11[2]+dpara_sm[2]; | |
cfce8870 | 368 | gMC->Gspos("SUPR", 1, "DM11", 0., 0., z_ps, irotdm, "ONLY"); |
6edc06da | 369 | z_pb=z_ps+dpara_sm[2]+dpara_pb[2]; |
cfce8870 | 370 | gMC->Gspos("SUPB", 1, "DM11", 0., 0., z_pb, 0, "ONLY"); |
6edc06da | 371 | z_fe=z_pb+dpara_pb[2]+dpara_fe[2]; |
cfce8870 | 372 | gMC->Gspos("SUFE", 1, "DM11", 0., 0., z_fe, 0, "ONLY"); |
6edc06da | 373 | z_cv=z_fe+dpara_fe[2]+dpara_sm[2]; |
cfce8870 | 374 | gMC->Gspos("SUPR", 2, "DM11", 0., 0., z_cv, 0, "ONLY"); |
6edc06da | 375 | // |
376 | } | |
377 | ||
378 | //_____________________________________________________________________________ | |
379 | void AliPMDv1::DrawModule() | |
380 | { | |
381 | // | |
382 | // Draw a shaded view of the Photon Multiplicity Detector | |
383 | // | |
384 | ||
cfce8870 | 385 | gMC->Gsatt("*", "seen", -1); |
386 | gMC->Gsatt("alic", "seen", 0); | |
6edc06da | 387 | // |
388 | // Set the visibility of the components | |
389 | // | |
cfce8870 | 390 | gMC->Gsatt("DP11","seen",0); |
391 | gMC->Gsatt("DS11","seen",1); | |
392 | gMC->Gsatt("DW11","seen",0); | |
393 | gMC->Gsatt("DM11","seen",1); | |
394 | gMC->Gsatt("DPMD","seen",0); | |
6edc06da | 395 | // |
cfce8870 | 396 | gMC->Gdopt("hide", "on"); |
397 | gMC->Gdopt("shad", "on"); | |
398 | gMC->Gsatt("*", "fill", 7); | |
399 | gMC->SetClipBox("."); | |
400 | gMC->SetClipBox("*", 0, 3000, -3000, 3000, -6000, 6000); | |
401 | gMC->DefaultRange(); | |
402 | gMC->Gdraw("alic", 40, 30, 0, 22, 20.5, .02, .02); | |
403 | gMC->Gdhead(1111, "Photon Multiplicity Detector Version 1"); | |
404 | //gMC->Gdman(17, 5, "MAN"); | |
405 | gMC->Gdopt("hide", "off"); | |
6edc06da | 406 | } |
407 | ||
408 | //_____________________________________________________________________________ | |
409 | void AliPMDv1::CreateMaterials() | |
410 | { | |
411 | // | |
412 | // Create materials for the PMD version 1 | |
413 | // | |
414 | // ORIGIN : Y. P. VIYOGI | |
415 | // | |
416 | ||
6edc06da | 417 | // --- The Argon- CO2 mixture --- |
418 | Float_t ag[2] = { 39.95 }; | |
419 | Float_t zg[2] = { 18. }; | |
420 | Float_t wg[2] = { .8,.2 }; | |
421 | Float_t dar = .001782; // --- Ar density in g/cm3 --- | |
422 | // --- CO2 --- | |
423 | Float_t ac[2] = { 12.,16. }; | |
424 | Float_t zc[2] = { 6.,8. }; | |
425 | Float_t wc[2] = { 1.,2. }; | |
426 | Float_t dc = .001977; | |
427 | Float_t dco = .002; // --- CO2 density in g/cm3 --- | |
428 | ||
429 | Float_t absl, radl, a, d, z; | |
430 | Float_t dg; | |
431 | Float_t x0ar; | |
432 | Float_t buf[1]; | |
433 | Int_t nbuf; | |
434 | Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 }; | |
435 | Float_t zsteel[4] = { 26.,24.,28.,14. }; | |
436 | Float_t wsteel[4] = { .715,.18,.1,.005 }; | |
437 | ||
ad51aeb0 | 438 | Int_t *idtmed = fIdtmed->GetArray()-599; |
6edc06da | 439 | Int_t isxfld = gAlice->Field()->Integ(); |
440 | Float_t sxmgmx = gAlice->Field()->Max(); | |
441 | ||
442 | // --- Define the various materials for GEANT --- | |
443 | AliMaterial(1, "Pb $", 207.19, 82., 11.35, .56, 18.5); | |
444 | x0ar = 19.55 / dar; | |
445 | AliMaterial(2, "Argon$", 39.95, 18., dar, x0ar, 6.5e4); | |
446 | AliMixture(3, "CO2 $", ac, zc, dc, -2, wc); | |
447 | AliMaterial(4, "Al $", 26.98, 13., 2.7, 8.9, 18.5); | |
448 | AliMaterial(6, "Fe $", 55.85, 26., 7.87, 1.76, 18.5); | |
449 | AliMaterial(7, "W $", 183.85, 74., 19.3, .35, 10.3); | |
450 | AliMaterial(8, "G10 $", 20., 10., 1.7, 19.4, 999.); | |
451 | AliMaterial(9, "SILIC$", 28.09, 14., 2.33, 9.36, 45.); | |
452 | AliMaterial(10, "Be $", 9.01, 4., 1.848, 35.3, 36.7); | |
453 | AliMaterial(15, "Cu $", 63.54, 29., 8.96, 1.43, 15.); | |
454 | AliMaterial(16, "C $", 12.01, 6., 2.265, 18.8, 49.9); | |
455 | AliMaterial(17, "POLYCARBONATE $", 20., 10., 1.2, 34.6, 999.); | |
456 | ||
457 | AliMaterial(96, "MYLAR$", 8.73, 4.55, 1.39, 28.7, 62.); | |
458 | AliMaterial(97, "CONCR$", 20., 10., 2.5, 10.7, 40.); | |
459 | AliMaterial(98, "Vacum$", 1e-9, 1e-9, 1e-9, 1e16, 1e16); | |
460 | AliMaterial(99, "Air $", 14.61, 7.3, .0012, 30420., 67500.); | |
461 | AliMixture(19, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel); | |
462 | // define gas-mixtures | |
463 | ||
464 | char namate[21]; | |
cfce8870 | 465 | gMC->Gfmate((*fIdmate)[3], namate, a, z, d, radl, absl, buf, nbuf); |
6edc06da | 466 | ag[1] = a; |
467 | zg[1] = z; | |
468 | dg = (dar * 4 + dco) / 5; | |
469 | AliMixture(5, "ArCO2$", ag, zg, dg, 2, wg); | |
470 | ||
471 | // Define tracking media | |
ad51aeb0 | 472 | AliMedium(1, "Pb conv.$", 1, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1); |
473 | AliMedium(2, " S steel$", 19, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1); | |
474 | AliMedium(7, "W conv.$", 7, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1); | |
475 | AliMedium(8, "G10plate$", 8, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1); | |
476 | AliMedium(4, "Al $", 4, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
477 | AliMedium(6, "Fe $", 6, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
478 | AliMedium(5, "ArCO2 $", 5, 1, 0, isxfld, sxmgmx, .1, .1, .1, .1); | |
479 | AliMedium(9, "SILICON $", 9, 1, 0, isxfld, sxmgmx, .1, .1, .1, .1); | |
480 | AliMedium(10, "Be $", 10, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
481 | AliMedium(98, "Vacuum $", 98, 0, 0, isxfld, sxmgmx, 1., .1, .1, 10); | |
482 | AliMedium(99, "Air gaps$", 99, 0, 0, isxfld, sxmgmx, 1., .1, .1, .1); | |
483 | AliMedium(15, "Cu $", 15, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
484 | AliMedium(16, "C $", 16, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
485 | AliMedium(17, "PLOYCARB$", 17, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1); | |
6edc06da | 486 | |
487 | // --- Generate explicitly delta rays in the iron, aluminium and lead --- | |
cfce8870 | 488 | gMC->Gstpar(idtmed[600], "LOSS", 3.); |
489 | gMC->Gstpar(idtmed[600], "DRAY", 1.); | |
6edc06da | 490 | |
cfce8870 | 491 | gMC->Gstpar(idtmed[603], "LOSS", 3.); |
492 | gMC->Gstpar(idtmed[603], "DRAY", 1.); | |
6edc06da | 493 | |
cfce8870 | 494 | gMC->Gstpar(idtmed[604], "LOSS", 3.); |
495 | gMC->Gstpar(idtmed[604], "DRAY", 1.); | |
6edc06da | 496 | |
cfce8870 | 497 | gMC->Gstpar(idtmed[605], "LOSS", 3.); |
498 | gMC->Gstpar(idtmed[605], "DRAY", 1.); | |
6edc06da | 499 | |
cfce8870 | 500 | gMC->Gstpar(idtmed[606], "LOSS", 3.); |
501 | gMC->Gstpar(idtmed[606], "DRAY", 1.); | |
6edc06da | 502 | |
cfce8870 | 503 | gMC->Gstpar(idtmed[607], "LOSS", 3.); |
504 | gMC->Gstpar(idtmed[607], "DRAY", 1.); | |
6edc06da | 505 | |
506 | // --- Energy cut-offs in the Pb and Al to gain time in tracking --- | |
507 | // --- without affecting the hit patterns --- | |
cfce8870 | 508 | gMC->Gstpar(idtmed[600], "CUTGAM", 1e-4); |
509 | gMC->Gstpar(idtmed[600], "CUTELE", 1e-4); | |
510 | gMC->Gstpar(idtmed[600], "CUTNEU", 1e-4); | |
511 | gMC->Gstpar(idtmed[600], "CUTHAD", 1e-4); | |
512 | gMC->Gstpar(idtmed[605], "CUTGAM", 1e-4); | |
513 | gMC->Gstpar(idtmed[605], "CUTELE", 1e-4); | |
514 | gMC->Gstpar(idtmed[605], "CUTNEU", 1e-4); | |
515 | gMC->Gstpar(idtmed[605], "CUTHAD", 1e-4); | |
516 | gMC->Gstpar(idtmed[606], "CUTGAM", 1e-4); | |
517 | gMC->Gstpar(idtmed[606], "CUTELE", 1e-4); | |
518 | gMC->Gstpar(idtmed[606], "CUTNEU", 1e-4); | |
519 | gMC->Gstpar(idtmed[606], "CUTHAD", 1e-4); | |
520 | gMC->Gstpar(idtmed[603], "CUTGAM", 1e-4); | |
521 | gMC->Gstpar(idtmed[603], "CUTELE", 1e-4); | |
522 | gMC->Gstpar(idtmed[603], "CUTNEU", 1e-4); | |
523 | gMC->Gstpar(idtmed[603], "CUTHAD", 1e-4); | |
524 | gMC->Gstpar(idtmed[609], "CUTGAM", 1e-4); | |
525 | gMC->Gstpar(idtmed[609], "CUTELE", 1e-4); | |
526 | gMC->Gstpar(idtmed[609], "CUTNEU", 1e-4); | |
527 | gMC->Gstpar(idtmed[609], "CUTHAD", 1e-4); | |
6edc06da | 528 | |
529 | // --- Prevent particles stopping in the gas due to energy cut-off --- | |
cfce8870 | 530 | gMC->Gstpar(idtmed[604], "CUTGAM", 1e-5); |
531 | gMC->Gstpar(idtmed[604], "CUTELE", 1e-5); | |
532 | gMC->Gstpar(idtmed[604], "CUTNEU", 1e-5); | |
533 | gMC->Gstpar(idtmed[604], "CUTHAD", 1e-5); | |
534 | gMC->Gstpar(idtmed[604], "CUTMUO", 1e-5); | |
6edc06da | 535 | } |
536 | ||
537 | //_____________________________________________________________________________ | |
538 | void AliPMDv1::Init() | |
539 | { | |
540 | // | |
541 | // Initialises PMD detector after it has been built | |
542 | // | |
543 | Int_t i; | |
544 | kdet=1; | |
545 | // | |
546 | printf("\n"); | |
547 | for(i=0;i<35;i++) printf("*"); | |
548 | printf(" PMD_INIT "); | |
549 | for(i=0;i<35;i++) printf("*"); | |
550 | printf("\n"); | |
551 | printf(" PMD simulation package (v1) initialised\n"); | |
552 | printf(" parameters of pmd\n"); | |
553 | printf("%6d %10.2f %10.2f %10.2f %10.2f %10.2f\n",kdet,thmin,thmax,zdist,thlow,thhigh); | |
554 | // | |
555 | for(i=0;i<80;i++) printf("*"); | |
556 | printf("\n"); | |
557 | // | |
ad51aeb0 | 558 | Int_t *idtmed = fIdtmed->GetArray()-599; |
6edc06da | 559 | fMedSens=idtmed[605-1]; |
560 | } | |
561 | ||
562 | //_____________________________________________________________________________ | |
563 | void AliPMDv1::StepManager() | |
564 | { | |
565 | // | |
566 | // Called at each step in the PMD | |
567 | // | |
568 | Int_t copy; | |
569 | Float_t hits[4], destep; | |
570 | Float_t center[3] = {0,0,0}; | |
571 | Int_t vol[5]; | |
0a6d8768 | 572 | // char *namep; |
6edc06da | 573 | |
cfce8870 | 574 | if(gMC->GetMedium() == fMedSens && (destep = gMC->Edep())) { |
6edc06da | 575 | |
0a6d8768 | 576 | gMC->CurrentVolID(copy); |
577 | // namep=gMC->CurrentVolName(); | |
578 | // printf("Current vol is %s \n",namep); | |
6edc06da | 579 | vol[0]=copy; |
0a6d8768 | 580 | gMC->CurrentVolOffID(1,copy); |
581 | // namep=gMC->CurrentVolOffName(1); | |
582 | // printf("Current vol 11 is %s \n",namep); | |
6edc06da | 583 | vol[1]=copy; |
0a6d8768 | 584 | gMC->CurrentVolOffID(2,copy); |
585 | // namep=gMC->CurrentVolOffName(2); | |
586 | // printf("Current vol 22 is %s \n",namep); | |
6edc06da | 587 | vol[2]=copy; |
588 | // if(strncmp(namep,"DW11",4))vol[2]=1; | |
0a6d8768 | 589 | gMC->CurrentVolOffID(3,copy); |
590 | // namep=gMC->CurrentVolOffName(3); | |
591 | // printf("Current vol 33 is %s \n",namep); | |
6edc06da | 592 | vol[3]=copy; |
0a6d8768 | 593 | gMC->CurrentVolOffID(4,copy); |
594 | // namep=gMC->CurrentVolOffName(4); | |
595 | // printf("Current vol 44 is %s \n",namep); | |
6edc06da | 596 | vol[4]=copy; |
597 | // printf("volume number %d,%d,%d,%d,%d \n",vol[0],vol[1],vol[2],vol[3],vol[4]); | |
cfce8870 | 598 | gMC->Gdtom(center,hits,1); |
6edc06da | 599 | hits[3] = destep*1e9; //Number in eV |
600 | AddHit(gAlice->CurrentTrack(), vol, hits); | |
601 | } | |
602 | } | |
603 | ||
604 |