]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PMD/AliPMDv2008.cxx
geometry for 2008 run
[u/mrichter/AliRoot.git] / PMD / AliPMDv2008.cxx
CommitLineData
8417fa6a 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/* $Id: AliPMDv1.cxx 18594 2007-05-15 13:28:06Z hristov $ */
16
17//
18///////////////////////////////////////////////////////////////////////////////
19// //
20// Photon Multiplicity Detector Version 1 //
21// Bedanga Mohanty : February 14th 2006
22// //
23//Begin_Html
24/*
25<img src="picts/AliPMDv1Class.gif">
26*/
27//End_Html
28// //
29///////////////////////////////////////////////////////////////////////////////
30////
31
32#include "Riostream.h"
33#include <TVirtualMC.h>
34
35#include "AliConst.h"
36#include "AliLog.h"
37#include "AliMC.h"
38#include "AliMagF.h"
39#include "AliPMDv2008.h"
40#include "AliRun.h"
41
42const Int_t AliPMDv2008::fgkNcolUM1 = 48; // Number of cols in UM, type 1
43const Int_t AliPMDv2008::fgkNcolUM2 = 96; // Number of cols in UM, type 2
44const Int_t AliPMDv2008::fgkNrowUM1 = 96; // Number of rows in UM, type 1
45const Int_t AliPMDv2008::fgkNrowUM2 = 48; // Number of rows in UM, type 2
46const Float_t AliPMDv2008::fgkCellRadius = 0.25; // Radius of a hexagonal cell
47const Float_t AliPMDv2008::fgkCellWall = 0.02; // Thickness of cell Wall
48const Float_t AliPMDv2008::fgkCellDepth = 0.50; // Gas thickness
49const Float_t AliPMDv2008::fgkThBase = 0.2; // Thickness of Base plate
50const Float_t AliPMDv2008::fgkThBKP = 0.1; // Thickness of Back plane
51const Float_t AliPMDv2008::fgkThAir = 1.03; // Thickness of Air
52const Float_t AliPMDv2008::fgkThPCB = 0.16; // Thickness of PCB
53const Float_t AliPMDv2008::fgkThLead = 1.5; // Thickness of Pb
54const Float_t AliPMDv2008::fgkThSteel = 0.5; // Thickness of Steel
55const Float_t AliPMDv2008::fgkGap = 0.025; // Air Gap
56const Float_t AliPMDv2008::fgkZdist = 361.5; // z-position of the detector
57const Float_t AliPMDv2008::fgkSqroot3 = 1.7320508;// Square Root of 3
58const Float_t AliPMDv2008::fgkSqroot3by2 = 0.8660254;// Square Root of 3 by 2
59const Float_t AliPMDv2008::fgkSSBoundary = 0.3;
60const Float_t AliPMDv2008::fgkThSS = 1.03;
61const Float_t AliPMDv2008::fgkThG10 = 1.03;
62ClassImp(AliPMDv2008)
63
64//_____________________________________________________________________________
65AliPMDv2008::AliPMDv2008():
66 fSMthick(0.),
67 fDthick(0.),
68 fSMLengthax(0.),
69 fSMLengthay(0.),
70 fSMLengthbx(0.),
71 fSMLengthby(0.),
72 fMedSens(0)
73{
74 //
75 // Default constructor
76 //
77 for (Int_t i = 0; i < 3; i++)
78 {
79 fDboxmm1[i] = 0.;
80 fDboxmm12[i] = 0.;
81 fDboxmm2[i] = 0.;
82 fDboxmm22[i] = 0.;
83 }
84}
85
86//_____________________________________________________________________________
87AliPMDv2008::AliPMDv2008(const char *name, const char *title):
88 AliPMD(name,title),
89 fSMthick(0.),
90 fDthick(0.),
91 fSMLengthax(0.),
92 fSMLengthay(0.),
93 fSMLengthbx(0.),
94 fSMLengthby(0.),
95 fMedSens(0)
96{
97 //
98 // Standard constructor
99 //
100 for (Int_t i = 0; i < 3; i++)
101 {
102 fDboxmm1[i] = 0.;
103 fDboxmm12[i] = 0.;
104 fDboxmm2[i] = 0.;
105 fDboxmm22[i] = 0.;
106 }
107}
108
109//_____________________________________________________________________________
110void AliPMDv2008::CreateGeometry()
111{
112 // Create geometry for Photon Multiplicity Detector
113
114 GetParameters();
115 CreateSupermodule();
116 CreatePMD();
117}
118
119//_____________________________________________________________________________
120void AliPMDv2008::CreateSupermodule()
121{
122 //
123 // Creates the geometry of the cells of PMD, places them in supermodule
124 // which is a rectangular object.
125 // Basic unit is ECAR, a hexagonal cell made of Ar+CO2, which is
126 // placed inside another hexagonal cell made of Cu (ECCU) with larger
127 // radius, compared to ECAR. The difference in radius gives the dimension
128 // of half width of each cell wall.
129 // These cells are placed in a rectangular strip which are of 2 types
130 // EST1 and EST2
131 // 2 types of unit modules are made EUM1 and EUM2 which contains these strips
132 // placed repeatedly
133 // Each supermodule (ESMA, ESMB), made of G10 is filled with following
134 //components. They have 6 unit moudles inside them
135 // ESMA, ESMB are placed in EPMD along with EMPB (Pb converter)
136 // and EMFE (iron support)
137
138
139 Int_t i,j;
140 Int_t number;
141 Int_t ihrotm,irotdm;
142 Float_t xb, yb, zb;
143
144 Int_t *idtmed = fIdtmed->GetArray()-599;
145
146 AliMatrix(ihrotm, 90., 30., 90., 120., 0., 0.);
147 AliMatrix(irotdm, 90., 180., 90., 270., 180., 0.);
148
149 // STEP - I
150 //******************************************************//
151 // First create the sensitive medium of a hexagon cell (ECAR)
152 // Inner hexagon filled with gas (Ar+CO2)
153
154 Float_t hexd2[10] = {0.,360.,6,2,-0.25,0.,0.23,0.25,0.,0.23};
155 hexd2[4] = -fgkCellDepth/2.;
156 hexd2[7] = fgkCellDepth/2.;
157 hexd2[6] = fgkCellRadius - fgkCellWall;
158 hexd2[9] = fgkCellRadius - fgkCellWall;
159
160 gMC->Gsvolu("ECAR", "PGON", idtmed[604], hexd2,10);
161 //******************************************************//
162
163 // STEP - II
164 //******************************************************//
165 // Place the sensitive medium inside a hexagon copper cell (ECCU)
166 // Outer hexagon made of Copper
167
168 Float_t hexd1[10] = {0.,360.,6,2,-0.25,0.,0.25,0.25,0.,0.25};
169 hexd1[4] = -fgkCellDepth/2.;
170 hexd1[7] = fgkCellDepth/2.;
171 hexd1[6] = fgkCellRadius;
172 hexd1[9] = fgkCellRadius;
173
174 gMC->Gsvolu("ECCU", "PGON", idtmed[614], hexd1,10);
175
176 // Place inner hex (sensitive volume) inside outer hex (copper)
177
178 gMC->Gspos("ECAR", 1, "ECCU", 0., 0., 0., 0, "ONLY");
179 //******************************************************//
180
181 // STEP - III
182 //******************************************************//
183 // Now create Rectangular TWO strips (EST1, EST2)
184 // of 1 column and 48 or 96 cells length
185
186 // volume for first strip EST1 made of AIR
187
188 Float_t dbox1[3];
189 dbox1[0] = fgkCellRadius/fgkSqroot3by2;
190 dbox1[1] = fgkNrowUM1*fgkCellRadius;
191 dbox1[2] = fgkCellDepth/2.;
192
193 gMC->Gsvolu("EST1","BOX", idtmed[698], dbox1, 3);
194
195 // volume for second strip EST2
196
197
198 Float_t dbox2[3];
199 dbox2[1] = fgkNrowUM2*fgkCellRadius;
200 dbox2[0] = dbox1[0];
201 dbox2[2] = dbox1[2];
202
203 gMC->Gsvolu("EST2","BOX", idtmed[698], dbox2, 3);
204
205 // Place hexagonal cells ECCU placed inside EST1
206 xb = 0.;
207 zb = 0.;
208 yb = (dbox1[1]) - fgkCellRadius;
209 for (i = 1; i <= fgkNrowUM1; ++i)
210 {
211 number = i;
212 gMC->Gspos("ECCU", number, "EST1", xb,yb,zb, 0, "ONLY");
213 yb -= (fgkCellRadius*2.);
214 }
215
216 // Place hexagonal cells ECCU placed inside EST2
217 xb = 0.;
218 zb = 0.;
219 yb = (dbox2[1]) - fgkCellRadius;
220 for (i = 1; i <= fgkNrowUM2; ++i)
221 {
222 number = i;
223 gMC->Gspos("ECCU", number, "EST2", xb,yb,zb, 0, "ONLY");
224 //PH cout << "ECCU in EST2 ==> " << number << "\t"<<xb << "\t"<<yb <<endl;
225 yb -= (fgkCellRadius*2.);
226 }
227
228
229 //******************************************************//
230
231
232 // STEP - IV
233 //******************************************************//
234 // 2 types of rectangular shaped unit modules EUM1 and EUM2 (defined by BOX)
235 //---------------------------------EHC1 Start----------------------//
236 // Create EHC1 : The honey combs for a unit module type 1
237 // First step is to create a honey comb unit module.
238 // This is named as EHC1, we will lay the EST1 strips of
239 // honey comb cells inside it.
240
241 //Dimensions of EHC1
242 //X-dimension = Number of columns + cell radius
243 //Y-dimension = Number of rows * cell radius/sqrt3by2 - (some factor)
244 //Z-dimension = cell depth/2
245
246 Float_t dbox3[3];
247 dbox3[0] = (dbox1[0]*fgkNcolUM1)-(fgkCellRadius*fgkSqroot3*(fgkNcolUM1-1)/6.);
248 dbox3[1] = dbox1[1]+fgkCellRadius/2.;
249 dbox3[2] = fgkCellDepth/2.;
250
251 //Create a BOX, Material AIR
252 gMC->Gsvolu("EHC1","BOX", idtmed[698], dbox3, 3);
253 // Place rectangular strips EST1 inside EHC1 unit module
254 xb = dbox3[0]-dbox1[0];
255
256 for (j = 1; j <= fgkNcolUM1; ++j)
257 {
258 if(j%2 == 0)
259 {
260 yb = -fgkCellRadius/2.0;
261 }
262 else
263 {
264 yb = fgkCellRadius/2.0;
265 }
266 number = j;
267 gMC->Gspos("EST1",number, "EHC1", xb, yb , 0. , 0, "MANY");
268 //The strips are being placed from top towards bottom of the module
269 //This is because the first cell in a module in hardware is the top
270 //left corner cell
271 xb = (dbox3[0]-dbox1[0])-j*fgkCellRadius*fgkSqroot3;
272
273 }
274 //--------------------EHC1 done----------------------------------//
275
276
277 //---------------------------------EHC2 Start----------------------//
278 // Create EHC2 : The honey combs for a unit module type 2
279 // First step is to create a honey comb unit module.
280 // This is named as EHC2, we will lay the EST2 strips of
281 // honey comb cells inside it.
282
283 //Dimensions of EHC2
284 //X-dimension = Number of columns + cell radius
285 //Y-dimension = Number of rows * cell radius/sqrt3by2 - (some factor)
286 //Z-dimension = cell depth/2
287
288 dbox3[0] = (dbox1[0]*fgkNcolUM1)-(fgkCellRadius*fgkSqroot3*(fgkNcolUM1-1)/6.);
289 dbox3[1] = dbox1[1]+fgkCellRadius/2.;
290 dbox3[2] = fgkCellDepth/2.;
291
292 Float_t dbox4[3];
293
294 dbox4[0] =(dbox2[0]*fgkNcolUM2)-(fgkCellRadius*fgkSqroot3*(fgkNcolUM2-1)/6.);
295 dbox4[1] = dbox2[1] + fgkCellRadius/2.;
296 dbox4[2] = dbox3[2];
297
298 //Create a BOX of AIR
299 gMC->Gsvolu("EHC2","BOX", idtmed[698], dbox4, 3);
300
301 // Place rectangular strips EST2 inside EHC2 unit module
302 xb = dbox4[0]-dbox2[0];
303 for (j = 1; j <= fgkNcolUM2; ++j)
304 {
305 if(j%2 == 0)
306 {
307 yb = -fgkCellRadius/2.0;
308 }
309 else
310 {
311 yb = +fgkCellRadius/2.0;
312 }
313 number = j;
314 gMC->Gspos("EST2",number, "EHC2", xb, yb , 0. ,0, "MANY");
315 xb = (dbox4[0]-dbox2[0])-j*fgkCellRadius*fgkSqroot3;
316 }
317
318
319 //--------------------EHC2 done----------------------------------//
320
321
322 // Now the job is to assmeble an Unit module
323 // It will have the following components
324 // (a) Base plate of G10 of 0.2 cm
325 // (b) Air gap of 0.05 cm
326 // (c) Bottom PCB of 0.16 cm G10
327 // (d) Honey comb 0f 0.5 cm
328 // (e) Top PCB of 0.16 cm G10
329 // (f) Air gap of 0.16 cm
330 // (g) Back Plane of 0.1 cm G10
331 // (h) Then all around then we have an air gap of 0.5mm
332 // (i) Then all around 0.5mm thick G10 insulation
333 // (h) Then all around Stainless Steel boundary channel 0.3 cm thick
334 //Let us first create them one by one
335 //---------------------------------------------------//
336
337 // ---------------- Lets do it first for UM Type A -----//
338
339 //--------------------------------------------------//
340 //Bottom and Top PCB : EPCA
341 //===========================
342 // Make a 1.6mm thick G10 Bottom and Top PCB for Unit module A
343 // X-dimension same as EHC1 - dbox3[0]
344 // Y-dimension same as EHC1 - dbox3[1]
345 // Z-dimension 0.16/2 = 0.08 cm
346 //-------------------------------------------------//
347 Float_t dboxPcbA[3];
348 dboxPcbA[0] = dbox3[0];
349 dboxPcbA[1] = dbox3[1];
350 dboxPcbA[2] = fgkThPCB/2.;
351
352 //Top and Bottom PCB is a BOX of Material G10
353 gMC->Gsvolu("EPCA","BOX", idtmed[607], dboxPcbA, 3);
354 //--------------------------------------------------------//
355 //Back Plane : EBKA
356 //==================
357 // Make a 1.0mm thick Back Plane PCB for Unit module A
358 // X-dimension same as EHC1 - dbox3[0]
359 // Y-dimension same as EHC1 - dbox3[1]
360 // Z-dimension 0.1/2 = 0.05 cm
361 //------------------------------------------------------//
362 Float_t dboxBPlaneA[3];
363 dboxBPlaneA[0] = dbox3[0];
364 dboxBPlaneA[1] = dbox3[1];
365 dboxBPlaneA[2] = fgkThBKP/2.;
366
367 //Back PLane PCB of MAterial G10
368 gMC->Gsvolu("EBKA","BOX", idtmed[607], dboxBPlaneA, 3);
369 //-------------------------------------------------------------//
370
371 //---------- That was all in the Z -direction of Unit Module A----//
372
373 // Now lets us construct the boundary arround the Unit Module --//
374 // This boundary has
375 // (a) 0.5 mm X and Y and 10.3 mm Z dimension AIR gap
376 // (b) 0.5 mm X and Y and 10.3 mm Z dimension G10
377 // (c) 3.0 mm X and Y and 12.3 mm Z dimension Stainless Steel
378
379
380
381 //-------------------------------------------------//
382 //AIR GAP between UM and Boundary : ECGA FOR PRESHOWER PLANE
383 //==========================================================
384 // Make a 10.3mm thick Air gap for Unit module A
385 // X-dimension same as EHC1+0.05
386 // Y-dimension same as EHC1+0.05
387 // Z-dimension 1.03/2 = 0.515 cm
388 Float_t dboxAir3A[3];
389 dboxAir3A[0] = dbox3[0]+(2.0*fgkGap);
390 dboxAir3A[1] = dbox3[1]+(2.0*fgkGap);
391 dboxAir3A[2] = fgkThAir/2.;
392
393 //FOR PRESHOWER
394 //Air gap is a BOX of Material Air
395 gMC->Gsvolu("ECGA","BOX", idtmed[698], dboxAir3A, 3);
396
397 //FOR VETO
398 //Air gap is a BOX of Material Air
399 gMC->Gsvolu("ECVA","BOX", idtmed[698], dboxAir3A, 3);
400 //-------------------------------------------------//
401
402 //-------------------------------------------------//
403 //G10 boundary between honeycomb and SS : EDGA
404 //================================================
405 // Make a 10.3mm thick G10 Boundary for Unit module A
406 // X-dimension same as EHC1+Airgap+0.05
407 // Y-dimension same as EHC1+Airgap+0.05
408 // Z-dimension 1.03/2 = 0.515 cm
409 Float_t dboxGGA[3];
410 dboxGGA[0] = dboxAir3A[0]+(2.0*fgkGap);
411 dboxGGA[1] = dboxAir3A[1]+(2.0*fgkGap);
412 dboxGGA[2] = fgkThG10/2.;
413
414 //FOR PRESHOWER
415 //G10 BOX
416 gMC->Gsvolu("EDGA","BOX", idtmed[607], dboxGGA, 3);
417
418 //FOR VETO
419 //G10 BOX
420 gMC->Gsvolu("EDVA","BOX", idtmed[607], dboxGGA, 3);
421
422 //-------------------------------------------------//
423 //----------------------------------------------------------//
424 //Stainless Steel Bounadry : ESSA
425 //==================================
426 // Make a 10.3mm thick Stainless Steel boundary for Unit module A
427 // X-dimension same as EHC1 + Airgap + G10 + 0.3
428 // Y-dimension same as EHC1 + Airgap + G10 + 0.3
429 // Z-dimension 1.03/2 = 0.515 cm
430 //------------------------------------------------------//
431 // A Stainless Steel Boundary Channel to house the unit module
432
433 Float_t dboxSS1[3];
434 dboxSS1[0] = dboxGGA[0]+fgkSSBoundary;
435 dboxSS1[1] = dboxGGA[1]+fgkSSBoundary;
436 dboxSS1[2] = fgkThSS/2.;
437
438 //FOR PRESHOWER
439
440 //Stainless Steel boundary - Material Stainless Steel
441 gMC->Gsvolu("ESSA","BOX", idtmed[618], dboxSS1, 3);
442
443 //FOR VETO
444 //Stainless Steel boundary - Material Stainless Steel
445 gMC->Gsvolu("ESVA","BOX", idtmed[618], dboxSS1, 3);
446
447 //----------------------------------------------------------------//
448
449 //----------------------------------------------------------------//
450 // Here we need to place the volume in order ESSA -> EDGA -> ECGA
451 // this makes the SS boundary and the 0.5mm thick FR4 insulation in place,
452 // and the air volume ECGA acts as mother for the rest of components.
453 // The above placeemnt is done at (0.,0.,0.) relative coordiante
454 // Now we place bottom PCB, honeycomb, top PCB in this volume. We donot place
455 // unnecessary air volumes now. Just leave the gap as we are placing them
456 // in air only. This also reduces the number of volumes for geant to track.
457
458// Tree structure for different volumes
459//
460// EUM1
461// |
462// --------------------
463// | | |
464// EBPA ESSA EBKA
465// |
466// EDGA
467// |
468// ECGA
469// |
470// --------------------
471// | | |
472// EPCA(1) EHC1 EPCA(2)
473// (bottom) | (top PCB)
474// |
475// Sensitive volume
476// (gas)
477//
478
479
480 //FOR VETO
481//Creating the side channels
482// SS boundary channel, followed by G10 and Air Gap
483 gMC->Gspos("EDVA", 1, "ESVA", 0., 0., 0., 0, "ONLY");
484 gMC->Gspos("ECVA", 1, "EDVA", 0., 0., 0., 0, "ONLY");
485
486//FOR PRESHOWER
487 gMC->Gspos("EDGA", 1, "ESSA", 0., 0., 0., 0, "ONLY");
488 gMC->Gspos("ECGA", 1, "EDGA", 0., 0., 0., 0, "ONLY");
489
490 // now other components, using Bedanga's code, but changing the values.
491 //Positioning Bottom PCB, Honey Comb abd Top PCB in AIR
492
493 //For veto plane
494 //Positioning the Bottom 0.16 cm PCB
495 Float_t zbpcb = -dboxAir3A[2] + (2.0*fgkGap) + fgkThPCB/2.;
496 gMC->Gspos("EPCA", 1, "ECVA", 0., 0., zbpcb, 0, "ONLY");
497 //Positioning the Honey Comb 0.5 cm
498 Float_t zhc = zbpcb + fgkThPCB/2. + fgkCellDepth/2.;
499 gMC->Gspos("EHC1", 1, "ECVA", 0., 0., zhc, 0, "ONLY");
500 //Positioning the Top PCB 0.16 cm
501 Float_t ztpcb = zhc + fgkCellDepth/2 + fgkThPCB/2.;
502 gMC->Gspos("EPCA", 2, "ECVA", 0., 0., ztpcb, 0, "ONLY");
503
504
505 //For Preshower plane the ordering is reversed
506 //Positioning the Bottom 0.16 cm PCB
507 zbpcb = -dboxAir3A[2] + fgkThPCB + fgkThPCB/2.;
508 gMC->Gspos("EPCA", 1, "ECGA", 0., 0., zbpcb, 0, "ONLY");
509 //Positioning the Honey Comb 0.5 cm
510 zhc = zbpcb + fgkThPCB/2. + fgkCellDepth/2.;
511 gMC->Gspos("EHC1", 1, "ECGA", 0., 0., zhc, 0, "ONLY");
512 //Positioning the Top PCB 0.16 cm
513 ztpcb = zhc + fgkCellDepth/2 + fgkThPCB/2.;
514 gMC->Gspos("EPCA", 2, "ECGA", 0., 0., ztpcb, 0, "ONLY");
515
516
517
518
519 //--------------Now let us construct final UM ---------------//
520 // We will do it as follows :
521 // (i) First make a UM of air. which will have dimensions
522 // of the SS boundary Channel (in x,y) and of height 13.3mm
523 //(ii) Then we will place all the components
524
525 //----------------------------------------------------------//
526 // A unit module type A of Air
527 // Dimensions of Unit Module same as SS boundary channel
528 Float_t dboxUM1[3];
529 dboxUM1[0] = dboxSS1[0];
530 dboxUM1[1] = dboxSS1[1];
531 dboxUM1[2] = fgkThSS/2. +0.15; // 0.15 added to accomodate Base Plate at
532 // the bottom and the backplane PCB at the top.
533
534 //FOR PRESHOWER
535 //Create a Unit module of above dimensions Material : AIR
536 gMC->Gsvolu("EUM1","BOX", idtmed[698], dboxUM1, 3);
537 //FOR VETO
538 gMC->Gsvolu("EUV1","BOX", idtmed[698], dboxUM1, 3);
539
540 //----------------------------------------------------------------//
541
542 //BASE PLATE : EBPA
543 //==================
544 // Make a 2mm thick G10 Base plate for Unit module A
545 // Base plate is as big as the final UM dimensions that is as
546 // SS boundary channel
547 Float_t dboxBaseA[3];
548 dboxBaseA[0] = dboxSS1[0];
549 dboxBaseA[1] = dboxSS1[1];
550 dboxBaseA[2] = fgkThBase/2.;
551
552 //Base Blate is a G10 BOX
553 gMC->Gsvolu("EBPA","BOX", idtmed[607], dboxBaseA, 3);
554 //----------------------------------------------------//
555
556 //FOR VETO
557 //- Placing of all components of UM in AIR BOX EUM1--//
558 //(1) FIRST PUT THE BASE PLATE
559 Float_t zbaseplate = -dboxUM1[2] + fgkThBase/2.;
560 gMC->Gspos("EBPA", 1, "EUV1", 0., 0., zbaseplate, 0, "ONLY");
561
562 //(2) NEXT PLACING the SS BOX
563 Float_t zss = zbaseplate + fgkThBase/2. + fgkThSS/2.;
564 gMC->Gspos("ESVA", 1, "EUV1", 0., 0., zss, 0, "ONLY");
565
566 // (3) Positioning the Backplane PCB 0.1 cm
567 Float_t zbkp = zss + fgkThSS/2. + fgkThBKP/2.;
568 gMC->Gspos("EBKA", 1, "EUV1", 0., 0., zbkp, 0, "ONLY");
569
570 //FOR PRESHOWER
571 // (3) Positioning the Backplane PCB 0.1 cm
572 zbkp = -dboxUM1[2] + fgkThBKP/2.;
573 gMC->Gspos("EBKA", 1, "EUM1", 0., 0., zbkp, 0, "ONLY");
574
575 //(2) NEXT PLACING the SS BOX
576 zss = zbkp + fgkThBKP/2. + fgkThSS/2.;
577 gMC->Gspos("ESSA", 1, "EUM1", 0., 0., zss, 0, "ONLY");
578
579 //(1) FIRST PUT THE BASE PLATE
580 zbaseplate = zss + fgkThSS/2 + fgkThBase/2.;
581 gMC->Gspos("EBPA", 1, "EUM1", 0., 0., zbaseplate, 0, "ONLY");
582 //-------------------- UM Type A completed ------------------------//
583
584
585
586 //-------------------- Lets do the same thing for UM type B -------//
587 //--------------------------------------------------//
588 //Bottom and Top PCB : EPCB
589 //===========================
590 // Make a 1.6mm thick G10 Bottom and Top PCB for Unit module B
591 // X-dimension same as EHC2 - dbox4[0]
592 // Y-dimension same as EHC2 - dbox4[1]
593 // Z-dimension 0.16/2 = 0.08 cm
594 //-------------------------------------------------//
595 Float_t dboxPcbB[3];
596 dboxPcbB[0] = dbox4[0];
597 dboxPcbB[1] = dbox4[1];
598 dboxPcbB[2] = fgkThPCB/2.;
599
600 //Top and Bottom PCB is a BOX of Material G10
601 gMC->Gsvolu("EPCB","BOX", idtmed[607], dboxPcbB, 3);
602 //--------------------------------------------------------//
603 //Back Plane : EBKB
604 //==================
605 // Make a 1.0mm thick Back Plane PCB for Unit module B
606 // X-dimension same as EHC2 - dbox4[0]
607 // Y-dimension same as EHC2 - dbox4[1]
608 // Z-dimension 0.1/2 = 0.05 cm
609 //------------------------------------------------------//
610 Float_t dboxBPlaneB[3];
611 dboxBPlaneB[0] = dbox4[0];
612 dboxBPlaneB[1] = dbox4[1];
613 dboxBPlaneB[2] = fgkThBKP/2.;
614
615 //Back PLane PCB of MAterial G10
616 gMC->Gsvolu("EBKB","BOX", idtmed[607], dboxBPlaneB, 3);
617 //-------------------------------------------------------------//
618
619 //---------- That was all in the Z -direction of Unit Module B----//
620
621 // Now lets us construct the boundary arround the Unit Module --//
622 // This boundary has
623 // (a) 0.5 mm X and Y and 10.3 mm Z dimension AIR gap
624 // (b) 0.5 mm X and Y and 10.3 mm Z dimension G10
625 // (c) 3.0 mm X and Y and 12.3 mm Z dimension Stainless Steel
626
627 //-------------------------------------------------//
628 //AIR GAP between UM and Boundary : ECGB
629 //================================================
630 // Make a 10.3mm thick Air gap for Unit module B
631 // X-dimension same as EHC2+0.05
632 // Y-dimension same as EHC2+0.05
633 // Z-dimension 1.03/2 = 0.515 cm
634 Float_t dboxAir3B[3];
635 dboxAir3B[0] = dbox4[0]+(2.0*fgkGap);
636 dboxAir3B[1] = dbox4[1]+(2.0*fgkGap);
637 dboxAir3B[2] = fgkThAir/2.;
638
639 //PRESHOWER
640 //Air gap is a BOX of Material Air
641 gMC->Gsvolu("ECGB","BOX", idtmed[698], dboxAir3B, 3);
642 //VETO
643 gMC->Gsvolu("ECVB","BOX", idtmed[698], dboxAir3B, 3);
644
645 //-------------------------------------------------//
646
647 //-------------------------------------------------//
648 //G10 boundary between honeycomb and SS : EDGB
649 //================================================
650 // Make a 10.3mm thick G10 Boundary for Unit module B
651 // X-dimension same as EHC2+Airgap+0.05
652 // Y-dimension same as EHC2+Airgap+0.05
653 // Z-dimension 1.03/2 = 0.515 cm
654 Float_t dboxGGB[3];
655 dboxGGB[0] = dboxAir3B[0]+(2.0*fgkGap);
656 dboxGGB[1] = dboxAir3B[1]+(2.0*fgkGap);
657 dboxGGB[2] = fgkThG10/2.;
658
659 //PRESHOWER
660 //G10 BOX
661 gMC->Gsvolu("EDGB","BOX", idtmed[607], dboxGGB, 3);
662 //VETO
663 gMC->Gsvolu("EDVB","BOX", idtmed[607], dboxGGB, 3);
664 //-------------------------------------------------//
665 //----------------------------------------------------------//
666 //Stainless Steel Bounadry : ESSB
667 //==================================
668 // Make a 10.3mm thick Stainless Steel boundary for Unit module B
669 // X-dimension same as EHC2 + Airgap + G10 + 0.3
670 // Y-dimension same as EHC2 + Airgap + G10 + 0.3
671 // Z-dimension 1.03/2 = 0.515 cm
672 //------------------------------------------------------//
673 // A Stainless Steel Boundary Channel to house the unit module
674
675 Float_t dboxSS2[3];
676 dboxSS2[0] = dboxGGB[0] + fgkSSBoundary;
677 dboxSS2[1] = dboxGGB[1] + fgkSSBoundary;
678 dboxSS2[2] = fgkThSS/2.;
679
680 //PRESHOWER
681 //Stainless Steel boundary - Material Stainless Steel
682 gMC->Gsvolu("ESSB","BOX", idtmed[618], dboxSS2, 3);
683 //VETO
684 gMC->Gsvolu("ESVB","BOX", idtmed[618], dboxSS2, 3);
685 //----------------------------------------------------------------//
686
687 //----------------------------------------------------------------//
688 // Here we need to place the volume in order ESSB -> EDGB -> ECGB
689 // this makes the SS boiundary and the 0.5mm thick FR4 insulation in place,
690 // and the air volume ECGB acts as mother for the rest of components.
691 // The above placeemnt is done at (0.,0.,0.) relative coordiante
692 // Now we place bottom PCB, honeycomb, top PCB in this volume. We donot place
693 // unnecessary air volumes now. Just leave the gap as we are placing them
694 // in air only. This also reduces the number of volumes for geant to track.
695
696// Tree structure for different volumes
697//
698// EUM2
699// |
700// --------------------
701// | | |
702// EBPB ESSB EBKB
703// |
704// EDGB
705// |
706// ECGB
707// |
708// --------------------
709// | | |
710// EPCB(1) EHC2 EPCB(2)
711// (bottom) | (top PCB)
712// |
713// Sensitive volume
714// (gas)
715//
716
717//PRESHOWER
718//Creating the side channels
719// SS boundary channel, followed by G10 and Air Gap
720 gMC->Gspos("EDGB", 1, "ESSB", 0., 0., 0., 0, "ONLY");
721 gMC->Gspos("ECGB", 1, "EDGB", 0., 0., 0., 0, "ONLY");
722 //VETO
723 gMC->Gspos("EDVB", 1, "ESVB", 0., 0., 0., 0, "ONLY");
724 gMC->Gspos("ECVB", 1, "EDVB", 0., 0., 0., 0, "ONLY");
725
726 // now other components, using Bedang's code, but changing the values.
727 //Positioning Bottom PCB, Honey Comb abd Top PCB in AIR
728
729 //VETO
730 //Positioning the Bottom 0.16 cm PCB
731 Float_t zbpcb2 = -dboxAir3B[2] + (2.0*fgkGap) + fgkThPCB/2.;
732 gMC->Gspos("EPCB", 1, "ECVB", 0., 0., zbpcb2, 0, "ONLY");
733 //Positioning the Honey Comb 0.5 cm
734 Float_t zhc2 = zbpcb2 + fgkThPCB/2. + fgkCellDepth/2.;
735 gMC->Gspos("EHC2", 1, "ECVB", 0., 0., zhc2, 0, "ONLY");
736 //Positioning the Top PCB 0.16 cm
737 Float_t ztpcb2 = zhc2 + fgkCellDepth/2 + fgkThPCB/2.;
738 gMC->Gspos("EPCB", 2, "ECVB", 0., 0., ztpcb2, 0, "ONLY");
739
740 //PRESHOWER
741 //For preshower plane the ordering is reversed
742 //Positioning the Bottom 0.16 cm PCB
743 zbpcb2 = -dboxAir3B[2] + fgkThPCB + fgkThPCB/2.;
744 gMC->Gspos("EPCB", 1, "ECGB", 0., 0., zbpcb2, 0, "ONLY");
745 //Positioning the Honey Comb 0.5 cm
746 zhc2 = zbpcb2 + fgkThPCB/2. + fgkCellDepth/2.;
747 gMC->Gspos("EHC2", 1, "ECGB", 0., 0., zhc2, 0, "ONLY");
748 //Positioning the Top PCB 0.16 cm
749 ztpcb2 = zhc2 + fgkCellDepth/2 + fgkThPCB/2.;
750 gMC->Gspos("EPCB", 2, "ECGB", 0., 0., ztpcb2, 0, "ONLY");
751
752
753
754 //--------------Now let us construct final UM ---------------//
755 // We will do it as follows :
756 // (i) First make a UM of air. which will have dimensions
757 // of the SS boundary Channel (in x,y) and of height 13.3mm
758 //(ii) Then we will place all the components
759
760 //----------------------------------------------------------//
761 // A unit module type B of Air
762 // Dimensions of Unit Module same as SS boundary channel
763
764 Float_t dboxUM2[3];
765 dboxUM2[0] = dboxSS2[0];
766 dboxUM2[1] = dboxSS2[1];
767 dboxUM2[2] = fgkThSS/2. +0.15; // 0.15 added to accomodate Base Plate at
768 // the bottom and the backplane PCB at the top.
769
770 //PRESHOWER
771 //Create a Unit module of above dimensions Material : AIR
772 gMC->Gsvolu("EUM2","BOX", idtmed[698], dboxUM2, 3);
773
774 //VETO
775 gMC->Gsvolu("EUV2","BOX", idtmed[698], dboxUM2, 3);
776 //----------------------------------------------------------------//
777
778 //BASE PLATE : EBPB
779 //==================
780 // Make a 2mm thick G10 Base plate for Unit module B
781 // Base plate is as big as the final UM dimensions that is as
782 // SS boundary channel
783 Float_t dboxBaseB[3];
784 dboxBaseB[0] = dboxSS2[0];
785 dboxBaseB[1] = dboxSS2[1];
786 dboxBaseB[2] = fgkThBase/2.;
787
788 //Base Blate is a G10 BOX
789 gMC->Gsvolu("EBPB","BOX", idtmed[607], dboxBaseB, 3);
790 //----------------------------------------------------//
791
792 //VETO
793 //- Placing of all components of UM in AIR BOX EUM2--//
794 //(1) FIRST PUT THE BASE PLATE
795 Float_t zbaseplate2 = -dboxUM2[2] + fgkThBase/2.;
796 gMC->Gspos("EBPB", 1, "EUV2", 0., 0., zbaseplate2, 0, "ONLY");
797
798 //(2) NEXT PLACING the SS BOX
799 Float_t zss2 = zbaseplate2 + fgkThBase/2. + fgkThSS/2.;
800 gMC->Gspos("ESVB", 1, "EUV2", 0., 0., zss2, 0, "ONLY");
801
802 // (3) Positioning the Backplane PCB 0.1 cm
803 Float_t zbkp2 = zss2 + fgkThSS/2. + fgkThBKP/2.;
804 gMC->Gspos("EBKB", 1, "EUV2", 0., 0., zbkp2, 0, "ONLY");
805
806
807
808 //FOR PRESHOWER
809 // (3) Positioning the Backplane PCB 0.1 cm
810 zbkp2 = -dboxUM2[2] + fgkThBKP/2.;
811 gMC->Gspos("EBKB", 1, "EUM2", 0., 0., zbkp2, 0, "ONLY");
812
813 //(2) NEXT PLACING the SS BOX
814 zss2 = zbkp2 + fgkThBKP/2. + fgkThSS/2.;
815 gMC->Gspos("ESSB", 1, "EUM2", 0., 0., zss2, 0, "ONLY");
816
817 //(1) FIRST PUT THE BASE PLATE
818 zbaseplate2 = zss2 + fgkThSS/2 + fgkThBase/2.;
819 gMC->Gspos("EBPB", 1, "EUM2", 0., 0., zbaseplate2, 0, "ONLY");
820 //-------------------- UM Type B completed ------------------------//
821
822
823 //--- Now we need to make Lead plates of UM dimension -----//
824
825 /**************************/
826 //----------------------------------------------------------//
827 // The lead convertor is of unit module size
828 // Dimensions of Unit Module same as SS boundary channel
829
830 Float_t dboxPba[3];
831 dboxPba[0] = dboxUM1[0];
832 dboxPba[1] = dboxUM1[1];
833 dboxPba[2] = fgkThLead/2.;
834 // Lead of UM dimension
835 gMC->Gsvolu("EPB1","BOX", idtmed[600], dboxPba, 3);
836
837 Float_t dboxPbb[3];
838 dboxPbb[0] = dboxUM2[0];
839 dboxPbb[1] = dboxUM2[1];
840 dboxPbb[2] = fgkThLead/2.;
841 // Lead of UM dimension
842 gMC->Gsvolu("EPB2","BOX", idtmed[600], dboxPbb, 3);
843
844 //----------------------------------------------------------------//
845
846 // 2 types of Rectangular shaped supermodules (BOX)
847 //each with 6 unit modules
848
849 // volume for SUPERMODULE ESMA
850 //Space added to provide a gapping for HV between UM's
851 //There is a gap of 0.15 cm between two Modules (UMs)
852 // in x-direction and 0.1cm along y-direction
853
854 Float_t dboxSM1[3];
855 dboxSM1[0] = 3.0*dboxUM1[0] + (2.0*0.075);
856 dboxSM1[1] = 2.0*dboxUM1[1] + 0.05;
857 dboxSM1[2] = dboxUM1[2];
858
859 //FOR PRESHOWER
860 gMC->Gsvolu("ESMA","BOX", idtmed[698], dboxSM1, 3);
861
862 //FOR VETO
863 gMC->Gsvolu("EMVA","BOX", idtmed[698], dboxSM1, 3);
864
865 //Position the 6 unit modules in EMSA
866 Float_t xa1,xa2,xa3,ya1,ya2;
867 xa1 = dboxSM1[0] - dboxUM1[0];
868 xa2 = xa1 - dboxUM1[0] - 0.15 - dboxUM1[0];
869 xa3 = xa2 - dboxUM1[0] - 0.15 - dboxUM1[0];
870 ya1 = dboxSM1[1] - dboxUM1[1];
871 ya2 = ya1 - dboxUM1[1] - 0.1 - dboxUM1[1];
872
873 //PRESHOWER
874 // gMC->Gspos("EUM1", 1, "ESMA", xa1, ya1, 0., 0, "ONLY"); // BKN
875 gMC->Gspos("EUM1", 2, "ESMA", xa2, ya1, 0., 0, "ONLY");
876 gMC->Gspos("EUM1", 3, "ESMA", xa3, ya1, 0., 0, "ONLY");
877 gMC->Gspos("EUM1", 4, "ESMA", xa1, ya2, 0., 0, "ONLY");
878 gMC->Gspos("EUM1", 5, "ESMA", xa2, ya2, 0., 0, "ONLY");
879 gMC->Gspos("EUM1", 6, "ESMA", xa3, ya2, 0., 0, "ONLY");
880
881 //VETO
882 gMC->Gspos("EUV1", 1, "EMVA", xa1, ya1, 0., 0, "ONLY");
883 gMC->Gspos("EUV1", 2, "EMVA", xa2, ya1, 0., 0, "ONLY");
884 gMC->Gspos("EUV1", 3, "EMVA", xa3, ya1, 0., 0, "ONLY");
885 gMC->Gspos("EUV1", 4, "EMVA", xa1, ya2, 0., 0, "ONLY");
886 gMC->Gspos("EUV1", 5, "EMVA", xa2, ya2, 0., 0, "ONLY");
887 gMC->Gspos("EUV1", 6, "EMVA", xa3, ya2, 0., 0, "ONLY");
888
889
890 // volume for SUPERMODULE ESMB
891 //Space is added to provide a gapping for HV between UM's
892 Float_t dboxSM2[3];
893 dboxSM2[0] = 2.0*dboxUM2[0] + 0.075;
894 dboxSM2[1] = 3.0*dboxUM2[1] + (2.0*0.05);
895 dboxSM2[2] = dboxUM2[2];
896
897 //PRESHOWER
898 gMC->Gsvolu("ESMB","BOX", idtmed[698], dboxSM2, 3);
899 //VETO
900 gMC->Gsvolu("EMVB","BOX", idtmed[698], dboxSM2, 3);
901
902 //Position the 6 unit modules in EMSB
903 Float_t xb1,xb2,yb1,yb2,yb3;
904 xb1 = dboxSM2[0] - dboxUM2[0];
905 xb2 = xb1 - dboxUM2[0] - 0.15 - dboxUM2[0];
906 yb1 = dboxSM2[1] - dboxUM2[1];
907 yb2 = yb1 - dboxUM2[1] - 0.1 - dboxUM2[1];
908 yb3 = yb2 - dboxUM2[1] - 0.1 - dboxUM2[1];
909
910
911 //PRESHOWER
912 // gMC->Gspos("EUM2", 1, "ESMB", xb1, yb1, 0., 0, "ONLY"); // BKN
913 // gMC->Gspos("EUM2", 2, "ESMB", xb2, yb1, 0., 0, "ONLY");
914 gMC->Gspos("EUM2", 3, "ESMB", xb1, yb2, 0., 0, "ONLY");
915 gMC->Gspos("EUM2", 4, "ESMB", xb2, yb2, 0., 0, "ONLY");
916 gMC->Gspos("EUM2", 5, "ESMB", xb1, yb3, 0., 0, "ONLY");
917 gMC->Gspos("EUM2", 6, "ESMB", xb2, yb3, 0., 0, "ONLY");
918
919 //VETO
920 gMC->Gspos("EUV2", 1, "EMVB", xb1, yb1, 0., 0, "ONLY");
921 gMC->Gspos("EUV2", 2, "EMVB", xb2, yb1, 0., 0, "ONLY");
922 gMC->Gspos("EUV2", 3, "EMVB", xb1, yb2, 0., 0, "ONLY");
923 gMC->Gspos("EUV2", 4, "EMVB", xb2, yb2, 0., 0, "ONLY");
924 gMC->Gspos("EUV2", 5, "EMVB", xb1, yb3, 0., 0, "ONLY");
925 gMC->Gspos("EUV2", 6, "EMVB", xb2, yb3, 0., 0, "ONLY");
926
927 // Make smiliar stucture for lead as for PMD plane
928 //================================================
929
930 // 2 types of Rectangular shaped supermodules (BOX)
931 //each with 6 unit modules
932
933 // volume for SUPERMODULE ESMPbA
934 //Space added to provide a gapping for HV between UM's
935
936 Float_t dboxSMPb1[3];
937 dboxSMPb1[0] = 3.0*dboxUM1[0] + (2.0*0.075);
938 dboxSMPb1[1] = 2.0*dboxUM1[1] + 0.05;
939 dboxSMPb1[2] = fgkThLead/2.;
940
941 gMC->Gsvolu("ESPA","BOX", idtmed[698], dboxSMPb1, 3);
942
943
944 //Position the 6 unit modules in ESMPbA
945 Float_t xpa1,xpa2,xpa3,ypa1,ypa2;
946 xpa1 = -dboxSMPb1[0] + dboxUM1[0];
947 xpa2 = xpa1 + dboxUM1[0] + 0.15 + dboxUM1[0];
948 xpa3 = xpa2 + dboxUM1[0] + 0.15 + dboxUM1[0];
949 ypa1 = dboxSMPb1[1] - dboxUM1[1];
950 ypa2 = ypa1 - dboxUM1[1] - 0.1 - dboxUM1[1];
951
952
953 gMC->Gspos("EPB1", 1, "ESPA", xpa1, ypa1, 0., 0, "ONLY");
954 gMC->Gspos("EPB1", 2, "ESPA", xpa2, ypa1, 0., 0, "ONLY");
955 gMC->Gspos("EPB1", 3, "ESPA", xpa3, ypa1, 0., 0, "ONLY");
956 gMC->Gspos("EPB1", 4, "ESPA", xpa1, ypa2, 0., 0, "ONLY");
957 gMC->Gspos("EPB1", 5, "ESPA", xpa2, ypa2, 0., 0, "ONLY");
958 gMC->Gspos("EPB1", 6, "ESPA", xpa3, ypa2, 0., 0, "ONLY");
959
960
961 // volume for SUPERMODULE ESMPbB
962 //Space is added to provide a gapping for HV between UM's
963 Float_t dboxSMPb2[3];
964 dboxSMPb2[0] = 2.0*dboxUM2[0] + 0.075;
965 dboxSMPb2[1] = 3.0*dboxUM2[1] + (2.0*0.05);
966 dboxSMPb2[2] = fgkThLead/2.;
967
968 gMC->Gsvolu("ESPB","BOX", idtmed[698], dboxSMPb2, 3);
969
970 //Position the 6 unit modules in ESMPbB
971 Float_t xpb1,xpb2,ypb1,ypb2,ypb3;
972 xpb1 = -dboxSMPb2[0] + dboxUM2[0];
973 xpb2 = xpb1 + dboxUM2[0] + 0.15 + dboxUM2[0];
974 ypb1 = dboxSMPb2[1] - dboxUM2[1];
975 ypb2 = ypb1 - dboxUM2[1] - 0.1 - dboxUM2[1];
976 ypb3 = ypb2 - dboxUM2[1] - 0.1 - dboxUM2[1];
977
978
979 gMC->Gspos("EPB2", 1, "ESPB", xpb1, ypb1, 0., 0, "ONLY");
980 gMC->Gspos("EPB2", 2, "ESPB", xpb2, ypb1, 0., 0, "ONLY");
981 gMC->Gspos("EPB2", 3, "ESPB", xpb1, ypb2, 0., 0, "ONLY");
982 gMC->Gspos("EPB2", 4, "ESPB", xpb2, ypb2, 0., 0, "ONLY");
983 gMC->Gspos("EPB2", 5, "ESPB", xpb1, ypb3, 0., 0, "ONLY");
984 gMC->Gspos("EPB2", 6, "ESPB", xpb2, ypb3, 0., 0, "ONLY");
985
986
987 //---------------------------------------------------
988 /// ALICE PMD FEE BOARDS IMPLEMENTATION
989 // Dt: 25th February 2006
990 // - M.M. Mondal, S.K. Prasad and P.K. Netrakanti
991 //---------------------------------------------------
992
993 //FEE boards
994 // It is FR4 board of length 7cm
995 // breadth of 2.4 cm and thickness 0.1cm
996 Float_t dboxFEE[3];
997 dboxFEE[0] = 0.05;
998 dboxFEE[1] = 3.50;
999 dboxFEE[2] = 1.20;
1000
1001 gMC->Gsvolu("EFEE","BOX", idtmed[607], dboxFEE, 3);
1002
1003 //Mother volume to accomodate FEE boards
1004 // It should have the dimension
1005 // as the back plane or the
1006 //corresponding UM
1007 //TYPE A
1008 //------------------------------------------------------//
1009
1010 Float_t dboxFEEBPlaneA[3];
1011 dboxFEEBPlaneA[0] = dboxBPlaneA[0]; //dbox3[0];
1012 dboxFEEBPlaneA[1] = dboxBPlaneA[1];//dbox3[1];
1013 dboxFEEBPlaneA[2] = 1.2;
1014
1015 //Volume of same dimension as Back PLane of Material AIR
1016 gMC->Gsvolu("EFBA","BOX", idtmed[698], dboxFEEBPlaneA, 3);
1017
1018 //TYPE B
1019 Float_t dboxFEEBPlaneB[3];
1020 dboxFEEBPlaneB[0] = dboxBPlaneB[0]; //dbox4[0];
1021 dboxFEEBPlaneB[1] = dboxBPlaneB[1];//dbox4[1];
1022 dboxFEEBPlaneB[2] = 1.2;
1023
1024 //Back PLane PCB of MAterial G10
1025 gMC->Gsvolu("EFBB","BOX", idtmed[698], dboxFEEBPlaneB, 3);
1026
1027 //Placing the FEE boards in the Mother volume of AIR
1028
1029 //Type A
1030
1031 Float_t xFee; // X-position of FEE board
1032 Float_t yFee; // Y-position of FEE board
1033 Float_t zFee = 0.0; // Z-position of FEE board
1034
1035 Float_t xA = 0.25; //distance from the border to 1st FEE board
1036 Float_t yA = 4.00; //distance from the border to 1st FEE board
1037 Float_t xSepa = 1.70; //Distance between two FEE boards
1038 Float_t ySepa = 8.00; //Distance between two FEE boards
1039
1040
1041 // FEE Boards EFEE placed inside EFBA
1042 number = 1;
1043 yFee = dboxFEEBPlaneA[1] - yA;
1044 for (i = 1; i <= 6; ++i)
1045 {
1046 xFee = -dboxFEEBPlaneA[0] + xA;
1047 for (j = 1; j <= 12; ++j)
1048 {
1049 gMC->Gspos("EFEE", number, "EFBA", xFee,yFee,zFee, 0, "ONLY");
1050 xFee += xSepa;
1051 number += 1;
1052 }
1053 yFee -= ySepa;
1054 }
1055 // FEE Boards EFEE placed inside EFBB
1056 number = 1;
1057 yFee = dboxFEEBPlaneB[1] - yA;
1058 for (i = 1; i <= 3; ++i)
1059 {
1060 xFee = -dboxFEEBPlaneB[0] + xA;
1061 for (j = 1; j <= 24; ++j)
1062 {
1063 gMC->Gspos("EFEE", number, "EFBB", xFee,yFee,zFee, 0, "ONLY");
1064 xFee += xSepa;
1065 number += 1;
1066 }
1067 yFee -= ySepa;
1068 }
1069
1070
1071 //Distance between the two backplanes of two UMs
1072 //in x-direction is 0.92 and ydirection is 0.95
1073 Float_t dboxEFSA[3];
1074 dboxEFSA[0] = 3.0*dboxFEEBPlaneA[0] + 0.92;
1075 dboxEFSA[1] = 2.0*dboxFEEBPlaneA[1] + (0.95/2.0);
1076 dboxEFSA[2] = dboxFEEBPlaneA[2];
1077
1078 //Type A
1079 gMC->Gsvolu("EFSA","BOX", idtmed[698],dboxEFSA, 3);
1080
1081 //Distance between the two backplanes of two UMs
1082 //in x-direction is 0.92 and ydirection is 0.95
1083 Float_t dboxEFSB[3];
1084 dboxEFSB[0] = 2.0*dboxFEEBPlaneB[0] + (0.938/2.0);
1085 dboxEFSB[1] = 3.0*dboxFEEBPlaneB[1] + 1.05;
1086 dboxEFSB[2] = dboxFEEBPlaneB[2];
1087
1088 //Type A
1089 gMC->Gsvolu("EFSB","BOX", idtmed[698],dboxEFSB, 3);
1090
1091
1092 Float_t xfs1,xfs2,xfs3,yfs1,yfs2,yfs3;
1093 xfs1 = -dboxEFSA[0] + dboxFEEBPlaneA[0];
1094 xfs2 = xfs1 + dboxFEEBPlaneA[0] + 0.92 + dboxFEEBPlaneA[0];
1095 xfs3 = xfs2 + dboxFEEBPlaneA[0] + 0.92 + dboxFEEBPlaneA[0];
1096 yfs1 = dboxEFSA[1] - dboxFEEBPlaneA[1];
1097 yfs2 = yfs1 - dboxFEEBPlaneA[1] - 0.95 - dboxFEEBPlaneA[1];
1098
1099
1100
1101 // gMC->Gspos("EFBA", 1, "EFSA", xfs1, yfs1, 0., 0, "ONLY"); // BKN
1102 gMC->Gspos("EFBA", 2, "EFSA", xfs2, yfs1, 0., 0, "ONLY");
1103 gMC->Gspos("EFBA", 3, "EFSA", xfs3, yfs1, 0., 0, "ONLY");
1104 gMC->Gspos("EFBA", 4, "EFSA", xfs1, yfs2, 0., 0, "ONLY");
1105 gMC->Gspos("EFBA", 5, "EFSA", xfs2, yfs2, 0., 0, "ONLY");
1106 gMC->Gspos("EFBA", 6, "EFSA", xfs3, yfs2, 0., 0, "ONLY");
1107
1108
1109 //Type B positioning
1110
1111 xfs1 = -dboxEFSB[0] + dboxFEEBPlaneB[0];
1112 xfs2 = xfs1 + dboxFEEBPlaneB[0] + 0.938 + dboxFEEBPlaneB[0];
1113 yfs1 = dboxEFSB[1] - dboxFEEBPlaneB[1];
1114 yfs2 = yfs1 - dboxFEEBPlaneB[1] - 1.05 - dboxFEEBPlaneB[1];
1115 yfs3 = yfs2 - dboxFEEBPlaneB[1] - 1.05 - dboxFEEBPlaneB[1];
1116
1117
1118
1119 // gMC->Gspos("EFBB", 1, "EFSB", xfs1, yfs1, 0., 0, "ONLY"); // BKN
1120 // gMC->Gspos("EFBB", 2, "EFSB", xfs2, yfs1, 0., 0, "ONLY"); // BKN
1121 gMC->Gspos("EFBB", 3, "EFSB", xfs1, yfs2, 0., 0, "ONLY");
1122 gMC->Gspos("EFBB", 4, "EFSB", xfs2, yfs2, 0., 0, "ONLY");
1123 gMC->Gspos("EFBB", 5, "EFSB", xfs1, yfs3, 0., 0, "ONLY");
1124 gMC->Gspos("EFBB", 6, "EFSB", xfs2, yfs3, 0., 0, "ONLY");
1125
1126
1127}
1128
1129//_____________________________________________________________________________
1130
1131void AliPMDv2008::CreatePMD()
1132{
1133 //
1134 // Create final detector from supermodules
1135 // -- Author : Bedanga and Viyogi June 2003
1136
1137 Float_t zp;
1138 Int_t jhrot12,jhrot13, irotdm;
1139 Int_t *idtmed = fIdtmed->GetArray()-599;
1140
1141 //VOLUMES Names : begining with "E" for all PMD volumes,
1142
1143 // --- DEFINE Iron volumes for SM A
1144 // Fe Support
1145 Float_t dboxFea[3];
1146 dboxFea[0] = fSMLengthax;
1147 dboxFea[1] = fSMLengthay;
1148 dboxFea[2] = fgkThSteel/2.;
1149
1150 gMC->Gsvolu("EFEA","BOX", idtmed[618], dboxFea, 3);
1151
1152 // --- DEFINE Iron volumes for SM B
1153
1154 // Fe Support
1155 Float_t dboxFeb[3];
1156 dboxFeb[0] = fSMLengthbx;
1157 dboxFeb[1] = fSMLengthby;
1158 dboxFeb[2] = fgkThSteel/2.;
1159
1160 gMC->Gsvolu("EFEB","BOX", idtmed[618], dboxFeb, 3);
1161
1162 AliMatrix(irotdm, 90., 0., 90., 90., 180., 0.);
1163 AliMatrix(jhrot12, 90., 180., 90., 270., 0., 0.);
1164 AliMatrix(jhrot13, 90., 240., 90., 330., 0., 0.);
1165
1166 // Gaspmd, the dimension of RECTANGULAR mother volume of PMD,
1167 // Four mother volumes EPM1,EPM2 for A-type and
1168 // volumes EPM3 and EPM4 for B-type. Four to create a hole
1169 // and avoid overlap with beam pipe
1170
1171 Float_t gaspmd[3];
1172 gaspmd[0] = fSMLengthax;
1173 gaspmd[1] = fSMLengthay;
1174 gaspmd[2] = fSMthick;
1175
1176 gMC->Gsvolu("EPM1", "BOX", idtmed[698], gaspmd, 3);
1177 gMC->Gsvolu("EPM2", "BOX", idtmed[698], gaspmd, 3);
1178
1179 //Complete detector for Type A
1180 //Position Super modules type A for both CPV and PMD in EPMD
1181 Float_t zpsa,zpba,zfea,zcva,zfee;
1182
1183 // zpsa = - gaspmd[2] + fSMthick/2.;
1184 // -2.5 is given to place PMD at -361.5
1185 // BM : In future after putting proper electronics
1186 // -2.5 will be replaced by -gaspmd[2]
1187
1188 //TYPE A
1189 //Fee board
1190
1191 // This part is commented for the time being by BKN
1192
1193 zfee=-gaspmd[2] + 1.2;
1194
1195 /*
1196 gMC->Gspos("EFSA", 1, "EPM1", 0., 0., zfee, 0, "ONLY");
1197 gMC->Gspos("EFSA", 2, "EPM2", 0., 0., zfee, jhrot12, "ONLY");
1198 */
1199
1200 //VETO
1201
1202 zcva = zfee + 1.2 + fDthick;
1203
1204 /*
1205 gMC->Gspos("EMVA", 1, "EPM1", 0., 0., zcva, 0, "ONLY");
1206 gMC->Gspos("EMVA", 2, "EPM2", 0., 0., zcva, jhrot12, "ONLY");
1207 */
1208
1209
1210
1211 //Iron support
1212 zfea = zcva + fDthick + fgkThSteel/2.;
1213 gMC->Gspos("EFEA", 1, "EPM1", 0., 0., zfea, 0, "ONLY");
1214 //gMC->Gspos("EFEA", 2, "EPM2", 0., 0., zfea, 0, "ONLY");
1215 //Lead
1216 zpba=zfea+fgkThSteel/2.+ fgkThLead/2.;
1217 gMC->Gspos("ESPA", 1, "EPM1", 0., 0., zpba, 0, "ONLY");
1218 //gMC->Gspos("ESPA", 2, "EPM2", 0., 0., zpba, 0, "ONLY");
1219 //Preshower
1220 zpsa = zpba + fgkThLead/2. + fDthick;
1221 gMC->Gspos("ESMA", 1, "EPM1", 0., 0., zpsa, 0, "ONLY");
1222 //gMC->Gspos("ESMA", 2, "EPM2", 0., 0., zpsa, jhrot12, "ONLY");
1223 //FEE boards
1224 zfee=zpsa + fDthick + 1.2;
1225 gMC->Gspos("EFSA", 3, "EPM1", 0., 0., zfee, 0, "ONLY");
1226 //gMC->Gspos("EFSA", 4, "EPM2", 0., 0., zfee, jhrot12, "ONLY");
1227
1228
1229 //TYPE - B
1230 gaspmd[0] = fSMLengthbx;
1231 gaspmd[1] = fSMLengthby;
1232 gaspmd[2] = fSMthick;
1233
1234 gMC->Gsvolu("EPM3", "BOX", idtmed[698], gaspmd, 3);
1235 gMC->Gsvolu("EPM4", "BOX", idtmed[698], gaspmd, 3);
1236
1237 //Complete detector for Type B
1238 //Position Super modules type B for both CPV and PMD in EPMD
1239 Float_t zpsb,zpbb,zfeb,zcvb;
1240 // zpsb = - gaspmd[2] + fSMthick/2.;
1241 // -2.5 is given to place PMD at -361.5
1242 // BM: In future after putting proper electronics
1243 // -2.5 will be replaced by -gaspmd[2]
1244
1245 //Fee board
1246
1247 zfee=-gaspmd[2] + 1.2;
1248
1249 /*
1250 gMC->Gspos("EFSB", 5, "EPM3", 0., 0., zfee, 0, "ONLY");
1251 gMC->Gspos("EFSB", 6, "EPM4", 0., 0., zfee, jhrot12, "ONLY");
1252 */
1253
1254 zcvb= zfee + 1.2 + fDthick;
1255
1256 //VETO
1257 /*
1258 gMC->Gspos("EMVB", 3, "EPM3", 0., 0., zcvb, 0, "ONLY");
1259 gMC->Gspos("EMVB", 4, "EPM4", 0., 0., zcvb, jhrot12, "ONLY");
1260 */
1261
1262 //IRON SUPPORT
1263 zfeb= zcvb + fDthick + fgkThSteel/2.;
1264 //gMC->Gspos("EFEB", 3, "EPM3", 0., 0., zfeb, 0, "ONLY");
1265 gMC->Gspos("EFEB", 4, "EPM4", 0., 0., zfeb, 0, "ONLY");
1266 //LEAD
1267 zpbb= zfeb + fgkThSteel/2.+ fgkThLead/2.;
1268 //gMC->Gspos("ESPB", 3, "EPM3", 0., 0., zpbb, 0, "ONLY");
1269 gMC->Gspos("ESPB", 4, "EPM4", 0., 0., zpbb, 0, "ONLY");
1270 //PRESHOWER
1271 zpsb = zpbb + fgkThLead/2.+ fDthick;
1272 //gMC->Gspos("ESMB", 3, "EPM3", 0., 0., zpsb, 0, "ONLY");
1273 gMC->Gspos("ESMB", 4, "EPM4", 0., 0., zpsb, jhrot12, "ONLY");
1274 //FEE boards
1275 zfee=zpsb + fDthick + 1.2;
1276 //gMC->Gspos("EFSB", 7, "EPM3", 0., 0., zfee, 0, "ONLY");
1277 gMC->Gspos("EFSB", 8, "EPM4", 0., 0., zfee, jhrot12, "ONLY");
1278
1279
1280 // --- Place the EPMD in ALICE
1281 //Z-distance of PMD from Interaction Point
1282 zp = fgkZdist;
1283
1284 //X and Y-positions of the PMD planes
1285 Float_t xfinal,yfinal;
1286 Float_t xsmb,ysmb;
1287 Float_t xsma,ysma;
1288
1289 xfinal = fSMLengthax + 0.48/2 + fSMLengthbx;
1290 yfinal = fSMLengthay + 0.20/2 + fSMLengthby;
1291
1292
1293 xsma = xfinal - fSMLengthax;
1294 ysma = yfinal - fSMLengthay;
1295 xsmb = -xfinal + fSMLengthbx;
1296 ysmb = yfinal - fSMLengthby;
1297
1298
1299//Position Full PMD in ALICE
1300//
1301// EPM1 EPM3
1302//
1303// EPM4 EPM2
1304// (rotated (rotated EPM1)
1305// EPM3)
1306//
1307 gMC->Gspos("EPM1", 1, "ALIC", xsma,ysma,zp, 0, "ONLY");
1308 gMC->Gspos("EPM2", 1, "ALIC", -xsma,-ysma,zp, 0, "ONLY");
1309 gMC->Gspos("EPM3", 1, "ALIC", xsmb,ysmb,zp, 0, "ONLY");
1310 gMC->Gspos("EPM4", 1, "ALIC", -xsmb,-ysmb,zp, 0, "ONLY");
1311}
1312
1313
1314//_____________________________________________________________________________
1315void AliPMDv2008::DrawModule() const
1316{
1317 // Draw a shaded view of the Photon Multiplicity Detector
1318 //
1319 // cout << " Inside Draw Modules " << endl;
1320
1321 gMC->Gsatt("*", "seen", -1);
1322 gMC->Gsatt("alic", "seen", 0);
1323 //
1324 // Set the visibility of the components
1325 //
1326 gMC->Gsatt("ECAR","seen",0);
1327 gMC->Gsatt("ECCU","seen",1);
1328 gMC->Gsatt("EST1","seen",1);
1329 gMC->Gsatt("EST2","seen",1);
1330 gMC->Gsatt("EUM1","seen",1);
1331 gMC->Gsatt("EUM2","seen",1);
1332 gMC->Gsatt("ESMA","seen",1);
1333 gMC->Gsatt("EPMD","seen",1);
1334 //
1335 gMC->Gdopt("hide", "on");
1336 gMC->Gdopt("shad", "on");
1337 gMC->Gsatt("*", "fill", 7);
1338 gMC->SetClipBox(".");
1339 gMC->SetClipBox("*", 0, 3000, -3000, 3000, -6000, 6000);
1340 gMC->DefaultRange();
1341 gMC->Gdraw("alic", 40, 30, 0, 22, 20.5, .02, .02);
1342 gMC->Gdhead(1111, "Photon Multiplicity Detector Version 1");
1343
1344 //gMC->Gdman(17, 5, "MAN");
1345 gMC->Gdopt("hide", "off");
1346
1347 AliDebug(1,"Outside Draw Modules");
1348}
1349
1350//_____________________________________________________________________________
1351void AliPMDv2008::CreateMaterials()
1352{
1353 // Create materials for the PMD
1354 //
1355 // ORIGIN : Y. P. VIYOGI
1356 //
1357 // cout << " Inside create materials " << endl;
1358
1359 Int_t isxfld = gAlice->Field()->Integ();
1360 Float_t sxmgmx = gAlice->Field()->Max();
1361
1362 // --- Define the various materials for GEANT ---
1363
1364 AliMaterial(1, "Pb $", 207.19, 82., 11.35, .56, 18.5);
1365
1366 // Argon
1367
1368 Float_t dAr = 0.001782; // --- Ar density in g/cm3 ---
1369 Float_t x0Ar = 19.55 / dAr;
1370 AliMaterial(2, "Argon$", 39.95, 18., dAr, x0Ar, 6.5e4);
1371
1372 // --- CO2 ---
1373
1374 Float_t aCO2[2] = { 12.,16. };
1375 Float_t zCO2[2] = { 6.,8. };
1376 Float_t wCO2[2] = { 1.,2. };
1377 Float_t dCO2 = 0.001977;
1378 AliMixture(3, "CO2 $", aCO2, zCO2, dCO2, -2, wCO2);
1379
1380 AliMaterial(4, "Al $", 26.98, 13., 2.7, 8.9, 18.5);
1381
1382 // ArCO2
1383
1384 Float_t aArCO2[3] = {39.948,12.0107,15.9994};
1385 Float_t zArCO2[3] = {18.,6.,8.};
1386 Float_t wArCO2[3] = {0.7,0.08,0.22};
1387 Float_t dArCO2 = dAr * 0.7 + dCO2 * 0.3;
1388 AliMixture(5, "ArCO2$", aArCO2, zArCO2, dArCO2, 3, wArCO2);
1389
1390 AliMaterial(6, "Fe $", 55.85, 26., 7.87, 1.76, 18.5);
1391
1392 // G10
1393
1394 Float_t aG10[4]={1.,12.011,15.9994,28.086};
1395 Float_t zG10[4]={1.,6.,8.,14.};
1396 Float_t wG10[4]={0.15201,0.10641,0.49444,0.24714};
1397 AliMixture(8,"G10",aG10,zG10,1.7,4,wG10);
1398
1399 AliMaterial(15, "Cu $", 63.54, 29., 8.96, 1.43, 15.);
1400
1401 // Steel
1402 Float_t aSteel[4] = { 55.847,51.9961,58.6934,28.0855 };
1403 Float_t zSteel[4] = { 26.,24.,28.,14. };
1404 Float_t wSteel[4] = { .715,.18,.1,.005 };
1405 Float_t dSteel = 7.88;
1406 AliMixture(19, "STAINLESS STEEL$", aSteel, zSteel, dSteel, 4, wSteel);
1407
1408 //Air
1409
1410 Float_t aAir[4]={12.0107,14.0067,15.9994,39.948};
1411 Float_t zAir[4]={6.,7.,8.,18.};
1412 Float_t wAir[4]={0.000124,0.755267,0.231781,0.012827};
1413 Float_t dAir1 = 1.20479E-10;
1414 Float_t dAir = 1.20479E-3;
1415 AliMixture(98, "Vacum$", aAir, zAir, dAir1, 4, wAir);
1416 AliMixture(99, "Air $", aAir, zAir, dAir , 4, wAir);
1417
1418 // Define tracking media
1419 AliMedium(1, "Pb conv.$", 1, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1);
1420 AliMedium(4, "Al $", 4, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1);
1421 AliMedium(5, "ArCO2 $", 5, 1, 0, isxfld, sxmgmx, .1, .1, .10, .1);
1422 AliMedium(6, "Fe $", 6, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1);
1423 AliMedium(8, "G10plate$", 8, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1);
1424 AliMedium(15, "Cu $", 15, 0, 0, isxfld, sxmgmx, .1, .1, .01, .1);
1425 AliMedium(19, "S steel$", 19, 0, 0, isxfld, sxmgmx, 1., .1, .01, .1);
1426 AliMedium(98, "Vacuum $", 98, 0, 0, isxfld, sxmgmx, 1., .1, .10, 10);
1427 AliMedium(99, "Air gaps$", 99, 0, 0, isxfld, sxmgmx, 1., .1, .10, .1);
1428
1429 AliDebug(1,"Outside create materials");
1430
1431}
1432
1433//_____________________________________________________________________________
1434void AliPMDv2008::Init()
1435{
1436 //
1437 // Initialises PMD detector after it has been built
1438 //
1439
1440 //
1441 AliDebug(2,"Inside Init");
1442 AliDebug(2,"PMD simulation package (v1) initialised");
1443 AliDebug(2,"parameters of pmd");
1444 AliDebug(2,Form("%10.2f %10.2f %10.2f %10.2f\n",
1445 fgkCellRadius,fgkCellWall,fgkCellDepth,fgkZdist));
1446 Int_t *idtmed = fIdtmed->GetArray()-599;
1447 fMedSens=idtmed[605-1];
1448 // --- Generate explicitly delta rays in the iron, aluminium and lead ---
1449 gMC->Gstpar(idtmed[600], "LOSS", 3.);
1450 gMC->Gstpar(idtmed[600], "DRAY", 1.);
1451
1452 gMC->Gstpar(idtmed[603], "LOSS", 3.);
1453 gMC->Gstpar(idtmed[603], "DRAY", 1.);
1454
1455 gMC->Gstpar(idtmed[604], "LOSS", 3.);
1456 gMC->Gstpar(idtmed[604], "DRAY", 1.);
1457
1458 gMC->Gstpar(idtmed[605], "LOSS", 3.);
1459 gMC->Gstpar(idtmed[605], "DRAY", 1.);
1460
1461 gMC->Gstpar(idtmed[607], "LOSS", 3.);
1462 gMC->Gstpar(idtmed[607], "DRAY", 1.);
1463
1464 // --- Energy cut-offs in the Pb and Al to gain time in tracking ---
1465 // --- without affecting the hit patterns ---
1466 gMC->Gstpar(idtmed[600], "CUTGAM", 1e-4);
1467 gMC->Gstpar(idtmed[600], "CUTELE", 1e-4);
1468 gMC->Gstpar(idtmed[600], "CUTNEU", 1e-4);
1469 gMC->Gstpar(idtmed[600], "CUTHAD", 1e-4);
1470
1471 gMC->Gstpar(idtmed[605], "CUTGAM", 1e-4);
1472 gMC->Gstpar(idtmed[605], "CUTELE", 1e-4);
1473 gMC->Gstpar(idtmed[605], "CUTNEU", 1e-4);
1474 gMC->Gstpar(idtmed[605], "CUTHAD", 1e-4);
1475
1476 gMC->Gstpar(idtmed[603], "CUTGAM", 1e-4);
1477 gMC->Gstpar(idtmed[603], "CUTELE", 1e-4);
1478 gMC->Gstpar(idtmed[603], "CUTNEU", 1e-4);
1479 gMC->Gstpar(idtmed[603], "CUTHAD", 1e-4);
1480// gMC->Gstpar(idtmed[609], "CUTGAM", 1e-4);
1481// gMC->Gstpar(idtmed[609], "CUTELE", 1e-4);
1482// gMC->Gstpar(idtmed[609], "CUTNEU", 1e-4);
1483// gMC->Gstpar(idtmed[609], "CUTHAD", 1e-4);
1484 // --- Prevent particles stopping in the gas due to energy cut-off ---
1485 gMC->Gstpar(idtmed[604], "CUTGAM", 1e-5);
1486 gMC->Gstpar(idtmed[604], "CUTELE", 1e-5);
1487 gMC->Gstpar(idtmed[604], "CUTNEU", 1e-5);
1488 gMC->Gstpar(idtmed[604], "CUTHAD", 1e-5);
1489 gMC->Gstpar(idtmed[604], "CUTMUO", 1e-5);
1490 // Visualization of volumes
1491 gMC->Gsatt("ECAR", "SEEN", 0);
1492 gMC->Gsatt("ECCU", "SEEN", 0);
1493 gMC->Gsatt("ECCU", "COLO", 4);
1494 gMC->Gsatt("EST1", "SEEN", 0);
1495 gMC->Gsatt("EST2", "SEEN", 0);
1496 gMC->Gsatt("EHC1", "SEEN", 0);
1497 gMC->Gsatt("EHC2", "SEEN", 0);
1498 gMC->Gsatt("EPCA", "SEEN", 0);
1499 gMC->Gsatt("EBKA", "SEEN", 0);
1500 gMC->Gsatt("ECGA", "SEEN", 0);
1501 gMC->Gsatt("ECVA", "SEEN", 0);
1502 gMC->Gsatt("EDGA", "SEEN", 0);
1503 gMC->Gsatt("EDVA", "SEEN", 0);
1504 gMC->Gsatt("ESSA", "SEEN", 0);
1505 gMC->Gsatt("ESVA", "SEEN", 0);
1506 gMC->Gsatt("EUM1", "SEEN", 0);
1507 gMC->Gsatt("EUV1", "SEEN", 0);
1508 gMC->Gsatt("EBPA", "SEEN", 0);
1509 gMC->Gsatt("EPCB", "SEEN", 0);
1510 gMC->Gsatt("EBKB", "SEEN", 0);
1511 gMC->Gsatt("ECGB", "SEEN", 0);
1512 gMC->Gsatt("ECVB", "SEEN", 0);
1513 gMC->Gsatt("EDGB", "SEEN", 0);
1514 gMC->Gsatt("EDVB", "SEEN", 0);
1515 gMC->Gsatt("ESSB", "SEEN", 0);
1516 gMC->Gsatt("ESVB", "SEEN", 0);
1517 gMC->Gsatt("EUM2", "SEEN", 0);
1518 gMC->Gsatt("EUV2", "SEEN", 0);
1519 gMC->Gsatt("EBPB", "SEEN", 0);
1520 gMC->Gsatt("EPB1", "SEEN", 0);
1521 gMC->Gsatt("EPB2", "SEEN", 0);
1522 gMC->Gsatt("ESMA", "SEEN", 0);
1523 gMC->Gsatt("EMVA", "SEEN", 0);
1524 gMC->Gsatt("ESMB", "SEEN", 0);
1525 gMC->Gsatt("EMVB", "SEEN", 0);
1526 gMC->Gsatt("ESPA", "SEEN", 0);
1527 gMC->Gsatt("ESPB", "SEEN", 0);
1528 gMC->Gsatt("EFEE", "SEEN", 0);
1529 gMC->Gsatt("EFEE", "COLO", 4);
1530 gMC->Gsatt("EFBA", "SEEN", 0);
1531 gMC->Gsatt("EFBB", "SEEN", 0);
1532 gMC->Gsatt("EFSA", "SEEN", 0);
1533 gMC->Gsatt("EFSB", "SEEN", 0);
1534 gMC->Gsatt("EFEA", "SEEN", 0);
1535 gMC->Gsatt("EFEB", "SEEN", 0);
1536 gMC->Gsatt("EPM1", "SEEN", 1);
1537 gMC->Gsatt("EPM2", "SEEN", 1);
1538 gMC->Gsatt("EPM3", "SEEN", 1);
1539 gMC->Gsatt("EPM4", "SEEN", 1);
1540}
1541
1542//_____________________________________________________________________________
1543void AliPMDv2008::StepManager()
1544{
1545 //
1546 // Called at each step in the PMD
1547 //
1548
1549 Int_t copy;
1550 Float_t hits[4], destep;
1551 Float_t center[3] = {0,0,0};
1552 Int_t vol[10];
1553 // const char *namep;
1554
1555 if(gMC->CurrentMedium() == fMedSens && (destep = gMC->Edep())) {
1556
1557 gMC->CurrentVolID(copy);
1558 // namep=gMC->CurrentVolName();
1559 // printf("Current vol is %s \n",namep);
1560 vol[0]=copy;
1561
1562 gMC->CurrentVolOffID(1,copy);
1563 //namep=gMC->CurrentVolOffName(1);
1564 // printf("Current vol 11 is %s \n",namep);
1565 vol[1]=copy;
1566
1567 gMC->CurrentVolOffID(2,copy);
1568 //namep=gMC->CurrentVolOffName(2);
1569 //printf("Current vol 22 is %s \n",namep);
1570 vol[2]=copy;
1571
1572 // if(strncmp(namep,"EHC1",4))vol[2]=1;
1573
1574 gMC->CurrentVolOffID(3,copy);
1575 // namep=gMC->CurrentVolOffName(3);
1576 //printf("Current vol 33 is %s \n",namep);
1577 vol[3]=copy;
1578
1579 gMC->CurrentVolOffID(4,copy);
1580 // namep=gMC->CurrentVolOffName(4);
1581 // printf("Current vol 44 is %s \n",namep);
1582 vol[4]=copy;
1583
1584 gMC->CurrentVolOffID(5,copy);
1585 // namep=gMC->CurrentVolOffName(5);
1586 // printf("Current vol 55 is %s \n",namep);
1587 vol[5]=copy;
1588
1589 gMC->CurrentVolOffID(6,copy);
1590 // namep=gMC->CurrentVolOffName(6);
1591 // printf("Current vol 66 is %s \n",namep);
1592 vol[6]=copy;
1593
1594 gMC->CurrentVolOffID(7,copy);
1595 // namep=gMC->CurrentVolOffName(7);
1596 // printf("Current vol 77 is %s \n",namep);
1597 vol[7]=copy;
1598
1599 gMC->CurrentVolOffID(8,copy);
1600 // namep=gMC->CurrentVolOffName(8);
1601 // printf("Current vol 88 is %s \n",namep);
1602 vol[8]=copy;
1603
1604
1605 gMC->CurrentVolOffID(9,copy);
1606 // namep=gMC->CurrentVolOffName(9);
1607 // printf("Current vol 99 is %s \n",namep);
1608 vol[9]=copy;
1609
1610
1611 // printf("volume number %4d %4d %4d %4d %4d %4d %4d %4d %4d %4d %10.3f \n",vol[0],vol[1],vol[2],vol[3],vol[4],vol[5],vol[6],vol[7],vol[8],vol[9],destep*1000000);
1612
1613 gMC->Gdtom(center,hits,1);
1614 hits[3] = destep*1e9; //Number in eV
1615 AddHit(gAlice->GetMCApp()->GetCurrentTrackNumber(), vol, hits);
1616
1617 }
1618}
1619
1620
1621//------------------------------------------------------------------------
1622// Get parameters
1623
1624void AliPMDv2008::GetParameters()
1625{
1626 // This gives all the parameters of the detector
1627 // such as Length of Supermodules, type A, type B,
1628 // thickness of the Supermodule
1629 //
1630
1631 fSMLengthax = 32.7434;
1632 //The total length in X is due to the following components
1633 // Factor 3 is because of 3 module length in X for this type
1634 // fgkNcolUM1*fgkCellRadius (48 x 0.25): Total span of each module in X
1635 // fgkCellRadius/2. : There is offset of 1/2 cell
1636 // 0.05+0.05 : Insulation gaps etc
1637 // fgkSSBoundary (0.3) : Boundary frame
1638 // double XA = 3.0*((fgkCellRadius/fgkSqroot3by2*fgkNcolUM1)-(fgkCellRadius*fgkSqroot3*(fgkNcolUM1-1)/6.)+(2.0*fgkGap)+(2.0*fgkGap)+fgkSSBoundary) + (2.0*0.075);
1639
1640 fSMLengthbx = 42.5886;
1641 //The total length in X is due to the following components
1642 // Factor 2 is because of 2 module length in X for this type
1643 // fgkNcolUM2*fgkCellRadius (96 x 0.25): Total span of each module in X
1644 // fgkCellRadius/2. : There is offset of 1/2 cell
1645 // 0.05+0.05 : Insulation gaps etc
1646 // fgkSSBoundary (0.3) : Boundary frame
1647 //double XB = 2.0*((fgkCellRadius/fgkSqroot3by2*fgkNcolUM2)-(fgkCellRadius*fgkSqroot3*(fgkNcolUM2-1)/6.)+(2.0*fgkGap)+(2.0*fgkGap)+fgkSSBoundary) + 0.075;
1648
1649
1650
1651 fSMLengthay = 49.1;
1652 //The total length in Y is due to the following components
1653 // Factor 2 is because of 2 module length in Y for this type
1654 // fgkCellRadius/fgkSqroot3by2)*fgkNrowUM1 (0.25/sqrt3/2 * 96): Total span of each module in Y
1655 // of strips
1656 // 0.05+0.05 : Insulation gaps etc
1657 // fgkSSBoundary (0.3) : Boundary frame
1658 // double YA = 2.0*(fgkNrowUM1*fgkCellRadius+fgkCellRadius/2.+(2.0*fgkGap)+(2.0*fgkGap)+fgkSSBoundary) + 0.05;
1659
1660 fSMLengthby = 37.675;
1661 //The total length in Y is due to the following components
1662 // Factor 3 is because of 3 module length in Y for this type
1663 // fgkCellRadius/fgkSqroot3by2)*fgkNrowUM2 (0.25/sqrt3/2 * 48): Total span of each module in Y
1664 // of strips
1665 // 0.05+0.05 : Insulation gaps etc
1666 // fgkSSBoundary (0.3) : Boundary frame
1667 //double YB = 3.0*((fgkNrowUM2*fgkCellRadius + fgkCellRadius/2.)+(2.0*fgkGap)+(2.0*fgkGap)+fgkSSBoundary) + (2.0*0.05);
1668
1669
1670 //Thickness of a pre/veto plane
1671 fDthick = fgkThSS/2. +0.15;
1672
1673 //Thickness of the PMD ; 2.4 added for FEE boards
1674 fSMthick = 2.0*(fgkThSS/2. +0.15)
1675 +fgkThSteel/2.+fgkThLead/2.0 + 2.4;
1676
1677
1678
1679}
1680// ---------------------------------------------------------------
1681void AliPMDv2008::AddAlignableVolumes() const
1682{
1683 //
1684 // Create entries for alignable volumes associating the symbolic volume
1685 // name with the corresponding volume path. Needs to be syncronized with
1686 // eventual changes in the geometry.
1687 //
1688 SetSectorAlignable();
1689
1690}
1691// ----------------------------------------------------------------
1692void AliPMDv2008::SetSectorAlignable() const
1693{
1694 //
1695
1696 TString vpsector = "ALIC_1/EPM";
1697 TString vpappend = "_1";
1698
1699 TString snsector="PMD/Sector";
1700
1701 TString volpath, symname;
1702
1703 for(Int_t cnt=1; cnt<=4; cnt++){
1704 volpath = vpsector;
1705 volpath += cnt;
1706 volpath += vpappend;
1707 symname = snsector;
1708 symname += cnt;
1709 if(!gGeoManager->SetAlignableEntry(symname.Data(),volpath.Data()))
1710 {
1711 AliFatal("Unable to set alignable entry!");
1712 }
1713 }
1714}
1715// ------------------------------------------------------------------