- Setting geometry module volume names and mother names
[u/mrichter/AliRoot.git] / MUON / AliMUONSt1GeometryBuilderV2.cxx
CommitLineData
ba030c0e 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
d1cd2474 16// $Id$
17//
5f1df83a 18// Authors: David Guez, Ivana Hrivnacova, Marion MacCormick; IPN Orsay
19//
d1cd2474 20// Class AliMUONSt1GeometryBuilderV2
21// ---------------------------------
22// MUON Station1 detailed geometry construction class.
5f1df83a 23// (Originally defined in AliMUONv2.cxx - now removed.)
24// Included in AliRoot 2004/01/23
d1cd2474 25
26#ifdef ST1_WITH_STL
27 #include <vector>
28#endif
ba030c0e 29
d1cd2474 30#ifdef ST1_WITH_ROOT
31 #include "TArrayI.h"
32#endif
ba030c0e 33
34#include <TVector2.h>
d1cd2474 35#include <TVector3.h>
36#include <TGeoMatrix.h>
ba030c0e 37#include <TClonesArray.h>
5f91c9e8 38#include <Riostream.h>
39#include <TSystem.h>
5d12ce38 40#include <TVirtualMC.h>
91111b9c 41#include <TGeoManager.h>
42#include <TGeoVolume.h>
43#include <TGeoTube.h>
44#include <TGeoCompositeShape.h>
ba030c0e 45
5f91c9e8 46#include "AliMpFiles.h"
ab126d0a 47#include "AliMpSectorReader.h"
5f91c9e8 48#include "AliMpSector.h"
49#include "AliMpRow.h"
50#include "AliMpVRowSegment.h"
51#include "AliMpMotifMap.h"
52#include "AliMpMotifPosition.h"
ba030c0e 53
e118b27e 54#include "AliRun.h"
55#include "AliMagF.h"
56#include "AliLog.h"
57
d1cd2474 58#include "AliMUONSt1GeometryBuilderV2.h"
59#include "AliMUONSt1SpecialMotif.h"
60#include "AliMUON.h"
b7ef3c96 61#include "AliMUONConstants.h"
e118b27e 62#include "AliMUONGeometryModule.h"
a432117a 63#include "AliMUONGeometryEnvelopeStore.h"
ba030c0e 64
d1cd2474 65ClassImp(AliMUONSt1GeometryBuilderV2)
ba030c0e 66
5f91c9e8 67// Thickness Constants
d1cd2474 68const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzPadPlane=0.0148/2.; //Pad plane
1c4b9c4c 69const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzFoam = 2.503/2.; //Foam of mechanicalplane
70const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzFR4 = 0.062/2.; //FR4 of mechanical plane
d1cd2474 71const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzSnPb = 0.0091/2.; //Pad/Kapton connection (66 pt)
72const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzKapton = 0.0122/2.; //Kapton
73const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzBergPlastic = 0.3062/2.;//Berg connector
74const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzBergCopper = 0.1882/2.; //Berg connector
75const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzDaughter = 0.0156/2.; //Daughter board
b367fd8f 76const GReal_t AliMUONSt1GeometryBuilderV2::fgkHzGas = 0.42/2.; //Gas thickness
5f91c9e8 77
78// Quadrant Mother volume - TUBS1 - Middle layer of model
d1cd2474 79const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherIR1 = 18.3;
80const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherOR1 = 105.673;
81const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherThick1 = 6.5/2;
82const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherPhiL1 = 0.;
83const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherPhiU1 = 90.;
5f91c9e8 84
85// Quadrant Mother volume - TUBS2 - near and far layers of model
d1cd2474 86const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherIR2 = 20.7;
87const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherOR2 = 100.073;
88const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherThick2 = 3.0/2;
89const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherPhiL2 = 0.;
90const GReal_t AliMUONSt1GeometryBuilderV2::fgkMotherPhiU2 = 90.;
5f91c9e8 91
92// Sensitive copper pads, foam layer, PCB and electronics model parameters
d1cd2474 93const GReal_t AliMUONSt1GeometryBuilderV2::fgkHxHole=1.5/2.;
94const GReal_t AliMUONSt1GeometryBuilderV2::fgkHyHole=6./2.;
95const GReal_t AliMUONSt1GeometryBuilderV2::fgkHxBergPlastic=0.74/2.;
96const GReal_t AliMUONSt1GeometryBuilderV2::fgkHyBergPlastic=5.09/2.;
97const GReal_t AliMUONSt1GeometryBuilderV2::fgkHxBergCopper=0.25/2.;
98const GReal_t AliMUONSt1GeometryBuilderV2::fgkHyBergCopper=3.6/2.;
99const GReal_t AliMUONSt1GeometryBuilderV2::fgkHxKapton=0.8/2.;
100const GReal_t AliMUONSt1GeometryBuilderV2::fgkHyKapton=5.7/2.;
101const GReal_t AliMUONSt1GeometryBuilderV2::fgkHxDaughter=2.3/2.;
102const GReal_t AliMUONSt1GeometryBuilderV2::fgkHyDaughter=6.3/2.;
103const GReal_t AliMUONSt1GeometryBuilderV2::fgkOffsetX=1.46;
104const GReal_t AliMUONSt1GeometryBuilderV2::fgkOffsetY=0.71;
105const GReal_t AliMUONSt1GeometryBuilderV2::fgkDeltaFilleEtamX=1.46;
106const GReal_t AliMUONSt1GeometryBuilderV2::fgkDeltaFilleEtamY=0.051;
107
108const GReal_t AliMUONSt1GeometryBuilderV2::fgkDeltaQuadLHC=2.6; // LHC Origin wrt Quadrant Origin
b367fd8f 109const GReal_t AliMUONSt1GeometryBuilderV2::fgkFrameOffset=5.2;
110 // Fix (1) of overlap SQN* layers with SQM* ones (was 5.0)
111
112// Pad planes offsets
113const GReal_t AliMUONSt1GeometryBuilderV2::fgkPadXOffsetBP = 0.50 - 0.63/2; // = 0.185
114const GReal_t AliMUONSt1GeometryBuilderV2::fgkPadYOffsetBP = -0.31 - 0.42/2; // =-0.52
d1cd2474 115
116const char* AliMUONSt1GeometryBuilderV2::fgkHoleName="MCHL";
117const char* AliMUONSt1GeometryBuilderV2::fgkDaughterName="MCDB";
118const char AliMUONSt1GeometryBuilderV2::fgkFoamLayerSuffix='F'; // prefix for automatic volume naming
b367fd8f 119const char* AliMUONSt1GeometryBuilderV2::fgkQuadrantEnvelopeName="SE";
d1cd2474 120const char* AliMUONSt1GeometryBuilderV2::fgkQuadrantMLayerName="SQM";
121const char* AliMUONSt1GeometryBuilderV2::fgkQuadrantNLayerName="SQN";
122const char* AliMUONSt1GeometryBuilderV2::fgkQuadrantFLayerName="SQF";
e8c253a0 123const Int_t AliMUONSt1GeometryBuilderV2::fgkDaughterCopyNoOffset=1000;
5f91c9e8 124
125//______________________________________________________________________________
d1cd2474 126AliMUONSt1GeometryBuilderV2::AliMUONSt1GeometryBuilderV2(AliMUON* muon)
b7ef3c96 127 : AliMUONVGeometryBuilder(0, 1),
d1cd2474 128 fMUON(muon)
ba030c0e 129{
5f91c9e8 130 // set path to mapping data files
131 if (! gSystem->Getenv("MINSTALL")) {
132 TString dirPath = gSystem->Getenv("ALICE_ROOT");
133 dirPath += "/MUON/mapping";
3d16af90 134 AliMpFiles::SetTopPath(dirPath);
5f91c9e8 135 gSystem->Setenv("MINSTALL", dirPath.Data());
136 //cout << "AliMpFiles top path set to " << dirPath << endl;
137 }
138 //else
d1cd2474 139 // cout << gSystem->Getenv("MINSTALL") << endl;
ba030c0e 140}
141
5f91c9e8 142//______________________________________________________________________________
d1cd2474 143AliMUONSt1GeometryBuilderV2::AliMUONSt1GeometryBuilderV2()
144 : AliMUONVGeometryBuilder(),
145 fMUON(0)
ba030c0e 146{
d1cd2474 147// Default Constructor
148// --
ba030c0e 149}
150
5f91c9e8 151//______________________________________________________________________________
d1cd2474 152AliMUONSt1GeometryBuilderV2::AliMUONSt1GeometryBuilderV2(const AliMUONSt1GeometryBuilderV2& rhs)
153 : AliMUONVGeometryBuilder(rhs)
ba030c0e 154{
155// Dummy copy constructor
d1cd2474 156
8c343c7c 157 AliFatal("Copy constructor is not implemented.");
ba030c0e 158}
159
5f91c9e8 160//______________________________________________________________________________
d1cd2474 161AliMUONSt1GeometryBuilderV2::~AliMUONSt1GeometryBuilderV2()
ba030c0e 162{
163// Destructor
ba030c0e 164}
165
d1cd2474 166
167//______________________________________________________________________________
168AliMUONSt1GeometryBuilderV2&
169AliMUONSt1GeometryBuilderV2::operator = (const AliMUONSt1GeometryBuilderV2& rhs)
170{
171 // check assignement to self
172 if (this == &rhs) return *this;
173
8c343c7c 174 AliFatal("Assignment operator is not implemented.");
d1cd2474 175
176 return *this;
177}
178
5f91c9e8 179//
180// Private methods
181//
182
183//______________________________________________________________________________
b367fd8f 184TString
185AliMUONSt1GeometryBuilderV2::QuadrantEnvelopeName(Int_t chamber, Int_t quadrant) const
186{
187// Generate unique envelope name from chamber Id and quadrant number
188// ---
189
190 return Form("%s%d", Form("%s%d",fgkQuadrantEnvelopeName,chamber), quadrant);
191}
192
193//______________________________________________________________________________
d1cd2474 194void AliMUONSt1GeometryBuilderV2::CreateHole()
ba030c0e 195{
5f91c9e8 196// Create all the elements found inside a foam hole
ba030c0e 197// --
d1cd2474 198 Int_t* idtmed = fMUON->GetIdtmed()->GetArray()-1099;
199 Int_t idAir = idtmed[1100]; // medium 1
200 //Int_t idCopper = idtmed[1109]; // medium 10 = copper
201 Int_t idCopper = idtmed[1121]; // medium 22 = copper
ba030c0e 202
5f91c9e8 203 GReal_t par[3];
204 GReal_t posX,posY,posZ;
205
206 par[0] = fgkHxHole;
207 par[1] = fgkHyHole;
208 par[2] = fgkHzFoam;
209 gMC->Gsvolu(fgkHoleName,"BOX",idAir,par,3);
210
211 par[0] = fgkHxKapton;
212 par[1] = fgkHyKapton;
213 par[2] = fgkHzSnPb;
214 gMC->Gsvolu("SNPB", "BOX", idCopper, par, 3);
215 posX = 0.;
216 posY = 0.;
217 posZ = -fgkHzFoam+fgkHzSnPb;
218 gMC->Gspos("SNPB",1,fgkHoleName, posX, posY, posZ, 0,"ONLY");
ba030c0e 219
5f91c9e8 220 par[0] = fgkHxHole;
221 par[1] = fgkHyBergPlastic;
222 par[2] = fgkHzKapton;
223 gMC->Gsvolu("KAPT", "BOX", idCopper, par, 3);
224 posX = 0.;
225 posY = 0.;
226 posZ = 0.;
227 gMC->Gspos("KAPT",1,fgkHoleName, posX, posY, posZ, 0,"ONLY");
228}
ba030c0e 229
5f91c9e8 230//______________________________________________________________________________
d1cd2474 231void AliMUONSt1GeometryBuilderV2::CreateDaughterBoard()
5f91c9e8 232{
233// Create all the elements in a daughter board
234// --
d1cd2474 235 Int_t* idtmed = fMUON->GetIdtmed()->GetArray()-1099;
5f91c9e8 236 Int_t idAir = idtmed[1100]; // medium 1
d1cd2474 237 //Int_t idCopper = idtmed[1109]; // medium 10 = copper
238 //Int_t idPlastic =idtmed[1116]; // medium 17 = Plastic
239 Int_t idCopper = idtmed[1121]; // medium 22 = copper
240 Int_t idPlastic =idtmed[1127]; // medium 28 = Plastic
ba030c0e 241
5f91c9e8 242 GReal_t par[3];
243 GReal_t posX,posY,posZ;
ba030c0e 244
5f91c9e8 245 par[0]=fgkHxDaughter;
246 par[1]=fgkHyDaughter;
247 par[2]=TotalHzDaughter();
248 gMC->Gsvolu(fgkDaughterName,"BOX",idAir,par,3);
ba030c0e 249
5f91c9e8 250 par[0]=fgkHxBergPlastic;
251 par[1]=fgkHyBergPlastic;
252 par[2]=fgkHzBergPlastic;
253 gMC->Gsvolu("BRGP","BOX",idPlastic,par,3);
254 posX=0.;
255 posY=0.;
256 posZ = -TotalHzDaughter() + fgkHzBergPlastic;
257 gMC->Gspos("BRGP",1,fgkDaughterName,posX,posY,posZ,0,"ONLY");
258
259 par[0]=fgkHxBergCopper;
260 par[1]=fgkHyBergCopper;
261 par[2]=fgkHzBergCopper;
262 gMC->Gsvolu("BRGC","BOX",idCopper,par,3);
263 posX=0.;
264 posY=0.;
265 posZ=0.;
266 gMC->Gspos("BRGC",1,"BRGP",posX,posY,posZ,0,"ONLY");
267
268 par[0]=fgkHxDaughter;
269 par[1]=fgkHyDaughter;
270 par[2]=fgkHzDaughter;
271 gMC->Gsvolu("DGHT","BOX",idCopper,par,3);
272 posX=0.;
273 posY=0.;
274 posZ = -TotalHzDaughter() + 2.*fgkHzBergPlastic + fgkHzDaughter;
275 gMC->Gspos("DGHT",1,fgkDaughterName,posX,posY,posZ,0,"ONLY");
276}
277
278//______________________________________________________________________________
d1cd2474 279void AliMUONSt1GeometryBuilderV2::CreateInnerLayers()
5f91c9e8 280{
281// Create the layer of sensitive volumes with gas
282// and the copper layer.
283// --
284
285// Gas Medium
d1cd2474 286 Int_t* idtmed = fMUON->GetIdtmed()->GetArray()-1099;
287 //Int_t idArCO2 = idtmed[1108]; // medium 9 (ArCO2 80%)
288 //Int_t idCopper = idtmed[1109]; // medium 10 = copper
289 Int_t idArCO2 = idtmed[1124]; // medium 25 (ArCO2 80%)
290 Int_t idCopper = idtmed[1121]; // medium 22 = copper
5f91c9e8 291
292 Float_t par[11];
293
294//Make gas volume - composed of 11 trapezoids
295// section 1 of 11
296 par[0] = fgkHzGas;
297 par[1] = 0.;
298 par[2] = 0.;
299 par[3] = 71.33/2.;
300 par[4] = 9.76/2.;
301 par[5] = 48.77/2.;
302 par[6] = 15.3;
303 par[7] = 71.33/2.;
304 par[8] = 9.76/2.;
305 par[9] = 48.77/2.;
306 par[10] = 15.3;
307
308 gMC->Gsvolu("SA1G", "TRAP", idArCO2, par, 11);
309 gMC->Gsvolu("SA2G", "TRAP", idArCO2, par, 11);
ba030c0e 310
5f91c9e8 311 par[0] = fgkHzPadPlane;
312 gMC->Gsvolu("SA1C", "TRAP", idCopper,par, 11);
313
314// section 2 of 11
315 par[0] = fgkHzGas;
316 par[1] = 0.;
317 par[2] = 0.;
318 par[3] = 79.68/2.;
319 par[4] = 10.4/2.;
320 par[5] = 57.0/2.;
321 par[6] = 0.;
322 par[7] = 79.68/2.;
323 par[8] = 10.4/2.;
324 par[9] = 57.0/2.;
325 par[10] = 0.;
326 gMC->Gsvolu("SB1G", "TRAP", idArCO2, par, 11);
327 gMC->Gsvolu("SB2G", "TRAP", idArCO2, par, 11);
328
329 par[0] = fgkHzPadPlane;
330 gMC->Gsvolu("SB1C", "TRAP", idCopper,par, 11);
331
332// section 3 of 11
333 par[0] = fgkHzGas;
334 par[1] = 0.;
335 par[2] = 0.;
336 par[3] = 71.33/2.;
337 par[4] = 48.77/2.;
338 par[5] = 9.73/2.;
339 par[6] = -15.3;
340 par[7] = 71.33/2.;
341 par[8] = 48.77/2.;
342 par[9] = 9.73/2.;
343 par[10] = -15.3;
344
345 gMC->Gsvolu("SC1G", "TRAP", idArCO2, par, 11);
346 gMC->Gsvolu("SC2G", "TRAP", idArCO2, par, 11);
347
348 par[0] = fgkHzPadPlane;
349 gMC->Gsvolu("SC1C", "TRAP", idCopper,par, 11);
350
351// section 4 of 11
352 par[0] = fgkHzGas;
353 par[1] = 0.;
354 par[2] = 0.;
355 par[3] = 6.00/2.;
356 par[4] = 0.;
357 par[5] = 1.56/2.;
358 par[6] = 7.41;
359 par[7] = 6.00/2.;
360 par[8] = 0.;
361 par[9] = 1.56/2.;
362 par[10] = 7.41;
363 gMC->Gsvolu("SD1G", "TRAP", idArCO2, par, 11);
364 gMC->Gsvolu("SD2G", "TRAP", idArCO2, par, 11);
365
366 par[0] = fgkHzPadPlane;
367 gMC->Gsvolu("SD1C", "TRAP", idCopper,par, 11);
368
369// section 5 of 11
370 par[0] = fgkHzGas;
371 par[1] = 0.;
372 par[2] = 0.;
373 par[3] = 1.516/2.;
374 par[4] = 0.;
375 par[5] = 0.829/2.;
376 par[6] = 15.3;
377 par[7] = 1.516/2.;
378 par[8] = 0.;
379 par[9] = 0.829/2.;
380 par[10] = 15.3;
381 gMC->Gsvolu("SE1G", "TRAP", idArCO2, par, 11);
382 gMC->Gsvolu("SE2G", "TRAP", idArCO2, par, 11);
383
384 par[0] = fgkHzPadPlane;
385 gMC->Gsvolu("SE1C", "TRAP", idCopper,par, 11);
386
387// section 6 of 11
388 par[0] = fgkHzGas;
389 par[1] = 0.;
390 par[2] = 0.;
391 par[3] = 3.92/2.;
392 par[4] = 0.;
393 par[5] = 0.562/2.;
394 par[6] = -4.1;
395 par[7] = 3.92/2.;
396 par[8] = 0.;
397 par[9] = 0.562/2.;
398 par[10] = -4.1;
399 gMC->Gsvolu("SF1G", "TRAP", idArCO2, par, 11);
400 gMC->Gsvolu("SF2G", "TRAP", idArCO2, par, 11);
401
402 par[0] = fgkHzPadPlane;
403 gMC->Gsvolu("SF1C", "TRAP", idCopper,par, 11);
404
405// section 7 of 11
406 par[0] = fgkHzGas;
407 par[1] = 0.;
408 par[2] = 0.;
409 par[3] = 0.941/2.;
410 par[4] = 0.562/2.;
411 par[5] = 0.;
412 par[6] = -16.6;
413 par[7] = 0.941/2.;
414 par[8] = 0.562/2.;
415 par[9] = 0.;
416 par[10] =-16.6;
417 gMC->Gsvolu("SG1G", "TRAP", idArCO2, par, 11);
418 gMC->Gsvolu("SG2G", "TRAP", idArCO2, par, 11);
419
420 par[0] = fgkHzPadPlane;
421 gMC->Gsvolu("SG1C", "TRAP", idCopper,par, 11);
422
423// section 8 of 11
424 par[0] = fgkHzGas;
425 par[1] = 0.;
426 par[2] = 0.;
427 par[3] = 3.94/2.;
428 par[4] = 0.57/2.;
429 par[5] = 0.;
430 par[6] = 4.14;
431 par[7] = 3.94/2.;
432 par[8] = 0.57/2.;
433 par[9] = 0.;
434 par[10] = 4.14;
435 gMC->Gsvolu("SH1G", "TRAP", idArCO2, par, 11);
436 gMC->Gsvolu("SH2G", "TRAP", idArCO2, par, 11);
437
438 par[0] = fgkHzPadPlane;
439 gMC->Gsvolu("SH1C", "TRAP", idCopper,par, 11);
440
441// section 9 of 11
442 par[0] = fgkHzGas;
443 par[1] = 0.;
444 par[2] = 0.;
445 par[3] = 0.95/2.;
446 par[4] = 0.;
447 par[5] = 0.57/2;
448 par[6] = 16.7;
449 par[7] = 0.95/2.;
450 par[8] = 0.;
451 par[9] = 0.57/2;
452 par[10] = 16.7;
453 gMC->Gsvolu("SI1G", "TRAP", idArCO2, par, 11);
454 gMC->Gsvolu("SI2G", "TRAP", idArCO2, par, 11);
455
456 par[0] = fgkHzPadPlane;
457 gMC->Gsvolu("SI1C", "TRAP", idCopper,par, 11);
458
459// section 10 of 11
460 par[0] = fgkHzGas;
461 par[1] = 0.;
462 par[2] = 0.;
463 par[3] = 1.49/2.;
464 par[4] = 0.;
465 par[5] = 0.817/2.;
466 par[6] = -15.4;
467 par[7] = 1.49/2.;
468 par[8] = 0.;
469 par[9] = 0.817/2.;
470 par[10] = -15.4;
471 gMC->Gsvolu("SJ1G", "TRAP", idArCO2, par, 11);
472 gMC->Gsvolu("SJ2G", "TRAP", idArCO2, par, 11);
473
474 par[0] = fgkHzPadPlane;
475 gMC->Gsvolu("SJ1C", "TRAP", idCopper,par, 11);
476
477// section 11 of 11
478 par[0] = fgkHzGas;
479 par[1] = 0.;
480 par[2] = 0.;
481 par[3] = 5.93/2.;
482 par[4] = 0.;
483 par[5] = 1.49/2.;
484 par[6] = -7.16;
485 par[7] = 5.93/2.;
486 par[8] = 0.;
487 par[9] = 1.49/2.;
488 par[10] = -7.16;
489 gMC->Gsvolu("SK1G", "TRAP", idArCO2, par, 11);
490 gMC->Gsvolu("SK2G", "TRAP", idArCO2, par, 11);
491
492 par[0] = fgkHzPadPlane;
493 gMC->Gsvolu("SK1C", "TRAP", idCopper,par, 11);
ba030c0e 494}
5f91c9e8 495
496//______________________________________________________________________________
d1cd2474 497void AliMUONSt1GeometryBuilderV2::CreateQuadrant(Int_t chamber)
ba030c0e 498{
499// create the quadrant (bending and non-bending planes)
500// for the given chamber
501// --
5f91c9e8 502
ba030c0e 503 CreateFrame(chamber);
504
d1cd2474 505#ifdef ST1_WITH_STL
506 SpecialMap specialMap;
e8c253a0 507 specialMap[76] = AliMUONSt1SpecialMotif(TVector2( 0.1, 0.84), 90.);
508 specialMap[75] = AliMUONSt1SpecialMotif(TVector2( 0.5, 0.36));
509 specialMap[47] = AliMUONSt1SpecialMotif(TVector2(1.01, 0.36));
d1cd2474 510#endif
511
512#ifdef ST1_WITH_ROOT
513 SpecialMap specialMap;
e8c253a0 514 specialMap.Add(76, (Long_t) new AliMUONSt1SpecialMotif(TVector2( 0.1, 0.84), 90.));
515 specialMap.Add(75, (Long_t) new AliMUONSt1SpecialMotif(TVector2( 0.5, 0.36)));
516 specialMap.Add(47, (Long_t) new AliMUONSt1SpecialMotif(TVector2(1.01, 0.36)));
d1cd2474 517#endif
518
ab126d0a 519 AliMpSectorReader reader1(kStation1, kBendingPlane);
5f91c9e8 520 AliMpSector* sector1 = reader1.BuildSector();
ba030c0e 521
b367fd8f 522 //Bool_t reflectZ = true;
523 Bool_t reflectZ = false;
524 //TVector3 where = TVector3(2.5+0.1+0.56+0.001, 2.5+0.1+0.001, 0.);
525 TVector3 where = TVector3(fgkDeltaQuadLHC + fgkPadXOffsetBP,
526 fgkDeltaQuadLHC + fgkPadYOffsetBP, 0.);
5f91c9e8 527 PlaceSector(sector1, specialMap, where, reflectZ, chamber);
ba030c0e 528
d1cd2474 529#ifdef ST1_WITH_STL
ba030c0e 530 specialMap.clear();
e8c253a0 531 specialMap[76] = AliMUONSt1SpecialMotif(TVector2(1.01,0.59),90.);
532 specialMap[75] = AliMUONSt1SpecialMotif(TVector2(1.96, 0.17));
b367fd8f 533 specialMap[47] = AliMUONSt1SpecialMotif(TVector2(2.18,-0.98));
e8c253a0 534 specialMap[20] = AliMUONSt1SpecialMotif(TVector2(0.2 ,-0.08));
535 specialMap[46] = AliMUONSt1SpecialMotif(TVector2(0.2 , 0.25));
536 specialMap[74] = AliMUONSt1SpecialMotif(TVector2(0.28, 0.21));
b367fd8f 537 // Fix (7) - overlap of SQ42 with MCHL (after moving the whole sector
538 // in the true position)
539 // Was: specialMap[47] = AliMUONSt1SpecialMotif(TVector2(1.61,-1.18));
d1cd2474 540#endif
541
542#ifdef ST1_WITH_ROOT
543 specialMap.Delete();
e8c253a0 544 specialMap.Add(76,(Long_t) new AliMUONSt1SpecialMotif(TVector2(1.01,0.59),90.));
545 specialMap.Add(75,(Long_t) new AliMUONSt1SpecialMotif(TVector2(1.96, 0.17)));
b367fd8f 546 specialMap.Add(47,(Long_t) new AliMUONSt1SpecialMotif(TVector2(2.18,-0.98)));
e8c253a0 547 specialMap.Add(20,(Long_t) new AliMUONSt1SpecialMotif(TVector2(0.2 ,-0.08)));
548 specialMap.Add(46,(Long_t) new AliMUONSt1SpecialMotif(TVector2(0.2 , 0.25)));
b367fd8f 549 specialMap.Add(74,(Long_t) new AliMUONSt1SpecialMotif(TVector2(0.28, 0.21)));
550 // Fix (7) - overlap of SQ42 with MCHL (after moving the whole sector
551 // in the true position)
552 // Was: specialMap.Add(47,(Long_t) new AliMUONSt1SpecialMotif(TVector2(1.61,-1.18)));
d1cd2474 553#endif
554
ab126d0a 555 AliMpSectorReader reader2(kStation1, kNonBendingPlane);
5f91c9e8 556 AliMpSector* sector2 = reader2.BuildSector();
b367fd8f 557
558 //reflectZ = false;
559 reflectZ = true;
ab126d0a 560 TVector2 offset = sector2->Position();
e77b6d6b 561 where = TVector3(where.X()+offset.X(), where.Y()+offset.Y(), 0.);
b367fd8f 562 // Add the half-pad shift of the non-bending plane wrt bending plane
563 // (The shift is defined in the mapping as sector offset)
564 // Fix (4) - was TVector3(where.X()+0.63/2, ... - now it is -0.63/2
5f91c9e8 565 PlaceSector(sector2, specialMap, where, reflectZ, chamber);
d1cd2474 566
567#ifdef ST1_WITH_ROOT
568 specialMap.Delete();
569#endif
ba030c0e 570}
571
5f91c9e8 572//______________________________________________________________________________
d1cd2474 573void AliMUONSt1GeometryBuilderV2::CreateFoamBox(const char* name,const TVector2& dimensions)
ba030c0e 574{
5f91c9e8 575// create all the elements in the copper plane
576// --
ba030c0e 577
d1cd2474 578 Int_t* idtmed = fMUON->GetIdtmed()->GetArray()-1099;
5f91c9e8 579 Int_t idAir = idtmed[1100]; // medium 1
d1cd2474 580 //Int_t idFoam = idtmed[1115]; // medium 16 = Foam
581 //Int_t idFR4 = idtmed[1114]; // medium 15 = FR4
582 Int_t idFoam = idtmed[1125]; // medium 26 = Foam
583 Int_t idFR4 = idtmed[1122]; // medium 23 = FR4
ba030c0e 584
5f91c9e8 585 // mother volume
586 GReal_t par[3];
587 par[0] = dimensions.X();
588 par[1] = dimensions.Y();
589 par[2] = TotalHzPlane();
590 gMC->Gsvolu(name,"BOX",idAir,par,3);
591
592 // foam layer
593 GReal_t posX,posY,posZ;
594 char eName[5];
595 strcpy(eName,name);
596 eName[3]=fgkFoamLayerSuffix;
597 par[0] = dimensions.X();
598 par[1] = dimensions.Y();
599 par[2] = fgkHzFoam;
600 gMC->Gsvolu(eName,"BOX",idFoam,par,3);
601 posX=0.;
602 posY=0.;
603 posZ = -TotalHzPlane() + fgkHzFoam;
604 gMC->Gspos(eName,1,name,posX,posY,posZ,0,"ONLY");
ba030c0e 605
5f91c9e8 606 // mechanical plane FR4 layer
607 eName[3]='R';
608 par[0] = dimensions.X();
609 par[1] = dimensions.Y();
610 par[2] = fgkHzFR4;
611 gMC->Gsvolu(eName,"BOX",idFR4,par,3);
612 posX=0.;
613 posY=0.;
614 posZ = -TotalHzPlane()+ 2.*fgkHzFoam + fgkHzFR4;
615 gMC->Gspos(eName,1,name,posX,posY,posZ,0,"ONLY");
616}
ba030c0e 617
5f91c9e8 618//______________________________________________________________________________
d1cd2474 619void AliMUONSt1GeometryBuilderV2::CreatePlaneSegment(const char* name,const TVector2& dimensions,
5f91c9e8 620 Int_t nofHoles)
621{
622// Create a segment of a plane (this includes a foam layer,
623// holes in the foam to feed the kaptons through, kapton connectors
624// and the mother board.)
625// --
ba030c0e 626
5f91c9e8 627 CreateFoamBox(name,dimensions);
ba030c0e 628
5f91c9e8 629 char eName[5];
630 strcpy(eName,name);
631 eName[3]=fgkFoamLayerSuffix;
ba030c0e 632
5f91c9e8 633 for (Int_t holeNum=0;holeNum<nofHoles;holeNum++) {
634 GReal_t posX = ((2.*holeNum+1.)/nofHoles-1.)*dimensions.X();
635 GReal_t posY = 0.;
636 GReal_t posZ = 0.;
ba030c0e 637
5f91c9e8 638 gMC->Gspos(fgkHoleName,holeNum+1,eName,posX,posY,posZ,0,"ONLY");
639 }
ba030c0e 640}
641
5f91c9e8 642//______________________________________________________________________________
d1cd2474 643void AliMUONSt1GeometryBuilderV2::CreateFrame(Int_t chamber)
ba030c0e 644{
645// Create the non-sensitive elements of the frame for the <chamber>
5f91c9e8 646//
647//
648// Model and notation:
649//
650// The Quadrant volume name starts with SQ
651// The volume segments are numbered 00 to XX.
652//
653// OutTopFrame
654// (SQ02-16)
655// ------------
656// OutEdgeFrame / |
657// (SQ17-24) / | InVFrame (SQ00-01)
658// / |
659// | |
660// OutVFrame | _- -
661// (SQ25-39) | | InArcFrame (SQ42-45)
662// | |
663// -------------
664// InHFrame (SQ40-41)
665//
666//
667// 06 February 2003 - Overlapping volumes resolved.
668// One quarter chamber is comprised of three TUBS volumes: SQMx, SQNx, and SQFx,
669// where SQMx is the Quadrant Middle layer for chamber <x> ( posZ in [-3.25,3.25]),
670// SQNx is the Quadrant Near side layer for chamber <x> ( posZ in [-6.25,3-.25) ), and
671// SQFx is the Quadrant Far side layer for chamber <x> ( posZ in (3.25,6.25] ).
672//---
ba030c0e 673
d1cd2474 674 const Float_t kNearFarLHC=2.4; // Near and Far TUBS Origin wrt LHC Origin
ba030c0e 675
ba030c0e 676 // tracking medias
d1cd2474 677 Int_t* idtmed = fMUON->GetIdtmed()->GetArray()-1099;
5f91c9e8 678
ba030c0e 679 Int_t idAir = idtmed[1100]; // medium 1
d1cd2474 680 //Int_t idFrameEpoxy = idtmed[1115]; // medium 16 = Frame Epoxy ME730
681 //Int_t idInox = idtmed[1116]; // medium 17 Stainless Steel (18%Cr,9%Ni,Fe)
682 //Int_t idFR4 = idtmed[1110]; // medium 11 FR4
683 //Int_t idCopper = idtmed[1109]; // medium 10 Copper
684 //Int_t idAlu = idtmed[1103]; // medium 4 Aluminium
685 Int_t idFrameEpoxy = idtmed[1123]; // medium 24 = Frame Epoxy ME730 // was 20 not 16
686 Int_t idInox = idtmed[1128]; // medium 29 Stainless Steel (18%Cr,9%Ni,Fe) // was 21 not 17
687 Int_t idFR4 = idtmed[1122]; // medium 23 FR4 // was 15 not 11
688 Int_t idCopper = idtmed[1121]; // medium 22 Copper
689 Int_t idAlu = idtmed[1120]; // medium 21 Aluminium
5f91c9e8 690
691
692// Rotation Matrices
693 Int_t rot1, rot2, rot3;
694
695// Rotation matrices
d1cd2474 696 fMUON->AliMatrix(rot1, 90., 90., 90., 180., 0., 0.); // +90 deg in x-y plane
697 fMUON->AliMatrix(rot2, 90., 45., 90., 135., 0., 0.); // +45 deg in x-y plane
698 fMUON->AliMatrix(rot3, 90., 45., 90., 315.,180., 0.); // +45 deg in x-y + rotation 180° around y
5f91c9e8 699
700// Translation matrices ... NOT USED
d1cd2474 701// fMUON->AliMatrix(trans1, 90., 0., 90., 90., 0., 0.); // X-> X; Y -> Y; Z -> Z
702// fMUON->AliMatrix(trans2, 90., 180., 90., 90., 180., 0.); // X->-X; Y -> Y; Z ->-Z
703// fMUON->AliMatrix(trans3, 90., 180., 90., 270., 0., 0.); // X->-X; Y ->-Y; Z -> Z
704// fMUON->AliMatrix(trans4, 90., 0., 90., 270., 180., 0.); // X-> X; Y ->-Y; Z ->-Z
ba030c0e 705//
5f91c9e8 706 // ___________________Volume thicknesses________________________
ba030c0e 707
d1cd2474 708 const Float_t kHzFrameThickness = 1.59/2.; //equivalent thickness
709 const Float_t kHzOuterFrameEpoxy = 1.19/2.; //equivalent thickness
710 const Float_t kHzOuterFrameInox = 0.1/2.; //equivalent thickness
711 const Float_t kHzFoam = 2.083/2.; //evaluated elsewhere
712 // CHECK with fgkHzFoam
5f91c9e8 713
714// Pertaining to the top outer area
d1cd2474 715 const Float_t kHzTopAnodeSteel1 = 0.185/2.; //equivalent thickness
716 const Float_t kHzTopAnodeSteel2 = 0.51/2.; //equivalent thickness
717 const Float_t kHzAnodeFR4 = 0.08/2.; //equivalent thickness
718 const Float_t kHzTopEarthFaceCu = 0.364/2.; //equivalent thickness
719 const Float_t kHzTopEarthProfileCu = 1.1/2.; //equivalent thickness
720 const Float_t kHzTopPositionerSteel = 1.45/2.; //should really be 2.125/2.;
721 const Float_t kHzTopGasSupportAl = 0.85/2.; //equivalent thickness
5f91c9e8 722
723// Pertaining to the vertical outer area
d1cd2474 724 const Float_t kHzVerticalCradleAl = 0.8/2.; //equivalent thickness
725 const Float_t kHzLateralSightAl = 0.975/2.; //equivalent thickness
726 const Float_t kHzLateralPosnInoxFace = 2.125/2.;//equivalent thickness
727 const Float_t kHzLatPosInoxProfM = 6.4/2.; //equivalent thickness
728 const Float_t kHzLatPosInoxProfNF = 1.45/2.; //equivalent thickness
729 const Float_t kHzLateralPosnAl = 0.5/2.; //equivalent thickness
730 const Float_t kHzVertEarthFaceCu = 0.367/2.; //equivalent thickness
731 const Float_t kHzVertBarSteel = 0.198/2.; //equivalent thickness
732 const Float_t kHzVertEarthProfCu = 1.1/2.; //equivalent thickness
5f91c9e8 733
734 //_______________Parameter definitions in sequence _________
735
736// InVFrame parameters
d1cd2474 737 const Float_t kHxInVFrame = 1.85/2.;
738 const Float_t kHyInVFrame = 73.95/2.;
739 const Float_t kHzInVFrame = kHzFrameThickness;
ba030c0e 740
5f91c9e8 741//Flat 7.5mm vertical section
d1cd2474 742 const Float_t kHxV1mm = 0.75/2.;
743 const Float_t kHyV1mm = 1.85/2.;
744 const Float_t kHzV1mm = kHzFrameThickness;
ba030c0e 745
5f91c9e8 746// OuterTopFrame Structure
747//
748// FRAME
749// The frame is composed of a cuboid and two trapezoids
750// (TopFrameAnode, TopFrameAnodeA, TopFrameAnodeB).
751// Each shape is composed of two layers (Epoxy and Inox) and
752// takes the frame's inner anode circuitry into account in the material budget.
753//
754// ANODE
755// The overhanging anode part is composed froma cuboid and two trapezoids
756// (TopAnode, TopAnode1, and TopAnode2). These surfaces neglect implanted
757// resistors, but accounts for the major Cu, Pb/Sn, and FR4 material
758// contributions.
759// The stainless steel anode supports have been included.
760//
761// EARTHING (TopEarthFace, TopEarthProfile)
762// Al GAS SUPPORT (TopGasSupport)
763//
764// ALIGNMENT (TopPositioner) - Alignment system, three sights per quarter
765// chamber. This sight is forseen for the alignment of the horizontal level
766// (parallel to the OY axis of LHC). Its position will be evaluated relative
767// to a system of sights places on the cradles;
768//
769//---
ba030c0e 770
5f91c9e8 771//TopFrameAnode parameters - cuboid, 2 layers
d1cd2474 772 const Float_t kHxTFA = 34.1433/2.;
773 const Float_t kHyTFA = 7.75/2.;
774 const Float_t kHzTFAE = kHzOuterFrameEpoxy; // layer 1 thickness
775 const Float_t kHzTFAI = kHzOuterFrameInox; // layer 3 thickness
ba030c0e 776
5f91c9e8 777// TopFrameAnodeA parameters - trapezoid, 2 layers
d1cd2474 778 const Float_t kHzFAAE = kHzOuterFrameEpoxy; // layer 1 thickness
779 const Float_t kHzFAAI = kHzOuterFrameInox; // layer 3 thickness
780 const Float_t kTetFAA = 0.;
781 const Float_t kPhiFAA = 0.;
782 const Float_t kH1FAA = 8.7/2.;
783 const Float_t kBl1FAA = 4.35/2.;
784 const Float_t kTl1FAA = 7.75/2.;
785 const Float_t kAlp1FAA = 11.06;
786 const Float_t kH2FAA = 8.7/2.;
787 const Float_t kBl2FAA = 4.35/2.;
788 const Float_t kTl2FAA = 7.75/2.;
789 const Float_t kAlp2FAA = 11.06;
ba030c0e 790
5f91c9e8 791// TopFrameAnodeB parameters - trapezoid, 2 layers
d1cd2474 792 const Float_t kHzFABE = kHzOuterFrameEpoxy; // layer 1 thickness
793 const Float_t kHzFABI = kHzOuterFrameInox; // layer 3 thickness
794 const Float_t kTetFAB = 0.;
795 const Float_t kPhiFAB = 0.;
796 const Float_t kH1FAB = 8.70/2.;
797 const Float_t kBl1FAB = 0.;
798 const Float_t kTl1FAB = 4.35/2.;
799 const Float_t kAlp1FAB = 14.03;
800 const Float_t kH2FAB = 8.70/2.;
801 const Float_t kBl2FAB = 0.;
802 const Float_t kTl2FAB = 4.35/2.;
803 const Float_t kAlp2FAB = 14.03;
ba030c0e 804
5f91c9e8 805// TopAnode parameters - cuboid (part 1 of 3 parts)
d1cd2474 806 const Float_t kHxTA1 = 16.2/2.;
807 const Float_t kHyTA1 = 3.5/2.;
808 const Float_t kHzTA11 = kHzTopAnodeSteel1; // layer 1
809 const Float_t kHzTA12 = kHzAnodeFR4; // layer 2
5f91c9e8 810
811// TopAnode parameters - trapezoid 1 (part 2 of 3 parts)
d1cd2474 812 const Float_t kHzTA21 = kHzTopAnodeSteel2; // layer 1
813 const Float_t kHzTA22 = kHzAnodeFR4; // layer 2
814 const Float_t kTetTA2 = 0.;
815 const Float_t kPhiTA2= 0.;
816 const Float_t kH1TA2 = 7.268/2.;
817 const Float_t kBl1TA2 = 2.03/2.;
818 const Float_t kTl1TA2 = 3.5/2.;
819 const Float_t kAlp1TA2 = 5.78;
820 const Float_t kH2TA2 = 7.268/2.;
821 const Float_t kBl2TA2 = 2.03/2.;
822 const Float_t kTl2TA2 = 3.5/2.;
823 const Float_t kAlp2TA2 = 5.78;
5f91c9e8 824
825// TopAnode parameters - trapezoid 2 (part 3 of 3 parts)
d1cd2474 826 const Float_t kHzTA3 = kHzAnodeFR4; // layer 1
827 const Float_t kTetTA3 = 0.;
828 const Float_t kPhiTA3 = 0.;
829 const Float_t kH1TA3 = 7.268/2.;
830 const Float_t kBl1TA3 = 0.;
831 const Float_t kTl1TA3 = 2.03/2.;
832 const Float_t kAlp1TA3 = 7.95;
833 const Float_t kH2TA3 = 7.268/2.;
834 const Float_t kBl2TA3 = 0.;
835 const Float_t kTl2TA3 = 2.03/2.;
836 const Float_t kAlp2TA3 = 7.95;
ba030c0e 837
5f91c9e8 838// TopEarthFace parameters - single trapezoid
d1cd2474 839 const Float_t kHzTEF = kHzTopEarthFaceCu;
840 const Float_t kTetTEF = 0.;
841 const Float_t kPhiTEF = 0.;
842 const Float_t kH1TEF = 1.200/2.;
843 const Float_t kBl1TEF = 21.323/2.;
844 const Float_t kTl1TEF = 17.963/2.;
845 const Float_t kAlp1TEF = -54.46;
846 const Float_t kH2TEF = 1.200/2.;
847 const Float_t kBl2TEF = 21.323/2.;
848 const Float_t kTl2TEF = 17.963/2.;
849 const Float_t kAlp2TEF = -54.46;
5f91c9e8 850
851// TopEarthProfile parameters - single trapezoid
d1cd2474 852 const Float_t kHzTEP = kHzTopEarthProfileCu;
853 const Float_t kTetTEP = 0.;
854 const Float_t kPhiTEP = 0.;
855 const Float_t kH1TEP = 0.40/2.;
856 const Float_t kBl1TEP = 31.766/2.;
857 const Float_t kTl1TEP = 30.535/2.;
858 const Float_t kAlp1TEP = -56.98;
859 const Float_t kH2TEP = 0.40/2.;
860 const Float_t kBl2TEP = 31.766/2.;
861 const Float_t kTl2TEP = 30.535/2.;
862 const Float_t kAlp2TEP = -56.98;
5f91c9e8 863
864// TopPositioner parameters - single Stainless Steel trapezoid
d1cd2474 865 const Float_t kHzTP = kHzTopPositionerSteel;
866 const Float_t kTetTP = 0.;
867 const Float_t kPhiTP = 0.;
868 const Float_t kH1TP = 3.00/2.;
869 const Float_t kBl1TP = 7.023/2.;
870 const Float_t kTl1TP = 7.314/2.;
871 const Float_t kAlp1TP = 2.78;
872 const Float_t kH2TP = 3.00/2.;
873 const Float_t kBl2TP = 7.023/2.;
874 const Float_t kTl2TP = 7.314/2.;
875 const Float_t kAlp2TP = 2.78;
5f91c9e8 876
877// TopGasSupport parameters - single cuboid
d1cd2474 878 const Float_t kHxTGS = 8.50/2.;
879 const Float_t kHyTGS = 3.00/2.;
880 const Float_t kHzTGS = kHzTopGasSupportAl;
5f91c9e8 881
882// OutEdgeFrame parameters - 4 trapezoidal sections, 2 layers of material
883//
884//---
885
886// Trapezoid 1
d1cd2474 887 const Float_t kHzOETFE = kHzOuterFrameEpoxy; // layer 1
888 const Float_t kHzOETFI = kHzOuterFrameInox; // layer 3
ba030c0e 889
d1cd2474 890 const Float_t kTetOETF = 0.; // common to all 4 trapezoids
891 const Float_t kPhiOETF = 0.; // common to all 4 trapezoids
5f91c9e8 892
d1cd2474 893 const Float_t kH1OETF = 7.196/2.; // common to all 4 trapezoids
894 const Float_t kH2OETF = 7.196/2.; // common to all 4 trapezoids
5f91c9e8 895
d1cd2474 896 const Float_t kBl1OETF1 = 3.75/2;
897 const Float_t kTl1OETF1 = 3.996/2.;
898 const Float_t kAlp1OETF1 = 0.98;
5f91c9e8 899
d1cd2474 900 const Float_t kBl2OETF1 = 3.75/2;
901 const Float_t kTl2OETF1 = 3.996/2.;
902 const Float_t kAlp2OETF1 = 0.98;
5f91c9e8 903
904// Trapezoid 2
d1cd2474 905 const Float_t kBl1OETF2 = 3.01/2.;
906 const Float_t kTl1OETF2 = 3.75/2;
907 const Float_t kAlp1OETF2 = 2.94;
5f91c9e8 908
d1cd2474 909 const Float_t kBl2OETF2 = 3.01/2.;
910 const Float_t kTl2OETF2 = 3.75/2;
911 const Float_t kAlp2OETF2 = 2.94;
5f91c9e8 912
913// Trapezoid 3
b367fd8f 914 //const Float_t kBl1OETF3 = 1.767/2.;
915 //const Float_t kTl1OETF3 = 3.01/2.;
916 const Float_t kBl1OETF3 = 1.117/2.;
917 const Float_t kTl1OETF3 = 2.36/2.;
d1cd2474 918 const Float_t kAlp1OETF3 = 4.94;
b367fd8f 919 // Fix (5) - overlap of SQ21 with 041M and 125M
ba030c0e 920
b367fd8f 921 //const Float_t kBl2OETF3 = 1.767/2.;
922 //const Float_t kTl2OETF3 = 3.01/2.;
923 const Float_t kBl2OETF3 = 1.117/2.;
924 const Float_t kTl2OETF3 = 2.36/2.;
d1cd2474 925 const Float_t kAlp2OETF3 = 4.94;
b367fd8f 926 // Fix (5) - overlap of SQ21 with 041M and 125M
ba030c0e 927
5f91c9e8 928// Trapezoid 4
d1cd2474 929 const Float_t kBl1OETF4 = 0.;
930 const Float_t kTl1OETF4 = 1.77/2.;
931 const Float_t kAlp1OETF4 = 7.01;
ba030c0e 932
d1cd2474 933 const Float_t kBl2OETF4 = 0.;
934 const Float_t kTl2OETF4 = 1.77/2.;
935 const Float_t kAlp2OETF4 = 7.01;
5f91c9e8 936
937// Frame Structure (OutVFrame):
938//
939// OutVFrame and corner (OutVFrame cuboid, OutVFrame trapezoid)
940// EARTHING (VertEarthFaceCu,VertEarthSteel,VertEarthProfCu),
941// DETECTOR POSITIONNING (SuppLateralPositionner, LateralPositionner),
942// CRADLE (VertCradle), and
943// ALIGNMENT (LateralSightSupport, LateralSight)
944//
945//---
946
947// OutVFrame parameters - cuboid
d1cd2474 948 const Float_t kHxOutVFrame = 1.85/2.;
949 const Float_t kHyOutVFrame = 46.23/2.;
950 const Float_t kHzOutVFrame = kHzFrameThickness;
5f91c9e8 951
952// OutVFrame corner parameters - trapezoid
d1cd2474 953 const Float_t kHzOCTF = kHzFrameThickness;
954 const Float_t kTetOCTF = 0.;
955 const Float_t kPhiOCTF = 0.;
956 const Float_t kH1OCTF = 1.85/2.;
957 const Float_t kBl1OCTF = 0.;
958 const Float_t kTl1OCTF = 3.66/2.;
959 const Float_t kAlp1OCTF = 44.67;
960 const Float_t kH2OCTF = 1.85/2.;
961 const Float_t kBl2OCTF = 0.;
962 const Float_t kTl2OCTF = 3.66/2.;
963 const Float_t kAlp2OCTF = 44.67;
5f91c9e8 964
965// VertEarthFaceCu parameters - single trapezoid
d1cd2474 966 const Float_t kHzVFC = kHzVertEarthFaceCu;
967 const Float_t kTetVFC = 0.;
968 const Float_t kPhiVFC = 0.;
969 const Float_t kH1VFC = 1.200/2.;
970 const Float_t kBl1VFC = 46.11/2.;
971 const Float_t kTl1VFC = 48.236/2.;
972 const Float_t kAlp1VFC = 41.54;
973 const Float_t kH2VFC = 1.200/2.;
974 const Float_t kBl2VFC = 46.11/2.;
975 const Float_t kTl2VFC = 48.236/2.;
976 const Float_t kAlp2VFC = 41.54;
5f91c9e8 977
978// VertEarthSteel parameters - single trapezoid
d1cd2474 979 const Float_t kHzVES = kHzVertBarSteel;
980 const Float_t kTetVES = 0.;
981 const Float_t kPhiVES = 0.;
982 const Float_t kH1VES = 1.200/2.;
983 const Float_t kBl1VES = 30.486/2.;
984 const Float_t kTl1VES = 32.777/2.;
985 const Float_t kAlp1VES = 43.67;
986 const Float_t kH2VES = 1.200/2.;
987 const Float_t kBl2VES = 30.486/2.;
988 const Float_t kTl2VES = 32.777/2.;
989 const Float_t kAlp2VES = 43.67;
5f91c9e8 990
991// VertEarthProfCu parameters - single trapezoid
d1cd2474 992 const Float_t kHzVPC = kHzVertEarthProfCu;
993 const Float_t kTetVPC = 0.;
994 const Float_t kPhiVPC = 0.;
995 const Float_t kH1VPC = 0.400/2.;
996 const Float_t kBl1VPC = 29.287/2.;
997 const Float_t kTl1VPC = 30.091/2.;
998 const Float_t kAlp1VPC = 45.14;
999 const Float_t kH2VPC = 0.400/2.;
1000 const Float_t kBl2VPC = 29.287/2.;
1001 const Float_t kTl2VPC = 30.091/2.;
1002 const Float_t kAlp2VPC = 45.14;
5f91c9e8 1003
1004// SuppLateralPositionner - single cuboid
d1cd2474 1005 const Float_t kHxSLP = 2.80/2.;
1006 const Float_t kHySLP = 5.00/2.;
1007 const Float_t kHzSLP = kHzLateralPosnAl;
5f91c9e8 1008
1009// LateralPositionner - squared off U bend, face view
d1cd2474 1010 const Float_t kHxLPF = 5.2/2.;
1011 const Float_t kHyLPF = 3.0/2.;
1012 const Float_t kHzLPF = kHzLateralPosnInoxFace;
5f91c9e8 1013
1014// LateralPositionner - squared off U bend, profile view
d1cd2474 1015 const Float_t kHxLPP = 0.425/2.;
1016 const Float_t kHyLPP = 3.0/2.;
1017 const Float_t kHzLPP = kHzLatPosInoxProfM; // middle layer
1018 const Float_t kHzLPNF = kHzLatPosInoxProfNF; // near and far layers
5f91c9e8 1019
1020// VertCradle, 3 layers (copies), each composed of 4 trapezoids
1021// VertCradleA
d1cd2474 1022 const Float_t kHzVC1 = kHzVerticalCradleAl;
1023 const Float_t kTetVC1 = 0.;
1024 const Float_t kPhiVC1 = 0.;
1025 const Float_t kH1VC1 = 10.25/2.;
1026 const Float_t kBl1VC1 = 3.70/2.;
1027 const Float_t kTl1VC1 = 0.;
1028 const Float_t kAlp1VC1 = -10.23;
1029 const Float_t kH2VC1 = 10.25/2.;
1030 const Float_t kBl2VC1 = 3.70/2.;
1031 const Float_t kTl2VC1 = 0.;
1032 const Float_t kAlp2VC1 = -10.23;
5f91c9e8 1033
1034// VertCradleB
d1cd2474 1035 const Float_t kHzVC2 = kHzVerticalCradleAl;
1036 const Float_t kTetVC2 = 0.;
1037 const Float_t kPhiVC2 = 0.;
1038 const Float_t kH1VC2 = 10.25/2.;
1039 const Float_t kBl1VC2 = 6.266/2.;
1040 const Float_t kTl1VC2 = 3.70/2.;
1041 const Float_t kAlp1VC2 = -7.13;
1042 const Float_t kH2VC2 = 10.25/2.;
1043 const Float_t kBl2VC2 = 6.266/2.;
1044 const Float_t kTl2VC2 = 3.70/2.;
1045 const Float_t kAlp2VC2 = -7.13;
5f91c9e8 1046
1047// VertCradleC
d1cd2474 1048 const Float_t kHzVC3 = kHzVerticalCradleAl;
1049 const Float_t kTetVC3 = 0.;
1050 const Float_t kPhiVC3 = 0.;
1051 const Float_t kH1VC3 = 10.25/2.;
1052 const Float_t kBl1VC3 = 7.75/2.;
1053 const Float_t kTl1VC3 = 6.266/2.;
1054 const Float_t kAlp1VC3 = -4.14;
1055 const Float_t kH2VC3 = 10.25/2.;
1056 const Float_t kBl2VC3 = 7.75/2.;
1057 const Float_t kTl2VC3 = 6.266/2.;
1058 const Float_t kAlp2VC3 = -4.14;
5f91c9e8 1059
1060// VertCradleD
d1cd2474 1061 const Float_t kHzVC4 = kHzVerticalCradleAl;
1062 const Float_t kTetVC4 = 0.;
1063 const Float_t kPhiVC4 = 0.;
1064 const Float_t kH1VC4 = 10.27/2.;
1065 const Float_t kBl1VC4 = 8.273/2.;
1066 const Float_t kTl1VC4 = 7.75/2.;
1067 const Float_t kAlp1VC4 = -1.46;
1068 const Float_t kH2VC4 = 10.27/2.;
1069 const Float_t kBl2VC4 = 8.273/2.;
1070 const Float_t kTl2VC4 = 7.75/2.;
1071 const Float_t kAlp2VC4 = -1.46;
5f91c9e8 1072
1073// LateralSightSupport - single trapezoid
d1cd2474 1074 const Float_t kHzVSS = kHzLateralSightAl;
1075 const Float_t kTetVSS = 0.;
1076 const Float_t kPhiVSS = 0.;
1077 const Float_t kH1VSS = 5.00/2.;
1078 const Float_t kBl1VSS = 7.747/2;
1079 const Float_t kTl1VSS = 7.188/2.;
1080 const Float_t kAlp1VSS = -3.20;
1081 const Float_t kH2VSS = 5.00/2.;
1082 const Float_t kBl2VSS = 7.747/2.;
1083 const Float_t kTl2VSS = 7.188/2.;
1084 const Float_t kAlp2VSS = -3.20;
5f91c9e8 1085
1086// LateralSight (reference point) - 3 per quadrant, only 1 programmed for now
d1cd2474 1087 const Float_t kVSInRad = 0.6;
1088 const Float_t kVSOutRad = 1.3;
1089 const Float_t kVSLen = kHzFrameThickness;
5f91c9e8 1090
1091//---
ba030c0e 1092
5f91c9e8 1093// InHFrame parameters
d1cd2474 1094 const Float_t kHxInHFrame = 75.8/2.;
1095 const Float_t kHyInHFrame = 1.85/2.;
1096 const Float_t kHzInHFrame = kHzFrameThickness;
5f91c9e8 1097
1098//Flat 7.5mm horizontal section
d1cd2474 1099 const Float_t kHxH1mm = 1.85/2.;
1100 const Float_t kHyH1mm = 0.75/2.;
1101 const Float_t kHzH1mm = kHzFrameThickness;
ba030c0e 1102
5f91c9e8 1103//---
ba030c0e 1104
5f91c9e8 1105// InArcFrame parameters
d1cd2474 1106 const Float_t kIAF = 15.70;
1107 const Float_t kOAF = 17.55;
1108 const Float_t kHzAF = kHzFrameThickness;
1109 const Float_t kAFphi1 = 0.0;
1110 const Float_t kAFphi2 = 90.0;
ba030c0e 1111
5f91c9e8 1112//---
ba030c0e 1113
5f91c9e8 1114// ScrewsInFrame parameters HEAD
d1cd2474 1115 const Float_t kSCRUHMI = 0.;
1116 const Float_t kSCRUHMA = 0.690/2.;
1117 const Float_t kSCRUHLE = 0.4/2.;
5f91c9e8 1118// ScrewsInFrame parameters MIDDLE
d1cd2474 1119 const Float_t kSCRUMMI = 0.;
1120 const Float_t kSCRUMMA = 0.39/2.;
1121 const Float_t kSCRUMLE = kHzFrameThickness;
5f91c9e8 1122// ScrewsInFrame parameters NUT
d1cd2474 1123 const Float_t kSCRUNMI = 0.;
1124 const Float_t kSCRUNMA = 0.78/2.;
1125 const Float_t kSCRUNLE = 0.8/2.;
5f91c9e8 1126
1127 // ___________________Make volumes________________________
ba030c0e 1128
5f91c9e8 1129 Float_t par[11];
1130 Float_t posX,posY,posZ;
ba030c0e 1131
5f91c9e8 1132// Quadrant volume TUBS1, positioned at the end
1133 par[0] = fgkMotherIR1;
1134 par[1] = fgkMotherOR1;
1135 par[2] = fgkMotherThick1;
1136 par[3] = fgkMotherPhiL1;
1137 par[4] = fgkMotherPhiU1;
1138 gMC->Gsvolu(QuadrantMLayerName(chamber),"TUBS",idAir,par,5);
ba030c0e 1139
91111b9c 1140// Replace the volume shape with a composite shape
1141// with substracted overlap with beam shield (YMOT)
1142
1143 if ( gMC->IsRootGeometrySupported() &&
1144 TString(gMC->ClassName()) != "TGeant4") {
1145
1146 // Get shape
1147 TGeoVolume* mlayer
1148 = gGeoManager->FindVolumeFast(QuadrantMLayerName(chamber));
1149 if ( !mlayer ) {
1150 AliErrorStream()
1151 << "Quadrant volume " << QuadrantMLayerName(chamber) << " not found"
1152 << endl;
1153 }
1154 else {
1155 TGeoShape* quadrant = mlayer->GetShape();
1156 quadrant->SetName("quadrant");
1157
1158 // Beam shield recess
1159 par[0] = 0;
1160 par[1] = 15.4;
1161 par[2] = fgkMotherThick1;
1162 new TGeoTube("shield_tube", par[0], par[1], par[2]);
1163
1164 // Displacement
1165 posX = 2.6;
1166 posY = 2.6;
1167 posZ = 0;
1168 TGeoTranslation* displacement
1169 = new TGeoTranslation("TR", posX, posY, posZ);
1170 displacement->RegisterYourself();
1171
1172 // Composite shape
1173 TGeoShape* composite
1174 = new TGeoCompositeShape("composite", "quadrant-shield_tube:TR");
1175
1176 // Reset shape to volume
1177 mlayer->SetShape(composite);
1178 }
1179 }
1180
5f91c9e8 1181// Quadrant volume TUBS2, positioned at the end
1182 par[0] = fgkMotherIR2;
1183 par[1] = fgkMotherOR2;
1184 par[2] = fgkMotherThick2;
1185 par[3] = fgkMotherPhiL2;
1186 par[4] = fgkMotherPhiU2;
ba030c0e 1187
5f91c9e8 1188 gMC->Gsvolu(QuadrantNLayerName(chamber),"TUBS",idAir,par,5);
1189 gMC->Gsvolu(QuadrantFLayerName(chamber),"TUBS",idAir,par,5);
ba030c0e 1190
5f91c9e8 1191 if (chamber==1) {
1192 // InVFrame
d1cd2474 1193 par[0] = kHxInVFrame;
1194 par[1] = kHyInVFrame;
1195 par[2] = kHzInVFrame;
5f91c9e8 1196 gMC->Gsvolu("SQ00","BOX",idFrameEpoxy,par,3);
1197
1198 //Flat 1mm vertical section
d1cd2474 1199 par[0] = kHxV1mm;
1200 par[1] = kHyV1mm;
1201 par[2] = kHzV1mm;
5f91c9e8 1202 gMC->Gsvolu("SQ01","BOX",idFrameEpoxy,par,3);
1203
1204// OutTopFrame
1205//
1206// - 3 components (a cuboid and 2 trapezes) and 2 layers (Epoxy/Inox)
1207//
1208//---
ba030c0e 1209
5f91c9e8 1210 // TopFrameAnode - layer 1 of 2
d1cd2474 1211 par[0] = kHxTFA;
1212 par[1] = kHyTFA;
1213 par[2] = kHzTFAE;
5f91c9e8 1214 gMC->Gsvolu("SQ02","BOX",idFrameEpoxy,par,3);
1215
1216 // TopFrameAnode - layer 2 of 2
d1cd2474 1217 par[2] = kHzTFAI;
5f91c9e8 1218 gMC->Gsvolu("SQ03","BOX",idInox,par,3);
1219
1220 // TopFrameAnodeA - layer 1 of 2
d1cd2474 1221 par[0] = kHzFAAE;
1222 par[1] = kTetFAA;
1223 par[2] = kPhiFAA;
1224 par[3] = kH1FAA;
1225 par[4] = kBl1FAA;
1226 par[5] = kTl1FAA;
1227 par[6] = kAlp1FAA;
1228 par[7] = kH2FAA;
1229 par[8] = kBl2FAA;
1230 par[9] = kTl2FAA;
1231 par[10] = kAlp2FAA;
5f91c9e8 1232 gMC->Gsvolu("SQ04","TRAP",idFrameEpoxy,par,11);
1233
1234 // TopFrameAnodeA - layer 2 of 2
d1cd2474 1235 par[0] = kHzFAAI;
5f91c9e8 1236 gMC->Gsvolu("SQ05","TRAP",idInox,par,11);
ba030c0e 1237
5f91c9e8 1238 // TopFrameAnodeB - layer 1 of 2
d1cd2474 1239 par[0] = kHzFABE;
1240 par[1] = kTetFAB;
1241 par[2] = kPhiFAB;
1242 par[3] = kH1FAB;
1243 par[4] = kBl1FAB;
1244 par[5] = kTl1FAB;
1245 par[6] = kAlp1FAB;
1246 par[7] = kH2FAB;
1247 par[8] = kBl2FAB;
1248 par[9] = kTl2FAB;
1249 par[10] = kAlp2FAB;
5f91c9e8 1250 gMC->Gsvolu("SQ06","TRAP",idFrameEpoxy,par,11);
1251
1252 // OutTopTrapFrameB - layer 2 of 2
d1cd2474 1253 par[0] = kHzFABI;
5f91c9e8 1254 gMC->Gsvolu("SQ07","TRAP",idInox,par,11);
1255
1256 // TopAnode1 - layer 1 of 2
d1cd2474 1257 par[0] = kHxTA1;
1258 par[1] = kHyTA1;
1259 par[2] = kHzTA11;
5f91c9e8 1260 gMC->Gsvolu("SQ08","BOX",idInox,par,3);
1261
1262 // TopAnode1 - layer 2 of 2
d1cd2474 1263 par[2] = kHzTA12;
5f91c9e8 1264 gMC->Gsvolu("SQ09","BOX",idFR4,par,11);
1265
1266 // TopAnode2 - layer 1 of 2
d1cd2474 1267 par[0] = kHzTA21;
1268 par[1] = kTetTA2;
1269 par[2] = kPhiTA2;
1270 par[3] = kH1TA2;
1271 par[4] = kBl1TA2;
1272 par[5] = kTl1TA2;
1273 par[6] = kAlp1TA2;
1274 par[7] = kH2TA2;
1275 par[8] = kBl2TA2;
1276 par[9] = kTl2TA2;
1277 par[10] = kAlp2TA2;
5f91c9e8 1278 gMC->Gsvolu("SQ10","TRAP",idInox,par,11);
1279
1280 // TopAnode2 - layer 2 of 2
d1cd2474 1281 par[0] = kHzTA22;
5f91c9e8 1282 gMC->Gsvolu("SQ11","TRAP",idFR4,par,11);
1283
1284 // TopAnode3 - layer 1 of 1
d1cd2474 1285 par[0] = kHzTA3;
1286 par[1] = kTetTA3;
1287 par[2] = kPhiTA3;
1288 par[3] = kH1TA3;
1289 par[4] = kBl1TA3;
1290 par[5] = kTl1TA3;
1291 par[6] = kAlp1TA3;
1292 par[7] = kH2TA3;
1293 par[8] = kBl2TA3;
1294 par[9] = kTl2TA3;
1295 par[10] = kAlp2TA3;
5f91c9e8 1296 gMC->Gsvolu("SQ12","TRAP",idFR4,par,11);
1297
1298 // TopEarthFace
d1cd2474 1299 par[0] = kHzTEF;
1300 par[1] = kTetTEF;
1301 par[2] = kPhiTEF;
1302 par[3] = kH1TEF;
1303 par[4] = kBl1TEF;
1304 par[5] = kTl1TEF;
1305 par[6] = kAlp1TEF;
1306 par[7] = kH2TEF;
1307 par[8] = kBl2TEF;
1308 par[9] = kTl2TEF;
1309 par[10] = kAlp2TEF;
5f91c9e8 1310 gMC->Gsvolu("SQ13","TRAP",idCopper,par,11);
1311
1312 // TopEarthProfile
d1cd2474 1313 par[0] = kHzTEP;
1314 par[1] = kTetTEP;
1315 par[2] = kPhiTEP;
1316 par[3] = kH1TEP;
1317 par[4] = kBl1TEP;
1318 par[5] = kTl1TEP;
1319 par[6] = kAlp1TEP;
1320 par[7] = kH2TEP;
1321 par[8] = kBl2TEP;
1322 par[9] = kTl2TEP;
1323 par[10] = kAlp2TEP;
5f91c9e8 1324 gMC->Gsvolu("SQ14","TRAP",idCopper,par,11);
1325
1326 // TopGasSupport
d1cd2474 1327 par[0] = kHxTGS;
1328 par[1] = kHyTGS;
1329 par[2] = kHzTGS;
5f91c9e8 1330 gMC->Gsvolu("SQ15","BOX",idAlu,par,3);
1331
1332 // TopPositioner parameters - single Stainless Steel trapezoid
d1cd2474 1333 par[0] = kHzTP;
1334 par[1] = kTetTP;
1335 par[2] = kPhiTP;
1336 par[3] = kH1TP;
1337 par[4] = kBl1TP;
1338 par[5] = kTl1TP;
1339 par[6] = kAlp1TP;
1340 par[7] = kH2TP;
1341 par[8] = kBl2TP;
1342 par[9] = kTl2TP;
1343 par[10] = kAlp2TP;
5f91c9e8 1344 gMC->Gsvolu("SQ16","TRAP",idInox,par,11);
ba030c0e 1345
5f91c9e8 1346//
1347// OutEdgeTrapFrame Epoxy = (4 trapezes)*2 copies*2 layers (Epoxy/Inox)
1348//
1349//---
1350 // Trapezoid 1 - 2 layers
d1cd2474 1351 par[1] = kTetOETF;
1352 par[2] = kPhiOETF;
1353 par[3] = kH1OETF;
1354 par[4] = kBl1OETF1;
1355 par[5] = kTl1OETF1;
1356 par[6] = kAlp1OETF1;
1357 par[7] = kH2OETF;
1358 par[8] = kBl2OETF1;
1359 par[9] = kTl2OETF1;
1360 par[10] = kAlp2OETF1;
5f91c9e8 1361
d1cd2474 1362 par[0] = kHzOETFE;
5f91c9e8 1363 gMC->Gsvolu("SQ17","TRAP",idFrameEpoxy,par,11);
d1cd2474 1364 par[0] = kHzOETFI;
5f91c9e8 1365 gMC->Gsvolu("SQ18","TRAP",idInox,par,11);
1366
1367 // Trapezoid 2 - 2 layers
d1cd2474 1368 par[4] = kBl1OETF2;
1369 par[5] = kTl1OETF2;
1370 par[6] = kAlp1OETF2;
5f91c9e8 1371
d1cd2474 1372 par[8] = kBl2OETF2;
1373 par[9] = kTl2OETF2;
1374 par[10] = kAlp2OETF2;
5f91c9e8 1375
d1cd2474 1376 par[0] = kHzOETFE;
5f91c9e8 1377 gMC->Gsvolu("SQ19","TRAP",idFrameEpoxy,par,11);
d1cd2474 1378 par[0] = kHzOETFI;
5f91c9e8 1379 gMC->Gsvolu("SQ20","TRAP",idInox,par,11);
1380
1381 // Trapezoid 3 - 2 layers
d1cd2474 1382 par[4] = kBl1OETF3;
1383 par[5] = kTl1OETF3;
1384 par[6] = kAlp1OETF3;
5f91c9e8 1385
d1cd2474 1386 par[8] = kBl2OETF3;
1387 par[9] = kTl2OETF3;
1388 par[10] = kAlp2OETF3;
5f91c9e8 1389
d1cd2474 1390 par[0] = kHzOETFE;
5f91c9e8 1391 gMC->Gsvolu("SQ21","TRAP",idFrameEpoxy,par,11);
d1cd2474 1392 par[0] = kHzOETFI;
5f91c9e8 1393 gMC->Gsvolu("SQ22","TRAP",idInox,par,11);
1394
1395 // Trapezoid 4 - 2 layers
ba030c0e 1396
d1cd2474 1397 par[4] = kBl1OETF4;
1398 par[5] = kTl1OETF4;
1399 par[6] = kAlp1OETF4;
ba030c0e 1400
d1cd2474 1401 par[8] = kBl2OETF4;
1402 par[9] = kTl2OETF4;
1403 par[10] = kAlp2OETF4;
5f91c9e8 1404
d1cd2474 1405 par[0] = kHzOETFE;
5f91c9e8 1406 gMC->Gsvolu("SQ23","TRAP",idFrameEpoxy,par,11);
d1cd2474 1407 par[0] = kHzOETFI;
5f91c9e8 1408 gMC->Gsvolu("SQ24","TRAP",idInox,par,11);
ba030c0e 1409
5f91c9e8 1410//---
1411 // OutVFrame
d1cd2474 1412 par[0] = kHxOutVFrame;
1413 par[1] = kHyOutVFrame;
1414 par[2] = kHzOutVFrame;
5f91c9e8 1415 gMC->Gsvolu("SQ25","BOX",idFrameEpoxy,par,3);
d1cd2474 1416
5f91c9e8 1417 // OutVFrame corner
d1cd2474 1418 par[0] = kHzOCTF;
1419 par[1] = kTetOCTF;
1420 par[2] = kPhiOCTF;
1421 par[3] = kH1OCTF;
1422 par[4] = kBl1OCTF;
1423 par[5] = kTl1OCTF;
1424 par[6] = kAlp1OCTF;
1425 par[7] = kH2OCTF;
1426 par[8] = kBl2OCTF;
1427 par[9] = kTl2OCTF;
1428 par[10] = kAlp2OCTF;
5f91c9e8 1429 gMC->Gsvolu("SQ26","TRAP",idFrameEpoxy,par,11);
1430
1431 // EarthFaceCu trapezoid
d1cd2474 1432 par[0] = kHzVFC;
1433 par[1] = kTetVFC;
1434 par[2] = kPhiVFC;
1435 par[3] = kH1VFC;
1436 par[4] = kBl1VFC;
1437 par[5] = kTl1VFC;
1438 par[6] = kAlp1VFC;
1439 par[7] = kH2VFC;
1440 par[8] = kBl2VFC;
1441 par[9] = kTl2VFC;
1442 par[10] = kAlp2VFC;
5f91c9e8 1443 gMC->Gsvolu("SQ27","TRAP",idCopper,par,11);
1444
1445 // VertEarthSteel trapezoid
d1cd2474 1446 par[0] = kHzVES;
1447 par[1] = kTetVES;
1448 par[2] = kPhiVES;
1449 par[3] = kH1VES;
1450 par[4] = kBl1VES;
1451 par[5] = kTl1VES;
1452 par[6] = kAlp1VES;
1453 par[7] = kH2VES;
1454 par[8] = kBl2VES;
1455 par[9] = kTl2VES;
1456 par[10] = kAlp2VES;
5f91c9e8 1457 gMC->Gsvolu("SQ28","TRAP",idInox,par,11);
1458
1459 // VertEarthProfCu trapezoid
d1cd2474 1460 par[0] = kHzVPC;
1461 par[1] = kTetVPC;
1462 par[2] = kPhiVPC;
1463 par[3] = kH1VPC;
1464 par[4] = kBl1VPC;
1465 par[5] = kTl1VPC;
1466 par[6] = kAlp1VPC;
1467 par[7] = kH2VPC;
1468 par[8] = kBl2VPC;
1469 par[9] = kTl2VPC;
1470 par[10] = kAlp2VPC;
5f91c9e8 1471 gMC->Gsvolu("SQ29","TRAP",idCopper,par,11);
1472
1473 // SuppLateralPositionner cuboid
d1cd2474 1474 par[0] = kHxSLP;
1475 par[1] = kHySLP;
1476 par[2] = kHzSLP;
5f91c9e8 1477 gMC->Gsvolu("SQ30","BOX",idAlu,par,3);
1478
1479 // LateralPositionerFace
d1cd2474 1480 par[0] = kHxLPF;
1481 par[1] = kHyLPF;
1482 par[2] = kHzLPF;
5f91c9e8 1483 gMC->Gsvolu("SQ31","BOX",idInox,par,3);
1484
1485 // LateralPositionerProfile
d1cd2474 1486 par[0] = kHxLPP;
1487 par[1] = kHyLPP;
1488 par[2] = kHzLPP;
5f91c9e8 1489 gMC->Gsvolu("SQ32","BOX",idInox,par,3); // middle layer
1490
d1cd2474 1491 par[0] = kHxLPP;
1492 par[1] = kHyLPP;
1493 par[2] = kHzLPNF;
5f91c9e8 1494 gMC->Gsvolu("SQ33","BOX",idInox,par,3); // near and far layers
1495
1496 // VertCradleA - 1st trapezoid
d1cd2474 1497 par[0] = kHzVC1;
1498 par[1] = kTetVC1;
1499 par[2] = kPhiVC1;
1500 par[3] = kH1VC1;
1501 par[4] = kBl1VC1;
1502 par[5] = kTl1VC1;
1503 par[6] = kAlp1VC1;
1504 par[7] = kH2VC1;
1505 par[8] = kBl2VC1;
1506 par[9] = kTl2VC1;
1507 par[10] = kAlp2VC1;
5f91c9e8 1508 gMC->Gsvolu("SQ34","TRAP",idAlu,par,11);
ba030c0e 1509
5f91c9e8 1510 // VertCradleB - 2nd trapezoid
d1cd2474 1511 par[0] = kHzVC2;
1512 par[1] = kTetVC2;
1513 par[2] = kPhiVC2;
1514 par[3] = kH1VC2;
1515 par[4] = kBl1VC2;
1516 par[5] = kTl1VC2;
1517 par[6] = kAlp1VC2;
1518 par[7] = kH2VC2;
1519 par[8] = kBl2VC2;
1520 par[9] = kTl2VC2;
1521 par[10] = kAlp2VC2;
5f91c9e8 1522 gMC->Gsvolu("SQ35","TRAP",idAlu,par,11);
1523
1524 // VertCradleC - 3rd trapezoid
d1cd2474 1525 par[0] = kHzVC3;
1526 par[1] = kTetVC3;
1527 par[2] = kPhiVC3;
1528 par[3] = kH1VC3;
1529 par[4] = kBl1VC3;
1530 par[5] = kTl1VC3;
1531 par[6] = kAlp1VC3;
1532 par[7] = kH2VC3;
1533 par[8] = kBl2VC3;
1534 par[9] = kTl2VC3;
1535 par[10] = kAlp2VC3;
5f91c9e8 1536 gMC->Gsvolu("SQ36","TRAP",idAlu,par,11);
1537
1538 // VertCradleD - 4th trapezoid
d1cd2474 1539 par[0] = kHzVC4;
1540 par[1] = kTetVC4;
1541 par[2] = kPhiVC4;
1542 par[3] = kH1VC4;
1543 par[4] = kBl1VC4;
1544 par[5] = kTl1VC4;
1545 par[6] = kAlp1VC4;
1546 par[7] = kH2VC4;
1547 par[8] = kBl2VC4;
1548 par[9] = kTl2VC4;
1549 par[10] = kAlp2VC4;
5f91c9e8 1550 gMC->Gsvolu("SQ37","TRAP",idAlu,par,11);
1551
1552 // LateralSightSupport trapezoid
d1cd2474 1553 par[0] = kHzVSS;
1554 par[1] = kTetVSS;
1555 par[2] = kPhiVSS;
1556 par[3] = kH1VSS;
1557 par[4] = kBl1VSS;
1558 par[5] = kTl1VSS;
1559 par[6] = kAlp1VSS;
1560 par[7] = kH2VSS;
1561 par[8] = kBl2VSS;
1562 par[9] = kTl2VSS;
1563 par[10] = kAlp2VSS;
5f91c9e8 1564 gMC->Gsvolu("SQ38","TRAP",idAlu,par,11);
1565
1566 // LateralSight
d1cd2474 1567 par[0] = kVSInRad;
1568 par[1] = kVSOutRad;
1569 par[2] = kVSLen;
5f91c9e8 1570 gMC->Gsvolu("SQ39","TUBE",idFrameEpoxy,par,3);
1571
1572//---
1573 // InHFrame
d1cd2474 1574 par[0] = kHxInHFrame;
1575 par[1] = kHyInHFrame;
1576 par[2] = kHzInHFrame;
5f91c9e8 1577 gMC->Gsvolu("SQ40","BOX",idFrameEpoxy,par,3);
1578
1579 //Flat 7.5mm horizontal section
d1cd2474 1580 par[0] = kHxH1mm;
1581 par[1] = kHyH1mm;
1582 par[2] = kHzH1mm;
5f91c9e8 1583 gMC->Gsvolu("SQ41","BOX",idFrameEpoxy,par,3);
1584
1585 // InArcFrame
d1cd2474 1586 par[0] = kIAF;
1587 par[1] = kOAF;
1588 par[2] = kHzAF;
1589 par[3] = kAFphi1;
1590 par[4] = kAFphi2;
5f91c9e8 1591
1592 gMC->Gsvolu("SQ42","TUBS",idFrameEpoxy,par,5);
1593
1594//---
1595 // ScrewsInFrame - 3 sections in order to avoid overlapping volumes
1596 // Screw Head, in air
d1cd2474 1597 par[0] = kSCRUHMI;
1598 par[1] = kSCRUHMA;
1599 par[2] = kSCRUHLE;
5f91c9e8 1600
1601 gMC->Gsvolu("SQ43","TUBE",idInox,par,3);
1602
1603 // Middle part, in the Epoxy
d1cd2474 1604 par[0] = kSCRUMMI;
1605 par[1] = kSCRUMMA;
1606 par[2] = kSCRUMLE;
5f91c9e8 1607 gMC->Gsvolu("SQ44","TUBE",idInox,par,3);
1608
1609 // Screw nut, in air
d1cd2474 1610 par[0] = kSCRUNMI;
1611 par[1] = kSCRUNMA;
1612 par[2] = kSCRUNLE;
5f91c9e8 1613 gMC->Gsvolu("SQ45","TUBE",idInox,par,3);
1614 }
1615
1616// __________________Place volumes in the quadrant ____________
1617
1618 // InVFrame
d1cd2474 1619 posX = kHxInVFrame;
1620 posY = 2.0*kHyInHFrame+2.*kHyH1mm+kIAF+kHyInVFrame;
5f91c9e8 1621 posZ = 0.;
1622 gMC->Gspos("SQ00",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
ba030c0e 1623
d1cd2474 1624// keep memory of the mid position. Used for placing screws
1625 const GReal_t kMidVposX = posX;
1626 const GReal_t kMidVposY = posY;
1627 const GReal_t kMidVposZ = posZ;
1628
5f91c9e8 1629 //Flat 7.5mm vertical section
d1cd2474 1630 posX = 2.0*kHxInVFrame+kHxV1mm;
1631 posY = 2.0*kHyInHFrame+2.*kHyH1mm+kIAF+kHyV1mm;
5f91c9e8 1632 posZ = 0.;
1633 gMC->Gspos("SQ01",1,QuadrantMLayerName(chamber),posX, posY, posZ,0, "ONLY");
1634
1635 // TopFrameAnode place 2 layers of TopFrameAnode cuboids
d1cd2474 1636 posX = kHxTFA;
1637 posY = 2.*kHyInHFrame+2.*kHyH1mm+kIAF+2.*kHyInVFrame+kHyTFA;
1638 posZ = kHzOuterFrameInox;
5f91c9e8 1639 gMC->Gspos("SQ02",1,QuadrantMLayerName(chamber),posX, posY, posZ,0,"ONLY");
d1cd2474 1640 posZ = posZ+kHzOuterFrameInox;
5f91c9e8 1641 gMC->Gspos("SQ03",1,QuadrantMLayerName(chamber),posX, posY, posZ,0,"ONLY");
1642
1643 // place 2 layers of TopFrameAnodeA trapezoids
1644 posX = 35.8932+fgkDeltaQuadLHC;
1645 posY = 92.6745+fgkDeltaQuadLHC;
d1cd2474 1646 posZ = kHzOuterFrameInox;
5f91c9e8 1647 gMC->Gspos("SQ04",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
d1cd2474 1648 posZ = posZ+kHzOuterFrameInox;
5f91c9e8 1649 gMC->Gspos("SQ05",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1650
1651 // place 2 layers of TopFrameAnodeB trapezoids
1652 posX = 44.593+fgkDeltaQuadLHC;
1653 posY = 90.737+fgkDeltaQuadLHC;
d1cd2474 1654 posZ = kHzOuterFrameInox;
5f91c9e8 1655 gMC->Gspos("SQ06",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
d1cd2474 1656 posZ = posZ+kHzOuterFrameInox;
5f91c9e8 1657 gMC->Gspos("SQ07",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1658
1659 // TopAnode1 place 2 layers
1660 posX = 6.8+fgkDeltaQuadLHC;
1661 posY = 99.85+fgkDeltaQuadLHC;
d1cd2474 1662 posZ = -1.*kHzAnodeFR4;
5f91c9e8 1663 gMC->Gspos("SQ08",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
d1cd2474 1664 posZ = posZ+kHzTopAnodeSteel1;
5f91c9e8 1665 gMC->Gspos("SQ09",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1666
1667 // TopAnode2 place 2 layers
1668 posX = 18.534+fgkDeltaQuadLHC;
1669 posY = 99.482+fgkDeltaQuadLHC;
d1cd2474 1670 posZ = -1.*kHzAnodeFR4;
5f91c9e8 1671 gMC->Gspos("SQ10",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
d1cd2474 1672 posZ = posZ+kHzTopAnodeSteel2;
5f91c9e8 1673 gMC->Gspos("SQ11",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1674
1675 // TopAnode3 place 1 layer
1676 posX = 25.80+fgkDeltaQuadLHC;
1677 posY = 98.61+fgkDeltaQuadLHC;
1678 posZ = 0.;
1679 gMC->Gspos("SQ12",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1680
1681 // TopEarthFace - 2 copies
1682 posX = 23.122+fgkDeltaQuadLHC;
1683 posY = 96.90+fgkDeltaQuadLHC;
d1cd2474 1684 posZ = kHzOuterFrameEpoxy+kHzOuterFrameInox+kHzTopEarthFaceCu;
5f91c9e8 1685 gMC->Gspos("SQ13",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1686 posZ = -1.*posZ;
1687 gMC->Gspos("SQ13",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1688
1689 // TopEarthProfile
1690 posX = 14.475+fgkDeltaQuadLHC;
1691 posY = 97.900+fgkDeltaQuadLHC;
d1cd2474 1692 posZ = kHzTopEarthProfileCu;
5f91c9e8 1693 gMC->Gspos("SQ14",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1694 posZ = -1.0*posZ;
1695 gMC->Gspos("SQ14",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1696
1697 // TopGasSupport - 2 copies
1698 posX = 4.9500+fgkDeltaQuadLHC;
1699 posY = 96.200+fgkDeltaQuadLHC;
d1cd2474 1700 posZ = kHzOuterFrameEpoxy+kHzOuterFrameInox+kHzTopGasSupportAl;
5f91c9e8 1701 gMC->Gspos("SQ15",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1702 posZ = -1.*posZ;
1703 gMC->Gspos("SQ15",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1704
1705 // TopPositioner parameters - single Stainless Steel trapezoid - 2 copies
1706 posX = 7.60+fgkDeltaQuadLHC;
1707 posY = 98.98+fgkDeltaQuadLHC;
d1cd2474 1708 posZ = kHzOuterFrameEpoxy+kHzOuterFrameInox+2.*kHzTopGasSupportAl+kHzTopPositionerSteel;
5f91c9e8 1709 gMC->Gspos("SQ16",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1710 posZ = -1.*posZ;
1711 gMC->Gspos("SQ16",2,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1712
1713 // OutEdgeFrame
c03e5213 1714 Float_t xCenter[8];
1715 Float_t yCenter[8];
5f91c9e8 1716
c03e5213 1717 xCenter[0] = 73.201 + fgkDeltaQuadLHC;
1718 xCenter[1] = 78.124 + fgkDeltaQuadLHC;
b367fd8f 1719 //xCenter[2] = 82.862 + fgkDeltaQuadLHC;
1720 xCenter[2] = 83.102 + fgkDeltaQuadLHC;
c03e5213 1721 xCenter[3] = 87.418 + fgkDeltaQuadLHC;
b367fd8f 1722 // Fix (5) - overlap of SQ21 with 041M and 125M
5f91c9e8 1723
c03e5213 1724 yCenter[0] = 68.122 + fgkDeltaQuadLHC;
1725 yCenter[1] = 62.860 + fgkDeltaQuadLHC;
b367fd8f 1726 //yCenter[2] = 57.420 + fgkDeltaQuadLHC;
1727 yCenter[2] = 57.660 + fgkDeltaQuadLHC;
c03e5213 1728 yCenter[3] = 51.800 + fgkDeltaQuadLHC;
b367fd8f 1729 // Fix (5) - overlap of SQ21 with 041M and 125M
5f91c9e8 1730
c03e5213 1731 xCenter[4] = 68.122 + fgkDeltaQuadLHC;
1732 xCenter[5] = 62.860 + fgkDeltaQuadLHC;
1733 xCenter[6] = 57.420 + fgkDeltaQuadLHC;
1734 xCenter[7] = 51.800 + fgkDeltaQuadLHC;
5f91c9e8 1735
c03e5213 1736 yCenter[4] = 73.210 + fgkDeltaQuadLHC;
1737 yCenter[5] = 78.124 + fgkDeltaQuadLHC;
1738 yCenter[6] = 82.862 + fgkDeltaQuadLHC;
1739 yCenter[7] = 87.418 + fgkDeltaQuadLHC;
5f91c9e8 1740
d1cd2474 1741 posZ = -1.0*kHzOuterFrameInox;
c03e5213 1742 gMC->Gspos("SQ17",1,QuadrantMLayerName(chamber), xCenter[0], yCenter[0], posZ, rot2,"ONLY");
1743 gMC->Gspos("SQ17",2,QuadrantMLayerName(chamber), xCenter[4], yCenter[4], posZ, rot3,"ONLY");
5f91c9e8 1744
c03e5213 1745 gMC->Gspos("SQ19",1,QuadrantMLayerName(chamber), xCenter[1], yCenter[1], posZ, rot2,"ONLY");
1746 gMC->Gspos("SQ19",2,QuadrantMLayerName(chamber), xCenter[5], yCenter[5], posZ, rot3,"ONLY");
5f91c9e8 1747
c03e5213 1748 gMC->Gspos("SQ21",1,QuadrantMLayerName(chamber), xCenter[2], yCenter[2], posZ, rot2,"ONLY");
1749 gMC->Gspos("SQ21",2,QuadrantMLayerName(chamber), xCenter[6], yCenter[6], posZ, rot3,"ONLY");
ba030c0e 1750
c03e5213 1751 gMC->Gspos("SQ23",1,QuadrantMLayerName(chamber), xCenter[3], yCenter[3], posZ, rot2,"ONLY");
1752 gMC->Gspos("SQ23",2,QuadrantMLayerName(chamber), xCenter[7], yCenter[7], posZ, rot3,"ONLY");
5f91c9e8 1753
d1cd2474 1754 posZ = posZ+kHzOuterFrameEpoxy;
5f91c9e8 1755
c03e5213 1756 gMC->Gspos("SQ18",1,QuadrantMLayerName(chamber), xCenter[0], yCenter[0], posZ, rot2,"ONLY");
1757 gMC->Gspos("SQ18",2,QuadrantMLayerName(chamber), xCenter[4], yCenter[4], posZ, rot3,"ONLY");
5f91c9e8 1758
c03e5213 1759 gMC->Gspos("SQ20",1,QuadrantMLayerName(chamber), xCenter[1], yCenter[1], posZ, rot2,"ONLY");
1760 gMC->Gspos("SQ20",2,QuadrantMLayerName(chamber), xCenter[5], yCenter[5], posZ, rot3,"ONLY");
5f91c9e8 1761
c03e5213 1762 gMC->Gspos("SQ22",1,QuadrantMLayerName(chamber), xCenter[2], yCenter[2], posZ, rot2,"ONLY");
1763 gMC->Gspos("SQ22",2,QuadrantMLayerName(chamber), xCenter[6], yCenter[6], posZ, rot3,"ONLY");
5f91c9e8 1764
c03e5213 1765 gMC->Gspos("SQ24",1,QuadrantMLayerName(chamber), xCenter[3], yCenter[3], posZ, rot2,"ONLY");
1766 gMC->Gspos("SQ24",2,QuadrantMLayerName(chamber), xCenter[7], yCenter[7], posZ, rot3,"ONLY");
5f91c9e8 1767
1768//---
1769
ba030c0e 1770// OutVFrame
d1cd2474 1771 posX = 2.*kHxInVFrame+kIAF+2.*kHxInHFrame-kHxOutVFrame+2.*kHxV1mm;
1772 posY = 2.*kHyInHFrame+kHyOutVFrame;
ba030c0e 1773 posZ = 0.;
5f91c9e8 1774 gMC->Gspos("SQ25",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1775
d1cd2474 1776 // keep memory of the mid position. Used for placing screws
1777 const GReal_t kMidOVposX = posX;
1778 const GReal_t kMidOVposY = posY;
1779 const GReal_t kMidOVposZ = posZ;
1780
1781 const Float_t kTOPY = posY+kHyOutVFrame;
1782 const Float_t kOUTX = posX;
ba030c0e 1783
5f91c9e8 1784// OutVFrame corner
d1cd2474 1785 posX = kOUTX;
1786 posY = kTOPY+((kBl1OCTF+kTl1OCTF)/2.);
5f91c9e8 1787 posZ = 0.;
1788 gMC->Gspos("SQ26",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1,"ONLY");
1789
1790// VertEarthFaceCu - 2 copies
1791 posX = 89.4000+fgkDeltaQuadLHC;
1792 posY = 25.79+fgkDeltaQuadLHC;
d1cd2474 1793 posZ = kHzFrameThickness+2.0*kHzFoam+kHzVertEarthFaceCu;
5f91c9e8 1794 gMC->Gspos("SQ27",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1795 posZ = -1.0*posZ;
1796 gMC->Gspos("SQ27",2,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1797
1798// VertEarthSteel - 2 copies
1799 posX = 91.00+fgkDeltaQuadLHC;
1800 posY = 30.616+fgkDeltaQuadLHC;
d1cd2474 1801 posZ = kHzFrameThickness+2.0*kHzFoam+kHzVertBarSteel;
5f91c9e8 1802 gMC->Gspos("SQ28",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1803 posZ = -1.0*posZ;
1804 gMC->Gspos("SQ28",2,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1805
1806// VertEarthProfCu - 2 copies
1807 posX = 92.000+fgkDeltaQuadLHC;
1808 posY = 29.64+fgkDeltaQuadLHC;
d1cd2474 1809 posZ = kHzFrameThickness;
5f91c9e8 1810 gMC->Gspos("SQ29",1,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1811 posZ = -1.0*posZ;
1812 gMC->Gspos("SQ29",2,QuadrantMLayerName(chamber),posX, posY, posZ, rot1, "ONLY");
1813
1814// SuppLateralPositionner - 2 copies
d1cd2474 1815 posX = 90.2-kNearFarLHC;
1816 posY = 5.00-kNearFarLHC;
1817 posZ = kHzLateralPosnAl-fgkMotherThick2;
5f91c9e8 1818 gMC->Gspos("SQ30",1,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1819 posZ = -1.0*posZ;
1820 gMC->Gspos("SQ30",2,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1821
1822// LateralPositionner - 2 copies - Face view
d1cd2474 1823 posX = 92.175-kNearFarLHC-2.*kHxLPP;
1824 posY = 5.00-kNearFarLHC;
1825 posZ =2.0*kHzLateralPosnAl+kHzLateralPosnInoxFace-fgkMotherThick2;
5f91c9e8 1826 gMC->Gspos("SQ31",1,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1827 posZ = -1.0*posZ;
1828 gMC->Gspos("SQ31",2,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1829
1830// LateralPositionner - Profile view
d1cd2474 1831 posX = 92.175+fgkDeltaQuadLHC+kHxLPF-kHxLPP;
5f91c9e8 1832 posY = 5.00+fgkDeltaQuadLHC;
1833 posZ = 0.;
1834 gMC->Gspos("SQ32",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY"); // middle layer
1835
d1cd2474 1836 posX = 92.175-kNearFarLHC+kHxLPF-kHxLPP;
1837 posY = 5.0000-kNearFarLHC;
1838 posZ = fgkMotherThick2-kHzLPNF;
5f91c9e8 1839 gMC->Gspos("SQ33",1,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY"); // near layer
1840 posZ = -1.*posZ;
1841 gMC->Gspos("SQ33",2,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY"); // far layer
1842
1843// VertCradleA 1st Trapezoid - 3 copies
1844 posX = 95.73+fgkDeltaQuadLHC;
1845 posY = 33.26+fgkDeltaQuadLHC;
1846 posZ = 0.;
1847 gMC->Gspos("SQ34",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1848
d1cd2474 1849 posX = 95.73-kNearFarLHC;
1850 posY = 33.26-kNearFarLHC;
1851 posZ = 2.0*kHzLateralSightAl+kHzVerticalCradleAl-fgkMotherThick2;
5f91c9e8 1852 gMC->Gspos("SQ34",1,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1853 posZ = -1.0*posZ;
1854 gMC->Gspos("SQ34",3,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1855
1856// VertCradleB 2nd Trapezoid - 3 copies
1857 posX = 97.29+fgkDeltaQuadLHC;
1858 posY = 23.02+fgkDeltaQuadLHC;
1859 posZ = 0.;
1860 gMC->Gspos("SQ35",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1861
d1cd2474 1862 posX = 97.29-kNearFarLHC;
1863 posY = 23.02-kNearFarLHC;
1864 posZ = 2.0*kHzLateralSightAl+kHzVerticalCradleAl-fgkMotherThick2;
5f91c9e8 1865 gMC->Gspos("SQ35",1,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1866 posZ = -1.0*posZ;
1867 gMC->Gspos("SQ35",3,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1868
1869// OutVertCradleC 3rd Trapeze - 3 copies
1870 posX = 98.31+fgkDeltaQuadLHC;
1871 posY = 12.77+fgkDeltaQuadLHC;
1872 posZ = 0.;
1873 gMC->Gspos("SQ36",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1874
b367fd8f 1875 posX = 98.05-kNearFarLHC;
d1cd2474 1876 posY = 12.77-kNearFarLHC;
d1cd2474 1877 posZ = 2.0*kHzLateralSightAl+kHzVerticalCradleAl-fgkMotherThick2;
b367fd8f 1878 // Fix (2) of extrusion SQ36 from SQN1, SQN2, SQF1, SQF2
1879 // (was posX = 98.31 ...)
5f91c9e8 1880 gMC->Gspos("SQ36",1,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1881 posZ = -1.0*posZ;
1882 gMC->Gspos("SQ36",3,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1883
1884// OutVertCradleD 4th Trapeze - 3 copies
1885 posX = 98.81+fgkDeltaQuadLHC;
1886 posY = 2.52+fgkDeltaQuadLHC;
1887 posZ = 0.;
1888 gMC->Gspos("SQ37",2,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1889
d1cd2474 1890 posZ = fgkMotherThick1-kHzVerticalCradleAl;
5f91c9e8 1891 gMC->Gspos("SQ37",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1892 posZ = -1.0*posZ;
1893 gMC->Gspos("SQ37",3,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1894
1895// LateralSightSupport - 2 copies
b367fd8f 1896 posX = 98.33-kNearFarLHC;
d1cd2474 1897 posY = 10.00-kNearFarLHC;
1898 posZ = kHzLateralSightAl-fgkMotherThick2;
b367fd8f 1899 // Fix (3) of extrusion SQ38 from SQN1, SQN2, SQF1, SQF2
1900 // (was posX = 98.53 ...)
5f91c9e8 1901 gMC->Gspos("SQ38",1,QuadrantNLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1902 posZ = -1.0*posZ;
1903 gMC->Gspos("SQ38",2,QuadrantFLayerName(chamber),posX, posY, posZ, 0, "ONLY");
1904
1905// Mire placement
1906 posX = 92.84+fgkDeltaQuadLHC;
1907 posY = 8.13+fgkDeltaQuadLHC;
ba030c0e 1908 posZ = 0.;
5f91c9e8 1909 gMC->Gspos("SQ39",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0,"ONLY");
1910
1911//---
1912
1913// InHFrame
d1cd2474 1914 posX = 2.0*kHxInVFrame+2.*kHxV1mm+kIAF+kHxInHFrame;
1915 posY = kHyInHFrame;
5f91c9e8 1916 posZ = 0.;
1917 gMC->Gspos("SQ40",1,QuadrantMLayerName(chamber),posX, posY, posZ, 0, "ONLY");
ba030c0e 1918
d1cd2474 1919 // keep memory of the mid position. Used for placing screws
1920 const GReal_t kMidHposX = posX;
1921 const GReal_t kMidHposY = posY;
1922 const GReal_t kMidHposZ = posZ;
1923
5f91c9e8 1924// Flat 7.5mm horizontal section
d1cd2474 1925 posX = 2.0*kHxInVFrame+2.*kHxV1mm+kIAF+kHxH1mm;
1926 posY = 2.0*kHyInHFrame+kHyH1mm;
ba030c0e 1927 posZ = 0.;
5f91c9e8 1928 gMC->Gspos("SQ41",1,QuadrantMLayerName(chamber),posX, posY, posZ,0, "ONLY");
ba030c0e 1929
1930// InArcFrame
d1cd2474 1931 posX = 2.0*kHxInVFrame+2.*kHxV1mm;
1932 posY = 2.0*kHyInHFrame+2.*kHyH1mm;
ba030c0e 1933 posZ = 0.;
5f91c9e8 1934 gMC->Gspos("SQ42",1,QuadrantMLayerName(chamber),posX, posY, posZ,0, "ONLY");
ba030c0e 1935
d1cd2474 1936// keep memory of the mid position. Used for placing screws
1937 const GReal_t kMidArcposX = posX;
1938 const GReal_t kMidArcposY = posY;
1939 const GReal_t kMidArcposZ = posZ;
1940
5f91c9e8 1941// ScrewsInFrame - in sensitive volume
ba030c0e 1942
1943 Float_t scruX[64];
1944 Float_t scruY[64];
1945
1946// Screws on IHEpoxyFrame
1947
d1cd2474 1948 const Int_t kNumberOfScrewsIH = 14; // no. of screws on the IHEpoxyFrame
1949 const Float_t kOffX = 5.; // inter-screw distance
ba030c0e 1950
1951 // first screw coordinates
1952 scruX[0] = 21.07;
1953 scruY[0] = -2.23;
1954 // other screw coordinates
d1cd2474 1955 for (Int_t i = 1;i<kNumberOfScrewsIH;i++){
1956 scruX[i] = scruX[i-1]+kOffX;
ba030c0e 1957 scruY[i] = scruY[0];
1958 }
1959 // Position the volumes on the frames
d1cd2474 1960 for (Int_t i = 0;i<kNumberOfScrewsIH;i++){
5f91c9e8 1961 posX = fgkDeltaQuadLHC + scruX[i];
1962 posY = fgkDeltaQuadLHC + scruY[i];
ba030c0e 1963 posZ = 0.;
d1cd2474 1964 gMC->Gspos("SQ43",i+1,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ-kHzInHFrame-kSCRUHLE, 0, "ONLY");
1965 if (chamber==1)
1966 gMC->Gspos("SQ44",i+1,"SQ40",posX+0.1-kMidHposX, posY+0.1-kMidHposY, posZ-kMidHposZ, 0, "ONLY");
1967 gMC->Gspos("SQ45",i+1,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ+kHzInHFrame+kSCRUNLE, 0, "ONLY");
ba030c0e 1968 }
1969 // special screw coordinates
1970 scruX[63] = 16.3;
1971 scruY[63] = -2.23;
5f91c9e8 1972 posX = fgkDeltaQuadLHC + scruX[63];
1973 posY = fgkDeltaQuadLHC + scruY[63];
ba030c0e 1974 posZ = 0.;
d1cd2474 1975 gMC->Gspos("SQ43",64,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ-kHzInHFrame-kSCRUHLE, 0, "ONLY");
1976 if (chamber==1)
1977 gMC->Gspos("SQ44",64,"SQ40",posX+0.1-kMidHposX, posY+0.1-kMidHposY, posZ-kMidHposZ, 0, "ONLY");
1978 gMC->Gspos("SQ45",64,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ+kHzInHFrame+kSCRUNLE, 0, "ONLY");
ba030c0e 1979
1980// Screws on the IVEpoxyFrame
1981
d1cd2474 1982 const Int_t kNumberOfScrewsIV = 15; // no. of screws on the IVEpoxyFrame
1983 const Float_t kOffY = 5.; // inter-screw distance
c03e5213 1984 Int_t firstScrew = 58;
1985 Int_t lastScrew = 44;
ba030c0e 1986
1987 // first (special) screw coordinates
c03e5213 1988 scruX[firstScrew-1] = -2.23;
1989 scruY[firstScrew-1] = 16.3;
ba030c0e 1990 // second (repetitive) screw coordinates
c03e5213 1991 scruX[firstScrew-2] = -2.23;
1992 scruY[firstScrew-2] = 21.07;
ba030c0e 1993 // other screw coordinates
c03e5213 1994 for (Int_t i = firstScrew-3;i>lastScrew-2;i--){
1995 scruX[i] = scruX[firstScrew-2];
d1cd2474 1996 scruY[i] = scruY[i+1]+kOffY;
ba030c0e 1997 }
1998
d1cd2474 1999 for (Int_t i = 0;i<kNumberOfScrewsIV;i++){
c03e5213 2000 posX = fgkDeltaQuadLHC + scruX[i+lastScrew-1];
2001 posY = fgkDeltaQuadLHC + scruY[i+lastScrew-1];
ba030c0e 2002 posZ = 0.;
d1cd2474 2003 gMC->Gspos("SQ43",i+lastScrew,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ-kHzInHFrame-kSCRUHLE, 0, "ONLY");
2004 if (chamber==1)
2005 gMC->Gspos("SQ44",i+lastScrew,"SQ00",posX+0.1-kMidVposX, posY+0.1-kMidVposY, posZ-kMidVposZ, 0, "ONLY");
2006 gMC->Gspos("SQ45",i+lastScrew,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ+kHzInHFrame+kSCRUNLE, 0, "ONLY");
ba030c0e 2007 }
2008
2009// Screws on the OVEpoxyFrame
2010
d1cd2474 2011 const Int_t kNumberOfScrewsOV = 10; // no. of screws on the OVEpoxyFrame
ba030c0e 2012
c03e5213 2013 firstScrew = 15;
2014 lastScrew = 25;
ba030c0e 2015
2016 // first (repetitive) screw coordinates
d1cd2474 2017 // notes: 1st screw should be placed in volume 40 (InnerHorizFrame)
c03e5213 2018 scruX[firstScrew-1] = 90.9;
2019 scruY[firstScrew-1] = -2.23; // true value
ba030c0e 2020
2021 // other screw coordinates
c03e5213 2022 for (Int_t i = firstScrew; i<lastScrew; i++ ){
2023 scruX[i] = scruX[firstScrew-1];
d1cd2474 2024 scruY[i] = scruY[i-1]+kOffY;
ba030c0e 2025 }
d1cd2474 2026 for (Int_t i = 1;i<kNumberOfScrewsOV;i++){
c03e5213 2027 posX = fgkDeltaQuadLHC + scruX[i+firstScrew-1];
2028 posY = fgkDeltaQuadLHC + scruY[i+firstScrew-1];
ba030c0e 2029 posZ = 0.;
d1cd2474 2030 gMC->Gspos("SQ43",i+firstScrew,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ-kHzInHFrame-kSCRUHLE, 0, "ONLY");
2031 // ??
2032 if (chamber==1)
2033 gMC->Gspos("SQ44",i+firstScrew,"SQ25",posX+0.1-kMidOVposX, posY+0.1-kMidOVposY, posZ-kMidOVposZ, 0, "ONLY");
2034 gMC->Gspos("SQ45",i+firstScrew,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ+kHzInHFrame+kSCRUNLE, 0, "ONLY");
ba030c0e 2035 }
d1cd2474 2036 // special case for 1st screw, inside the horizontal frame (volume 40)
2037 posX = fgkDeltaQuadLHC + scruX[firstScrew-1];
2038 posY = fgkDeltaQuadLHC + scruY[firstScrew-1];
2039 posZ = 0.;
2040 if (chamber==1)
2041 gMC->Gspos("SQ44",firstScrew,"SQ40",posX+0.1-kMidHposX, posY+0.1-kMidHposY, posZ-kMidHposZ, 0, "ONLY");
2042
ba030c0e 2043// Inner Arc of Frame, screw positions and numbers-1
2044 scruX[62] = 16.009; scruY[62] = 1.401;
2045 scruX[61] = 14.564; scruY[61] = 6.791;
2046 scruX[60] = 11.363; scruY[60] = 11.363;
2047 scruX[59] = 6.791 ; scruY[59] = 14.564;
2048 scruX[58] = 1.401 ; scruY[58] = 16.009;
2049
2050 for (Int_t i = 0;i<5;i++){
5f91c9e8 2051 posX = fgkDeltaQuadLHC + scruX[i+58];
2052 posY = fgkDeltaQuadLHC + scruY[i+58];
ba030c0e 2053 posZ = 0.;
d1cd2474 2054 gMC->Gspos("SQ43",i+58+1,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ-kHzInHFrame-kSCRUHLE, 0, "ONLY");
2055 if (chamber==1)
2056 gMC->Gspos("SQ44",i+58+1,"SQ42",posX+0.1-kMidArcposX, posY+0.1-kMidArcposY, posZ-kMidArcposZ, 0, "ONLY");
2057 gMC->Gspos("SQ45",i+58+1,QuadrantMLayerName(chamber),posX+0.1, posY+0.1, posZ+kHzInHFrame+kSCRUNLE, 0, "ONLY");
5f91c9e8 2058 }
2059}
ba030c0e 2060
5f91c9e8 2061//______________________________________________________________________________
d1cd2474 2062void AliMUONSt1GeometryBuilderV2::PlaceInnerLayers(Int_t chamber)
5f91c9e8 2063{
2064// Place the gas and copper layers for the specified chamber.
2065// --
ba030c0e 2066
5f91c9e8 2067// Rotation Matrices
2068 Int_t rot1, rot2, rot3, rot4;
ba030c0e 2069
d1cd2474 2070 fMUON->AliMatrix(rot1, 90., 315., 90., 45., 0., 0.); // -45 deg
2071 fMUON->AliMatrix(rot2, 90., 90., 90., 180., 0., 0.); // 90 deg
2072 fMUON->AliMatrix(rot3, 90., 270., 90., 0., 0., 0.); // -90 deg
2073 fMUON->AliMatrix(rot4, 90., 45., 90., 135., 0., 0.); // deg
ba030c0e 2074
5f91c9e8 2075 GReal_t x;
2076 GReal_t y;
2077 GReal_t zg = 0.;
2078 GReal_t zc = fgkHzGas + fgkHzPadPlane;
2079 Int_t dpos = (chamber-1)*2;
2080 TString name;
ba030c0e 2081
5f91c9e8 2082 x = 14.53 + fgkDeltaQuadLHC;
2083 y = 53.34 + fgkDeltaQuadLHC;
2084 name = GasVolumeName("SAG", chamber);
2085 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,0,"ONLY");
2086 gMC->Gspos("SA1C", 1+dpos, QuadrantMLayerName(chamber),x,y, zc,0,"ONLY");
2087 gMC->Gspos("SA1C", 2+dpos, QuadrantMLayerName(chamber),x,y,-zc,0,"ONLY");
2088
2089 x = 40.67 + fgkDeltaQuadLHC;
2090 y = 40.66 + fgkDeltaQuadLHC;
2091 name = GasVolumeName("SBG", chamber);
2092 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot1,"ONLY");
2093 gMC->Gspos("SB1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot1,"ONLY");
2094 gMC->Gspos("SB1C", 2+dpos, QuadrantMLayerName(chamber),x,y,-zc,rot1,"ONLY");
2095
2096 x = 53.34 + fgkDeltaQuadLHC;
2097 y = 14.52 + fgkDeltaQuadLHC;
2098 name = GasVolumeName("SCG", chamber);
2099 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot2,"ONLY");
2100 gMC->Gspos("SC1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot2,"ONLY");
2101 gMC->Gspos("SC1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot2,"ONLY");
2102
2103 x = 5.83 + fgkDeltaQuadLHC;
2104 y = 17.29 + fgkDeltaQuadLHC;
2105 name = GasVolumeName("SDG", chamber);
2106 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot3,"ONLY");
2107 gMC->Gspos("SD1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot3,"ONLY");
2108 gMC->Gspos("SD1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot3,"ONLY");
2109
2110 x = 9.04 + fgkDeltaQuadLHC;
2111 y = 16.91 + fgkDeltaQuadLHC;
2112 name = GasVolumeName("SEG", chamber);
2113 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,0,"ONLY");
2114 gMC->Gspos("SE1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,0,"ONLY");
2115 gMC->Gspos("SE1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,0,"ONLY");
2116
2117 x = 10.12 + fgkDeltaQuadLHC;
2118 y = 14.67 + fgkDeltaQuadLHC;
2119 name = GasVolumeName("SFG", chamber);
2120 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot4,"ONLY");
2121 gMC->Gspos("SF1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot4,"ONLY");
2122 gMC->Gspos("SF1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot4,"ONLY");
2123
2124 x = 8.2042 + fgkDeltaQuadLHC;
2125 y = 16.19 + fgkDeltaQuadLHC;
2126 name = GasVolumeName("SGG", chamber);
2127 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot4,"ONLY");
2128 gMC->Gspos("SG1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot4,"ONLY");
2129 gMC->Gspos("SG1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot4,"ONLY");
2130
2131 x = 14.68 + fgkDeltaQuadLHC;
2132 y = 10.10 + fgkDeltaQuadLHC;
2133 name = GasVolumeName("SHG", chamber);
2134 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot4,"ONLY");
2135 gMC->Gspos("SH1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot4,"ONLY");
2136 gMC->Gspos("SH1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot4,"ONLY");
2137
2138 x = 16.21 + fgkDeltaQuadLHC;
2139 y = 8.17 + fgkDeltaQuadLHC;
2140 name = GasVolumeName("SIG", chamber);
2141 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot4,"ONLY");
2142 gMC->Gspos("SI1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot4,"ONLY");
2143 gMC->Gspos("SI1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot4,"ONLY");
2144
2145 x = 16.92 + fgkDeltaQuadLHC;
2146 y = 9.02 + fgkDeltaQuadLHC;
2147 name = GasVolumeName("SJG", chamber);
2148 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,rot3,"ONLY");
2149 gMC->Gspos("SJ1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,rot3,"ONLY");
2150 gMC->Gspos("SJ1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,rot3,"ONLY");
2151
2152 x = 17.30 + fgkDeltaQuadLHC;
2153 y = 5.85 + fgkDeltaQuadLHC;
2154 name = GasVolumeName("SKG", chamber);
2155 gMC->Gspos(name,1,QuadrantMLayerName(chamber),x,y,zg,0,"ONLY");
2156 gMC->Gspos("SK1C", 1+dpos ,QuadrantMLayerName(chamber),x,y, zc,0,"ONLY");
2157 gMC->Gspos("SK1C", 2+dpos ,QuadrantMLayerName(chamber),x,y,-zc,0,"ONLY");
ba030c0e 2158}
2159
5f91c9e8 2160//______________________________________________________________________________
d1cd2474 2161void AliMUONSt1GeometryBuilderV2::PlaceSector(AliMpSector* sector,SpecialMap specialMap,
5f91c9e8 2162 const TVector3& where, Bool_t reflectZ, Int_t chamber)
ba030c0e 2163{
5f91c9e8 2164// Place all the segments in the mother volume, at the position defined
2165// by the sector's data.
ba030c0e 2166// --
ba030c0e 2167
5f91c9e8 2168 static Int_t segNum=1;
2169 Int_t sgn;
2170 Int_t reflZ;
2171 Int_t rotMat;
2172
2173 if (!reflectZ) {
2174 sgn= 1;
2175 reflZ=0; // no reflection along z... nothing
d1cd2474 2176 fMUON->AliMatrix(rotMat, 90.,90.,90,180.,0.,0.); // 90° rotation around z, NO reflection along z
5f91c9e8 2177 } else {
2178 sgn=-1;
d1cd2474 2179 fMUON->AliMatrix(reflZ, 90.,0.,90,90.,180.,0.); // reflection along z
2180 fMUON->AliMatrix(rotMat, 90.,90.,90,180.,180.,0.); // 90° rotation around z AND reflection along z
5f91c9e8 2181 }
2182
ba030c0e 2183 GReal_t posX,posY,posZ;
2184
d1cd2474 2185#ifdef ST1_WITH_STL
2186 vector<Int_t> alreadyDone;
2187#endif
2188
2189#ifdef ST1_WITH_ROOT
2190 TArrayI alreadyDone(20);
2191 Int_t nofAlreadyDone = 0;
2192#endif
2193
5f91c9e8 2194 for (Int_t irow=0;irow<sector->GetNofRows();irow++){ // for each row
2195 AliMpRow* row = sector->GetRow(irow);
ba030c0e 2196
ba030c0e 2197
5f91c9e8 2198 for (Int_t iseg=0;iseg<row->GetNofRowSegments();iseg++){ // for each row segment
2199 AliMpVRowSegment* seg = row->GetRowSegment(iseg);
2200 char segName[5];
2201
d1cd2474 2202#ifdef ST1_WITH_STL
2203 SpecialMap::iterator iter
5f91c9e8 2204 = specialMap.find(seg->GetMotifPositionId(0));
ba030c0e 2205
5f91c9e8 2206 if ( iter == specialMap.end()){ //if this is a normal segment (ie. not part of <specialMap>)
d1cd2474 2207#endif
2208
2209#ifdef ST1_WITH_ROOT
2210 Long_t value = specialMap.GetValue(seg->GetMotifPositionId(0));
2211
2212 if ( value == 0 ){ //if this is a normal segment (ie. not part of <specialMap>)
2213#endif
5f91c9e8 2214
2215 // create the cathode part
2216 sprintf(segName,"%.3dM", segNum);
e77b6d6b 2217 CreatePlaneSegment(segName, seg->Dimensions(), seg->GetNofMotifs());
5f91c9e8 2218
e77b6d6b 2219 posX = where.X() + seg->Position().X();
2220 posY = where.Y() + seg->Position().Y();
5f91c9e8 2221 posZ = where.Z() + sgn * (TotalHzPlane() + fgkHzGas + 2.*fgkHzPadPlane);
2222 gMC->Gspos(segName, 1, QuadrantMLayerName(chamber), posX, posY, posZ, reflZ, "ONLY");
2223
2224 // and place all the daughter boards of this segment
2225 for (Int_t motifNum=0;motifNum<seg->GetNofMotifs();motifNum++) {
e8c253a0 2226
2227 // Copy number
5f91c9e8 2228 Int_t motifPosId = seg->GetMotifPositionId(motifNum);
2229 AliMpMotifPosition* motifPos =
2230 sector->GetMotifMap()->FindMotifPosition(motifPosId);
e8c253a0 2231 Int_t copyNo = motifPosId;
2232 if ( sector->GetDirection() == kX) copyNo += fgkDaughterCopyNoOffset;
5f91c9e8 2233
e8c253a0 2234 // Position
e77b6d6b 2235 posX = where.X() + motifPos->Position().X() + fgkOffsetX;
2236 posY = where.Y() + motifPos->Position().Y() + fgkOffsetY;
5f91c9e8 2237 posZ = where.Z() + sgn * (fgkMotherThick1 - TotalHzDaughter());
e8c253a0 2238
2239 gMC->Gspos(fgkDaughterName, copyNo, QuadrantMLayerName(chamber), posX, posY, posZ, reflZ, "ONLY");
5f91c9e8 2240 }
2241 segNum++;
2242
2243 } else {
2244
2245 // if this is a special segment
2246 for (Int_t motifNum=0;motifNum<seg->GetNofMotifs();motifNum++) {// for each motif
2247
2248 Int_t motifPosId = seg->GetMotifPositionId(motifNum);
2249
d1cd2474 2250#ifdef ST1_WITH_STL
2251 if (find(alreadyDone.begin(),alreadyDone.end(),motifPosId)
2252 != alreadyDone.end()) continue; // don't treat the same motif twice
2253
5f91c9e8 2254 AliMUONSt1SpecialMotif spMot = specialMap[motifPosId];
d1cd2474 2255#endif
2256#ifdef ST1_WITH_ROOT
2257 Bool_t isDone = false;
2258 Int_t i=0;
2259 while (i<nofAlreadyDone && !isDone) {
2260 if (alreadyDone.At(i) == motifPosId) isDone=true;
2261 i++;
2262 }
2263 if (isDone) continue; // don't treat the same motif twice
2264
2265 AliMUONSt1SpecialMotif spMot = *((AliMUONSt1SpecialMotif*)specialMap.GetValue(motifPosId));
2266#endif
2267 // check
2268 // cout << chamber << " processing special motif: " << motifPosId << endl;
2269
5f91c9e8 2270 AliMpMotifPosition* motifPos = sector->GetMotifMap()->FindMotifPosition(motifPosId);
2271
e8c253a0 2272 // Copy number
2273 Int_t copyNo = motifPosId;
2274 if ( sector->GetDirection() == kX) copyNo += fgkDaughterCopyNoOffset;
2275
5f91c9e8 2276 // place the hole for the motif, wrt the requested rotation angle
2277 Int_t rot = ( spMot.GetRotAngle()<0.1 ) ? reflZ:rotMat;
2278
e77b6d6b 2279 posX = where.X() + motifPos->Position().X() + spMot.GetDelta().X();
2280 posY = where.Y() + motifPos->Position().Y() + spMot.GetDelta().Y();
5f91c9e8 2281 posZ = where.Z() + sgn * (TotalHzPlane() + fgkHzGas + 2.*fgkHzPadPlane);
e8c253a0 2282 gMC->Gspos(fgkHoleName, copyNo, QuadrantMLayerName(chamber), posX, posY, posZ, rot, "ONLY");
5f91c9e8 2283
2284 // then place the daughter board for the motif, wrt the requested rotation angle
2285 posX = posX+fgkDeltaFilleEtamX;
2286 posY = posY+fgkDeltaFilleEtamY;
2287 posZ = where.Z() + sgn * (fgkMotherThick1 - TotalHzDaughter());
e8c253a0 2288 gMC->Gspos(fgkDaughterName, copyNo, QuadrantMLayerName(chamber), posX, posY, posZ, rot, "ONLY");
5f91c9e8 2289
d1cd2474 2290#ifdef ST1_WITH_STL
2291 alreadyDone.push_back(motifPosId);// mark this motif as done
2292#endif
2293#ifdef ST1_WITH_ROOT
2294 if (nofAlreadyDone == alreadyDone.GetSize())
2295 alreadyDone.Set(2*nofAlreadyDone);
2296 alreadyDone.AddAt(motifPosId, nofAlreadyDone++);
2297#endif
2298 // check
2299 // cout << chamber << " processed motifPosId: " << motifPosId << endl;
5f91c9e8 2300 }
2301 }// end of special motif case
2302 }
2303 }
2304}
2305
2306//______________________________________________________________________________
d1cd2474 2307TString AliMUONSt1GeometryBuilderV2::GasVolumeName(const TString& name, Int_t chamber) const
ba030c0e 2308{
5f91c9e8 2309// Inserts the chamber number into the name.
2310// ---
ba030c0e 2311
5f91c9e8 2312 TString newString(name);
2313
2314 TString number("");
2315 number += chamber;
ba030c0e 2316
5f91c9e8 2317 newString.Insert(2, number);
ba030c0e 2318
5f91c9e8 2319 return newString;
ba030c0e 2320}
2321
d1cd2474 2322/*
5f91c9e8 2323//______________________________________________________________________________
d1cd2474 2324Bool_t AliMUONSt1GeometryBuilderV2::IsInChamber(Int_t ich, Int_t volGid) const
ba030c0e 2325{
5f91c9e8 2326// True if volume <volGid> is part of the sensitive
2327// volumes of chamber <ich>
2328// ---
2329 for (Int_t i = 0; i < fChamberV2[ich]->GetSize(); i++) {
2330 if (fChamberV2[ich]->At(i) == volGid) return kTRUE;
2331 }
2332 return kFALSE;
2333}
d1cd2474 2334*/
ba030c0e 2335
5f91c9e8 2336//
2337// protected methods
2338//
ba030c0e 2339
d1cd2474 2340/*
5f91c9e8 2341//______________________________________________________________________________
d1cd2474 2342Int_t AliMUONSt1GeometryBuilderV2::GetChamberId(Int_t volId) const
5f91c9e8 2343{
2344// Check if the volume with specified volId is a sensitive volume (gas)
2345// of some chamber and returns the chamber number;
2346// if not sensitive volume - return 0.
2347// ---
2348
2349 for (Int_t i = 1; i <=2; i++)
2350 if (IsInChamber(i-1,volId)) return i;
ba030c0e 2351
5f91c9e8 2352 for (Int_t i = 3; i <= AliMUONConstants::NCh(); i++)
2353 if (volId==((AliMUONChamber*)(*fChambers)[i-1])->GetGid()) return i;
ba030c0e 2354
5f91c9e8 2355 return 0;
ba030c0e 2356}
d1cd2474 2357*/
ba030c0e 2358
5f91c9e8 2359//
2360// public methods
2361//
2362
2363//______________________________________________________________________________
d1cd2474 2364void AliMUONSt1GeometryBuilderV2::CreateMaterials()
ba030c0e 2365{
d1cd2474 2366// Materials and medias defined in MUONv1:
2367//
2368// AliMaterial( 9, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
2369// AliMaterial(10, "ALUMINIUM$", 26.98, 13., 2.7, 8.9, 37.2);
2370// AliMaterial(15, "AIR$ ", 14.61, 7.3, .001205, 30423.24, 67500);
2371// AliMixture( 19, "Bakelite$", abak, zbak, dbak, -3, wbak);
2372// AliMixture( 20, "ArC4H10 GAS$", ag, zg, dg, 3, wg);
2373// AliMixture( 21, "TRIG GAS$", atrig, ztrig, dtrig, -5, wtrig);
2374// AliMixture( 22, "ArCO2 80%$", ag1, zg1, dg1, 3, wg1);
2375// AliMixture( 23, "Ar-freon $", atr1, ztr1, dtr1, 4, wtr1);
2376// AliMixture( 24, "ArCO2 GAS$", agas, zgas, dgas, 3, wgas);
2377// AliMaterial(31, "COPPER$", 63.54, 29., 8.96, 1.4, 0.);
2378// AliMixture( 32, "Vetronite$",aglass, zglass, dglass, 5, wglass);
2379// AliMaterial(33, "Carbon$", 12.01, 6., 2.265, 18.8, 49.9);
2380// AliMixture( 34, "Rohacell$", arohac, zrohac, drohac, -4, wrohac);
2381
2382// AliMedium( 1, "AIR_CH_US ", 15, 1, iSXFLD, ...
2383// AliMedium( 4, "ALU_CH_US ", 9, 0, iSXFLD, ...
2384// AliMedium( 5, "ALU_CH_US ", 10, 0, iSXFLD, ...
2385// AliMedium( 6, "AR_CH_US ", 20, 1, iSXFLD, ...
2386// AliMedium( 7, "GAS_CH_TRIGGER ", 21, 1, iSXFLD, ...
2387// AliMedium( 8, "BAKE_CH_TRIGGER ", 19, 0, iSXFLD, ...
2388// AliMedium( 9, "ARG_CO2 ", 22, 1, iSXFLD, ...
2389// AliMedium(11, "PCB_COPPER ", 31, 0, iSXFLD, ...
2390// AliMedium(12, "VETRONITE ", 32, 0, iSXFLD, ...
2391// AliMedium(13, "CARBON ", 33, 0, iSXFLD, ...
2392// AliMedium(14, "Rohacell ", 34, 0, iSXFLD, ...
2393
2394 //
2395 // --- Define materials for GEANT ---
2396 //
2397
2398 fMUON->AliMaterial(41, "Aluminium II$", 26.98, 13., 2.7, -8.9, 26.1);
2399 // was id: 9
2400 // from PDG and "The Particle Detector BriefBook", Bock and Vasilescu, P.18
2401 // ??? same but the last but one argument < 0
d1cd2474 2402 //
2403 // --- Define mixtures for GEANT ---
2404 //
2405
2406 // Ar-CO2 gas II (80%+20%)
2407 Float_t ag1[2] = { 39.95, 44.01};
2408 Float_t zg1[2] = { 18., 22.};
2409 Float_t wg1[2] = { .8, 0.2};
2410 Float_t dg1 = .001821;
2411 fMUON->AliMixture(45, "ArCO2 II 80%$", ag1, zg1, dg1, 2, wg1);
2412 // was id: 22
2413 // use wg1 weighting factors (6th arg > 0)
2414
2415 // Rohacell 51 II - imide methacrylique
2416 Float_t aRohacell51[4] = { 12.01, 1.01, 16.00, 14.01};
2417 Float_t zRohacell51[4] = { 6., 1., 8., 7.};
2418 Float_t wRohacell51[4] = { 9., 13., 2., 1.};
5f91c9e8 2419 Float_t dRohacell51 = 0.052;
d1cd2474 2420 fMUON->AliMixture(46, "FOAM$",aRohacell51,zRohacell51,dRohacell51,-4,wRohacell51);
2421 // was id: 32
2422 // use relative A (molecular) values (6th arg < 0)
5f91c9e8 2423
d1cd2474 2424 Float_t aSnPb[2] = { 118.69, 207.19};
2425 Float_t zSnPb[2] = { 50, 82};
2426 Float_t wSnPb[2] = { 0.6, 0.4} ;
5f91c9e8 2427 Float_t dSnPb = 8.926;
d1cd2474 2428 fMUON->AliMixture(47, "SnPb$", aSnPb,zSnPb,dSnPb,2,wSnPb);
2429 // was id: 35
2430 // use wSnPb weighting factors (6th arg > 0)
ba030c0e 2431
5f91c9e8 2432 // plastic definition from K5, Freiburg (found on web)
d1cd2474 2433 Float_t aPlastic[2]={ 1.01, 12.01};
2434 Float_t zPlastic[2]={ 1, 6};
2435 Float_t wPlastic[2]={ 1, 1};
5f91c9e8 2436 Float_t denPlastic=1.107;
d1cd2474 2437 fMUON->AliMixture(48, "Plastic$",aPlastic,zPlastic,denPlastic,-2,wPlastic);
2438 // was id: 33
2439 // use relative A (molecular) values (6th arg < 0)...no other info...
5f91c9e8 2440
d1cd2474 2441 // Not used, to be removed
2442 //
d1cd2474 2443 // was id: 34
2444
5f91c9e8 2445 // Inox/Stainless Steel (18%Cr, 9%Ni)
d1cd2474 2446 Float_t aInox[3] = {55.847, 51.9961, 58.6934};
2447 Float_t zInox[3] = {26., 24., 28.};
2448 Float_t wInox[3] = {0.73, 0.18, 0.09};
5f91c9e8 2449 Float_t denInox = 7.930;
d1cd2474 2450 fMUON->AliMixture(50, "StainlessSteel$",aInox,zInox,denInox,3,wInox);
2451 // was id: 37
2452 // use wInox weighting factors (6th arg > 0)
2453 // from CERN note NUFACT Note023, Oct.2000
2454 //
2455 // End - Not used, to be removed
2456
2457 //
2458 // --- Define the tracking medias for GEANT ---
2459 //
2460
5f91c9e8 2461 GReal_t epsil = .001; // Tracking precision,
d1cd2474 2462 //GReal_t stemax = -1.; // Maximum displacement for multiple scat
5f91c9e8 2463 GReal_t tmaxfd = -20.; // Maximum angle due to field deflection
d1cd2474 2464 //GReal_t deemax = -.3; // Maximum fractional energy loss, DLS
5f91c9e8 2465 GReal_t stmin = -.8;
d1cd2474 2466 GReal_t maxStepAlu = fMUON->GetMaxStepAlu();
2467 GReal_t maxDestepAlu = fMUON->GetMaxDestepAlu();
2468 GReal_t maxStepGas = fMUON->GetMaxStepGas();
5f91c9e8 2469 Int_t iSXFLD = gAlice->Field()->Integ();
2470 Float_t sXMGMX = gAlice->Field()->Max();
2471
d1cd2474 2472 fMUON->AliMedium(21, "ALU_II$", 41, 0, iSXFLD, sXMGMX,
2473 tmaxfd, maxStepAlu, maxDestepAlu, epsil, stmin);
f1501d74 2474
d1cd2474 2475 // was med: 15 mat: 31
2476 fMUON->AliMedium(24, "FrameCH$", 44, 1, iSXFLD, sXMGMX,
2477 10.0, 0.001, 0.001, 0.001, 0.001);
2478 // was med: 20 mat: 36
2479 fMUON->AliMedium(25, "ARG_CO2_II", 45, 1, iSXFLD, sXMGMX,
2480 tmaxfd, maxStepGas, maxDestepAlu, epsil, stmin);
2481 // was med: 9 mat: 22
2482 fMUON->AliMedium(26, "FOAM_CH$", 46, 0, iSXFLD, sXMGMX,
2483 10.0, 0.1, 0.1, 0.1, 0.1, 0, 0) ;
2484 // was med: 16 mat: 32
2485 fMUON->AliMedium(27, "SnPb$", 47, 0, iSXFLD, sXMGMX,
2486 10.0, 0.01, 1.0, 0.003, 0.003);
2487 // was med: 19 mat: 35
2488 fMUON->AliMedium(28, "Plastic$", 48, 0, iSXFLD, sXMGMX,
2489 10.0, 0.01, 1.0, 0.003, 0.003);
2490 // was med: 17 mat: 33
2491
2492 // Not used, to be romoved
2493 //
f1501d74 2494
d1cd2474 2495 fMUON->AliMedium(30, "InoxBolts$", 50, 1, iSXFLD, sXMGMX,
2496 10.0, 0.01, 1.0, 0.003, 0.003);
2497 // was med: 21 mat: 37
2498 //
2499 // End - Not used, to be removed
ba030c0e 2500}
2501
5f91c9e8 2502//______________________________________________________________________________
d1cd2474 2503void AliMUONSt1GeometryBuilderV2::CreateGeometry()
ba030c0e 2504{
d1cd2474 2505// Create the detailed GEANT geometry for the dimuon arm station1
ba030c0e 2506// --
5a0e88a7 2507 AliDebug(1,"Called");
5f91c9e8 2508
2509 // Create basic volumes
2510 //
2511 CreateHole();
2512 CreateDaughterBoard();
2513 CreateInnerLayers();
ba030c0e 2514
5f91c9e8 2515 // Create reflexion matrices
2516 //
d1cd2474 2517/*
5f91c9e8 2518 Int_t reflXZ, reflYZ, reflXY;
d1cd2474 2519 fMUON->AliMatrix(reflXZ, 90., 180., 90., 90., 180., 0.);
2520 fMUON->AliMatrix(reflYZ, 90., 0., 90.,-90., 180., 0.);
2521 fMUON->AliMatrix(reflXY, 90., 180., 90., 270., 0., 0.);
2522*/
5f91c9e8 2523 // Define transformations for each quadrant
e7addd77 2524 // In old coordinate system: In new coordinate system:
5f91c9e8 2525 //
e7addd77 2526 //
2527 // II. | I. I. | II.
ecbcb19e 2528 // | (101) | (100)
e7addd77 2529 // _____ | ____ _____ | ____
2530 // | |
2531 // III. | IV. IV. | III.
ecbcb19e 2532 // (102) | (103)
5f91c9e8 2533 //
d1cd2474 2534/*
5f91c9e8 2535 Int_t rotm[4];
2536 rotm[0]=0; // quadrant I
2537 rotm[1]=reflXZ; // quadrant II
2538 rotm[2]=reflXY; // quadrant III
2539 rotm[3]=reflYZ; // quadrant IV
d1cd2474 2540*/
2541 TGeoRotation rotm[4];
2542 rotm[0] = TGeoRotation("identity");
2543 rotm[1] = TGeoRotation("reflXZ", 90., 180., 90., 90., 180., 0.);
2544 rotm[2] = TGeoRotation("reflXY", 90., 180., 90., 270., 0., 0.);
2545 rotm[3] = TGeoRotation("reflYZ", 90., 0., 90.,-90., 180., 0.);
ba030c0e 2546
5f91c9e8 2547 TVector3 scale[4];
2548 scale[0] = TVector3( 1, 1, 1); // quadrant I
2549 scale[1] = TVector3(-1, 1, -1); // quadrant II
2550 scale[2] = TVector3(-1, -1, 1); // quadrant III
2551 scale[3] = TVector3( 1, -1, -1); // quadrant IV
ba030c0e 2552
a432117a 2553 Int_t detElemId[4];
ecbcb19e 2554 detElemId[0] = 1; // quadrant I
e7addd77 2555 detElemId[1] = 0; // quadrant II
ecbcb19e 2556 detElemId[2] = 3; // quadrant III
2557 detElemId[3] = 2; // quadrant IV
a432117a 2558
5f91c9e8 2559 // Shift in Z of the middle layer
10bb087f 2560 Double_t deltaZ = 7.5/2.;
5f91c9e8 2561
2562 // Position of quadrant I wrt to the chamber position
b367fd8f 2563 // TVector3 pos0(-fgkDeltaQuadLHC, -fgkDeltaQuadLHC, deltaZ);
5f91c9e8 2564
2565 // Shift for near/far layers
2566 GReal_t shiftXY = fgkFrameOffset;
2567 GReal_t shiftZ = fgkMotherThick1+fgkMotherThick2;
2568
2569 // Build two chambers
2570 //
2571 for (Int_t ich=1; ich<3; ich++) {
2572
2573 // Create quadrant volume
2574 CreateQuadrant(ich);
2575
2576 // Place gas volumes
2577 PlaceInnerLayers(ich);
2578
2579 // Place the quadrant
2580 for (Int_t i=0; i<4; i++) {
2581
b367fd8f 2582 // DE envelope
2583 GReal_t posx0, posy0, posz0;
2584 posx0 = fgkPadXOffsetBP * scale[i].X();
2585 posy0 = fgkPadYOffsetBP * scale[i].Y();;
2586 posz0 = deltaZ * scale[i].Z();
2587 GetEnvelopes(ich-1)
2588 ->AddEnvelope(QuadrantEnvelopeName(ich,i), detElemId[i] + ich*100, true,
2589 TGeoTranslation(posx0, posy0, posz0), rotm[i]);
2590
5f91c9e8 2591 // Middle layer
a432117a 2592 GReal_t posx, posy, posz;
b367fd8f 2593 posx = -fgkDeltaQuadLHC - fgkPadXOffsetBP;
2594 posy = -fgkDeltaQuadLHC - fgkPadYOffsetBP;
2595 posz = 0.;
a432117a 2596 GetEnvelopes(ich-1)
b367fd8f 2597 ->AddEnvelopeConstituent(QuadrantMLayerName(ich), QuadrantEnvelopeName(ich,i),
2598 i+1, TGeoTranslation(posx, posy, posz));
5f91c9e8 2599
2600 // Near/far layers
b367fd8f 2601 GReal_t posx2 = posx + shiftXY;;
2602 GReal_t posy2 = posy + shiftXY;;
2603 GReal_t posz2 = posz - shiftZ;;
d1cd2474 2604 //gMC->Gspos(QuadrantNLayerName(ich), i+1, "ALIC", posx2, posy2, posz2, rotm[i],"ONLY");
a432117a 2605 GetEnvelopes(ich-1)
b367fd8f 2606 ->AddEnvelopeConstituent(QuadrantNLayerName(ich), QuadrantEnvelopeName(ich,i),
2607 i+1, TGeoTranslation(posx2, posy2, posz2));
5f91c9e8 2608
b367fd8f 2609 posz2 = posz + shiftZ;
d1cd2474 2610 //gMC->Gspos(QuadrantFLayerName(ich), i+1, "ALIC", posx2, posy2, posz2, rotm[i],"ONLY");
a432117a 2611 GetEnvelopes(ich-1)
b367fd8f 2612 ->AddEnvelopeConstituent(QuadrantFLayerName(ich), QuadrantEnvelopeName(ich,i),
2613 i+1, TGeoTranslation(posx2, posy2, posz2));
5f91c9e8 2614 }
2615 }
5f91c9e8 2616}
2617
2618//______________________________________________________________________________
d1cd2474 2619void AliMUONSt1GeometryBuilderV2::SetTransformations()
5f91c9e8 2620{
d1cd2474 2621// Defines the transformations for the station2 chambers.
2622// ---
5f91c9e8 2623
b7ef3c96 2624 Double_t zpos1 = - AliMUONConstants::DefaultChamberZ(0);
2625 SetTranslation(0, TGeoTranslation(0., 0., zpos1));
5f91c9e8 2626
b7ef3c96 2627 Double_t zpos2 = - AliMUONConstants::DefaultChamberZ(1);
2628 SetTranslation(1, TGeoTranslation(0., 0., zpos2));
d1cd2474 2629}
5f91c9e8 2630
d1cd2474 2631//______________________________________________________________________________
2632void AliMUONSt1GeometryBuilderV2::SetSensitiveVolumes()
2633{
2634// Defines the sensitive volumes for station2 chambers.
2635// ---
5f91c9e8 2636
e118b27e 2637 GetGeometry(0)->SetSensitiveVolume("SA1G");
2638 GetGeometry(0)->SetSensitiveVolume("SB1G");
2639 GetGeometry(0)->SetSensitiveVolume("SC1G");
2640 GetGeometry(0)->SetSensitiveVolume("SD1G");
2641 GetGeometry(0)->SetSensitiveVolume("SE1G");
2642 GetGeometry(0)->SetSensitiveVolume("SF1G");
2643 GetGeometry(0)->SetSensitiveVolume("SG1G");
2644 GetGeometry(0)->SetSensitiveVolume("SH1G");
2645 GetGeometry(0)->SetSensitiveVolume("SI1G");
2646 GetGeometry(0)->SetSensitiveVolume("SJ1G");
2647 GetGeometry(0)->SetSensitiveVolume("SK1G");
d1cd2474 2648
e118b27e 2649 GetGeometry(1)->SetSensitiveVolume("SA2G");
2650 GetGeometry(1)->SetSensitiveVolume("SB2G");
2651 GetGeometry(1)->SetSensitiveVolume("SC2G");
2652 GetGeometry(1)->SetSensitiveVolume("SD2G");
2653 GetGeometry(1)->SetSensitiveVolume("SE2G");
2654 GetGeometry(1)->SetSensitiveVolume("SF2G");
2655 GetGeometry(1)->SetSensitiveVolume("SG2G");
2656 GetGeometry(1)->SetSensitiveVolume("SH2G");
2657 GetGeometry(1)->SetSensitiveVolume("SI2G");
2658 GetGeometry(1)->SetSensitiveVolume("SJ2G");
2659 GetGeometry(1)->SetSensitiveVolume("SK2G");
ba030c0e 2660}
5f91c9e8 2661