EMC bad channels map added.
[u/mrichter/AliRoot.git] / ITS / AliITSv11GeometrySSD.cxx
CommitLineData
d7599219 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16
17//*************************************************************************
18// SSD geometry, based on ROOT geometrical modeler
19//
20// Enrico Cattaruzza ecattar@ts.infn.it
21//*************************************************************************
22#include "TMath.h"
23#include "TGeoVolume.h"
44285dfa 24//#include "TGeoMedium.h"
d7599219 25#include "TGeoMatrix.h"
26#include <TGeoManager.h>
d7599219 27#include "TVector3.h"
28#include "TGeoArb8.h"
29#include "TList.h"
30#include "TGeoMatrix.h"
31#include "TGeoCompositeShape.h"
32#include "TGeoTube.h"
33#include "TGeoBBox.h"
44285dfa 34#include "AliITSv11GeometrySSD.h"
d7599219 35/////////////////////////////////////////////////////////////////////////////////
36//Parameters for SSD Geometry
37/////////////////////////////////////////////////////////////////////////////////
38// Layer5 (lengths are in mm and angles in degrees)
39/////////////////////////////////////////////////////////////////////////////////
40const Double_t AliITSv11GeometrySSD::fgkSSDLay5LadderLength = 950.7;
41const Int_t AliITSv11GeometrySSD::fgkSSDLay5SensorsNumber = 22;
42const Int_t AliITSv11GeometrySSD::fgkSSDLay5LadderNumber = 34;
43const Double_t AliITSv11GeometrySSD::fgkSSDLay5RadiusMin = 378.0;
44const Double_t AliITSv11GeometrySSD::fgkSSDLay5RadiusMax = 384.0;
45const Double_t AliITSv11GeometrySSD::fgkLay5CenterITSPosition = 467.85;
46/////////////////////////////////////////////////////////////////////////////////
47// Layer6 (lengths are in mm and angles in degrees)
48/////////////////////////////////////////////////////////////////////////////////
49const Double_t AliITSv11GeometrySSD::fgkSSDLay6LadderLength = 1068.0;
50const Int_t AliITSv11GeometrySSD::fgkSSDLay6SensorsNumber = 25;
51const Int_t AliITSv11GeometrySSD::fgkSSDLay6LadderNumber = 38;
52const Double_t AliITSv11GeometrySSD::fgkSSDLay6RadiusMin = 428.0;
53const Double_t AliITSv11GeometrySSD::fgkSSDLay6RadiusMax = 434.0;
54const Double_t AliITSv11GeometrySSD::fgkLay6CenterITSPosition = 526.50;
55/////////////////////////////////////////////////////////////////////////////////
56// SSD Chips and Hybrid (lengths are in mm and angles in degrees)
57/////////////////////////////////////////////////////////////////////////////////
58const Int_t AliITSv11GeometrySSD::fgkSSDChipNumber = 6;
59const Double_t AliITSv11GeometrySSD::fgkSSDChipLength = 11.100;
60const Double_t AliITSv11GeometrySSD::fgkSSDChipWidth = 3.850;
61const Double_t AliITSv11GeometrySSD::fgkSSDChipHeight = 0.180;
62const Double_t AliITSv11GeometrySSD::fgkSSDChipSeparationLength = 1.000;
63const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueLength = fgkSSDChipLength;
64const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueWidth = fgkSSDChipWidth;
65const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueHeight = 0.030;
66/////////////////////////////////////////////////////////////////////////////////
67// Stiffener (lengths are in mm and angles in degrees)
68/////////////////////////////////////////////////////////////////////////////////
69const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerLength = 73.000;
70const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerWidth = 6.500;
71//const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerHeight = 3.315;
72const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerHeight = 0.315;
73const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerToChipDist = 2.500;
74const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Length = 1.600;
75const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Width = 0.870;
76const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Height = 0.800;
77const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Length = 4.600;
78const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Width = 3.400;
79const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Height = 1.400;
80const Double_t AliITSv11GeometrySSD::fgkSSDWireLength = 30.000;
81const Double_t AliITSv11GeometrySSD::fgkSSDWireRadius = 0.185;
82const Double_t AliITSv11GeometrySSD::fgkSSDConnectorPosition[2] = {44.32, 0.33};
83const Double_t AliITSv11GeometrySSD::fgkSSDConnectorSeparation = 0.44;
84const Double_t AliITSv11GeometrySSD::fgkSSDConnectorLength = 2.16;
85const Double_t AliITSv11GeometrySSD::fgkSSDConnectorWidth = 3.60;
86const Double_t AliITSv11GeometrySSD::fgkSSDConnectorHeight =
87 0.25*fgkSSDStiffenerHeight;
88/////////////////////////////////////////////////////////////////////////////////
89// Cooling Block (lengths are in mm and angles in degrees)
90/////////////////////////////////////////////////////////////////////////////////
91const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockLength = 3.000;
92const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockWidth = 4.000;
93const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHeight[3] =
94 {1.950, 0.240, 0.300};
95const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleRadius[2] =
96 {1.000, 0.120};
97const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleLength[2] =
98 {1.900, 0.400};
99const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleCenter =
100 1.500;
101const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleHeight =
102 0.300;
103/////////////////////////////////////////////////////////////////////////////////
104// SSD Sensor (lengths are in mm and angles in degrees)
105/////////////////////////////////////////////////////////////////////////////////
106const char* AliITSv11GeometrySSD::fgkSSDSensitiveVolName =
107 "SSDSensorSensitiveVol";
108const Double_t AliITSv11GeometrySSD::fgkSSDSensorLength = 42.000;
109const Double_t AliITSv11GeometrySSD::fgkSSDSensorHeight = 0.300;
110const Double_t AliITSv11GeometrySSD::fgkSSDSensorWidth = 75.000;
111const Double_t AliITSv11GeometrySSD::fgkSSDSensorOverlap =
112 fgkSSDSensorLength-39.1;
113const Double_t AliITSv11GeometrySSD::fgkSSDSensorInsensitiveLength = 1.;
114const Double_t AliITSv11GeometrySSD::fgkSSDSensorInsensitiveWidth = 1.;
115/////////////////////////////////////////////////////////////////////////////////
116// Flex (lengths are in mm and angles in degrees)
117/////////////////////////////////////////////////////////////////////////////////
118const Double_t AliITSv11GeometrySSD::fgkSSDFlexFullLength = 106.000;
119const Double_t AliITSv11GeometrySSD::fgkSSDFlexLength[4] =
120 {0.5*(fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
121 +(fgkSSDChipNumber-1)*fgkSSDChipSeparationLength),
122 0.5*(fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
123 +(fgkSSDChipNumber-1)*fgkSSDChipSeparationLength)-4.000,
124 9.500, 10.000};
125const Double_t AliITSv11GeometrySSD::fgkSSDFlexWidth[2] =
126 { 9.340, 5.380};
127const Double_t AliITSv11GeometrySSD::fgkSSDFlexHeight[2] =
128 { 0.030, 0.020};
129const Double_t AliITSv11GeometrySSD::fgkSSDFlexAngle = 30.000;
130const Double_t AliITSv11GeometrySSD::fgkSSDFlexHoleLength = 1.430;
131const Double_t AliITSv11GeometrySSD::fgkSSDFlexHoleWidth = 3.000;
132const Double_t AliITSv11GeometrySSD::fgkSSDEndFlexCompLength[6] =
133 {3.30,4.12,4.22,1.70,0.75,7.18};
134const Double_t AliITSv11GeometrySSD:: fgkSSDEndFlexCompWidth[3] =
135 {15.03,23.48,12.28};
136/////////////////////////////////////////////////////////////////////////////////
137// SSD Ladder Cable (lengths are in mm and angles in degrees)
138/////////////////////////////////////////////////////////////////////////////////
139const Double_t AliITSv11GeometrySSD::fgkSSDLadderCableWidth = 23.5;
d7599219 140/////////////////////////////////////////////////////////////////////////////////
141// SSD Module (lengths are in mm and angles in degrees)
142/////////////////////////////////////////////////////////////////////////////////
143const Double_t AliITSv11GeometrySSD::fgkSSDModuleStiffenerPosition[2] =
144 { 1.000, 3.900};
145const Double_t AliITSv11GeometrySSD::fgkSSDModuleSensorSupportDistance =
146 45.600;
147const Double_t AliITSv11GeometrySSD::fgkSSDModuleCoolingBlockToSensor =
148 5.075;
149/////////////////////////////////////////////////////////////////////////////////
150// Sensor Support (lengths are in mm and angles in degrees)
151/////////////////////////////////////////////////////////////////////////////////
152const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportLength =
153 5.800;
154const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportWidth =
155 2.000;
156const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportHeight[2] =
157 { 4.620, 5.180};
158const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportThickness[2] =
159 { 0.450, 0.450};
160const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportPosition =
161 0.5*(fgkSSDModuleSensorSupportDistance
162 + fgkSSDSensorSideSupportThickness[0])
163 - fgkSSDSensorSideSupportLength;
164const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportLength =
165 5.250;
166const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportWidth =
167 1.680;
168const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportHeight[2] =
169 {fgkSSDSensorSideSupportHeight[0]+fgkSSDSensorSideSupportThickness[0],
170 fgkSSDSensorSideSupportHeight[1]+fgkSSDSensorSideSupportThickness[1]};
171const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportThickness[2] =
172 {fgkSSDSensorSideSupportThickness[0],fgkSSDSensorSideSupportThickness[1]};
173const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportPosition =
174 19.000;
175/////////////////////////////////////////////////////////////////////////////////
176// Chip Cables (lengths are in mm and angles in degrees)
177/////////////////////////////////////////////////////////////////////////////////
178const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesLength[2] =
179 {73.12/fgkSSDChipNumber,fgkSSDChipLength+2.*0.19};
180const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesHeight[4] =
181 { 0.014, 0.010, fgkSSDModuleCoolingBlockToSensor
182 - (fgkSSDSensorSideSupportHeight[1]-fgkSSDSensorSideSupportHeight[0])
183 - fgkSSDCoolingBlockHoleCenter-fgkSSDStiffenerHeight
184 - fgkSSDChipHeight-fgkSSDSensorHeight,
185 fgkSSDModuleCoolingBlockToSensor
186 - fgkSSDCoolingBlockHoleCenter-fgkSSDStiffenerHeight
187 - fgkSSDChipHeight-fgkSSDSensorHeight};
188const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesWidth[3] =
189 { 11.000, 0.800, 0.600};
190/////////////////////////////////////////////////////////////////////////////////
191// Carbon Fiber Junction Parameters (lengths are in mm and angles in degrees)
192/////////////////////////////////////////////////////////////////////////////////
193const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionLength =
194 3.820;
195//const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionLength =
196// 3.780;
197const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionWidth =
198 fgkSSDSensorLength-fgkSSDSensorOverlap;
199const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionEdge[2] =
200 { 0.86, 0.30};
201const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionAngle[2] =
202 { 30.00, 90.00};
203const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionToSensorSupport =
204 1.78;
205/////////////////////////////////////////////////////////////////////////////////
206//Carbon Fiber Parameters (lengths are in mm and angles in degrees)
207/////////////////////////////////////////////////////////////////////////////////
208const Double_t AliITSv11GeometrySSD::fgkCarbonFiberTriangleLength =
209 fgkSSDModuleSensorSupportDistance-2.*fgkCarbonFiberJunctionToSensorSupport;
210const Double_t AliITSv11GeometrySSD::fgkCarbonFiberTriangleAngle =
211 60.00;
212const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportTopEdgeDist[2] =
213 { 0.751, 0.482};
214const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportEdgeLength =
215 1.630;
216const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportWidth =
217 0.950;
218const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportXAxisLength =
219 fgkCarbonFiberTriangleLength-0.5*fgkCarbonFiberSupportTopEdgeDist[1]
220 / TMath::Cos(fgkCarbonFiberTriangleAngle*TMath::DegToRad());
221const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportYAxisLength =
222 0.5*(fgkCarbonFiberJunctionWidth-fgkCarbonFiberSupportWidth)
223 - fgkCarbonFiberSupportTopEdgeDist[0]-fgkCarbonFiberSupportWidth;
224/////////////////////////////////////////////////////////////////////////////////
225// Carbon Fiber Lower Support Parameters (lengths are in mm)
226/////////////////////////////////////////////////////////////////////////////////
227const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportWidth
228 = 0.950;
229const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportLowerLenght
230 = 1.600;
231const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportHeight
232 = 0.830;
233const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportVolumeSeparation
234 = 0.5*fgkCarbonFiberSupportWidth;
235const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportTransverseWidth
236 = fgkCarbonFiberJunctionWidth
237 - 2.*(fgkCarbonFiberLowerSupportWidth
238 + fgkCarbonFiberLowerSupportVolumeSeparation);
239const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportVolumePosition[2]
240 = {fgkCarbonFiberLowerSupportWidth
241 + fgkCarbonFiberLowerSupportVolumeSeparation,
242 fgkCarbonFiberLowerSupportWidth
243 + fgkCarbonFiberLowerSupportVolumeSeparation
244 + fgkCarbonFiberLowerSupportTransverseWidth};
245/////////////////////////////////////////////////////////////////////////////////
246// End Ladder Carbon Fiber Junction Parameters (lengths are in mm and angles in degrees)
247/////////////////////////////////////////////////////////////////////////////////
248const Double_t AliITSv11GeometrySSD::fgkEndLadderCarbonFiberLowerJunctionLength[2] =
249 {0.5*(fgkSSDLay5LadderLength
250 -fgkSSDLay5SensorsNumber*fgkCarbonFiberJunctionWidth
251 -fgkCarbonFiberLowerSupportWidth),
252 0.5*(fgkSSDLay5LadderLength
253 -fgkSSDLay5SensorsNumber*fgkCarbonFiberJunctionWidth
254 +fgkCarbonFiberLowerSupportWidth)};
255const Double_t AliITSv11GeometrySSD::fgkEndLadderCarbonFiberUpperJunctionLength[2] =
256 {fgkEndLadderCarbonFiberLowerJunctionLength[0]-20.4,
257 fgkEndLadderCarbonFiberLowerJunctionLength[1]-20.6};
258const Double_t AliITSv11GeometrySSD::fgkEndLadderMountingBlockPosition[2] =
259 {fgkEndLadderCarbonFiberLowerJunctionLength[0]-16.50,
260 fgkEndLadderCarbonFiberLowerJunctionLength[1]-31.50};
261/////////////////////////////////////////////////////////////////////////////////
262// Cooling Tube Support (lengths are in mm and angles in degrees)
263/////////////////////////////////////////////////////////////////////////////////
264const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportRmax = 1.45;
265const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportRmin
266 = fgkSSDCoolingBlockHoleRadius[0];
267const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportLength = 8.55;
268const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportHeight = 0.85;
269const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportWidth = 2.00;
270const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportSeparation =
271 fgkSSDSensorLength-2.*fgkSSDSensorOverlap;
272const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportToCarbonFiber = 11.70;
273/////////////////////////////////////////////////////////////////////////////////
274// Cooling Tube (lengths are in mm and angles in degrees)
275/////////////////////////////////////////////////////////////////////////////////
276const Double_t AliITSv11GeometrySSD::fgkCoolingTubeRmax =
277 fgkCoolingTubeSupportRmin;
278const Double_t AliITSv11GeometrySSD::fgkCoolingTubeRmin = 0.96;
279const Double_t AliITSv11GeometrySSD::fgkCoolingTubeLength =
280 fgkCarbonFiberJunctionWidth;
281const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSeparation =
282 fgkSSDModuleSensorSupportDistance+fgkSSDCoolingBlockLength;
283//const Double_t AliITSv11GeometrySSD_ct::fgkCoolingTubeLength = 39.1;
284/////////////////////////////////////////////////////////////////////////////////
285// SSD Mounting Block Parameters (lengths are in mm and angles in degrees)
286/////////////////////////////////////////////////////////////////////////////////
287const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockLength[3] =
288 { 60.0, 42.2, 34.0};
289const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHeight[4] =
290 { 4.0, 8.0, 5.0, 0.2};
291const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockWidth =
292 20.0;
293const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidAngle =
294 40.0;
295const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidHeight =
296 0.30*(fgkSSDMountingBlockHeight[1]-fgkSSDMountingBlockHeight[2]);
297const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidUpBasis =
298 2.5;
299const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTubeLength[2] =
300 { 56.0, 12.0};
301const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTubeWidth[2] =
302 { 5.0, 2.9};
303const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleRadius =
304 1.0;
305const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleEdge =
306 6.0;
307const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleHeigth =
308 4.0;
309const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleRadius[2] =
310 { 1.5,fgkSSDMountingBlockScrewHoleEdge/6.};
311/////////////////////////////////////////////////////////////////////////////////
44285dfa 312ClassImp(AliITSv11GeometrySSD)
313/////////////////////////////////////////////////////////////////////////////////
314AliITSv11GeometrySSD::AliITSv11GeometrySSD(): TObject(),
315 fSSDChipMedium(),
316 fSSDChipGlueMedium(),
317 fSSDStiffenerMedium(),
318 fSSDStiffenerConnectorMedium(),
319 fSSDStiffener0603CapacitorMedium(),
320 fSSDStiffener1812CapacitorMedium(),
321 fSSDStiffenerHybridWireMedium(),
322 fSSDKaptonFlexMedium(),
323 fSSDAlTraceFlexMedium(),
324 fSSDAlTraceLadderCableMedium(),
325 fSSDKaptonLadderCableMedium(),
326 fSSDKaptonChipCableMedium(),
327 fSSDAlTraceChipCableMedium(),
328 fSSDAlCoolBlockMedium(),
329 fSSDSensorMedium(),
330 fSSDSensorSupportMedium(),
331 fSSDCarbonFiberMedium(),
332 fSSDTubeHolderMedium(),
333 fSSDCoolingTubeWater(),
334 fSSDCoolingTubePhynox(),
335 fSSDMountingBlockMedium(),
336 fMotherVol(0),
337 fColorCarbonFiber(4),
338 fColorRyton(5),
339 fColorPhynox(5),
340 fColorSilicon(3),
341 fColorAl(7),
342 fColorKapton(6),
343 fColorPolyhamide(5),
344 fColorStiffener(9),
345 fColorEpoxy(30)
346{
347 ////////////////////////
348 // Standard constructor
349 ////////////////////////
350 CreateMaterials();
351}
352/////////////////////////////////////////////////////////////////////////////////
353AliITSv11GeometrySSD::AliITSv11GeometrySSD(const AliITSv11GeometrySSD &s):
354 TObject(s),
355 fSSDChipMedium(s.fSSDChipMedium),
356 fSSDChipGlueMedium(s.fSSDChipGlueMedium),
357 fSSDStiffenerMedium(s.fSSDStiffenerMedium),
358 fSSDStiffenerConnectorMedium(s.fSSDStiffenerConnectorMedium),
359 fSSDStiffener0603CapacitorMedium(s.fSSDStiffener0603CapacitorMedium),
360 fSSDStiffener1812CapacitorMedium(s.fSSDStiffener1812CapacitorMedium),
361 fSSDStiffenerHybridWireMedium(s.fSSDStiffenerHybridWireMedium),
362 fSSDKaptonFlexMedium(s.fSSDKaptonFlexMedium),
363 fSSDAlTraceFlexMedium(s.fSSDAlTraceFlexMedium),
364 fSSDAlTraceLadderCableMedium(s.fSSDAlTraceLadderCableMedium),
365 fSSDKaptonLadderCableMedium(s.fSSDKaptonLadderCableMedium),
366 fSSDKaptonChipCableMedium(s.fSSDKaptonChipCableMedium),
367 fSSDAlTraceChipCableMedium(s.fSSDAlTraceChipCableMedium),
368 fSSDAlCoolBlockMedium(s.fSSDAlCoolBlockMedium),
369 fSSDSensorMedium(s.fSSDSensorMedium),
370 fSSDSensorSupportMedium(s.fSSDSensorSupportMedium),
371 fSSDCarbonFiberMedium(s.fSSDCarbonFiberMedium),
372 fSSDTubeHolderMedium(s.fSSDTubeHolderMedium),
373 fSSDCoolingTubeWater(s.fSSDCoolingTubeWater),
374 fSSDCoolingTubePhynox(s.fSSDCoolingTubePhynox),
375 fSSDMountingBlockMedium(s.fSSDMountingBlockMedium),
376 fMotherVol(s.fMotherVol),
377 fColorCarbonFiber(s.fColorCarbonFiber),
378 fColorRyton(s.fColorRyton),
379 fColorPhynox(s.fColorPhynox),
380 fColorSilicon(s.fColorSilicon),
381 fColorAl(s.fColorAl),
382 fColorKapton(s.fColorKapton),
383 fColorPolyhamide(s.fColorPolyhamide),
384 fColorStiffener(s.fColorStiffener),
385 fColorEpoxy(s.fColorEpoxy)
386{
387 ////////////////////////
388 // Copy Constructor
389 ////////////////////////
d7599219 390 CreateMaterials();
391}
392/////////////////////////////////////////////////////////////////////////////////
44285dfa 393AliITSv11GeometrySSD& AliITSv11GeometrySSD::
394operator=(const AliITSv11GeometrySSD &s){
395 ////////////////////////
396 // Assignment operator
397 ////////////////////////
398 this->~AliITSv11GeometrySSD();
399 new(this) AliITSv11GeometrySSD(s);
400 return *this;
401/*
402 if(&s == this) return *this;
403 fMotherVol = s.fMotherVol;
404 return *this;
405 */
406}
407/////////////////////////////////////////////////////////////////////////////////
d7599219 408// Setting the transformation Matrices
409/////////////////////////////////////////////////////////////////////////////////
410void AliITSv11GeometrySSD::SetSSDSensorSupportCombiTransMatrix(){
44285dfa 411 /////////////////////////////////////////////////////////////
412 // Method generating CombiTrans Matrix for SSD Sensor Support
413 /////////////////////////////////////////////////////////////
d7599219 414 //Translation Parameters SSDSensorSupportAssembly:
415 ////////////////////////////////////////////////////////
44285dfa 416 const Double_t kssdsensorsupporttransx[3] = {-0.5*fgkSSDSensorSideSupportWidth,
d7599219 417 0.5*fgkSSDSensorSideSupportWidth,
418 0.5*fgkSSDSensorCenterSupportThickness[0]
419 - fgkSSDSensorCenterSupportPosition};
44285dfa 420 const Double_t kssdsensorsupporttransy[3] =
d7599219 421 {0.5*fgkSSDSensorSideSupportThickness[0],
422 -0.5*fgkSSDSensorSideSupportThickness[0]
423 -fgkSSDModuleSensorSupportDistance,
424 0.5*fgkSSDSensorCenterSupportWidth
425 -0.5*fgkSSDModuleSensorSupportDistance};
44285dfa 426 const Double_t kssdsensorsupporttransz[3] = {0.,0.,
d7599219 427 fgkSSDSensorCenterSupportThickness[0]};
428 ////////////////////////////////////////////////////////
429 //Rotational Parameters SSDSensorSupportAssembly:
430 ////////////////////////////////////////////////////////
44285dfa 431 const Double_t kssdsensorsupportrotphi[3] = { 0., 180., 270.};
432 const Double_t kssdsensorsupportrottheta[3] = { 90., 90., 90.};
433 const Double_t kssdsensorsupportrotpsi[3] = {- 90.,- 90.,- 90.};
d7599219 434 ////////////////////////////////////////////////////////////////
435 //Name of CombiTrans Transformation of SSDSensorSupportAssembly:
436 ////////////////////////////////////////////////////////////////
44285dfa 437 char ssdsensorsupportcombitransname[40];
438 char ssdsensorsupportrotname[40];
439 TGeoCombiTrans *ssdsensorsupportlocalmatrix[fgkSSDSensorSupportCombiTransNumber];
d7599219 440 for(Int_t i=0; i<fgkSSDSensorSupportCombiTransNumber; i++){
44285dfa 441 sprintf(ssdsensorsupportcombitransname,"SSDSensorSupportCombiTrans%i",i);
442 sprintf(ssdsensorsupportrotname,"SSDSensorSupportRot%i",i);
443 ssdsensorsupportlocalmatrix[i] =
444 new TGeoCombiTrans(ssdsensorsupportcombitransname,
445 kssdsensorsupporttransx[i],
446 kssdsensorsupporttransy[i],
447 kssdsensorsupporttransz[i],
448 new TGeoRotation(ssdsensorsupportrotname,
449 kssdsensorsupportrotphi[i],
450 kssdsensorsupportrottheta[i],
451 kssdsensorsupportrotpsi[i]));
452 fSSDSensorSupportCombiTransMatrix[i] = ssdsensorsupportlocalmatrix[i];
d7599219 453 }
454}
455/////////////////////////////////////////////////////////////////////////////////
456void AliITSv11GeometrySSD::SetSSDModuleCombiTransMatrix(Double_t SSDChipCablesHeigth){
44285dfa 457 /////////////////////////////////////////////////////////////
458 // Method generating CombiTrans Matrix for SSD Module
459 /////////////////////////////////////////////////////////////
460 //Translation Parameters SSDModuleAssembly:
461 ////////////////////////////////////////////////////////
462 const Double_t kssdmoduletransx[7] = {0.5*fgkSSDStiffenerLength,
d7599219 463 0.5*fgkSSDChipLength+0.5*(fgkSSDStiffenerLength
464 - (fgkSSDChipNumber*fgkSSDChipLength+(fgkSSDChipNumber-1)
465 * fgkSSDChipSeparationLength)),
466 - fgkSSDModuleStiffenerPosition[0]+0.5*fgkSSDSensorWidth,
467 0.5*(fgkSSDStiffenerLength-fgkSSDChipNumber*fgkSSDChipLength
468 - (fgkSSDChipNumber-1)*fgkSSDChipSeparationLength),
469 0.5*fgkSSDStiffenerLength-0.5*fgkSSDModuleSensorSupportDistance
470 - fgkSSDCoolingBlockLength,
471 0.5*(fgkSSDStiffenerLength+fgkSSDChipCablesLength[1]
472 + (fgkSSDChipNumber-1)*fgkSSDChipCablesLength[0]),
473 0.5*(fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
474 +(fgkSSDChipNumber-1)*fgkSSDChipSeparationLength)};
44285dfa 475 const Double_t kssdmoduletransy[7] = {0.5*fgkSSDStiffenerWidth,
d7599219 476 0.5*fgkSSDChipWidth+(fgkSSDStiffenerWidth
477 - fgkSSDStiffenerToChipDist-fgkSSDChipWidth),
478 - fgkSSDModuleStiffenerPosition[1]+0.5*fgkSSDSensorLength,
479 fgkSSDStiffenerWidth,
480 0.,
481 fgkSSDSensorLength-2.*fgkSSDModuleStiffenerPosition[1]
482 - fgkSSDStiffenerWidth
483 + fgkSSDStiffenerToChipDist+fgkSSDChipWidth,
484 fgkSSDSensorLength-2.*fgkSSDModuleStiffenerPosition[1]
485 - fgkSSDStiffenerWidth};
44285dfa 486 const Double_t kssdmoduletransz[7] = {0.5*fgkSSDStiffenerHeight,
d7599219 487 - 0.5*fgkSSDChipHeight,
488 0.5*fgkSSDSensorHeight-fgkSSDStiffenerHeight-fgkSSDChipHeight
489 - SSDChipCablesHeigth,
490 - 0.5*fgkSSDFlexHeight[0],
491 fgkSSDStiffenerHeight,
492 - fgkSSDChipHeight,
493 - 0.5*fgkSSDChipHeight};
494 ////////////////////////////////////////////////////////
495 //Rotational Parameters SSDModuleAssembly:
496 ////////////////////////////////////////////////////////
44285dfa 497 const Double_t kssdmodulerotphi[7] = { 0., 0., 90., 0., 0., 90., 180.};
498 const Double_t kssdmodulerottheta[7] = { 0., 0., 0., 0., 0., 0., 0.};
499 const Double_t kssdmodulerotpsi[7] = { 0., 0., 0., 0., 0., 0., 0.};
d7599219 500 ////////////////////////////////////////////////////////
501 //Name of CombiTrans Transformation of SSDModuleAssembly:
502 ////////////////////////////////////////////////////////
44285dfa 503 const char* ssdmodulecombitransname[7] = {"SSDStiffenerCombiTrans",
d7599219 504 "SSDChipCombiTrans",
505 "SSDSensorCombiTrans",
506 "SSDFlex0CombiTrans",
507 "SSDCoolingBlockCombiTrans",
508 "SSDChipCablesCombiTrans",
509 "SSDFlex1CombiTrans"};
44285dfa 510 const char* ssdmodulerotname[7] = {"SSDStiffenerRotName",
d7599219 511 "SSDChipRotName",
512 "SSDSensorRotName",
513 "SSDFlex0RotName",
514 "SSDCoolingBlockRotName",
515 "SSDChipCablesRotName",
516 "SSDFlex1RotName"};
44285dfa 517 TGeoCombiTrans *ssdmodulelocalmatrix[fgkSSDModuleCombiTransNumber];
d7599219 518 for(Int_t i=0; i<fgkSSDModuleCombiTransNumber; i++){
44285dfa 519 ssdmodulelocalmatrix[i] =
520 new TGeoCombiTrans(ssdmodulecombitransname[i],
521 kssdmoduletransx[i],
522 kssdmoduletransy[i],
523 kssdmoduletransz[i],
524 new TGeoRotation(ssdmodulerotname[i],
525 kssdmodulerotphi[i],
526 kssdmodulerottheta[i],
527 kssdmodulerotpsi[i]));
528 fSSDModuleCombiTransMatrix[i] = ssdmodulelocalmatrix[i];
d7599219 529 }
530}
531/////////////////////////////////////////////////////////////////////////////////
532void AliITSv11GeometrySSD::SetCarbonFiberJunctionCombiTransMatrix(){
44285dfa 533 /////////////////////////////////////////////////////////////
534 // Method generating CombiTrans Matrix for Carbon Fiber Junction
535 /////////////////////////////////////////////////////////////
d7599219 536 //Translation Parameters CarbonFiberJunction:
537 ////////////////////////////////////////////////////////
44285dfa 538 const Double_t kcarbonfiberjunctiontransx[3] =
d7599219 539 { 0.0,fgkCarbonFiberTriangleLength,fgkCarbonFiberTriangleLength
540 * TMath::Cos(fgkCarbonFiberTriangleAngle*TMath::DegToRad())};
44285dfa 541 const Double_t kcarbonfiberjunctiontransy[3] =
d7599219 542 { 0.0, 0.0,fgkCarbonFiberTriangleLength
543 * TMath::Sin(fgkCarbonFiberTriangleAngle*TMath::DegToRad())};
44285dfa 544 const Double_t kcarbonfiberjunctiontransz[3] = { 0.0, 0.0, 0.0};
d7599219 545 ////////////////////////////////////////////////////////
546 //Rotational Parameters CarbonFiberJunction:
547 ////////////////////////////////////////////////////////
44285dfa 548 const Double_t kcarbonfiberjunctionrotphi[3] = { 0., 120., 240.};
549 const Double_t kcarbonfiberjunctionrottheta[3] = { 0., 0., 0.};
550 const Double_t kcarbonfiberjunctionrotpsi[3] = { 0., 0., 0.};
d7599219 551 ///////////////////////////////////////////////////////////
552 //Name of CombiTrans Transformation of CarbonFiberJunction:
553 ///////////////////////////////////////////////////////////
44285dfa 554 char carbonfiberjunctioncombitransname[40];
555 char carbonfiberjunctionrotname[40];
556 TGeoCombiTrans *carbonfiberjunctionlocalmatrix[fgkCarbonFiberJunctionCombiTransNumber];
d7599219 557 for(Int_t i=0; i<fgkCarbonFiberJunctionCombiTransNumber; i++) {
44285dfa 558 sprintf(carbonfiberjunctioncombitransname,"CarbonFiberJunctionCombiTrans%i",i);
559 sprintf(carbonfiberjunctionrotname,"CarbonFiberJunctionRot%i",i);
560 carbonfiberjunctionlocalmatrix[i] =
561 new TGeoCombiTrans(carbonfiberjunctioncombitransname,
562 kcarbonfiberjunctiontransx[i],
563 kcarbonfiberjunctiontransy[i],
564 kcarbonfiberjunctiontransz[i],
565 new TGeoRotation(carbonfiberjunctionrotname,
566 kcarbonfiberjunctionrotphi[i],
567 kcarbonfiberjunctionrottheta[i],
568 kcarbonfiberjunctionrotpsi[i]));
569 fCarbonFiberJunctionCombiTransMatrix[i] = carbonfiberjunctionlocalmatrix[i];
d7599219 570 }
571}
572/////////////////////////////////////////////////////////////////////////////////
573void AliITSv11GeometrySSD::SetEndLadderCarbonFiberJunctionCombiTransMatrix(Int_t i){
44285dfa 574 /////////////////////////////////////////////////////////////
575 // Method generating CombiTrans Matrix for End Ladder Carbon Fiber Junction
576 /////////////////////////////////////////////////////////////
d7599219 577 //Translation Parameters EndLadderCarbonFiberJunction:
578 ////////////////////////////////////////////////////////
44285dfa 579 const Double_t kendladdercarbonfiberjunctiontransx[3] =
d7599219 580 { 0.0,fgkCarbonFiberTriangleLength,fgkCarbonFiberTriangleLength
581 * TMath::Cos(fgkCarbonFiberTriangleAngle*TMath::DegToRad())};
44285dfa 582 const Double_t kendladdercarbonfiberjunctiontransy[3] =
d7599219 583 { 0.0, 0.0,fgkCarbonFiberTriangleLength
584 * TMath::Sin(fgkCarbonFiberTriangleAngle*TMath::DegToRad())};
44285dfa 585 const Double_t kendladdercarbonfiberjunctiontransz[3] = { 0.0, 0.0,
d7599219 586 0.5*(fgkEndLadderCarbonFiberLowerJunctionLength[i]
587 -fgkEndLadderCarbonFiberUpperJunctionLength[i])};
588 ////////////////////////////////////////////////////////
589 //Rotational Parameters EndLadderCarbonFiberJunction:
590 ////////////////////////////////////////////////////////
44285dfa 591 const Double_t kendladdercarbonfiberjunctionrotphi[3] = { 0., 120., 240.};
592 const Double_t kendladdercarbonfiberjunctionrottheta[3] = { 0., 0., 0.};
593 const Double_t kendladdercarbonfiberjunctionrotpsi[3] = { 0., 0., 0.};
d7599219 594 ///////////////////////////////////////////////////////////
595 //Name of CombiTrans Transformation of CarbonFiberJunction:
596 ///////////////////////////////////////////////////////////
44285dfa 597 char endladdercarbonfiberjunctioncombitransname[40];
598 char endladdercarbonfiberjunctionrotname[40];
599 TGeoCombiTrans *endladdercarbonfiberjunctionlocalmatrix[fgkEndLadderCarbonFiberJunctionCombiTransNumber];
d7599219 600 for(Int_t i=0; i<fgkEndLadderCarbonFiberJunctionCombiTransNumber; i++) {
44285dfa 601 sprintf(endladdercarbonfiberjunctioncombitransname,"EndLadderCarbonFiberJunctionCombiTrans%i",i);
602 sprintf(endladdercarbonfiberjunctionrotname,"EndLadderCarbonFiberJunctionRot%i",i);
603 endladdercarbonfiberjunctionlocalmatrix[i] =
604 new TGeoCombiTrans(endladdercarbonfiberjunctioncombitransname,
605 kendladdercarbonfiberjunctiontransx[i],
606 kendladdercarbonfiberjunctiontransy[i],
607 kendladdercarbonfiberjunctiontransz[i],
608 new TGeoRotation(endladdercarbonfiberjunctionrotname,
609 kendladdercarbonfiberjunctionrotphi[i],
610 kendladdercarbonfiberjunctionrottheta[i],
611 kendladdercarbonfiberjunctionrotpsi[i]));
612 fEndLadderCarbonFiberJunctionCombiTransMatrix[i] =
613 endladdercarbonfiberjunctionlocalmatrix[i];
d7599219 614 }
615}
616////////////////////////////////////////////////////////////////////////////////
617void AliITSv11GeometrySSD::SetCarbonFiberAssemblyCombiTransMatrix(){
44285dfa 618 /////////////////////////////////////////////////////////////
619 // Method generating CombiTrans Matrix for Carbon fiber Assembly
620 /////////////////////////////////////////////////////////////
d7599219 621 //Translation Parameters CarbonFiberAssembly:
622 ////////////////////////////////////////////////////////
44285dfa 623 const Double_t kcarbonfiberassemblytransx[3] = { 0.0, 0.0, 0.0};
624 const Double_t kcarbonfiberassemblytransy[3] =
d7599219 625 { 0.5*fgkCarbonFiberJunctionWidth, 0.0,
626 fgkCarbonFiberJunctionWidth-fgkCarbonFiberLowerSupportWidth
627 - fgkCarbonFiberLowerSupportVolumePosition[0]
628 - fgkCarbonFiberLowerSupportVolumePosition[1]};
44285dfa 629 const Double_t kcarbonfiberassemblytransz[3] =
d7599219 630 { 0.0, 0.0,- 0.5*fgkCarbonFiberLowerSupportHeight};
631 ////////////////////////////////////////////////////////
632 //Rotational Parameters CarbonFiberAssembly:
633 ////////////////////////////////////////////////////////
44285dfa 634 const Double_t kcarbonfiberassemblyrotphi[3] = { 0., 90., 0.};
635 const Double_t kcarbonfiberassemblyrottheta[3] = { 90.,
d7599219 636 -fgkCarbonFiberTriangleAngle, 0.};
44285dfa 637 const Double_t kcarbonfiberassemblyrotpsi[3] = { 0.,- 90., 0.};
d7599219 638 ///////////////////////////////////////////////////////////
639 //Name of CombiTrans Transformation of CarbonFiberAssembly:
640 ///////////////////////////////////////////////////////////
44285dfa 641 char carbonfiberassemblycombitransname[30];
642 char carbonfiberassemblyrotname[30];
643 TGeoCombiTrans *carbonfiberassemblylocalmatrix[fgkCarbonFiberAssemblyCombiTransNumber];
d7599219 644 for(Int_t i=0; i<fgkCarbonFiberAssemblyCombiTransNumber; i++) {
44285dfa 645 sprintf(carbonfiberassemblycombitransname,"CarbonFiberAssemblyCombiTrans%i",i);
646 sprintf(carbonfiberassemblyrotname,"CarbonFiberAssemblyRot%i",i);
647 carbonfiberassemblylocalmatrix[i] =
648 new TGeoCombiTrans(carbonfiberassemblycombitransname,
649 kcarbonfiberassemblytransx[i],
650 kcarbonfiberassemblytransy[i],
651 kcarbonfiberassemblytransz[i],
652 new TGeoRotation(carbonfiberassemblyrotname,
653 kcarbonfiberassemblyrotphi[i],
654 kcarbonfiberassemblyrottheta[i],
655 kcarbonfiberassemblyrotpsi[i]));
656 fCarbonFiberAssemblyCombiTransMatrix[i] = carbonfiberassemblylocalmatrix[i];
d7599219 657 }
658}
659/////////////////////////////////////////////////////////////////////////////////
660void AliITSv11GeometrySSD::SetCoolingTubeSupportCombiTransMatrix(){
44285dfa 661 /////////////////////////////////////////////////////////////
662 // Method generating CombiTrans Matrix for Cooling Tube Support
663 /////////////////////////////////////////////////////////////
d7599219 664 //Translation Parameters CoolingTubeSupport:
665 ////////////////////////////////////////////////////////
44285dfa 666 Double_t phi = TMath::ASin(0.5*fgkCoolingTubeSupportHeight
d7599219 667 /fgkCoolingTubeSupportRmax);
44285dfa 668 const Double_t kcoolingtubesupporttransx[2] =
669 {0.,2.*fgkCoolingTubeSupportRmax*TMath::Cos(phi)
d7599219 670 + 2.*(fgkCoolingTubeSupportLength
44285dfa 671 - fgkCoolingTubeSupportRmax*(1.+TMath::Cos(phi)))
d7599219 672 + fgkCarbonFiberTriangleLength
673 - 2.0*fgkCarbonFiberJunctionLength};
44285dfa 674 const Double_t kcoolingtubesupporttransy[2] = { 0.0, 0.0};
675 const Double_t kcoolingtubesupporttransz[2] = { 0.0, 0.0};
d7599219 676 ////////////////////////////////////////////////////////
677 //Rotational Parameters CoolingTubeSupport:
678 ////////////////////////////////////////////////////////
44285dfa 679 const Double_t kcoolingsubesupportrotphi[2] = { 0., 180.};
680 const Double_t kcoolingsubesupportrottheta[2] = { 0., 0.};
681 const Double_t kcoolingsubesupportrotpsi[2] = { 0., 0.};
d7599219 682 ///////////////////////////////////////////////////////////
683 //Name of CombiTrans Transformation of CarbonFiberJunction:
684 ///////////////////////////////////////////////////////////
44285dfa 685 char coolingtubesupportcombitransname[40];
686 char coolingtubesupportrotname[40];
687 TGeoCombiTrans *coolingtubesupportlocalmatrix[fgkCoolingTubeSupportCombiTransNumber];
d7599219 688 for(Int_t i=0; i<fgkCoolingTubeSupportCombiTransNumber; i++) {
44285dfa 689 sprintf(coolingtubesupportcombitransname,"CoolingTubeSupportCombiTrans%i",i);
690 sprintf(coolingtubesupportrotname,"CoolingTubeSupportRot%i",i);
691 coolingtubesupportlocalmatrix[i] =
692 new TGeoCombiTrans(coolingtubesupportcombitransname,
693 kcoolingtubesupporttransx[i],
694 kcoolingtubesupporttransy[i],
695 kcoolingtubesupporttransz[i],
696 new TGeoRotation(coolingtubesupportrotname,
697 kcoolingsubesupportrotphi[i],
698 kcoolingsubesupportrottheta[i],
699 kcoolingsubesupportrotpsi[i]));
700 fCoolingTubeSupportCombiTransMatrix[i] = coolingtubesupportlocalmatrix[i];
d7599219 701 }
702}
703/////////////////////////////////////////////////////////////////////////////////
704void AliITSv11GeometrySSD::SetCoolingTubeCombiTransMatrix(){
44285dfa 705 /////////////////////////////////////////////////////////////
706 // Method generating CombiTrans Matrix for Cooling Tube
707 /////////////////////////////////////////////////////////////
d7599219 708 //Translation Parameters CoolingTube:
709 ////////////////////////////////////////////////////////
44285dfa 710 const Double_t kcoolingtubetransx[2] = { 0., fgkCoolingTubeSeparation};
711 const Double_t kcoolingtubetransy[2] = { fgkCoolingTubeLength/2.0, fgkCoolingTubeLength/2.0};
712 const Double_t kcoolingtubetransz[2] = { 0.0, 0.};
d7599219 713 ////////////////////////////////////////////////////////
714 //Rotational Parameters CoolingTube:
715 ////////////////////////////////////////////////////////
44285dfa 716 const Double_t kcoolingtuberotphi[2] = { 0., 0.};
717 const Double_t kcoolingtuberottheta[2] = { 90., 90.};
718 const Double_t kcoolingtuberotpsi[2] = { 0., 0.};
d7599219 719 ///////////////////////////////////////////////////////////
720 //Name of CombiTrans Transformation of CarbonFiberJunction:
721 ///////////////////////////////////////////////////////////
44285dfa 722 const char* coolingtubecombitransname[fgkCoolingTubeCombiTransNumber] =
d7599219 723 {"CoolingTubeCombiTrans0","CoolingTubeCombiTrans1"};
44285dfa 724 const char* coolingtuberotationname[fgkCoolingTubeCombiTransNumber] =
d7599219 725 {"CoolingTubeRotation0","CoolingTubeRotation1"};
44285dfa 726 TGeoCombiTrans *coolingtubelocalmatrix[fgkCoolingTubeCombiTransNumber];
d7599219 727 for(Int_t i=0; i<fgkCoolingTubeCombiTransNumber; i++) {
44285dfa 728 coolingtubelocalmatrix[i] =
729 new TGeoCombiTrans(coolingtubecombitransname[i],
730 kcoolingtubetransx[i],
731 kcoolingtubetransy[i],
732 kcoolingtubetransz[i],
733 new TGeoRotation(coolingtuberotationname[i],
734 kcoolingtuberotphi[i],
735 kcoolingtuberottheta[i],
736 kcoolingtuberotpsi[i]) );
737 fCoolingTubeTransMatrix[i] = coolingtubelocalmatrix[i];
d7599219 738 }
739}
740/////////////////////////////////////////////////////////////////////////////////
741void AliITSv11GeometrySSD::SetLadderSegmentCombiTransMatrix(){
44285dfa 742 /////////////////////////////////////////////////////////////
743 // Method generating CombiTrans Matrix for SSD Ladder Segment
744 /////////////////////////////////////////////////////////////
d7599219 745 //Translation Parameters LadderSegment:
746 ////////////////////////////////////////////////////////
44285dfa 747 const Double_t kladdersegmenttransx[fgkLadderSegmentCombiTransNumber] = { 0.,
d7599219 748 - 0.5*(fgkSSDSensorWidth-fgkCarbonFiberTriangleLength),
749 fgkCarbonFiberTriangleLength+fgkCarbonFiberJunctionToSensorSupport,
750 fgkCarbonFiberJunctionLength-(fgkCoolingTubeSupportLength
751 - fgkCoolingTubeSupportRmax),
752 0.5*(fgkCarbonFiberTriangleLength-fgkCoolingTubeSeparation)};
44285dfa 753 const Double_t kladdersegmenttransy[fgkLadderSegmentCombiTransNumber] = { 0.,
d7599219 754 - (2.*fgkSSDSensorLength-fgkSSDSensorOverlap)+
755 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
756 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
757 - 0.5*(fgkCarbonFiberLowerSupportWidth+fgkSSDSensorCenterSupportLength
758 - fgkSSDSensorCenterSupportThickness[0]),
759 fgkCarbonFiberJunctionWidth-0.5*(fgkCarbonFiberLowerSupportWidth
760 + fgkSSDSensorCenterSupportLength
761 - fgkSSDSensorCenterSupportThickness[0])
762 - fgkSSDSensorCenterSupportPosition,
763 fgkCarbonFiberJunctionWidth-fgkCarbonFiberLowerSupportWidth
764 - fgkCoolingTubeSupportToCarbonFiber,
765 0.0};
44285dfa 766 const Double_t kladdersegmenttransz[fgkLadderSegmentCombiTransNumber] = { 0.,
d7599219 767 - (fgkSSDModuleCoolingBlockToSensor+0.5*fgkCoolingTubeSupportHeight
768 - fgkSSDSensorHeight-fgkSSDChipCablesHeight[3]-fgkSSDChipHeight),
769 0.,
770 - 0.5*fgkCoolingTubeSupportHeight,
771 - 0.5*fgkCoolingTubeSupportHeight};
772//////////////////////////////////////////////////
773 //Rotational Parameters LadderSegment:
774 ////////////////////////////////////////////////////////
44285dfa 775 const Double_t kladdersegmentrotphi[fgkLadderSegmentCombiTransNumber] =
d7599219 776 { 0., 0.,- 90., 0., 0.};
44285dfa 777 const Double_t kladdersegmentrottheta[fgkLadderSegmentCombiTransNumber] =
d7599219 778 { 0., 0., 0., 90., 0.};
44285dfa 779 const Double_t kladdersegmentrotpsi[fgkLadderSegmentCombiTransNumber] =
d7599219 780 { 0., 0., 0., 0., 0.};
781 //////////////////////////////////////////////////////
782 //Name of CombiTrans Transformation of LadderSegment:
783 //////////////////////////////////////////////////////
44285dfa 784 char laddersegmentcombitransname[40];
785 char laddersegmentrotname[40];
786 TGeoCombiTrans *laddersegmentlocalmatrix[fgkLadderSegmentCombiTransNumber];
d7599219 787 for(Int_t i=0; i<fgkLadderSegmentCombiTransNumber; i++) {
44285dfa 788 sprintf(laddersegmentcombitransname,"LadderSegmentCombiTrans%i",i);
789 sprintf(laddersegmentrotname,"LadderSegmentRot%i",i);
790 laddersegmentlocalmatrix[i] =
791 new TGeoCombiTrans(laddersegmentcombitransname,
792 kladdersegmenttransx[i],
793 kladdersegmenttransy[i],
794 kladdersegmenttransz[i],
795 new TGeoRotation(laddersegmentrotname,
796 kladdersegmentrotphi[i],
797 kladdersegmentrottheta[i],
798 kladdersegmentrotpsi[i]));
799 fLadderSegmentCombiTransMatrix[i] = laddersegmentlocalmatrix[i];
d7599219 800 }
801}
802/////////////////////////////////////////////////////////////////////////////////
803void AliITSv11GeometrySSD::SetEndLadderSegmentCombiTransMatrix(Int_t i){
44285dfa 804 /////////////////////////////////////////////////////////////
805 // Method generating CombiTrans Matrix for SSD End Ladder Segment
806 /////////////////////////////////////////////////////////////
d7599219 807 //Translation Parameters EndLadderSegment:
808 ////////////////////////////////////////////////////////
44285dfa 809 const Double_t kendladdersegmenttransx[fgkEndLadderSegmentCombiTransNumber] =
810 {0.0,
d7599219 811 0.0,
44285dfa 812 - 0.25*(fgkSSDMountingBlockLength[0]
813 + fgkSSDMountingBlockLength[1])
814 + 0.5*fgkCarbonFiberTriangleLength,
d7599219 815 0.0};
44285dfa 816 const Double_t kendladdersegmenttransy[fgkEndLadderSegmentCombiTransNumber] =
d7599219 817 {0.5*fgkEndLadderCarbonFiberLowerJunctionLength[i],
44285dfa 818 i==0 ? 0. : fgkCarbonFiberLowerSupportWidth,
819 fgkEndLadderMountingBlockPosition[i],
d7599219 820 (1-i)*(fgkEndLadderMountingBlockPosition[i]
821 + 0.5*fgkSSDMountingBlockWidth)};
44285dfa 822 const Double_t kendladdersegmenttransz[fgkEndLadderSegmentCombiTransNumber] =
823 {0.0,
d7599219 824 0.0,
825 - fgkSSDMountingBlockHeight[1]
826 + 0.5*fgkSSDMountingBlockHeight[0],
44285dfa 827 - 0.5*fgkCarbonFiberLowerSupportHeight};
d7599219 828 ////////////////////////////////////////////////////////
829 //Rotational Parameters EndLadderSegment:
830 ////////////////////////////////////////////////////////
44285dfa 831 const Double_t kendladdersegmentrotphi[fgkEndLadderSegmentCombiTransNumber] =
832 { 0., 90., 0., 0.};
833 const Double_t kendladdersegmentrottheta[fgkEndLadderSegmentCombiTransNumber] =
834 { 90.,-fgkCarbonFiberTriangleAngle, 0., 0.};
835 const Double_t kendladdersegmentrotpsi[fgkEndLadderSegmentCombiTransNumber] =
836 { 0.,- 90., 0., 0.};
d7599219 837 ////////////////////////////////////////////////////////
838 //Name of CombiTrans Transformation of EndLadderSegment:
839 ////////////////////////////////////////////////////////
44285dfa 840 char endladdersegmentcombitransname[30];
841 char endladdersegmentrotname[30];
842 TGeoCombiTrans *endladdersegmentlocalmatrix[fgkEndLadderSegmentCombiTransNumber];
d7599219 843 for(Int_t i=0; i<fgkEndLadderSegmentCombiTransNumber; i++){
44285dfa 844 sprintf(endladdersegmentcombitransname,"EndLadderSegmentCombiTrans%i",i);
845 sprintf(endladdersegmentrotname,"EndLadderSegmentRot%i",i);
846 endladdersegmentlocalmatrix[i] =
847 new TGeoCombiTrans(endladdersegmentcombitransname,
848 kendladdersegmenttransx[i],
849 kendladdersegmenttransy[i],
850 kendladdersegmenttransz[i],
851 new TGeoRotation(endladdersegmentrotname,
852 kendladdersegmentrotphi[i],
853 kendladdersegmentrottheta[i],
854 kendladdersegmentrotpsi[i]));
855 fEndLadderSegmentCombiTransMatrix[i] = endladdersegmentlocalmatrix[i];
d7599219 856 }
857}
858/////////////////////////////////////////////////////////////////////////////////
859void AliITSv11GeometrySSD::SetLadderCableCombiTransMatrix(Int_t iLayer){
44285dfa 860 /////////////////////////////////////////////////////////////
861 // Method generating CombiTrans Matrix for SSD Ladder Cable
862 /////////////////////////////////////////////////////////////
863 // Translation Parameters for LadderCable
864 /////////////////////////////////////////
865 Double_t ssdflexradius = fgkSSDStiffenerHeight+2*fgkSSDFlexHeight[0]
d7599219 866 + fgkSSDFlexHeight[1];
44285dfa 867 Double_t ssdflexradiusmax = (fgkSSDFlexLength[3]-fgkSSDFlexLength[2])
d7599219 868 / TMath::Tan(fgkSSDFlexAngle*TMath::DegToRad());
44285dfa 869 Double_t ssdladdercabletransx[3];
870 ssdladdercabletransx[0] = (ssdflexradiusmax-fgkSSDFlexHeight[1]-ssdflexradius)
d7599219 871 * TMath::Sin(2.*fgkSSDFlexAngle*TMath::DegToRad())
872 * TMath::Cos(2.*fgkSSDFlexAngle*TMath::DegToRad());
44285dfa 873 ssdladdercabletransx[1] = ((ssdflexradiusmax-fgkSSDFlexHeight[1]-ssdflexradius)
874 - ssdladdercabletransx[0]
d7599219 875 / TMath::Sin(2.*fgkSSDFlexAngle*TMath::DegToRad()))
876 * TMath::Cos(fgkSSDFlexAngle*TMath::DegToRad());
44285dfa 877 ssdladdercabletransx[2] = (fgkSSDFlexFullLength-2.*fgkSSDFlexAngle
878 * TMath::DegToRad()*ssdflexradiusmax
d7599219 879 - fgkSSDFlexLength[2]-TMath::Pi()
880 * fgkSSDStiffenerHeight-fgkSSDFlexLength[0]
881 - fgkSSDLadderCableWidth)
882 * TMath::Cos(2.*fgkSSDFlexAngle*TMath::DegToRad());
44285dfa 883 Double_t ssdladdercabletransz[3] = {ssdladdercabletransx[0]
d7599219 884 * TMath::Tan(2.*fgkSSDFlexAngle*TMath::DegToRad()),
44285dfa 885 ssdladdercabletransx[1]
d7599219 886 * TMath::Tan(fgkSSDFlexAngle*TMath::DegToRad()),
44285dfa 887 ssdladdercabletransx[2]
d7599219 888 * TMath::Tan(2.*fgkSSDFlexAngle*TMath::DegToRad())};
44285dfa 889 TGeoRotation* localladdercablerot[3];
890 localladdercablerot[0] = new TGeoRotation("LocalLadderCableRot0",90.,0.,0.);
891 localladdercablerot[1] = new TGeoRotation("LocalLadderCableRot1",90.,60.,-90.);
892 localladdercablerot[2] = new TGeoRotation("LocalLadderCableRot2");
893 localladdercablerot[2]->SetRotation((*localladdercablerot[1])
894 * (*localladdercablerot[0]));
895 ////////////////////////////////////////////
896 // LocalLadderCableCombiTransMatrix
897 ////////////////////////////////////////////
898 const Int_t klocalladdersidecablesnumber = 2;
899 const Int_t klocalladdercombitransnumber = 5;
900 TGeoCombiTrans** localladdercablecombitransmatrix[klocalladdersidecablesnumber];
901 for(Int_t i=0; i<klocalladdersidecablesnumber; i++)
902 localladdercablecombitransmatrix[i] =
903 new TGeoCombiTrans*[klocalladdercombitransnumber];
904 ///////////////////////////////////////////
905 // Left Side Ladder Cables Transformations
906 ///////////////////////////////////////////
907 localladdercablecombitransmatrix[0][0] =
d7599219 908 new TGeoCombiTrans(-0.5*fgkCarbonFiberTriangleLength,
909 0.,0.,NULL);
44285dfa 910 localladdercablecombitransmatrix[0][1] = fLadderSegmentCombiTransMatrix[1];
911 localladdercablecombitransmatrix[0][2] =
d7599219 912 new TGeoCombiTrans(fgkSSDModuleStiffenerPosition[0],
913 fgkSSDModuleStiffenerPosition[1],0.,0);
44285dfa 914 localladdercablecombitransmatrix[0][3] = fSSDModuleCombiTransMatrix[6];
915 localladdercablecombitransmatrix[0][4] =
916 new TGeoCombiTrans(-ssdladdercabletransx[0]
917 - ssdladdercabletransx[1]-ssdladdercabletransx[2]
d7599219 918 + fgkSSDFlexLength[0]-fgkSSDFlexLength[2],
919 0.,
920 0.5*fgkSSDFlexHeight[0]+2.*(fgkSSDFlexHeight[0]
921 + fgkSSDFlexHeight[1])+2.*fgkSSDStiffenerHeight
44285dfa 922 + ssdladdercabletransz[0]-ssdladdercabletransz[1]
923 + ssdladdercabletransz[2],localladdercablerot[2]);
924 ///////////////////////////////////////////
925 // Rigth Side Ladder Cables Transformations
926 ///////////////////////////////////////////
927 for(Int_t i=0; i<klocalladdercombitransnumber; i++)
928 localladdercablecombitransmatrix[1][i] =
929 (i!=3 ? localladdercablecombitransmatrix[0][i]:
930 fSSDModuleCombiTransMatrix[3]);
931 ///////////////////////////////////////////
932 // Setting LadderCableCombiTransMatrix
933 ///////////////////////////////////////////
934 Int_t beamaxistrans[3] = {0,0,0};
935 switch(iLayer){
936 case 5:
937 beamaxistrans[0] = fgkSSDLay5SensorsNumber/2;
938 beamaxistrans[1] = beamaxistrans[0]+1;
939 beamaxistrans[2] = beamaxistrans[0]-1;
940 break;
941 case 6:
942 beamaxistrans[0] = (fgkSSDLay6SensorsNumber-1)/2;
943 beamaxistrans[1] = beamaxistrans[0]+1;
944 beamaxistrans[2] = beamaxistrans[0];
945 break;
946 }
947 TGeoHMatrix* localladdercablehmatrix[klocalladdersidecablesnumber];
948 TGeoRotation* laddercablerot;
949 TGeoTranslation* laddercabletrans;
950 for(Int_t i=0; i<klocalladdersidecablesnumber; i++){
951 localladdercablehmatrix[i] = new TGeoHMatrix();
952 for(Int_t j=0; j<klocalladdercombitransnumber; j++){
953 localladdercablehmatrix[i]->MultiplyLeft(
954 localladdercablecombitransmatrix[i][klocalladdercombitransnumber-j-1]);
955 }
956 laddercablerot = new TGeoRotation();
957 laddercablerot->SetMatrix(localladdercablehmatrix[i]->GetRotationMatrix());
958 laddercabletrans = new TGeoTranslation();
959 Double_t* laddercabletransvector = localladdercablehmatrix[i]->GetTranslation();
960 laddercabletrans->SetTranslation(laddercabletransvector[0],
961 laddercabletransvector[1]
962 + (i==0 ? beamaxistrans[0] : 0.)
d7599219 963 * fgkCarbonFiberJunctionWidth,
44285dfa 964 laddercabletransvector[2]);
965 fLadderCableCombiTransMatrix[i] = new TGeoCombiTrans(*laddercabletrans,
966 *laddercablerot);
d7599219 967 }
44285dfa 968 fLadderCableCombiTransMatrix[2] =
969 AddTranslationToCombiTrans(fLadderCableCombiTransMatrix[1],0.,
970 beamaxistrans[1]*fgkCarbonFiberJunctionWidth,0.);
971 fLadderCableCombiTransMatrix[3] =
972 AddTranslationToCombiTrans(fLadderCableCombiTransMatrix[0],0.,
973 beamaxistrans[2]*fgkCarbonFiberJunctionWidth,0.);
974}
d7599219 975/////////////////////////////////////////////////////////////////////////////////
976TGeoVolume* AliITSv11GeometrySSD::GetSSDSensorSupportShape(Double_t length,
977 Double_t height,Double_t width,Double_t* thickness){
44285dfa 978 /////////////////////////////////////////////////////////////
979 // Method generating SSD Sensor Support Shape
980 /////////////////////////////////////////////////////////////
981 const Int_t kvertexnumber = 4;
982 const Int_t kshapesnumber = 2;
983 Double_t shapewidth[2] = {width,width};
984 TVector3** vertexposition[kshapesnumber];
985 for(Int_t i = 0; i<kshapesnumber; i++) vertexposition[i] =
986 new TVector3*[kvertexnumber];
d7599219 987 //First Shape Vertex Positioning
44285dfa 988 vertexposition[0][0] = new TVector3();
989 vertexposition[0][1] = new TVector3(height);
990 vertexposition[0][2] = new TVector3(thickness[0]);
991 vertexposition[0][3] = new TVector3(*vertexposition[0][1]);
d7599219 992 //Second Shape Vertex Positioning
44285dfa 993 vertexposition[1][0] = new TVector3(*vertexposition[0][0]);
994 vertexposition[1][1] = new TVector3(length);
995 vertexposition[1][2] = new TVector3(thickness[1]);
996 vertexposition[1][3] = new TVector3(vertexposition[1][1]->X());
997 char* ssdsensorsupportshapename[kshapesnumber] =
d7599219 998 {"SSDSensorSupportShape1","SSDSensorSupportShape2"};
44285dfa 999 TGeoArb8* lSSDSensorSupportShape[kshapesnumber];
1000 for(Int_t i = 0; i< kshapesnumber; i++) lSSDSensorSupportShape[i] =
1001 GetArbShape(vertexposition[i],shapewidth,i==0 ?
d7599219 1002 thickness[1]: thickness[0],
44285dfa 1003 ssdsensorsupportshapename[i]);
d7599219 1004 /////////////////////////////////////
1005 //Setting Translations and Rotations:
1006 /////////////////////////////////////
44285dfa 1007 TGeoRotation* ssdsensorsupportshaperot[2];
1008 ssdsensorsupportshaperot[0] =
d7599219 1009 new TGeoRotation("SSDSensorSupportShapeRot1",180.,0.,0.);
44285dfa 1010 ssdsensorsupportshaperot[1] =
d7599219 1011 new TGeoRotation("SSDSensorSupportShapeRot2",90.,90.,-90.);
44285dfa 1012 TGeoTranslation* ssdsensorsupportshapetrans =
d7599219 1013 new TGeoTranslation("SSDSensorSupportShapeTrans",0.,0.,
1014 0.5*thickness[0]);
44285dfa 1015 TGeoCombiTrans* ssdsensorsupportcombitrans =
d7599219 1016 new TGeoCombiTrans("SSDSensorSupportCombiTrans",0.5*thickness[0],width,0.,
44285dfa 1017 new TGeoRotation((*ssdsensorsupportshaperot[1])
1018 * (*ssdsensorsupportshaperot[0])));
1019 TGeoVolume* ssdsensorsupportcompvolume =
d7599219 1020 new TGeoVolumeAssembly("SSDSensorSupportCompVolume");
44285dfa 1021 ssdsensorsupportcompvolume->AddNode(new TGeoVolume("SSDSensorSupportVolume1",
1022 lSSDSensorSupportShape[0],fSSDSensorSupportMedium),1,
1023 ssdsensorsupportshapetrans);
1024 ssdsensorsupportcompvolume->AddNode(new TGeoVolume("SSDSensorSupportVolume2",
1025 lSSDSensorSupportShape[1],fSSDSensorSupportMedium),1,
1026 ssdsensorsupportcombitrans);
1027 return ssdsensorsupportcompvolume;
d7599219 1028}
1029/////////////////////////////////////////////////////////////////////////////////
1030TGeoVolume* AliITSv11GeometrySSD::GetSSDSensorSupport(Int_t VolumeKind, Int_t n){
44285dfa 1031 /////////////////////////////////////////////////////////////
1032 // Method generating SSD Sensor Support
1033 /////////////////////////////////////////////////////////////
1034 TGeoVolume* ssdsensorsupport;
1035 Double_t sidesupporthickness[2] = {fgkSSDSensorSideSupportThickness[0],
d7599219 1036 fgkSSDSensorSideSupportThickness[1]};
44285dfa 1037 VolumeKind == 0 ? ssdsensorsupport = GetSSDSensorSupportShape(
d7599219 1038 fgkSSDSensorSideSupportLength,
1039 fgkSSDSensorSideSupportHeight[(n==0 ? 0 : 1)],
1040 fgkSSDSensorSideSupportWidth,
44285dfa 1041 sidesupporthickness) :
1042 ssdsensorsupport = GetSSDSensorSupportShape(fgkSSDSensorCenterSupportLength,
d7599219 1043 fgkSSDSensorCenterSupportHeight[(n==0 ? 0 : 1)],
1044 fgkSSDSensorCenterSupportWidth,
44285dfa 1045 sidesupporthickness);
1046 return ssdsensorsupport;
d7599219 1047}
1048/////////////////////////////////////////////////////////////////////////////////
1049TGeoVolume* AliITSv11GeometrySSD::GetSSDSensorSupportAssembly(Int_t n){
44285dfa 1050 /////////////////////////////////////////////////////////////
1051 // Method generating SSD Sensor Support Assembly
1052 /////////////////////////////////////////////////////////////
1053 TGeoVolume* ssdsensorsupportassembly =
d7599219 1054 new TGeoVolumeAssembly("SSDSensorSupportAssembly");
44285dfa 1055 const Int_t kvolumenumber = 2;
1056 TGeoVolume* ssdsensorsupport[kvolumenumber];
1057 for(Int_t i=0; i<kvolumenumber; i++) ssdsensorsupport[i] =
d7599219 1058 GetSSDSensorSupport(i,n);
1059 SetSSDSensorSupportCombiTransMatrix();
1060 for(Int_t i=0; i<fgkSSDSensorSupportCombiTransNumber; i++)
44285dfa 1061 ssdsensorsupportassembly->AddNode((i<2 ? ssdsensorsupport[0]:
1062 ssdsensorsupport[1]),
1063 i+1,fSSDSensorSupportCombiTransMatrix[i]);
1064 return ssdsensorsupportassembly;
d7599219 1065}
1066/////////////////////////////////////////////////////////////////////////////////
1067TGeoVolume* AliITSv11GeometrySSD::GetSSDModule(Int_t iChipCablesHeight){
44285dfa 1068 /////////////////////////////////////////////////////////////
1069 // Method generating SSD Sensor Module
1070 /////////////////////////////////////////////////////////////
1071 TGeoVolume* ssdmodulevolume[fgkSSDModuleCombiTransNumber-1];
1072 ssdmodulevolume[0] = GetSSDStiffenerAssembly();
1073 ssdmodulevolume[1] = GetSSDChipAssembly();
1074 ssdmodulevolume[2] = GetSSDSensor();
1075 ssdmodulevolume[3] = GetSSDFlexAssembly();
1076 ssdmodulevolume[4] = GetSSDCoolingBlockAssembly();
1077 ssdmodulevolume[5] = GetSSDChipCablesAssembly(fgkSSDChipCablesHeight[iChipCablesHeight+2]);
d7599219 1078 SetSSDModuleCombiTransMatrix(fgkSSDChipCablesHeight[iChipCablesHeight+2]);
44285dfa 1079 TGeoCombiTrans* ssdmoduleglobalcombitrans =
d7599219 1080 new TGeoCombiTrans("SSDModuleGlobalCombiTrans",
1081 fgkSSDModuleStiffenerPosition[0],
1082 fgkSSDModuleStiffenerPosition[1],0.,NULL);
44285dfa 1083 TGeoHMatrix* ssdmodulehmatrix[fgkSSDModuleCombiTransNumber];
1084 TGeoVolume* ssdmodule = new TGeoVolumeAssembly("SSDModule");
d7599219 1085 for(Int_t i=0; i<fgkSSDModuleCombiTransNumber; i++){
44285dfa 1086 ssdmodulehmatrix[i] = new TGeoHMatrix((*ssdmoduleglobalcombitrans)
1087 * (*fSSDModuleCombiTransMatrix[i]));
1088 ssdmodule->AddNode(i==fgkSSDModuleCombiTransNumber-1 ? ssdmodulevolume[3] :
1089 ssdmodulevolume[i],i!=fgkSSDModuleCombiTransNumber-1?1:2,
1090 ssdmodulehmatrix[i]);
d7599219 1091 }
44285dfa 1092 return ssdmodule;
d7599219 1093}
1094/////////////////////////////////////////////////////////////////////////////////
1095TGeoVolume* AliITSv11GeometrySSD::GetSSDSensor(){
44285dfa 1096 /////////////////////////////////////////////////////////////
1097 // Method generating SSD Sensor
1098 /////////////////////////////////////////////////////////////
1099 Double_t ssdsensitivelength = fgkSSDSensorLength-2.*fgkSSDSensorInsensitiveLength;
1100 Double_t ssdsensitivewidth = fgkSSDSensorWidth-2.*fgkSSDSensorInsensitiveWidth;
1101 TGeoBBox* ssdsensorsensitiveshape = new TGeoBBox("SSDSensorSensitiveShape",
1102 0.5*ssdsensitivelength,
1103 0.5*ssdsensitivewidth,
d7599219 1104 0.5*fgkSSDSensorHeight);
44285dfa 1105 TGeoVolume* ssdsensorsensitive =
1106 new TGeoVolume(fgkSSDSensitiveVolName,ssdsensorsensitiveshape,fSSDSensorMedium);
1107 ssdsensorsensitive->SetLineColor(fColorSilicon);
1108 TGeoBBox* ssdsensorinsensitiveshape[2];
1109 ssdsensorinsensitiveshape[0] = new TGeoBBox("SSDSensorInsensitiveShape1",
d7599219 1110 0.5*fgkSSDSensorLength,
1111 0.5*fgkSSDSensorInsensitiveWidth,
1112 0.5*fgkSSDSensorHeight);
44285dfa 1113 ssdsensorinsensitiveshape[1] = new TGeoBBox("SSDSensorInsensitiveShape2",
d7599219 1114 0.5*fgkSSDSensorInsensitiveWidth,
44285dfa 1115 0.5*ssdsensitivewidth,
d7599219 1116 0.5*fgkSSDSensorHeight);
44285dfa 1117 const char* ssdsensorinsensitivename[2] = {"SSDSensorInsensitive1",
d7599219 1118 "SSDSensorInsensitive2"};
44285dfa 1119 TGeoVolume* ssdsensorinsensitive[2];
1120 for(Int_t i=0; i<2; i++){ ssdsensorinsensitive[i] =
1121 new TGeoVolume(ssdsensorinsensitivename[i],ssdsensorinsensitiveshape[i],
1122 fSSDSensorMedium);
1123 ssdsensorinsensitive[i]->SetLineColor(fColorCarbonFiber);
d7599219 1124 }
44285dfa 1125 TGeoVolume* ssdsensorinsensitivevol =
d7599219 1126 new TGeoVolumeAssembly("SSDSensorInsensitiveVol");
1127 for(Int_t i=0; i<4; i++)
44285dfa 1128 ssdsensorinsensitivevol->AddNode(i%2==0 ? ssdsensorinsensitive[0]:
1129 ssdsensorinsensitive[1],i<2?1:2,
d7599219 1130 new TGeoTranslation(0.5*(1.-TMath::Power(-1.,i))*(i==1? 1.:-1.)
44285dfa 1131 * (ssdsensorsensitiveshape->GetDX()+ssdsensorinsensitiveshape[1]->GetDX()),
d7599219 1132 0.5*(1.+TMath::Power(-1.,i))*(i==0?-1.: 1.)
44285dfa 1133 * (ssdsensorsensitiveshape->GetDY()+ssdsensorinsensitiveshape[0]->GetDY()),0.));
1134 TGeoVolume* ssdsensor = new TGeoVolumeAssembly("SSDSensor");
1135 ssdsensor->AddNode(ssdsensorsensitive,1),ssdsensor->AddNode(ssdsensorinsensitivevol,1);
1136 return ssdsensor;
d7599219 1137}
1138/////////////////////////////////////////////////////////////////////////////////
44285dfa 1139TGeoVolume* AliITSv11GeometrySSD::GetSSDChipAssembly() const{
1140 /////////////////////////////////////////////////////////////
1141 // Method generating SSD Chip Assembly
1142 /////////////////////////////////////////////////////////////
1143 const Int_t kssdchiprownumber = 2;
1144 TGeoBBox* ssdchipcompshape[2];
1145 ssdchipcompshape[0] = new TGeoBBox("SSDChipCompShape",
d7599219 1146 0.5*fgkSSDChipLength,
1147 0.5*fgkSSDChipWidth,
1148 0.5*(fgkSSDChipHeight-fgkSSDChipGlueHeight));
44285dfa 1149 ssdchipcompshape[1] = new TGeoBBox("SSDChipGlueCompShape",
d7599219 1150 0.5*fgkSSDChipLength,
1151 0.5*fgkSSDChipWidth,
1152 0.5*fgkSSDChipGlueHeight);
44285dfa 1153 TGeoVolume* ssdchipcomp[2];
1154 ssdchipcomp[0] = new TGeoVolume("SSDChipComp",ssdchipcompshape[0],fSSDChipMedium);
1155 ssdchipcomp[1] = new TGeoVolume("SSDChipGlueComp",ssdchipcompshape[1],
1156 fSSDChipGlueMedium);
1157 ssdchipcomp[0]->SetLineColor(fColorSilicon);
1158 ssdchipcomp[1]->SetLineColor(fColorEpoxy);
1159 TGeoTranslation* ssdchipcomptrans[2];
1160 ssdchipcomptrans[0] = new TGeoTranslation(0.,0.,-ssdchipcompshape[1]->GetDZ());
1161 ssdchipcomptrans[1] = new TGeoTranslation(0.,0.,ssdchipcompshape[0]->GetDZ());
1162 TGeoVolume* ssdchip = new TGeoVolumeAssembly("SSDChip");
1163 for(Int_t i=0; i<2; i++) ssdchip->AddNode(ssdchipcomp[i],1,ssdchipcomptrans[i]);
1164 Double_t ssdchipseparation[2] = {fgkSSDChipLength+fgkSSDChipSeparationLength,
d7599219 1165 fgkSSDSensorLength-2.*fgkSSDModuleStiffenerPosition[1]
1166 - 2.*(fgkSSDStiffenerWidth-fgkSSDStiffenerToChipDist
1167 - 0.5*fgkSSDChipWidth)};
44285dfa 1168 TGeoVolume* ssdchipassembly = new TGeoVolumeAssembly("SSDChipAssembly");
1169 for(Int_t i=0; i<kssdchiprownumber; i++)
d7599219 1170 for(Int_t j=0; j<fgkSSDChipNumber; j++)
44285dfa 1171 ssdchipassembly->AddNode(ssdchip,fgkSSDChipNumber*i+j+1,
1172 new TGeoTranslation(j*ssdchipseparation[0],i*ssdchipseparation[1],0.));
1173 return ssdchipassembly;
d7599219 1174}
1175/////////////////////////////////////////////////////////////////////////////////
1176TGeoVolume* AliITSv11GeometrySSD::GetSSDStiffenerAssembly(){
44285dfa 1177 /////////////////////////////////////////////////////////////
1178 // Method generating SSD Stiffener Assembly
1179 /////////////////////////////////////////////////////////////
1180 const Int_t kssdstiffenernumber = 2;
1181 Double_t ssdstiffenerseparation = fgkSSDSensorLength
d7599219 1182 - 2.*fgkSSDModuleStiffenerPosition[1]
1183 - fgkSSDStiffenerWidth;
44285dfa 1184 TGeoVolume* ssdstiffener = new TGeoVolumeAssembly("SSDStiffener");
d7599219 1185////////////////////////////
1186// Stiffener Volumes
1187///////////////////////////
44285dfa 1188 const Int_t kstiffenerboxnumber = 6;
1189 TGeoBBox* ssdstiffenerboxshapes[kstiffenerboxnumber];
1190 ssdstiffenerboxshapes[0] = new TGeoBBox("SSDStiffenerBoxShape1",
d7599219 1191 0.5* fgkSSDStiffenerLength,
1192 0.5* fgkSSDStiffenerWidth,
1193 0.5*(fgkSSDStiffenerHeight
1194 - fgkSSDConnectorHeight));
44285dfa 1195 ssdstiffenerboxshapes[1] = new TGeoBBox("SSDStiffenerBoxShape2",
d7599219 1196 0.5*(fgkSSDConnectorPosition[0]
1197 - 2.0* fgkSSDConnectorLength
1198 - fgkSSDConnectorSeparation),
1199 0.5* fgkSSDStiffenerWidth,
1200 0.5* fgkSSDConnectorHeight);
44285dfa 1201 ssdstiffenerboxshapes[2] = new TGeoBBox("SSDStiffenerBoxShape3",
d7599219 1202 0.5*(fgkSSDConnectorSeparation
1203 + 2.* fgkSSDConnectorLength),
1204 0.5* fgkSSDConnectorPosition[1],
1205 0.5* fgkSSDConnectorHeight);
44285dfa 1206 ssdstiffenerboxshapes[3] = new TGeoBBox("SSDStiffenerBoxShape4",
1207 ssdstiffenerboxshapes[2]->GetDX(),
d7599219 1208 0.5*(fgkSSDStiffenerWidth
1209 - fgkSSDConnectorPosition[1]
1210 - fgkSSDConnectorWidth),
1211 0.5* fgkSSDConnectorHeight);
44285dfa 1212 ssdstiffenerboxshapes[4] = new TGeoBBox("SSDStiffenerBoxShape5",
d7599219 1213 0.5* fgkSSDConnectorSeparation,
1214 0.5* fgkSSDConnectorWidth,
1215 0.5* fgkSSDConnectorHeight);
44285dfa 1216 ssdstiffenerboxshapes[5] = new TGeoBBox("SSDStiffenerBoxShape6",
d7599219 1217 0.5*(fgkSSDStiffenerLength
1218 - fgkSSDConnectorPosition[0]),
1219 0.5* fgkSSDStiffenerWidth,
1220 0.5* fgkSSDConnectorHeight);
44285dfa 1221 TGeoVolume* ssdstiffenerbox[kstiffenerboxnumber];
1222 char ssdtiffenerboxname[30];
1223 for(Int_t i=0; i<kstiffenerboxnumber; i++){
1224 sprintf(ssdtiffenerboxname,"SSDStiffenerBox%i",i+1);
1225 ssdstiffenerbox[i] = new TGeoVolume(ssdtiffenerboxname,ssdstiffenerboxshapes[i],
1226 fSSDStiffenerMedium);
1227 ssdstiffenerbox[i]->SetLineColor(fColorStiffener);
d7599219 1228 }
1229////////////////////////////
1230// Connector
1231///////////////////////////
44285dfa 1232 TGeoBBox* ssdconnectorshape = new TGeoBBox("SSDConnectorShape",
d7599219 1233 0.5*fgkSSDConnectorLength,
1234 0.5*fgkSSDConnectorWidth,
1235 0.5*fgkSSDConnectorHeight);
44285dfa 1236 TGeoVolume* ssdconnector = new TGeoVolume("SSDConnector",ssdconnectorshape,
1237 fSSDStiffenerConnectorMedium);
1238 ssdconnector->SetLineColor(fColorAl);
1239 const Int_t kssdconnectornumber = 2;
1240 TGeoTranslation* ssdconnectortrans[kssdconnectornumber];
1241 ssdconnectortrans[0] = new TGeoTranslation("SSDConnectorTrans1",
1242 - ssdstiffenerboxshapes[0]->GetDX()+fgkSSDConnectorPosition[0]
d7599219 1243 - fgkSSDConnectorSeparation-1.5*fgkSSDConnectorLength,
44285dfa 1244 ssdstiffenerboxshapes[0]->GetDY()-fgkSSDConnectorPosition[1]
1245 - ssdconnectorshape->GetDY(),
1246 ssdstiffenerboxshapes[0]->GetDZ()+ssdconnectorshape->GetDZ());
1247 ssdconnectortrans[1] = new TGeoTranslation("SSDConnectorTrans2",
1248 - ssdstiffenerboxshapes[0]->GetDX()+fgkSSDConnectorPosition[0]
d7599219 1249 - 0.5*fgkSSDConnectorLength,
44285dfa 1250 ssdstiffenerboxshapes[0]->GetDY()-fgkSSDConnectorPosition[1]
1251 - ssdconnectorshape->GetDY(),
1252 ssdstiffenerboxshapes[0]->GetDZ()+ssdconnectorshape->GetDZ());
1253 for(Int_t i=0; i<kssdconnectornumber; i++)
1254 ssdstiffener->AddNode(ssdconnector,i+1,ssdconnectortrans[i]);
d7599219 1255//////////////////////////////////////
1256// TGeoTranslation for Stiffener Boxes
1257//////////////////////////////////////
44285dfa 1258 TGeoTranslation* ssdstiffenerboxtrans[kstiffenerboxnumber];
1259 ssdstiffenerboxtrans[0] = new TGeoTranslation("SSDStiffenerBoxTrans1",0.,0.,0.);
1260 ssdstiffenerboxtrans[1] = new TGeoTranslation("SSDStiffenerBoxTrans2",
1261 - (ssdstiffenerboxshapes[0]->GetDX()-ssdstiffenerboxshapes[1]->GetDX()),
d7599219 1262 0.,
44285dfa 1263 ssdstiffenerboxshapes[0]->GetDZ()+ssdstiffenerboxshapes[1]->GetDZ());
1264 ssdstiffenerboxtrans[2] = new TGeoTranslation("SSDStiffenerBoxTrans3",
1265 - ssdstiffenerboxshapes[0]->GetDX()-ssdstiffenerboxshapes[2]->GetDX()
d7599219 1266 + fgkSSDConnectorPosition[0],
44285dfa 1267 ssdstiffenerboxshapes[0]->GetDY()-ssdstiffenerboxshapes[2]->GetDY(),
1268 ssdstiffenerboxshapes[0]->GetDZ()+ssdstiffenerboxshapes[2]->GetDZ());
1269 ssdstiffenerboxtrans[3] = new TGeoTranslation("SSDStiffenerBoxTrans4",
1270 - ssdstiffenerboxshapes[0]->GetDX()-ssdstiffenerboxshapes[3]->GetDX()
d7599219 1271 + fgkSSDConnectorPosition[0],
44285dfa 1272 - ssdstiffenerboxshapes[0]->GetDY()+ssdstiffenerboxshapes[3]->GetDY(),
1273 ssdstiffenerboxshapes[0]->GetDZ()+ssdstiffenerboxshapes[3]->GetDZ());
1274 ssdstiffenerboxtrans[4] = new TGeoTranslation("SSDStiffenerBoxTrans5",
1275 - ssdstiffenerboxshapes[0]->GetDX()+fgkSSDConnectorPosition[0]
1276 - 0.5*fgkSSDConnectorSeparation-2.*ssdconnectorshape->GetDX(),
1277 ssdstiffenerboxshapes[0]->GetDY()-fgkSSDConnectorPosition[1]
1278 - ssdconnectorshape->GetDY(),
1279 ssdstiffenerboxshapes[0]->GetDZ()+ssdconnectorshape->GetDZ());
1280 ssdstiffenerboxtrans[5] = new TGeoTranslation("SSDStiffenerBoxTrans6",
1281 - ssdstiffenerboxshapes[0]->GetDX()+fgkSSDConnectorPosition[0]
1282 + ssdstiffenerboxshapes[5]->GetDX(),
d7599219 1283 0.,
44285dfa 1284 ssdstiffenerboxshapes[0]->GetDZ()+ssdstiffenerboxshapes[5]->GetDZ());
1285 for(Int_t i=0; i<kstiffenerboxnumber; i++)
1286 ssdstiffener->AddNode(ssdstiffenerbox[i],1,ssdstiffenerboxtrans[i]);
1287 TGeoCombiTrans* ssdstiffenercombitrans[kssdstiffenernumber];
1288 char ssdstiffenercombitransname[30];
1289 for(Int_t i=0; i<kssdstiffenernumber; i++){
1290 sprintf(ssdstiffenercombitransname,"SSDStiffenerCombiTrans%i",i+1);
1291 ssdstiffenercombitrans[i] = new TGeoCombiTrans(ssdstiffenercombitransname,
1292 0.,i*ssdstiffenerseparation,0.,new TGeoRotation("",180*(1-i),0.,0.));
d7599219 1293 }
1294////////////////////////////
1295// Capacitor 0603-2200 nF
1296///////////////////////////
44285dfa 1297 const Int_t knapacitor0603number = 5;
1298 TGeoBBox* capacitor0603shape = new TGeoBBox("Capacitor0603Shape",
d7599219 1299 0.5*fgkSSDCapacitor0603Length,
1300 0.5*fgkSSDCapacitor0603Width,
1301 0.5*fgkSSDCapacitor0603Height);
44285dfa 1302 TGeoVolume* capacitor0603 = new TGeoVolume("Capacitor0603",capacitor0603shape,
1303 fSSDStiffener0603CapacitorMedium);
1304 capacitor0603->SetLineColor(fColorAl);
d7599219 1305////////////////////////////
1306// Capacitor 1812-330 nF
1307///////////////////////////
44285dfa 1308 TGeoBBox* capacitor1812shape = new TGeoBBox("Capacitor1812Shape",
d7599219 1309 0.5*fgkSSDCapacitor1812Length,
1310 0.5*fgkSSDCapacitor1812Width,
1311 0.5*fgkSSDCapacitor1812Height);
44285dfa 1312 TGeoVolume* capacitor1812 = new TGeoVolume("Capacitor1812",capacitor1812shape,
1313 fSSDStiffener1812CapacitorMedium);
1314 capacitor1812->SetLineColor(fColorAl);
1315 TGeoTranslation* capacitor1812trans = new TGeoTranslation("Capacitor1812Trans",
d7599219 1316 0.,
44285dfa 1317 0.5*fgkSSDStiffenerWidth+ssdstiffenerseparation
1318 - capacitor1812shape->GetDY()-fgkSSDConnectorPosition[1],
1319 ssdstiffenerboxshapes[0]->GetDZ()+fgkSSDConnectorHeight
d7599219 1320 + 0.5*fgkSSDCapacitor1812Height);
1321////////////////////////////
1322//Hybrid Wire
1323////////////////////////////
44285dfa 1324 Double_t wirex = 2.*(fgkSSDConnectorPosition[0]-0.5*fgkSSDStiffenerLength
d7599219 1325 - 0.5*fgkSSDConnectorLength)-fgkSSDConnectorLength
1326 - fgkSSDConnectorSeparation;
44285dfa 1327 Double_t wirey = ssdstiffenerseparation+fgkSSDStiffenerWidth
d7599219 1328 - 2.*fgkSSDConnectorPosition[1]-fgkSSDConnectorWidth;
44285dfa 1329 Double_t ssdwireradius = TMath::Sqrt(TMath::Power(wirex,2.)
1330 + TMath::Power(wirey,2));
1331 Double_t wireangle = TMath::ATan(wirex/wirey);
1332 TGeoTube *hybridwireshape = new TGeoTube("HybridWireShape", 0.,
1333 fgkSSDWireRadius, 0.5*ssdwireradius);
1334 TGeoVolume* hybridwire = new TGeoVolume("HybridWire",hybridwireshape,
1335 fSSDStiffenerHybridWireMedium);
1336 hybridwire->SetLineColor(fColorPhynox);
1337 TGeoCombiTrans* hybridwirecombitrans[2];
1338 hybridwirecombitrans[0] = new TGeoCombiTrans("HybridWireCombiTrans1",
d7599219 1339 0.5*fgkSSDStiffenerLength-fgkSSDConnectorPosition[0]
1340 + 1.5*fgkSSDConnectorLength+fgkSSDConnectorSeparation,
44285dfa 1341 0.5*ssdwireradius-0.5*fgkSSDStiffenerWidth
d7599219 1342 + fgkSSDConnectorPosition[1]+0.5*fgkSSDConnectorWidth,
44285dfa 1343 ssdstiffenerboxshapes[0]->GetDZ()+fgkSSDConnectorHeight
d7599219 1344 + fgkSSDWireRadius,
1345 new TGeoRotation("HybridWireRot1",0.,90.,0.));
44285dfa 1346 hybridwirecombitrans[1] = new TGeoCombiTrans("HybridWireCombiTrans2",
d7599219 1347 0.,
1348 - 0.5*fgkSSDConnectorWidth+fgkSSDWireRadius,
1349 0.,
1350 new TGeoRotation("HybridWireRot2",
44285dfa 1351 - wireangle*TMath::RadToDeg(),0.,0.));
1352 TGeoHMatrix* hybridwirematrix = new TGeoHMatrix();
1353 hybridwirematrix->MultiplyLeft(hybridwirecombitrans[0]);
1354 hybridwirematrix->MultiplyLeft(hybridwirecombitrans[1]);
d7599219 1355////////////////////////////
1356// Stiffener Assembly
1357///////////////////////////
44285dfa 1358 TGeoVolume* ssdstiffenerassembly =
d7599219 1359 new TGeoVolumeAssembly("SSDStiffenerAssembly");
44285dfa 1360 ssdstiffenerassembly->AddNode(hybridwire,1,hybridwirematrix);
1361 for(Int_t i=0; i<kssdstiffenernumber; i++) {
1362 ssdstiffenerassembly->AddNode(ssdstiffener,i+1,ssdstiffenercombitrans[i]);
1363 for(Int_t j=1; j<knapacitor0603number+1; j++){
1364 ssdstiffenerassembly->AddNode(capacitor0603,knapacitor0603number*i+j,new TGeoTranslation("",(j-3.
d7599219 1365 )/6*fgkSSDStiffenerLength,
44285dfa 1366 i*ssdstiffenerseparation+
d7599219 1367 0.5*((i==0? 1:-1)*fgkSSDStiffenerWidth
1368 +(i==0? -1:+1)*fgkSSDCapacitor0603Width),
1369 -0.5*(fgkSSDStiffenerHeight+fgkSSDCapacitor0603Height)));
1370 }
44285dfa 1371 if(i==1) ssdstiffenerassembly->AddNode(capacitor1812,1,capacitor1812trans);
d7599219 1372}
44285dfa 1373 return ssdstiffenerassembly;
d7599219 1374}
1375/////////////////////////////////////////////////////////////////////////////////
1376TGeoVolume* AliITSv11GeometrySSD::GetSSDChipCables(Double_t SSDChipCablesHeigth,
1377 char* side){
44285dfa 1378 /////////////////////////////////////////////////////////////
1379 // Method generating SSD Chip Cables
1380 /////////////////////////////////////////////////////////////
1381 const Int_t kssdchipcableslaynumber = 2;
1382 Int_t ssdchipcablescolor[2] = {fColorAl,fColorPolyhamide};
1383 Double_t ssdchipcablesradius[2];
1384 ssdchipcablesradius[0] = 0.25*(SSDChipCablesHeigth
d7599219 1385 - fgkSSDChipCablesHeight[0]
1386 - fgkSSDChipCablesHeight[1]);
44285dfa 1387 ssdchipcablesradius[1] = ssdchipcablesradius[0]-fgkSSDChipCablesHeight[0];
1388 Double_t ssdchipcablespiecelength = 0.5*(fgkSSDChipCablesWidth[0]
1389 - 2.*TMath::Pi()*ssdchipcablesradius[0]
1390 - ssdchipcablesradius[0]
d7599219 1391 - fgkSSDChipCablesWidth[1]
1392 - fgkSSDChipCablesWidth[2]
1393 - (side=="Right" ? 0 :
1394 fgkSSDModuleStiffenerPosition[1]
1395 + TMath::Pi()*(0.5*fgkSSDSensorHeight
1396 + fgkSSDChipCablesHeight[0]
1397 + fgkSSDChipCablesHeight[1])));
1398 //////////////////////////
1399 //Box and Tube Seg Shapes
1400 //////////////////////////
44285dfa 1401 char* ssdchipcablesboxshapename[2*kssdchipcableslaynumber] =
d7599219 1402 {"SSDChipCablesBoxLay0Shape0","SSDChipCablesBoxLay0Shape1",
1403 "SSDChipCablesBoxLay1Shape0","SSDChipCablesBoxLay1Shape1"};
44285dfa 1404 char* ssdchipcablestubesegshapename[2*kssdchipcableslaynumber] =
d7599219 1405 {"SSDChipCablesTubeSegLay0Shape0","SSDChipCablesTubeSegLay0Shape1",
1406 "SSDChipCablesTubeSegLay1Shape0","SSDChipCablesTubeSegLay1Shape1"};
44285dfa 1407 TGeoBBox** ssdchipcablesboxshape[kssdchipcableslaynumber];
1408 TGeoTubeSeg** ssdchipcablestubesegshape[kssdchipcableslaynumber];
1409 for(Int_t i=0; i<kssdchipcableslaynumber; i++){
1410 ssdchipcablesboxshape[i] = new TGeoBBox*[2];
1411 ssdchipcablestubesegshape[i] = new TGeoTubeSeg*[2+(side=="Right" ? 0 : 1)];
1412 ssdchipcablesboxshape[i][0] = new TGeoBBox(ssdchipcablesboxshapename[2*i],
1413 0.5*ssdchipcablespiecelength,
d7599219 1414 0.5*fgkSSDChipCablesLength[1],
1415 0.5*fgkSSDChipCablesHeight[i]);
44285dfa 1416 ssdchipcablesboxshape[i][1] = new TGeoBBox(ssdchipcablesboxshapename[2*i+1],
1417 0.5*(ssdchipcablespiecelength+ssdchipcablesradius[0]
d7599219 1418 + (side=="Right" ? 0. : fgkSSDModuleStiffenerPosition[1])),
1419 0.5*fgkSSDChipCablesLength[1],0.5*fgkSSDChipCablesHeight[i]);
44285dfa 1420 ssdchipcablestubesegshape[i][0] =
1421 new TGeoTubeSeg(ssdchipcablestubesegshapename[2*i],
1422 ssdchipcablesradius[1]-i*fgkSSDChipCablesHeight[1],
1423 ssdchipcablesradius[i],0.5*fgkSSDChipCablesLength[1],
d7599219 1424 0.,180.);
44285dfa 1425 ssdchipcablestubesegshape[i][1] =
1426 new TGeoTubeSeg(ssdchipcablestubesegshapename[2*i+1],
1427 ssdchipcablesradius[0]+i*fgkSSDChipCablesHeight[0],
1428 ssdchipcablesradius[0]+fgkSSDChipCablesHeight[0]
d7599219 1429 + i*fgkSSDChipCablesHeight[1],
1430 0.5*fgkSSDChipCablesLength[1],0.,180.);
44285dfa 1431 if(side!="Right") ssdchipcablestubesegshape[i][2] =
1432 new TGeoTubeSeg(ssdchipcablestubesegshapename[2*i],
d7599219 1433 0.5*fgkSSDSensorHeight+(1-i)*fgkSSDChipCablesHeight[1],
1434 0.5*fgkSSDSensorHeight+(1-i)*fgkSSDChipCablesHeight[0]
1435 + fgkSSDChipCablesHeight[1],
1436 0.5*fgkSSDChipCablesLength[1],0.,180.);
1437 }
1438 //////////////////////////
1439 //Box under Chip
1440 //////////////////////////
44285dfa 1441 char ssdunderchipcablesboxshapename[30];
1442 char ssdunderchipcablesboxname[30];
1443 char ssdunderchipcablesboxtransname[30];
1444 TGeoBBox* ssdunderchipcablesboxshape[kssdchipcableslaynumber];
1445 TGeoVolume* ssdunderchipcablesbox[kssdchipcableslaynumber];
1446 TGeoTranslation* ssdunderchipcablesboxtrans[kssdchipcableslaynumber];
1447 for(Int_t i=0; i<kssdchipcableslaynumber; i++){
1448 sprintf(ssdunderchipcablesboxshapename,"SSDUnderChipCablesBoxShape%i",i+1);
1449 sprintf(ssdunderchipcablesboxname,"SSDUnderChipCablesBox%i",i+1);
1450 sprintf(ssdunderchipcablesboxtransname,"SSDUnderChipCablesBoxTrans%i",i+1);
1451 ssdunderchipcablesboxshape[i] =
1452 new TGeoBBox(ssdunderchipcablesboxshapename,
d7599219 1453 0.5*fgkSSDChipWidth,
1454 0.5*fgkSSDChipCablesLength[1],
1455 0.5*fgkSSDChipCablesHeight[i]);
44285dfa 1456 ssdunderchipcablesbox[i] = new TGeoVolume(ssdunderchipcablesboxname,
1457 ssdunderchipcablesboxshape[i],
1458 (i==0?fSSDAlTraceChipCableMedium:fSSDKaptonChipCableMedium));
1459 ssdunderchipcablesbox[i]->SetLineColor(ssdchipcablescolor[i]);
1460 ssdunderchipcablesboxtrans[i] =
1461 new TGeoTranslation(ssdunderchipcablesboxtransname,
d7599219 1462 (side=="Right"?-1.:1.)*0.5*fgkSSDChipWidth,
1463 0.5*(fgkSSDChipCablesLength[0]-fgkSSDChipCablesLength[1])
1464 +0.5*fgkSSDChipCablesLength[1],
1465 (i==0?1.:-1.)*0.5*fgkSSDChipCablesHeight[1-i]);
1466 }
1467 //////////////////
1468 //Trapezoid Shapes
1469 //////////////////
44285dfa 1470 const Int_t kssdchipcablesvertexnumber = 2;
1471 const Int_t kssdchipcablestrapezoidnumber = 2;
1472 TVector3** ssdchipcablestrapezoidvertex[kssdchipcablesvertexnumber];
1473 for(Int_t i = 0; i< kssdchipcablestrapezoidnumber; i++)
1474 ssdchipcablestrapezoidvertex[i] = new TVector3*[kssdchipcablesvertexnumber];
d7599219 1475 //First Shape Vertex Positioning
44285dfa 1476 ssdchipcablestrapezoidvertex[0][0] = new TVector3();
1477 ssdchipcablestrapezoidvertex[0][1] =
d7599219 1478 new TVector3(0.5*(fgkSSDChipCablesLength[0]-fgkSSDChipCablesLength[1]));
1479 //Second Shape Vertex Positioning
44285dfa 1480 ssdchipcablestrapezoidvertex[1][0] =
1481 new TVector3(*ssdchipcablestrapezoidvertex[0][0]);
1482 ssdchipcablestrapezoidvertex[1][1] =
1483 new TVector3(*ssdchipcablestrapezoidvertex[0][1]);
d7599219 1484 //Setting the names of shapes and volumes
44285dfa 1485 char* ssdchipcablestrapezoidboxshapename[kssdchipcablestrapezoidnumber] =
d7599219 1486 {"SSDChipCablesTrapezoidBoxShape1","SSDChipCablesTrapezoidBoxShape2"};
44285dfa 1487 char* ssdchipcablestrapezoidshapename[kssdchipcablestrapezoidnumber] =
d7599219 1488 {"SSDChipCablesTrapezoidShape1","SSDChipCablesTrapezoidShape2"};
44285dfa 1489 char* ssdchipcablestrapezoidboxname[kssdchipcablestrapezoidnumber] =
d7599219 1490 {"SSDChipCablesTrapezoidBox1","SSDChipCablesTrapezoidBox2"};
44285dfa 1491 char* ssdhipcablestrapezoidname[kssdchipcablestrapezoidnumber] =
d7599219 1492 {"SSDChipCablesTrapezoid1","SSDChipCablesTrapezoid2"};
44285dfa 1493 char* ssdchipcablestrapezoidassemblyname[kssdchipcablestrapezoidnumber] =
d7599219 1494 {"SSDChipCablesTrapezoidAssembly1","SSDChipCablesTrapezoidAssembly2"};
1495 //Setting the Shapes
44285dfa 1496 TGeoBBox* ssdchipcablestrapezoidboxshape[kssdchipcablestrapezoidnumber];
1497 TGeoArb8* ssdchipcablestrapezoidshape[kssdchipcablestrapezoidnumber];
d7599219 1498 //Setting the Volumes
44285dfa 1499 TGeoVolume* ssdchipcablestrapezoidbox[kssdchipcablestrapezoidnumber];
1500 TGeoVolume* ssdchipcablestrapezoid[kssdchipcablestrapezoidnumber];
1501 TGeoVolume* ssdchipcablestrapezoidassembly[kssdchipcablestrapezoidnumber];
1502 Double_t ssdchipcablestrapezoidwidth[kssdchipcablesvertexnumber] =
d7599219 1503 {fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2],fgkSSDChipCablesWidth[1]};
44285dfa 1504 for(Int_t i=0; i<kssdchipcablestrapezoidnumber; i++){
1505 ssdchipcablestrapezoidboxshape[i] =
1506 new TGeoBBox(ssdchipcablestrapezoidboxshapename[i],
d7599219 1507 0.5*fgkSSDChipCablesLength[1],
1508 0.5*(fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2]),
1509 0.5*fgkSSDChipCablesHeight[i]);
44285dfa 1510 ssdchipcablestrapezoidshape[i] =
1511 GetTrapezoidShape(ssdchipcablestrapezoidvertex[i],
1512 ssdchipcablestrapezoidwidth,
d7599219 1513 fgkSSDChipCablesHeight[i],
44285dfa 1514 ssdchipcablestrapezoidshapename[i]);
1515 ssdchipcablestrapezoidbox[i] =
1516 new TGeoVolume(ssdchipcablestrapezoidboxname[i],
1517 ssdchipcablestrapezoidboxshape[i],
1518 (i==0?fSSDAlTraceChipCableMedium:fSSDKaptonChipCableMedium));
1519 ssdchipcablestrapezoid[i] = new TGeoVolume(ssdhipcablestrapezoidname[i],
1520 ssdchipcablestrapezoidshape[i],
1521 (i==0?fSSDAlTraceChipCableMedium:fSSDKaptonChipCableMedium));
1522 ssdchipcablestrapezoidbox[i]->SetLineColor(ssdchipcablescolor[i]);
1523 ssdchipcablestrapezoid[i]->SetLineColor(ssdchipcablescolor[i]);
1524 ssdchipcablestrapezoidassembly[i] =
1525 new TGeoVolumeAssembly(ssdchipcablestrapezoidassemblyname[i]);
1526 ssdchipcablestrapezoidassembly[i]->AddNode(ssdchipcablestrapezoidbox[i],1,
d7599219 1527 new TGeoTranslation(0.5*fgkSSDChipCablesLength[1],
1528 0.5*(fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2]),0.));
44285dfa 1529 ssdchipcablestrapezoidassembly[i]->AddNode(ssdchipcablestrapezoid[i],0,
d7599219 1530 new TGeoCombiTrans(0.,0.,0.,new TGeoRotation("",90.,180.,-90.)));
44285dfa 1531 ssdchipcablestrapezoidassembly[i]->AddNode(ssdchipcablestrapezoid[i],1,
d7599219 1532 new TGeoTranslation(fgkSSDChipCablesLength[1],0.,0.));
1533 }
1534 /////////////////////////////
1535 //Box and Tube Seg CombiTrans
1536 /////////////////////////////
44285dfa 1537 TGeoTranslation* ssdchipcablesboxtrans[2*kssdchipcableslaynumber];
1538 ssdchipcablesboxtrans[0] =
d7599219 1539 new TGeoTranslation("SSDChipCablesLay1Box1Trans",0.,0.,0.);
44285dfa 1540 ssdchipcablesboxtrans[1] =
d7599219 1541 new TGeoTranslation("SSDChipCablesLay1Box2Trans",
44285dfa 1542 ssdchipcablesboxshape[0][1]->GetDX()
1543 - 0.5*ssdchipcablespiecelength,
d7599219 1544 0.0,
44285dfa 1545 - 2.*ssdchipcablesradius[0]
d7599219 1546 - fgkSSDChipCablesHeight[0]);
44285dfa 1547 ssdchipcablesboxtrans[2] = new TGeoTranslation("SSDChipCablesLay2Box1Trans",
d7599219 1548 0.0,
1549 0.0,
1550 0.5*(fgkSSDChipCablesHeight[0]
1551 + fgkSSDChipCablesHeight[1]));
44285dfa 1552 ssdchipcablesboxtrans[3] =
d7599219 1553 new TGeoTranslation("SSDChipCablesLay2Box2Trans",
44285dfa 1554 ssdchipcablesboxshape[1][1]->GetDX()
1555 - 0.5*ssdchipcablespiecelength,
d7599219 1556 0.0,
44285dfa 1557 - 2.*ssdchipcablesradius[0]
d7599219 1558 - 0.5*fgkSSDChipCablesHeight[1]
1559 - 1.5*fgkSSDChipCablesHeight[0]);
44285dfa 1560 TGeoRotation* ssdchipcablesrot[3];
1561 ssdchipcablesrot[0] = new TGeoRotation("SSDChipCablesRot1",0.,90.,0.);
1562 ssdchipcablesrot[1] = new TGeoRotation("SSDChipCablesRot2",90.,90.,-90.);
1563 ssdchipcablesrot[2] = new TGeoRotation("SSDChipCablesRot3",90.,-90.,-90.);
1564 TGeoCombiTrans* ssdchipcablestubesegcombitrans[2*(kssdchipcableslaynumber+1)];
1565// TGeoCombiTrans* SSDChipCablesTubeSegCombiTrans[2*(SSDChipCablesLayNumber+
1566// (side=="Right" ? 0 : 1))];
1567 ssdchipcablestubesegcombitrans[0] =
d7599219 1568 new TGeoCombiTrans("SSDChipCablesLay1TubeSeg1CombiTrans",
44285dfa 1569 0.5*ssdchipcablespiecelength,
d7599219 1570 0.0,
44285dfa 1571 ssdchipcablesradius[0]
d7599219 1572 - 0.5*fgkSSDChipCablesHeight[0],
44285dfa 1573 new TGeoRotation((*ssdchipcablesrot[1])*(*ssdchipcablesrot[0])));
1574 ssdchipcablestubesegcombitrans[1] =
d7599219 1575 new TGeoCombiTrans("SSDChipCablesLay1TubeSeg2CombiTrans",
44285dfa 1576 - 0.5*ssdchipcablespiecelength,
d7599219 1577 0.0,
44285dfa 1578 - ssdchipcablesradius[0]-0.5*fgkSSDChipCablesHeight[0],
1579 new TGeoRotation((*ssdchipcablesrot[2])*(*ssdchipcablesrot[0])));
1580 ssdchipcablestubesegcombitrans[2] =
d7599219 1581 new TGeoCombiTrans("SSDChipCablesLay2TubeSeg1CombiTrans",
44285dfa 1582 0.5*ssdchipcablespiecelength,
d7599219 1583 0.0,
44285dfa 1584 ssdchipcablesradius[0]-0.5*fgkSSDChipCablesHeight[0],
1585 new TGeoRotation((*ssdchipcablesrot[1])*(*ssdchipcablesrot[0])));
1586 ssdchipcablestubesegcombitrans[3] =
d7599219 1587 new TGeoCombiTrans("SSDChipCablesLay2TubeSeg2CombiTrans",
44285dfa 1588 - 0.5*ssdchipcablespiecelength,
d7599219 1589 0.0,
44285dfa 1590 - ssdchipcablesradius[0]+0.5*fgkSSDChipCablesHeight[0]
d7599219 1591 - fgkSSDChipCablesHeight[0],
44285dfa 1592 new TGeoRotation((*ssdchipcablesrot[2])*(*ssdchipcablesrot[0])));
1593 ssdchipcablestubesegcombitrans[4] =
d7599219 1594 new TGeoCombiTrans("SSDChipCablesLay1TubeSeg4CombiTrans",
44285dfa 1595 0.5*ssdchipcablespiecelength+ssdchipcablesradius[0]
d7599219 1596 + fgkSSDModuleStiffenerPosition[1],
1597 0.0,
44285dfa 1598 - 2.*ssdchipcablesradius[0]-0.5*fgkSSDChipCablesHeight[0]
d7599219 1599 - (0.5*fgkSSDSensorHeight+fgkSSDChipCablesHeight[0]
1600 + fgkSSDChipCablesHeight[1]),
44285dfa 1601 new TGeoRotation((*ssdchipcablesrot[1])*(*ssdchipcablesrot[0])));
1602 ssdchipcablestubesegcombitrans[5] =
d7599219 1603 new TGeoCombiTrans("SSDChipCablesLay2TubeSeg5CombiTrans",
44285dfa 1604 0.5*ssdchipcablespiecelength+ssdchipcablesradius[0]
d7599219 1605 + fgkSSDModuleStiffenerPosition[1],
1606 0.0,
44285dfa 1607 - 2.*ssdchipcablesradius[0]-0.5*fgkSSDChipCablesHeight[0]
d7599219 1608 - (0.5*fgkSSDSensorHeight+fgkSSDChipCablesHeight[0]
1609 + fgkSSDChipCablesHeight[1]),
44285dfa 1610 new TGeoRotation((*ssdchipcablesrot[1])*(*ssdchipcablesrot[0])));
1611 TGeoCombiTrans* ssdchipcablestrapezoidcombitrans[kssdchipcableslaynumber];
1612 ssdchipcablestrapezoidcombitrans[0] = (side=="Right" ?
d7599219 1613 new TGeoCombiTrans("SSDChipCableLay1TrapezoidRightCombiTrans",
44285dfa 1614 0.5*ssdchipcablespiecelength+ssdchipcablestrapezoidwidth[0]
1615 + ssdchipcablesradius[0],
d7599219 1616 - 0.5*fgkSSDChipCablesLength[1],
44285dfa 1617 - fgkSSDChipCablesHeight[0]-2.*ssdchipcablesradius[0],
d7599219 1618 new TGeoRotation("",90.,0.,0.)) :
1619 new TGeoCombiTrans("SSDChipCableLay1TrapezoidLeftCombiTrans",
1620 - 2.*(fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2])
44285dfa 1621 + 0.5*ssdchipcablespiecelength+ssdchipcablestrapezoidwidth[0]
1622 + ssdchipcablesradius[0]+fgkSSDModuleStiffenerPosition[1],
d7599219 1623 0.5*fgkSSDChipCablesLength[1],
1624 - 2.*(fgkSSDChipCablesHeight[0]+fgkSSDChipCablesHeight[1])
44285dfa 1625 - 2.*ssdchipcablesradius[0]-fgkSSDSensorHeight,
d7599219 1626 new TGeoRotation("",-90.,0.,0.)));
44285dfa 1627 ssdchipcablestrapezoidcombitrans[1] = (side=="Right" ?
d7599219 1628 new TGeoCombiTrans("SSDChipCableLay2TrapezoidRightCombiTrans",
44285dfa 1629 0.5*ssdchipcablespiecelength+ssdchipcablestrapezoidwidth[0]
1630 + ssdchipcablesradius[0],
d7599219 1631 - 0.5*fgkSSDChipCablesLength[1],
1632 - 0.5*(fgkSSDChipCablesHeight[0]+fgkSSDChipCablesHeight[1])
44285dfa 1633 - fgkSSDChipCablesHeight[0]-2.*ssdchipcablesradius[0],
d7599219 1634 new TGeoRotation("",90.,0.,0.)) :
1635 new TGeoCombiTrans("SSDChipCableLay2TrapezoidLeftCombiTrans",
1636 - 2.*(fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2])
44285dfa 1637 + 0.5*ssdchipcablespiecelength+ssdchipcablestrapezoidwidth[0]
1638 + ssdchipcablesradius[0]+fgkSSDModuleStiffenerPosition[1],
d7599219 1639 0.5*fgkSSDChipCablesLength[1],-0.5*(fgkSSDChipCablesHeight[0]
1640 + fgkSSDChipCablesHeight[1])-fgkSSDChipCablesHeight[1]
44285dfa 1641 - fgkSSDChipCablesHeight[0]-2.*ssdchipcablesradius[0]
d7599219 1642 - fgkSSDSensorHeight,new TGeoRotation("",-90.,0.,0.)));
1643 //////////////////////////
1644 //Box and Tube Seg Volumes
1645 //////////////////////////
44285dfa 1646 char* ssdchipcablesboxname[2*kssdchipcableslaynumber] =
d7599219 1647 {"SSDChipCablesLay1Box1","SSDChipCablesLay1Box2",
1648 "SSDChipCablesLay2Box1","SSDChipCablesLay2Box2"};
44285dfa 1649 char* ssdchiprightcablestubesegname[2*kssdchipcableslaynumber] =
d7599219 1650 {"SSDChipRightCablesLay1TubeSeg1","SSDChipRightCablesLay1TubeSeg2",
1651 "SSDChipRightCablesLay2TubeSeg1","SSDChipRightCablesLay2TubeSeg2"};
44285dfa 1652 char* ssdchipLeftcablestubesegname[2*kssdchipcableslaynumber] =
d7599219 1653 {"SSDChipLeftCablesLay1TubeSeg1","SSDChipLeftCablesLay1TubeSeg2",
1654 "SSDChipLeftCablesLay2TubeSeg1","SSDChipLeftCablesLay2TubeSeg2"};
44285dfa 1655 char* ssdchipcableslayassemblyname[kssdchipcableslaynumber] =
d7599219 1656 {"SSDChipCablesLay1","SSDChipCablesLay2"};
44285dfa 1657 TGeoVolume** ssdchipcablesbox[kssdchipcableslaynumber];
1658 TGeoVolume** ssdchipcablestubeseg[kssdchipcableslaynumber];
1659 TGeoVolume* ssdchipcableslayassembly[kssdchipcableslaynumber];
1660 for(Int_t i=0; i<kssdchipcableslaynumber; i++){
1661 TGeoMedium* ssdchipcableslaymed =
1662 (i==0?fSSDAlTraceChipCableMedium:fSSDKaptonChipCableMedium);
1663 ssdchipcablesbox[i] = new TGeoVolume*[2];
1664 ssdchipcablestubeseg[i] = new TGeoVolume*[2+(side=="Right" ? 0 : 1)];
1665 ssdchipcablesbox[i][0] = new TGeoVolume(ssdchipcablesboxname[2*i],
1666 ssdchipcablesboxshape[i][0],ssdchipcableslaymed);
1667 ssdchipcablesbox[i][1] = new TGeoVolume(ssdchipcablesboxname[2*i+1],
1668 ssdchipcablesboxshape[i][1],ssdchipcableslaymed);
1669 ssdchipcablestubeseg[i][0] = new TGeoVolume(ssdchiprightcablestubesegname[2*i],
1670 ssdchipcablestubesegshape[i][0],ssdchipcableslaymed);
1671 ssdchipcablestubeseg[i][1] = new TGeoVolume(ssdchiprightcablestubesegname[2*i+1],
1672 ssdchipcablestubesegshape[i][1],ssdchipcableslaymed);
1673 ssdchipcablesbox[i][0]->SetLineColor(ssdchipcablescolor[i]);
1674 ssdchipcablesbox[i][1]->SetLineColor(ssdchipcablescolor[i]);
1675 ssdchipcablestubeseg[i][0]->SetLineColor(ssdchipcablescolor[i]);
1676 ssdchipcablestubeseg[i][1]->SetLineColor(ssdchipcablescolor[i]);
1677 ssdchipcableslayassembly[i] = new TGeoVolumeAssembly(ssdchipcableslayassemblyname[i]);
1678 ssdchipcableslayassembly[i]->AddNode(ssdchipcablesbox[i][0],1,
1679 ssdchipcablesboxtrans[2*i]);
1680 ssdchipcableslayassembly[i]->AddNode(ssdchipcablesbox[i][1],1,
1681 ssdchipcablesboxtrans[2*i+1]);
1682 ssdchipcableslayassembly[i]->AddNode(ssdchipcablestubeseg[i][0],1,
1683 ssdchipcablestubesegcombitrans[2*i]);
1684 ssdchipcableslayassembly[i]->AddNode(ssdchipcablestubeseg[i][1],1,
1685 ssdchipcablestubesegcombitrans[2*i+1]);
d7599219 1686 if(side!="Right"){
44285dfa 1687 ssdchipcablestubeseg[i][2] = new TGeoVolume(ssdchipLeftcablestubesegname[2*i],
1688 ssdchipcablestubesegshape[i][2],
1689 ssdchipcableslaymed);
1690 ssdchipcablestubeseg[i][2]->SetLineColor(ssdchipcablescolor[i]);
1691 ssdchipcableslayassembly[i]->AddNode(ssdchipcablestubeseg[i][2],1,
1692 ssdchipcablestubesegcombitrans[4+i]);
d7599219 1693 }
44285dfa 1694 ssdchipcableslayassembly[i]->AddNode(ssdchipcablestrapezoidassembly[i],1,
1695 ssdchipcablestrapezoidcombitrans[i]);
d7599219 1696 }
44285dfa 1697 TGeoCombiTrans* ssdchipcablescombitrans[kssdchipcableslaynumber];
1698 ssdchipcablescombitrans[0] = new TGeoCombiTrans("SSDChipCablesCombiTrans1",
1699 (side=="Right" ? -1 : 1)*0.5*ssdchipcablespiecelength,
d7599219 1700 0.5*fgkSSDChipCablesLength[0],
44285dfa 1701 - (2.*ssdchipcablesradius[0]-fgkSSDChipCablesHeight[0]
d7599219 1702 - 0.5*fgkSSDChipCablesHeight[1]),
1703 new TGeoRotation("",(side=="Right" ? 0 : 1)*180.,0.,0.));
44285dfa 1704 ssdchipcablescombitrans[1] = new TGeoCombiTrans("SSDChipCablesCombiTrans2",
1705 (side=="Right" ? -1 : 1)*0.5*ssdchipcablespiecelength,
d7599219 1706 0.5*fgkSSDChipCablesLength[0],
44285dfa 1707 - (2.*ssdchipcablesradius[0]-fgkSSDChipCablesHeight[0]
d7599219 1708 - 0.5*fgkSSDChipCablesHeight[1]),
1709 new TGeoRotation("",(side=="Right" ? 0 : 1)*180.,0.,0.));
44285dfa 1710 TGeoVolume* ssdchipcablesassembly =
d7599219 1711 new TGeoVolumeAssembly("SSDChipCables");
44285dfa 1712 for(Int_t i=0; i<kssdchipcableslaynumber; i++){
1713 ssdchipcablesassembly->AddNode(ssdchipcableslayassembly[i],1,
1714 ssdchipcablescombitrans[i]);
1715 ssdchipcablesassembly->AddNode(ssdunderchipcablesbox[i],1,ssdunderchipcablesboxtrans[i]);
d7599219 1716 }
44285dfa 1717 return ssdchipcablesassembly;
d7599219 1718}
1719/////////////////////////////////////////////////////////////////////////////////
1720TGeoVolume* AliITSv11GeometrySSD::GetSSDChipCablesAssembly(Double_t SSDChipCablesHeigth){
44285dfa 1721 /////////////////////////////////////////////////////////////
1722 // Method generating SSD Chip Cables Assembly
1723 /////////////////////////////////////////////////////////////
1724 const Int_t kchipcablesnumber = 2;
1725 Double_t chipcablestransvector = fgkSSDSensorLength
d7599219 1726 - 2.*fgkSSDModuleStiffenerPosition[1]
1727 - 2.*(fgkSSDStiffenerWidth
1728 - fgkSSDStiffenerToChipDist-fgkSSDChipWidth);
44285dfa 1729 char* ssdchipcablesname[kchipcablesnumber] = {"Right","Left"};
1730 TGeoVolume* ssdchipcables[kchipcablesnumber];
1731 TGeoVolume* ssdchipcablesassembly =
d7599219 1732 new TGeoVolumeAssembly("SSDChipCablesAssembly");
44285dfa 1733 for(Int_t i=0; i<kchipcablesnumber; i++) ssdchipcables[i] =
1734 GetSSDChipCables(SSDChipCablesHeigth,ssdchipcablesname[i]);
1735 for(Int_t i=0; i<kchipcablesnumber; i++)
d7599219 1736 for(Int_t j=0; j<fgkSSDChipNumber; j++)
44285dfa 1737 ssdchipcablesassembly->AddNode(ssdchipcables[i],fgkSSDChipNumber*i+j+1,
1738 new TGeoTranslation(-(ssdchipcablesname[i]=="Left" ? 1. : 0.)
1739 * chipcablestransvector,(j-0.5)*fgkSSDChipCablesLength[0]
d7599219 1740 + 0.5*fgkSSDChipCablesLength[1],0.));
44285dfa 1741 return ssdchipcablesassembly;
d7599219 1742}
1743/////////////////////////////////////////////////////////////////////////////////
44285dfa 1744TGeoVolume* AliITSv11GeometrySSD::GetSSDFlex(Double_t ssdflexradius, Double_t SSDFlexHeigth){
1745 /////////////////////////////////////////////////////////////
1746 // Method generating SSD Flex
1747 /////////////////////////////////////////////////////////////
1748 const Int_t kssdflexvolumenumber = 3;
1749 TGeoVolume* ssdflexvolume[kssdflexvolumenumber];
d7599219 1750 ////////////////////////
1751 // Setting Display Color
1752 ////////////////////////
44285dfa 1753 Int_t ssdflexcolor;
1754 ssdflexcolor = (SSDFlexHeigth == fgkSSDFlexHeight[0] ? fColorAl: fColorPolyhamide);
1755 TGeoMedium* ssdflexmed = (SSDFlexHeigth == fgkSSDFlexHeight[0] ? fSSDAlTraceFlexMedium :
1756 fSSDKaptonFlexMedium);
d7599219 1757 ////////////////////////
1758 // SSDFlexTrapezoidShape
1759 ////////////////////////
44285dfa 1760 const Int_t kssdflexvertexnumber = 2;
1761 Double_t ssdflexwidth[kssdflexvertexnumber] = {fgkSSDFlexWidth[1],
d7599219 1762 fgkSSDFlexWidth[0]};
44285dfa 1763 TVector3* ssdflexvertex[kssdflexvertexnumber];
1764 ssdflexvertex[0] = new TVector3();
1765 ssdflexvertex[1] = new TVector3(fgkSSDFlexLength[0]-fgkSSDFlexLength[1]);
1766 TGeoArb8* ssdflextrapezoidshape = GetTrapezoidShape(ssdflexvertex,
1767 ssdflexwidth,SSDFlexHeigth,
d7599219 1768 "SSDFlexTrapezoidShape");
44285dfa 1769 ssdflexvolume[0] = new TGeoVolume("SSDFlexTrapezoid",ssdflextrapezoidshape,ssdflexmed);
1770 ssdflexvolume[0]->SetLineColor(ssdflexcolor);
d7599219 1771 /////////////////////////
1772 //SSDFlexTubeSeg Assembly
1773 /////////////////////////
44285dfa 1774 const Int_t kssdflextubesegnumber = 2;
1775 TGeoTubeSeg* ssdflextubesegshape[kssdflextubesegnumber];
1776 Double_t ssdflexradiusmax = (fgkSSDFlexLength[3]-fgkSSDFlexLength[2])
d7599219 1777 / TMath::Tan(fgkSSDFlexAngle*TMath::DegToRad());
44285dfa 1778 ssdflextubesegshape[0] = new TGeoTubeSeg("SSDFlexTubeSegShape1",
1779 ssdflexradius,ssdflexradius+SSDFlexHeigth,
d7599219 1780 0.5*fgkSSDFlexWidth[0],0.,180.);
44285dfa 1781 ssdflextubesegshape[1] = new TGeoTubeSeg("SSDFlexTubeSegShape2",
1782 ssdflexradiusmax-ssdflexradius-SSDFlexHeigth,
1783 ssdflexradiusmax-ssdflexradius,0.5*fgkSSDFlexWidth[0],
d7599219 1784 0.,2.*fgkSSDFlexAngle);
44285dfa 1785 TGeoRotation** ssdflextubsegrot[kssdflextubesegnumber];
1786 for(Int_t i = 0; i<kssdflextubesegnumber; i++)
1787 ssdflextubsegrot[i] = new TGeoRotation*[2];
1788 ssdflextubsegrot[0][0] = new TGeoRotation("SSDFlexTubeSeg1Rot1", 0., 90., 0.);
1789 ssdflextubsegrot[0][1] = new TGeoRotation("SSDFlexTubeSeg1Rot2",90., 90.,-90.);
1790 ssdflextubsegrot[1][0] = new TGeoRotation("SSDFlexTubeSeg2Rot1", 0.,-90., 0.);
1791 ssdflextubsegrot[1][1] = new TGeoRotation("SSDFlexTubeSeg2Rot2",90., 90.,-90.);
1792 TGeoCombiTrans* ssdflextubesegcombitrans[kssdflextubesegnumber];
1793 ssdflextubesegcombitrans[0] = new TGeoCombiTrans("SSDFlexTubeSegCombiTrans1",
d7599219 1794 fgkSSDFlexLength[0],0.5*fgkSSDFlexWidth[0],
44285dfa 1795 ssdflexradius+0.5*SSDFlexHeigth,
1796 new TGeoRotation((*ssdflextubsegrot[0][1])
1797 * (*ssdflextubsegrot[0][0])));
1798 ssdflextubesegcombitrans[1] = new TGeoCombiTrans("SSDFlexTubeSegCombiTrans2",
d7599219 1799 fgkSSDFlexLength[0]-fgkSSDFlexLength[2],
1800 0.5*fgkSSDFlexWidth[0],
44285dfa 1801 ssdflexradiusmax+0.5*SSDFlexHeigth+ssdflexradius,
1802 new TGeoRotation((*ssdflextubsegrot[1][1])
1803 * (*ssdflextubsegrot[1][0])));
1804 ssdflexvolume[1] = new TGeoVolumeAssembly("SSDFlexTubeSegAssembly");
1805 TGeoVolume* ssdflextubeseg[kssdflextubesegnumber];
1806 char ssdflextubesegname[30];
1807 for(Int_t i=0; i<kssdflextubesegnumber; i++){
1808 sprintf(ssdflextubesegname,"SSDFlexTubeSeg%i",i+1);
1809 ssdflextubeseg[i] = new TGeoVolume(ssdflextubesegname,ssdflextubesegshape[i],
1810 ssdflexmed);
1811 ssdflextubeseg[i]->SetLineColor(ssdflexcolor);
1812 ssdflexvolume[1]->AddNode(ssdflextubeseg[i],1,ssdflextubesegcombitrans[i]);
d7599219 1813 }
1814 ///////////
1815 //Box Shape
1816 ///////////
44285dfa 1817 const Int_t kssdflexboxnumber = 7;
1818 Double_t ssdflexboxlength[kssdflexboxnumber];
1819 ssdflexboxlength[0] = 0.5*(fgkSSDChipNumber
d7599219 1820 * fgkSSDChipLength+(fgkSSDChipNumber-1)
1821 * fgkSSDChipSeparationLength
1822 - fgkSSDModuleSensorSupportDistance-fgkSSDFlexHoleLength)
1823 - (fgkSSDFlexLength[0]-fgkSSDFlexLength[1]);
44285dfa 1824 ssdflexboxlength[1] = fgkSSDModuleSensorSupportDistance+fgkSSDFlexHoleLength;
1825 ssdflexboxlength[2] = 0.5*(fgkSSDModuleSensorSupportDistance
d7599219 1826 - fgkSSDFlexHoleLength-fgkSSDFlexHoleWidth);
44285dfa 1827 ssdflexboxlength[3] = fgkSSDFlexHoleWidth;
1828 ssdflexboxlength[4] = fgkSSDFlexLength[1]-ssdflexboxlength[0]
1829 - ssdflexboxlength[1];
1830 ssdflexboxlength[5] = fgkSSDFlexLength[2];
1831 ssdflexboxlength[6] = fgkSSDFlexFullLength-2.*fgkSSDFlexAngle
1832 * TMath::DegToRad()*ssdflexradiusmax
d7599219 1833 - fgkSSDFlexLength[2]-TMath::Pi()
1834 * fgkSSDStiffenerHeight-fgkSSDFlexLength[0];
44285dfa 1835 Double_t ssdflexboxwidth[kssdflexboxnumber];
1836 ssdflexboxwidth[0] = fgkSSDFlexWidth[0];
1837 ssdflexboxwidth[1] = fgkSSDFlexWidth[0]-fgkSSDFlexHoleWidth;
1838 ssdflexboxwidth[2] = fgkSSDFlexHoleWidth;
1839 ssdflexboxwidth[3] = ssdflexboxwidth[2]-fgkSSDFlexHoleLength;
1840 ssdflexboxwidth[4] = fgkSSDFlexWidth[0];
1841 ssdflexboxwidth[5] = fgkSSDFlexWidth[0];
1842 ssdflexboxwidth[6] = fgkSSDFlexWidth[0];
1843 TGeoBBox* ssdflexboxshape[kssdflexboxnumber+1];
1844 for(Int_t i=0; i<kssdflexboxnumber+1; i++) ssdflexboxshape[i] =
1845 (i!= kssdflexboxnumber ? new TGeoBBox("SSDFlexBoxShape",
1846 0.5*ssdflexboxlength[i],
1847 0.5*ssdflexboxwidth[i],0.5*SSDFlexHeigth) :
1848 ssdflexboxshape[2]);
d7599219 1849 //////////////////////////////
1850 //SSDFlex Box Shape CombiTrans
1851 //////////////////////////////
44285dfa 1852 TGeoCombiTrans* ssdflexboxcombitrans[kssdflexboxnumber+1];
1853 ssdflexboxcombitrans[0] = new TGeoCombiTrans("SSDFlexBoxCombiTrans0",
1854 ssdflexvertex[1]->X()+0.5*ssdflexboxlength[0],
d7599219 1855 0.5*fgkSSDFlexWidth[0],0.,0);
44285dfa 1856 ssdflexboxcombitrans[1] = new TGeoCombiTrans("SSDFlexBoxCombiTrans1",
1857 ssdflexvertex[1]->X()+ssdflexboxlength[0]
1858 + 0.5*ssdflexboxlength[1],
1859 fgkSSDFlexHoleWidth+0.5*ssdflexboxwidth[1],0.,0);
1860 ssdflexboxcombitrans[2] = new TGeoCombiTrans("SSDFlexBoxCombiTrans2",
1861 ssdflexvertex[1]->X()+ssdflexboxlength[0]
1862 + fgkSSDFlexHoleLength+0.5*ssdflexboxlength[2],
1863 0.5*ssdflexboxwidth[2],0.,0);
1864 ssdflexboxcombitrans[3] = new TGeoCombiTrans("SSDFlexBoxCombiTrans3",
1865 ssdflexvertex[1]->X()+ssdflexboxlength[0]
1866 + fgkSSDFlexHoleLength+ssdflexboxlength[2]
d7599219 1867 + 0.5*fgkSSDFlexHoleWidth,
44285dfa 1868 fgkSSDFlexHoleLength+0.5*ssdflexboxwidth[3],0.,0);
1869 ssdflexboxcombitrans[4] = new TGeoCombiTrans("SSDFlexBoxCombiTrans4",
1870 ssdflexvertex[1]->X()+ssdflexboxlength[0]
1871 + ssdflexboxlength[1]+0.5*ssdflexboxlength[4],
d7599219 1872 0.5*fgkSSDFlexWidth[0],0.,0);
44285dfa 1873 ssdflexboxcombitrans[5] = new TGeoCombiTrans("SSDFlexBoxCombiTrans5",
d7599219 1874 - 0.5*fgkSSDFlexLength[2]+fgkSSDFlexLength[0],
1875 0.5*fgkSSDFlexWidth[0],
44285dfa 1876 2.*ssdflexradius+SSDFlexHeigth,0);
1877 ssdflexboxcombitrans[6] = new TGeoCombiTrans("SSDFlexBoxCombiTrans6",
1878 - ssdflexboxshape[6]->GetDX()
1879 + ssdflexboxshape[6]->GetDX()
d7599219 1880 * TMath::Cos(2.*fgkSSDFlexAngle*TMath::DegToRad())
1881 + fgkSSDFlexLength[0]-fgkSSDFlexLength[2]
44285dfa 1882 - (ssdflexradiusmax-ssdflexradius-0.5*SSDFlexHeigth)
d7599219 1883 * TMath::Cos(fgkSSDFlexAngle*TMath::DegToRad()),
44285dfa 1884 0.5*fgkSSDFlexWidth[0],ssdflexboxshape[6]->GetDX()
d7599219 1885 *TMath::Sin(2.*fgkSSDFlexAngle*TMath::DegToRad())
44285dfa 1886 + SSDFlexHeigth+2.*ssdflexradius+(ssdflexradiusmax
1887 - ssdflexradius-0.5*SSDFlexHeigth)
d7599219 1888 * TMath::Sin(fgkSSDFlexAngle*TMath::DegToRad()),
1889 new TGeoRotation("",90.,2.*fgkSSDFlexAngle,-90.));
44285dfa 1890 ssdflexboxcombitrans[7] = new TGeoCombiTrans("SSDFlexBoxCombiTrans7",
1891 ssdflexvertex[1]->X()+ssdflexboxlength[0]
1892 + fgkSSDFlexHoleLength+1.5*ssdflexboxlength[2]
1893 + ssdflexboxlength[3],
1894 0.5*ssdflexboxwidth[2],0.,0);
d7599219 1895 ////////////////////////////
1896 //SSDFlex Box Shape Assembly
1897 ////////////////////////////
44285dfa 1898 ssdflexvolume[2] = new TGeoVolumeAssembly("SSDFlexBoxAssembly");
1899 TGeoVolume* ssdflexbox[kssdflexboxnumber+1];
1900 TGeoVolume* ssdendflex = GetSSDEndFlex(ssdflexboxlength[6],SSDFlexHeigth);
1901 TGeoHMatrix* ssdendflexhmatrix = new TGeoHMatrix();
1902 TGeoRotation* ssdendflexrot = new TGeoRotation("SSDEndFlexRot",180.,0.,0);
1903 ssdendflexhmatrix->MultiplyLeft(ssdendflexrot);
1904 ssdendflexhmatrix->MultiplyLeft(ssdflexboxcombitrans[6]);
1905 char ssdflexboxname[30];
1906 for(Int_t i=0; i<kssdflexboxnumber+1; i++){
1907 sprintf(ssdflexboxname,"SSDFlexBox%i",i!=kssdflexboxnumber?i+1:7);
1908 if(i==6){ssdflexvolume[2]->AddNode(ssdendflex,1,ssdendflexhmatrix);}
d7599219 1909 else{
44285dfa 1910 ssdflexbox[i] = new TGeoVolume(ssdflexboxname,ssdflexboxshape[i],
1911 ssdflexmed);
1912 ssdflexbox[i]->SetLineColor(ssdflexcolor);
1913 ssdflexvolume[2]->AddNode(ssdflexbox[i],1,ssdflexboxcombitrans[i]);}
d7599219 1914 }
1915 //////////////////////
1916 //SSDFlex Construction
1917 //////////////////////
44285dfa 1918 TGeoVolume* ssdflex = new TGeoVolumeAssembly("SSDFlex");
1919 for(Int_t i =0; i<kssdflexvolumenumber; i++) ssdflex->AddNode(ssdflexvolume[i],1);
1920 return ssdflex;
d7599219 1921}
1922/////////////////////////////////////////////////////////////////////////////////
1923TGeoVolume* AliITSv11GeometrySSD::GetSSDEndFlex(Double_t SSDEndFlexLength,
1924 Double_t SSDFlexHeigth){
44285dfa 1925 /////////////////////////////////////////////////////////////
1926 // Method generating SSD End Flex
d7599219 1927 /////////////////////////////////////////
1928 // Setting Display Color, Media and Index
1929 /////////////////////////////////////////
44285dfa 1930 Int_t ssdflexcolor;
1931 ssdflexcolor = (SSDFlexHeigth == fgkSSDFlexHeight[0] ? fColorAl: fColorPolyhamide);
1932 TGeoMedium* ssdflexmed = (SSDFlexHeigth == fgkSSDFlexHeight[0] ? fSSDAlTraceFlexMedium :
1933 fSSDKaptonFlexMedium);
d7599219 1934 ////////////////////////
44285dfa 1935 const Int_t kssdendflexboxnumber = 5;
1936 TGeoBBox* ssdendflexbboxshape[kssdendflexboxnumber];
1937 ssdendflexbboxshape[0] = new TGeoBBox("SSDFlexBoxShape1",
d7599219 1938 0.5*SSDEndFlexLength,0.5*fgkSSDFlexWidth[0],
1939 0.5*SSDFlexHeigth);
44285dfa 1940 ssdendflexbboxshape[1] = new TGeoBBox("SSDFlexBoxShape2",
d7599219 1941 0.5*fgkSSDEndFlexCompLength[1],
1942 0.5*(fgkSSDEndFlexCompWidth[0]-fgkSSDFlexWidth[0])/2,
1943 0.5*SSDFlexHeigth);
44285dfa 1944 ssdendflexbboxshape[2] = new TGeoBBox("SSDFlexBoxShape3",
d7599219 1945 0.5*fgkSSDEndFlexCompLength[2],
1946 0.5*(fgkSSDEndFlexCompWidth[1]-fgkSSDFlexWidth[0])/2,
1947 0.5*SSDFlexHeigth);
44285dfa 1948 ssdendflexbboxshape[3] = new TGeoBBox("SSDFlexBoxShape4",
d7599219 1949 0.5*fgkSSDEndFlexCompLength[3],
1950 0.5*(fgkSSDEndFlexCompWidth[0]-fgkSSDFlexWidth[0])/2,
1951 0.5*SSDFlexHeigth);
44285dfa 1952 ssdendflexbboxshape[4] = new TGeoBBox("SSDFlexBoxShape5",
d7599219 1953 0.5*(fgkSSDEndFlexCompLength[4]+fgkSSDEndFlexCompLength[5]),
1954 0.25*(fgkSSDEndFlexCompWidth[2]-fgkSSDFlexWidth[0])/2,
1955 0.5*SSDFlexHeigth);
44285dfa 1956 TGeoVolume* ssdendflexbbox[kssdendflexboxnumber];
1957 char ssdendflexbboxname[30];
1958 for(Int_t i=0; i<kssdendflexboxnumber; i++){
1959 sprintf(ssdendflexbboxname,"SSDEndFlexBBox%i",i+1);
1960 ssdendflexbbox[i] = new TGeoVolume(ssdendflexbboxname,
1961 ssdendflexbboxshape[i],
1962 ssdflexmed);
1963 ssdendflexbbox[i]->SetLineColor(ssdflexcolor);
d7599219 1964 }
44285dfa 1965 TGeoVolume* ssdendflex = new TGeoVolumeAssembly("SSDEndFlex");
1966 Double_t partialsumlength = 0.;
1967 for(Int_t i=0; i<kssdendflexboxnumber+1; i++) partialsumlength += fgkSSDEndFlexCompLength[i];
1968 Double_t referencelength = SSDEndFlexLength-partialsumlength;
1969 ssdendflex->AddNode(ssdendflexbbox[0],1);
1970 ssdendflex->AddNode(ssdendflexbbox[1],1,new TGeoTranslation(
1971 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1972 + 0.5*fgkSSDEndFlexCompLength[1],
44285dfa 1973 0.5*fgkSSDFlexWidth[0]+ssdendflexbboxshape[1]->GetDY(),
d7599219 1974 0.));
44285dfa 1975 ssdendflex->AddNode(ssdendflexbbox[1],2,new TGeoTranslation(
1976 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1977 + 0.5*fgkSSDEndFlexCompLength[1],
44285dfa 1978 - 0.5*fgkSSDFlexWidth[0]-ssdendflexbboxshape[1]->GetDY(),
d7599219 1979 0.));
44285dfa 1980 ssdendflex->AddNode(ssdendflexbbox[2],1,new TGeoTranslation(
1981 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1982 + fgkSSDEndFlexCompLength[1]+0.5*fgkSSDEndFlexCompLength[2],
44285dfa 1983 + 0.5*fgkSSDFlexWidth[0]+ssdendflexbboxshape[2]->GetDY(),
d7599219 1984 0.));
44285dfa 1985 ssdendflex->AddNode(ssdendflexbbox[2],2,new TGeoTranslation(
1986 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1987 + fgkSSDEndFlexCompLength[1]+0.5*fgkSSDEndFlexCompLength[2],
44285dfa 1988 - 0.5*fgkSSDFlexWidth[0]-ssdendflexbboxshape[2]->GetDY(),
d7599219 1989 0.));
44285dfa 1990 ssdendflex->AddNode(ssdendflexbbox[3],1,new TGeoTranslation(
1991 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1992 + fgkSSDEndFlexCompLength[1]+fgkSSDEndFlexCompLength[2]
1993 + 0.5*fgkSSDEndFlexCompLength[3],
44285dfa 1994 + 0.5*fgkSSDFlexWidth[0]+ssdendflexbboxshape[3]->GetDY(),
d7599219 1995 0.));
44285dfa 1996 ssdendflex->AddNode(ssdendflexbbox[3],2,new TGeoTranslation(
1997 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 1998 + fgkSSDEndFlexCompLength[1]+fgkSSDEndFlexCompLength[2]
1999 + 0.5*fgkSSDEndFlexCompLength[3],
44285dfa 2000 - 0.5*fgkSSDFlexWidth[0]-ssdendflexbboxshape[3]->GetDY(),
d7599219 2001 0.));
44285dfa 2002 ssdendflex->AddNode(ssdendflexbbox[4],1,new TGeoTranslation(
2003 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 2004 + fgkSSDEndFlexCompLength[1]+fgkSSDEndFlexCompLength[2]
2005 + fgkSSDEndFlexCompLength[3]+0.5*(fgkSSDEndFlexCompLength[4]+fgkSSDEndFlexCompLength[5]),
44285dfa 2006 + 0.5*fgkSSDFlexWidth[0]+ssdendflexbboxshape[4]->GetDY(),
d7599219 2007 0.));
44285dfa 2008 ssdendflex->AddNode(ssdendflexbbox[4],2,new TGeoTranslation(
2009 - 0.5*SSDEndFlexLength+referencelength+fgkSSDEndFlexCompLength[0]
d7599219 2010 + fgkSSDEndFlexCompLength[1]+fgkSSDEndFlexCompLength[2]
2011 + fgkSSDEndFlexCompLength[3]+0.5*(fgkSSDEndFlexCompLength[4]
2012 + fgkSSDEndFlexCompLength[5]),
44285dfa 2013 - 0.5*fgkSSDFlexWidth[0]-ssdendflexbboxshape[4]->GetDY(),
d7599219 2014 0.));
44285dfa 2015 return ssdendflex;
d7599219 2016}
2017/////////////////////////////////////////////////////////////////////////////////
2018TGeoVolume* AliITSv11GeometrySSD::GetSSDFlexAssembly(){
44285dfa 2019 /////////////////////////////////////////////////////////////
2020 // Method generating SSD Flex Assembly
2021 /////////////////////////////////////////////////////////////
2022 TGeoVolume* ssdflexassembly = new TGeoVolumeAssembly("SSDFlexAssembly");
2023 const Int_t kssdflexlayernumber = 4;
2024 Double_t ssdflexheight[kssdflexlayernumber];
2025 Double_t ssdflexradius[kssdflexlayernumber];
2026 TGeoTranslation* ssdflextrans[kssdflexlayernumber];
2027 for(Int_t i=0; i<kssdflexlayernumber; i++){
2028 ssdflexheight[i] = (i%2==0 ? fgkSSDFlexHeight[0] : fgkSSDFlexHeight[1]);
2029 ssdflexradius[i] = (i==0 ? fgkSSDStiffenerHeight : ssdflexradius[i-1]
2030 + ssdflexheight[i-1]);
2031 ssdflextrans[i] = new TGeoTranslation(0.,0.,-0.5*i*(ssdflexheight[0]
2032 + ssdflexheight[1]));
2033 ssdflexassembly->AddNode(GetSSDFlex(ssdflexradius[i],ssdflexheight[i]),i+1,
2034 ssdflextrans[i]);
d7599219 2035 }
44285dfa 2036 return ssdflexassembly;
d7599219 2037}
2038/////////////////////////////////////////////////////////////////////////////////
2039TGeoVolume* AliITSv11GeometrySSD::GetSSDCoolingBlockAssembly(){
44285dfa 2040 /////////////////////////////////////////////////////////////
2041 // Method generating SSD Cooling Block Assembly
2042 /////////////////////////////////////////////////////////////
2043 const Int_t kssdcoolingblocktransnumber = 2;
2044 Double_t ssdcoolingblocktransvector[kssdcoolingblocktransnumber] =
d7599219 2045 {fgkSSDModuleSensorSupportDistance+fgkSSDCoolingBlockLength,
2046 fgkSSDSensorLength-2.*fgkSSDModuleStiffenerPosition[1]
2047 - fgkSSDCoolingBlockWidth};
44285dfa 2048 TGeoVolume* ssdcoolingblock = GetSSDCoolingBlock();
2049 TGeoVolume* ssdcoolingblockassembly =
d7599219 2050 new TGeoVolumeAssembly("SSDCoolingBlockAssembly");
44285dfa 2051 for(Int_t i=0; i<kssdcoolingblocktransnumber; i++)
2052 for(Int_t j=0; j<kssdcoolingblocktransnumber; j++)
2053 ssdcoolingblockassembly->AddNode(ssdcoolingblock,
2054 kssdcoolingblocktransnumber*i+j+1,
2055 new TGeoTranslation(i*ssdcoolingblocktransvector[0],
2056 j*ssdcoolingblocktransvector[1],0.));
2057 return ssdcoolingblockassembly;
d7599219 2058}
2059/////////////////////////////////////////////////////////////////////////////////
2060TGeoVolume* AliITSv11GeometrySSD::GetSSDCoolingBlock(){
44285dfa 2061 /////////////////////////////////////////////////////////////
2062 // Method generating SSD Cooling Block
2063 /////////////////////////////////////////////////////////////
d7599219 2064 // Center Cooling Block Hole
2065 ////////////////////////////
44285dfa 2066 Double_t coolingblockholeangle = TMath::ACos(0.5*fgkSSDCoolingBlockHoleLength[0]
d7599219 2067 /fgkSSDCoolingBlockHoleRadius[0])*TMath::RadToDeg();
44285dfa 2068 Double_t coolingblockholewidth = fgkSSDCoolingBlockWidth;
2069 new TGeoTubeSeg("CoolingBlockHoleShape",
d7599219 2070 0.,
2071 fgkSSDCoolingBlockHoleRadius[0],
44285dfa 2072 0.5*coolingblockholewidth,
2073 180.-coolingblockholeangle,360.+coolingblockholeangle);
2074 TVector3* coolingblockholevertex[3];
2075 coolingblockholevertex[0] = new TVector3();
2076 coolingblockholevertex[1] = new TVector3(fgkSSDCoolingBlockHoleRadius[0]
2077 * TMath::Cos((90.-coolingblockholeangle)*TMath::DegToRad()),
d7599219 2078 fgkSSDCoolingBlockHoleRadius[0]
44285dfa 2079 * TMath::Sin((90.-coolingblockholeangle)*TMath::DegToRad()));
2080 coolingblockholevertex[2] = new TVector3(coolingblockholevertex[1]->X(),
2081 - coolingblockholevertex[1]->Y());
2082 GetTriangleShape(coolingblockholevertex,
2083 coolingblockholewidth,"CoolingBlockTriangleHoleShape");
2084 TGeoRotation* coolingblockholerot =
d7599219 2085 new TGeoRotation("CoolingBlockHoleRot",90,0.,0.);
44285dfa 2086 coolingblockholerot->RegisterYourself();
2087 new TGeoCompositeShape("CoolingTubeHoleShape",
d7599219 2088 "CoolingBlockTriangleHoleShape:CoolingBlockHoleRot+"
2089 "CoolingBlockHoleShape");
2090 ///////////////////////////
2091 // Cooling Block Trapezoids
2092 ///////////////////////////
44285dfa 2093 const Int_t kvertexnumber = 4;
2094 const Int_t ktrapezoidnumber = 2;
2095 TVector3** coolingblocktrapezoidvertex[ktrapezoidnumber];
2096 for(Int_t i = 0; i<ktrapezoidnumber; i++) coolingblocktrapezoidvertex[i] =
2097 new TVector3*[kvertexnumber];
2098 Double_t coolingblockcomponentheight = fgkSSDCoolingBlockHeight[0]
d7599219 2099 - fgkSSDCoolingBlockHoleCenter
2100 - fgkSSDCoolingBlockHoleRadius[0]
44285dfa 2101 * TMath::Sin(coolingblockholeangle*TMath::DegToRad());
2102 Double_t coolingblocktrapezoidlength[ktrapezoidnumber] =
d7599219 2103 { fgkSSDCoolingBlockLength,
2104 0.5*(fgkSSDCoolingBlockLength-2.
2105 * (fgkSSDCoolingBlockHoleLength[1]
2106 - fgkSSDCoolingBlockHoleRadius[1])
2107 - fgkSSDCoolingBlockHoleLength[0])};
44285dfa 2108 Double_t coolingblocktrapezoidheigth[ktrapezoidnumber] =
2109 { fgkSSDCoolingBlockHeight[0]-coolingblockcomponentheight
d7599219 2110 - fgkSSDCoolingBlockHeight[1]-fgkSSDCoolingBlockHeight[2]
2111 - fgkSSDCoolingBlockHoleRadius[1],
44285dfa 2112 coolingblockcomponentheight};
2113 Double_t coolingblocktrapezoidwidth[ktrapezoidnumber] =
d7599219 2114 {fgkSSDCoolingBlockWidth,fgkSSDCoolingBlockWidth};
2115 //////////////////////////
2116 //Vertex Positioning Shape
2117 //////////////////////////
44285dfa 2118 coolingblocktrapezoidvertex[0][0] = new TVector3();
2119 coolingblocktrapezoidvertex[0][1] = new TVector3(coolingblocktrapezoidlength[0]);
2120 coolingblocktrapezoidvertex[0][2] = new TVector3(
2121 0.5*(coolingblocktrapezoidvertex[0][1]->X()
2122 - 2.*coolingblocktrapezoidlength[1]
d7599219 2123 - fgkSSDCoolingBlockHoleLength[0]));
44285dfa 2124 coolingblocktrapezoidvertex[0][3] =
2125 new TVector3(coolingblocktrapezoidvertex[0][1]->X()
2126 - coolingblocktrapezoidvertex[0][2]->X());
2127 coolingblocktrapezoidvertex[1][0] = new TVector3();
2128 coolingblocktrapezoidvertex[1][1] = new TVector3(coolingblocktrapezoidlength[1]);
2129 coolingblocktrapezoidvertex[1][2] =
2130 new TVector3(coolingblocktrapezoidheigth[1]
2131 / coolingblocktrapezoidheigth[0]
2132 * coolingblocktrapezoidvertex[0][2]->X());
2133 coolingblocktrapezoidvertex[1][3] =
2134 new TVector3(coolingblocktrapezoidvertex[1][1]->X());
2135 char* coolingblocktrapezoidshapename[ktrapezoidnumber] =
d7599219 2136 {"CoolingBlockTrapezoidShape0","CoolingBlockTrapezoidShape1"};
44285dfa 2137 TGeoArb8* coolingblocktrapezoidshape[ktrapezoidnumber];
2138 for(Int_t i = 0; i< ktrapezoidnumber; i++) coolingblocktrapezoidshape[i] =
2139 GetArbShape(coolingblocktrapezoidvertex[i],
2140 coolingblocktrapezoidwidth,
2141 coolingblocktrapezoidheigth[i],
2142 coolingblocktrapezoidshapename[i]);
2143 TGeoTranslation* coolingblocktrapezoidtrans =
d7599219 2144 new TGeoTranslation("CoolingBlockTrapezoidTrans",
44285dfa 2145 coolingblocktrapezoidvertex[0][2]->X(),
d7599219 2146 0.0,
44285dfa 2147 0.5*(coolingblocktrapezoidheigth[0]
2148 + coolingblocktrapezoidheigth[1]));
2149 coolingblocktrapezoidtrans->RegisterYourself();
2150 TGeoCombiTrans* coolingblocktrapezoidcombitrans =
d7599219 2151 new TGeoCombiTrans("CoolingBlockTrapezoidCombiTrans",
44285dfa 2152 coolingblocktrapezoidvertex[0][3]->X(),
d7599219 2153 fgkSSDCoolingBlockWidth,
44285dfa 2154 0.5*(coolingblocktrapezoidheigth[0]
2155 + coolingblocktrapezoidheigth[1]),
d7599219 2156 new TGeoRotation("",180.,0.,0.));
44285dfa 2157 coolingblocktrapezoidcombitrans->RegisterYourself();
d7599219 2158 new TGeoCompositeShape("CoolingBlockTrapezoidCompositeShape",
2159 "CoolingBlockTrapezoidShape0+CoolingBlockTrapezoidShape1:CoolingBlockTrapezoidTrans+"
2160 "CoolingBlockTrapezoidShape1:CoolingBlockTrapezoidCombiTrans");
2161 /////////////////////////////
2162 // Cooling Block Boxes Shapes
2163 /////////////////////////////
44285dfa 2164 const Int_t kboxnumber = 3;
2165 TGeoBBox* coolingblockboxshape[kboxnumber];
2166 coolingblockboxshape[0] = new TGeoBBox("CoolingBlockBoxShape0",
d7599219 2167 0.5*fgkSSDCoolingBlockLength,
2168 0.5*fgkSSDCoolingBlockWidth,
2169 0.5*fgkSSDCoolingBlockHoleRadius[1]);
44285dfa 2170 coolingblockboxshape[1] = new TGeoBBox("CoolingBlockBoxShape1",
d7599219 2171 0.5*(fgkSSDCoolingBlockLength
2172 - 2.*fgkSSDCoolingBlockHoleLength[1]),
2173 0.5*fgkSSDCoolingBlockWidth,
2174 0.5*fgkSSDCoolingBlockHeight[2]);
44285dfa 2175 coolingblockboxshape[2] = new TGeoBBox("CoolingBlockBoxShape2",
d7599219 2176 0.5*fgkSSDCoolingBlockLength,
2177 0.5*fgkSSDCoolingBlockWidth,
2178 0.5*fgkSSDCoolingBlockHeight[1]);
44285dfa 2179 TGeoTranslation* coolingblockboxtrans[kboxnumber-1];
2180 coolingblockboxtrans[0] = new TGeoTranslation("CoolingBlockBoxTrans0",0.,0.,
d7599219 2181 0.5*(fgkSSDCoolingBlockHeight[1]
2182 + fgkSSDCoolingBlockHoleRadius[1])
2183 + fgkSSDCoolingBlockHeight[2]);
44285dfa 2184 coolingblockboxtrans[1] = new TGeoTranslation("CoolingBlockBoxTrans1",
d7599219 2185 0.0,
2186 0.0,
2187 0.5*(fgkSSDCoolingBlockHeight[1]
2188 + fgkSSDCoolingBlockHeight[2]));
44285dfa 2189 for(Int_t i=0; i<kboxnumber-1; i++) coolingblockboxtrans[i]->RegisterYourself();
d7599219 2190 new TGeoCompositeShape("CoolingBlockBoxCompositeShape",
2191 "CoolingBlockBoxShape0:CoolingBlockBoxTrans0+"
2192 "CoolingBlockBoxShape1:CoolingBlockBoxTrans1+CoolingBlockBoxShape2");
2193 ///////////////////////
2194 // Cooling Block Shape
2195 //////////////////////
44285dfa 2196 TGeoCombiTrans* coolingtubeholeshapecombitrans =
d7599219 2197 new TGeoCombiTrans("CoolingTubeHoleShapeCombiTrans",
2198 0.5*fgkSSDCoolingBlockLength,
2199 0.5*fgkSSDCoolingBlockWidth,
2200 fgkSSDCoolingBlockHoleCenter,
2201 new TGeoRotation("",0.,90.,0.));
44285dfa 2202 coolingtubeholeshapecombitrans->RegisterYourself();
2203 TGeoTranslation* coolingblocktrapezoidcompositeshapetrans =
d7599219 2204 new TGeoTranslation("CoolingBlockTrapezoidCompositeShapeTrans",
2205 0.0,
2206 0.0,
44285dfa 2207 0.5*coolingblocktrapezoidheigth[0]+fgkSSDCoolingBlockHeight[1]+
d7599219 2208 fgkSSDCoolingBlockHeight[2]+fgkSSDCoolingBlockHoleRadius[1]);
44285dfa 2209 coolingblocktrapezoidcompositeshapetrans->RegisterYourself();
2210 TGeoTranslation* coolingblockboxcompositeshapetrans =
d7599219 2211 new TGeoTranslation("CoolingBlockBoxCompositeShapeTrans",
2212 0.5*fgkSSDCoolingBlockLength,
2213 0.5*fgkSSDCoolingBlockWidth,
2214 0.5*fgkSSDCoolingBlockHeight[1]);
44285dfa 2215 coolingblockboxcompositeshapetrans->RegisterYourself();
2216 TGeoCompositeShape* ssdoolingblockshape =
d7599219 2217 new TGeoCompositeShape("SSDCoolingBlockShape",
2218 "CoolingBlockBoxCompositeShape:CoolingBlockBoxCompositeShapeTrans+"
2219 "CoolingBlockTrapezoidCompositeShape:CoolingBlockTrapezoidCompositeShapeTrans-"
2220 "CoolingTubeHoleShape:CoolingTubeHoleShapeCombiTrans");
44285dfa 2221 TGeoVolume* ssdcoolingblock = new TGeoVolume("SSDCoolingBlock",
2222 ssdoolingblockshape,fSSDAlCoolBlockMedium);
2223 return ssdcoolingblock;
d7599219 2224}
2225/////////////////////////////////////////////////////////////////////////////////
2226TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberJunction(Double_t width){
44285dfa 2227 /////////////////////////////////////////////////////////////
2228 // Method generating SSD Carbon Fiber Junction
2229 /////////////////////////////////////////////////////////////
2230 const Int_t kvertexnumber = 4;
2231 TVector3* vertex[kvertexnumber];
2232 vertex[0] = new TVector3();
2233 vertex[1] = new TVector3(fgkCarbonFiberJunctionLength,0.);
2234 vertex[2] = new TVector3(fgkCarbonFiberJunctionLength
d7599219 2235 - fgkCarbonFiberJunctionEdge[1]
2236 * TMath::Cos(fgkCarbonFiberJunctionAngle[1]*TMath::DegToRad()),
2237 fgkCarbonFiberJunctionEdge[1]*TMath::Sin(fgkCarbonFiberJunctionAngle[1]
2238 * TMath::DegToRad()));
44285dfa 2239 vertex[3] = new TVector3(fgkCarbonFiberJunctionEdge[0]
d7599219 2240 * TMath::Cos(fgkCarbonFiberJunctionAngle[0]*TMath::DegToRad()),
2241 fgkCarbonFiberJunctionEdge[0]
2242 * TMath::Sin(fgkCarbonFiberJunctionAngle[0]*TMath::DegToRad()));
44285dfa 2243 TGeoArb8* carbonfiberjunctionshapepiece =
d7599219 2244 new TGeoArb8("CarbonFiberJunctionShapePiece",0.5*width);
2245 //////////////////////////////////
2246 //Setting the vertices in TGeoArb8
2247 //////////////////////////////////
44285dfa 2248 for(Int_t i = 0; i<2*kvertexnumber; i++)
2249 carbonfiberjunctionshapepiece->SetVertex(i,
2250 vertex[(i < kvertexnumber ? i: i-kvertexnumber)]->X(),
2251 vertex[(i < kvertexnumber ? i : i-kvertexnumber)]->Y());
2252 TGeoRotation* carbonfiberjunctionrot =
d7599219 2253 new TGeoRotation("CarbonFiberJunctionRot",
2254 180.,
2255 180.,
2256 180-2.*fgkCarbonFiberJunctionAngle[0]);
44285dfa 2257 TGeoVolume* carbonfiberjunctionpiece =
d7599219 2258 new TGeoVolume("CarbonFiberJunctionPiece",
44285dfa 2259 carbonfiberjunctionshapepiece,fSSDCarbonFiberMedium);
2260 TGeoVolume* carbonfiberjunction =
d7599219 2261 new TGeoVolumeAssembly("CarbonFiberJunction");
44285dfa 2262 carbonfiberjunctionpiece->SetLineColor(fColorCarbonFiber);
2263 carbonfiberjunction->AddNode(carbonfiberjunctionpiece,1);
2264 carbonfiberjunction->AddNode(carbonfiberjunctionpiece,2,carbonfiberjunctionrot);
2265 return carbonfiberjunction;
d7599219 2266}
2267/////////////////////////////////////////////////////////////////////////////////
2268TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberJunctionAssembly(){
44285dfa 2269 /////////////////////////////////////////////////////////////
2270 // Method generating SSD Carbon Fiber Junction Assembly
2271 /////////////////////////////////////////////////////////////
d7599219 2272 SetCarbonFiberJunctionCombiTransMatrix();
44285dfa 2273 TGeoVolume* carbonfiberjunctionassembly =
d7599219 2274 new TGeoVolumeAssembly("CarbonFiberJunctionAssembly");
44285dfa 2275 TGeoVolume* carbonfiberjunction =
d7599219 2276 GetCarbonFiberJunction(fgkCarbonFiberJunctionWidth);
2277 for(Int_t i=0; i<fgkCarbonFiberJunctionCombiTransNumber;i++)
44285dfa 2278 carbonfiberjunctionassembly->AddNode(carbonfiberjunction,i+1,
2279 fCarbonFiberJunctionCombiTransMatrix[i]);
2280 return carbonfiberjunctionassembly;
d7599219 2281}
2282/////////////////////////////////////////////////////////////////////////////////
44285dfa 2283TList* AliITSv11GeometrySSD::GetLadderCableSegment(Double_t ssdendladdercablelength){
2284 /////////////////////////////////////////////////////////////
2285 // Method returning a List containing pointers to Ladder Cable Volumes
2286 /////////////////////////////////////////////////////////////
2287 const Int_t kladdercablesegmentnumber = 2;
2288 /////////////////////////////////////////
2289 // LadderSegmentBBox Volume
2290 /////////////////////////////////////////
2291 TGeoBBox* laddercablesegmentbboxshape[kladdercablesegmentnumber];
2292 const char* laddercablesegmentbboxshapename[kladdercablesegmentnumber] =
d7599219 2293 {"LadderCableSegmentBBoxShape1","LadderCableSegmentBBoxShape2"};
44285dfa 2294 for(Int_t i=0; i<kladdercablesegmentnumber; i++) laddercablesegmentbboxshape[i] =
2295 new TGeoBBox(laddercablesegmentbboxshapename[i],
d7599219 2296 0.5*fgkSSDFlexWidth[0],
2297 0.5*fgkSSDLadderCableWidth,
2298 0.5*fgkSSDFlexHeight[i]);
44285dfa 2299 const char* laddercablesegmentbboxname[kladdercablesegmentnumber] =
d7599219 2300 {"LadderCableSegmentBBox1","LadderCableSegmentBBox2"};
44285dfa 2301 TGeoVolume* laddercablesegmentbbox[kladdercablesegmentnumber];
2302 for(Int_t i=0; i<kladdercablesegmentnumber; i++){
2303 laddercablesegmentbbox[i] =
2304 new TGeoVolume(laddercablesegmentbboxname[i],
2305 laddercablesegmentbboxshape[i],
2306 (i==0?fSSDAlTraceLadderCableMedium:
2307 fSSDKaptonLadderCableMedium));
2308 laddercablesegmentbbox[i]->SetLineColor(i==0 ? fColorAl :
d7599219 2309 fColorPolyhamide);
2310 }
44285dfa 2311 TGeoTranslation* laddercablesegmentbboxtrans[kladdercablesegmentnumber];
2312 laddercablesegmentbboxtrans[0] =
d7599219 2313 new TGeoTranslation("LadderCableSegmentBBoxTrans1",
2314 0.5*fgkSSDFlexWidth[0],
2315 0.5*fgkSSDLadderCableWidth,
2316 0.5*fgkSSDFlexHeight[0]);
44285dfa 2317 laddercablesegmentbboxtrans[1] =
d7599219 2318 new TGeoTranslation("LadderCableSegmentBBoxTrans2",
2319 0.5*fgkSSDFlexWidth[0],
2320 0.5*fgkSSDLadderCableWidth,
2321 fgkSSDFlexHeight[0]
2322 +0.5*fgkSSDFlexHeight[1]);
44285dfa 2323 TGeoVolume* laddercablesegmentbboxassembly =
d7599219 2324 new TGeoVolumeAssembly("LadderCableSegmentBBoxAssembly");
44285dfa 2325 for(Int_t i=0; i<kladdercablesegmentnumber; i++)
2326 laddercablesegmentbboxassembly->AddNode(laddercablesegmentbbox[i],1,
2327 laddercablesegmentbboxtrans[i]);
d7599219 2328/////////////////////////////////////////
2329// LadderSegmentArb8 Volume
2330/////////////////////////////////////////
44285dfa 2331 const Int_t kvertexnumber = 4;
2332 TVector3** laddercablesegmentvertexposition[kladdercablesegmentnumber];
2333 for(Int_t i = 0; i<kladdercablesegmentnumber; i++) laddercablesegmentvertexposition[i] =
2334 new TVector3*[kvertexnumber];
d7599219 2335//Shape Vertex Positioning
44285dfa 2336 for(Int_t i=0; i<kladdercablesegmentnumber; i++){
2337 laddercablesegmentvertexposition[i][0] = new TVector3(0.,i*fgkSSDFlexHeight[0]);
2338 laddercablesegmentvertexposition[i][1] = new TVector3(fgkSSDLadderCableWidth,
d7599219 2339 i*fgkSSDFlexHeight[0]);
44285dfa 2340 laddercablesegmentvertexposition[i][2] = new TVector3(0.,fgkSSDFlexHeight[0]
d7599219 2341 + fgkSSDFlexHeight[1]
2342 + i*fgkSSDFlexHeight[0]);
44285dfa 2343 laddercablesegmentvertexposition[i][3] =
2344 new TVector3(laddercablesegmentvertexposition[i][1]->X(),
2345 laddercablesegmentvertexposition[i][2]->Y());
d7599219 2346 }
44285dfa 2347 Double_t laddercablesegmentwidth[2][2] = {{fgkSSDFlexHeight[0],fgkSSDFlexHeight[0]},
d7599219 2348 {fgkSSDFlexHeight[1],fgkSSDFlexHeight[1]}};
44285dfa 2349 char* laddercablesegmentarbshapename[kladdercablesegmentnumber] =
d7599219 2350 {"LadderCableSegmentArbShape1","LadderCableSegmentArbShape2"};
44285dfa 2351 TGeoArb8* laddercablesegmentarbshape[kladdercablesegmentnumber];
2352 for(Int_t i = 0; i< kladdercablesegmentnumber; i++) laddercablesegmentarbshape[i] =
2353 GetArbShape(laddercablesegmentvertexposition[i],
2354 laddercablesegmentwidth[i],
d7599219 2355 fgkCarbonFiberJunctionWidth-fgkSSDFlexWidth[0],
44285dfa 2356 laddercablesegmentarbshapename[i]);
2357 const char* laddercablesegmentarbname[kladdercablesegmentnumber] =
d7599219 2358 {"LadderCableSegmentArb1","LadderCableSegmentArb2"};
44285dfa 2359 TGeoVolume* laddercablesegmentarb[kladdercablesegmentnumber];
2360 for(Int_t i=0; i<kladdercablesegmentnumber; i++){
2361 laddercablesegmentarb[i] =
2362 new TGeoVolume(laddercablesegmentarbname[i],
2363 laddercablesegmentarbshape[i],
2364 (i==0?fSSDAlTraceLadderCableMedium:
2365 fSSDKaptonLadderCableMedium));
2366 laddercablesegmentarb[i]->SetLineColor(i==0 ? fColorAl :
d7599219 2367 fColorPolyhamide);
2368}
44285dfa 2369 TGeoRotation* laddercablesegmentarbrot[kladdercablesegmentnumber];
2370 laddercablesegmentarbrot[0] = new TGeoRotation("LadderCableSegmentArbRot1",
d7599219 2371 90.,90,-90.);
44285dfa 2372 laddercablesegmentarbrot[1] = new TGeoRotation("LadderCableSegmentArbRot2",
d7599219 2373 0.,90.,0.);
44285dfa 2374 TGeoCombiTrans* laddercablesegmentarbcombitrans =
d7599219 2375 new TGeoCombiTrans("LadderCableSegmentArbCombiTrans",
2376 0.5*(fgkCarbonFiberJunctionWidth-fgkSSDFlexWidth[0])
2377 + fgkSSDFlexWidth[0],0.,0.,
44285dfa 2378 new TGeoRotation((*laddercablesegmentarbrot[1])
2379 *(*laddercablesegmentarbrot[0])));
2380 TGeoVolume* laddercablesegmentarbassembly =
d7599219 2381 new TGeoVolumeAssembly("LadderCableSegmentArbAssembly");
44285dfa 2382 for(Int_t i=0; i<kladdercablesegmentnumber; i++)
2383 laddercablesegmentarbassembly->AddNode(laddercablesegmentarb[i],1,
2384 laddercablesegmentarbcombitrans);
d7599219 2385/////////////////////////////////////////
2386// End Ladder Cable Volume
2387/////////////////////////////////////////
44285dfa 2388 TGeoBBox* ladderendcablesegmentbboxshape[kladdercablesegmentnumber];
2389 const char* ladderendcablesegmentbboxshapename[kladdercablesegmentnumber] =
d7599219 2390 {"LadderEndCableSegmentBBoxShape1","LadderEndCableSegmentBBoxShape2"};
44285dfa 2391 for(Int_t i=0; i<kladdercablesegmentnumber; i++) ladderendcablesegmentbboxshape[i] =
2392 new TGeoBBox(ladderendcablesegmentbboxshapename[i],
2393 0.5*ssdendladdercablelength,
d7599219 2394 0.5*fgkSSDLadderCableWidth,
2395 0.5*fgkSSDFlexHeight[i]);
44285dfa 2396 const char* ladderendcablesegmentbboxname[kladdercablesegmentnumber] =
d7599219 2397 {"LadderEndCableSegmentBBox1","LadderEndCableSegmentBBox2"};
44285dfa 2398 TGeoVolume* ladderendcablesegmentbbox[kladdercablesegmentnumber];
2399 for(Int_t i=0; i<kladdercablesegmentnumber; i++){
2400 ladderendcablesegmentbbox[i] =
2401 new TGeoVolume(ladderendcablesegmentbboxname[i],
2402 ladderendcablesegmentbboxshape[i],
2403 (i==0?fSSDAlTraceLadderCableMedium:
2404 fSSDKaptonLadderCableMedium));
2405 ladderendcablesegmentbbox[i]->SetLineColor(i==0 ? fColorAl :
d7599219 2406 fColorPolyhamide);
2407 }
44285dfa 2408 TGeoTranslation* ladderendcablesegmentbboxtrans[kladdercablesegmentnumber];
2409 ladderendcablesegmentbboxtrans[0] =
d7599219 2410 new TGeoTranslation("LadderEndCableSegmentBBoxTrans0",
44285dfa 2411 0.5*ssdendladdercablelength,
d7599219 2412 0.5*fgkSSDLadderCableWidth,
2413 0.5*fgkSSDFlexHeight[0]);
44285dfa 2414 ladderendcablesegmentbboxtrans[1] =
d7599219 2415 new TGeoTranslation("LadderEndCableSegmentBBoxTrans1",
44285dfa 2416 0.5*ssdendladdercablelength,
d7599219 2417 0.5*fgkSSDLadderCableWidth,
2418 fgkSSDFlexHeight[0]
2419 +0.5*fgkSSDFlexHeight[1]);
44285dfa 2420 TGeoVolume* ladderendcablesegmentbboxassembly =
d7599219 2421 new TGeoVolumeAssembly("LadderEndCableSegmentBBoxAssembly");
44285dfa 2422 for(Int_t i=0; i<kladdercablesegmentnumber; i++)
2423 ladderendcablesegmentbboxassembly->AddNode(ladderendcablesegmentbbox[i],1,
2424 ladderendcablesegmentbboxtrans[i]);
d7599219 2425/////////////////////////////////////////
44285dfa 2426 TList* laddercablesegmentlist = new TList();
2427 laddercablesegmentlist->Add(laddercablesegmentbboxassembly);
2428 laddercablesegmentlist->Add(laddercablesegmentarbassembly);
2429 laddercablesegmentlist->Add(ladderendcablesegmentbboxassembly);
2430 return laddercablesegmentlist;
d7599219 2431 }
2432/////////////////////////////////////////////////////////////////////////////////
44285dfa 2433TGeoVolume* AliITSv11GeometrySSD::GetLadderCable(Int_t n, Double_t ssdendladdercablelength){
2434 /////////////////////////////////////////////////////////////
2435 // Method generating Ladder Cable Volumes Assemblies
2436 /////////////////////////////////////////////////////////////
2437 TList* laddercablesegmentlist = GetLadderCableSegment(ssdendladdercablelength);
2438 TGeoVolume* laddercable = new TGeoVolumeAssembly("LadderCable");
d7599219 2439 for(Int_t i=0; i<n; i++){
44285dfa 2440 TGeoTranslation* laddercabletrans = new TGeoTranslation(
d7599219 2441 i*(fgkCarbonFiberJunctionWidth),
2442 fgkSSDLadderCableWidth-fgkSSDFlexWidth[0],
2443 i*(fgkSSDFlexHeight[0]+fgkSSDFlexHeight[1]));
44285dfa 2444 laddercable->AddNode((TGeoVolume*)laddercablesegmentlist->At(0),i+1,laddercabletrans);
2445 if(i!=n-1) laddercable->AddNode((TGeoVolume*)laddercablesegmentlist->At(1),i+1,laddercabletrans);
d7599219 2446 }
44285dfa 2447 TGeoTranslation* endladdercabletrans = new TGeoTranslation("EndLadderCableTrans",
d7599219 2448 (n-1)*fgkCarbonFiberJunctionWidth+fgkSSDFlexWidth[0],
2449 fgkSSDLadderCableWidth-fgkSSDFlexWidth[0],
2450 (n-1)*(fgkSSDFlexHeight[0]+fgkSSDFlexHeight[1]));
44285dfa 2451 laddercable->AddNode((TGeoVolume*)laddercablesegmentlist->At(2),1,endladdercabletrans);
2452 return laddercable;
d7599219 2453}
2454/////////////////////////////////////////////////////////////////////////////////
44285dfa 2455TGeoVolume* AliITSv11GeometrySSD::GetLadderCableAssembly(Int_t n, Double_t ssdendladdercablelength){
2456 /////////////////////////////////////////////////////////////
2457 // Method generating Ladder Cable Volumes Assembly
2458 /////////////////////////////////////////////////////////////
2459 TGeoVolume* laddercableassembly = new TGeoVolumeAssembly("LadderCableAssembly");
2460 char laddercabletransname[30];
d7599219 2461 for(Int_t i=0; i<n; i++){
44285dfa 2462 sprintf(laddercabletransname,"LadderCableTrans%i",i+1);
2463 laddercableassembly->AddNode(GetLadderCable(n-i,ssdendladdercablelength),i+1,
2464 new TGeoTranslation(laddercabletransname,i*fgkCarbonFiberJunctionWidth,0.,0.));
d7599219 2465 }
44285dfa 2466 return laddercableassembly;
d7599219 2467}
2468/////////////////////////////////////////////////////////////////////////////////
44285dfa 2469TList* AliITSv11GeometrySSD::GetLadderCableAssemblyList(Int_t n, Double_t ssdendladdercablelength){
2470 /////////////////////////////////////////////////////////////
2471 // Method generating Ladder Cable List Assemblies
2472 /////////////////////////////////////////////////////////////
2473 const Int_t kladdercableassemblynumber = 2;
2474 TGeoVolume* laddercableassembly = GetLadderCableAssembly(n,ssdendladdercablelength);
2475 TGeoVolume* ladderCable[kladdercableassemblynumber];
2476 char laddercableassemblyname[30];
2477 TList* laddercableassemblylist = new TList();
2478 for(Int_t i=0; i<kladdercableassemblynumber; i++){
2479 sprintf(laddercableassemblyname,"LadderCableAssembly%i",i+1);
2480 ladderCable[i] = new TGeoVolumeAssembly(laddercableassemblyname);
2481 ladderCable[i]->AddNode(laddercableassembly,i+1,i==0 ? NULL :
d7599219 2482 new TGeoCombiTrans((n-1)
2483 * fgkCarbonFiberJunctionWidth+fgkSSDFlexWidth[0],
2484 2.*fgkSSDLadderCableWidth+0.5*fgkSSDFlexWidth[0],
2485 0.,new TGeoRotation("",180,0.,0.)));
44285dfa 2486 laddercableassemblylist->Add(ladderCable[i]);
d7599219 2487}
44285dfa 2488 return laddercableassemblylist;
d7599219 2489}
2490/////////////////////////////////////////////////////////////////////////////////
2491TList* AliITSv11GeometrySSD::GetEndLadderCarbonFiberJunctionAssembly(){
44285dfa 2492 /////////////////////////////////////////////////////////////
2493 // Method generating the End Ladder Carbon Fiber Junction Assembly
2494 /////////////////////////////////////////////////////////////
2495 const Int_t kendlabbercarbonfiberjunctionumber = 2;
2496 TGeoVolume* endladdercarbonfiberjunctionassembly[kendlabbercarbonfiberjunctionumber];
2497 endladdercarbonfiberjunctionassembly[0] =
d7599219 2498 new TGeoVolumeAssembly("EndLadderCarbonFiberJunctionAssembly1");
44285dfa 2499 endladdercarbonfiberjunctionassembly[1] =
d7599219 2500 new TGeoVolumeAssembly("EndLadderCarbonFiberJunctionAssembly2");
44285dfa 2501 TGeoVolume** endladdercarbonfiberjunction[kendlabbercarbonfiberjunctionumber];
2502 for(Int_t i=0; i<kendlabbercarbonfiberjunctionumber; i++)
2503 endladdercarbonfiberjunction[i] = new TGeoVolume*[2];
2504 for(Int_t i=0; i<kendlabbercarbonfiberjunctionumber; i++){
2505 endladdercarbonfiberjunction[i][0] =
d7599219 2506 GetCarbonFiberJunction(fgkEndLadderCarbonFiberLowerJunctionLength[i]);
44285dfa 2507 endladdercarbonfiberjunction[i][1] =
d7599219 2508 GetCarbonFiberJunction(fgkEndLadderCarbonFiberUpperJunctionLength[i]);
2509 }
44285dfa 2510 TList* endladdercarbonfiberjunctionlist = new TList();
2511 for(Int_t i=0; i<kendlabbercarbonfiberjunctionumber; i++){
d7599219 2512 SetEndLadderCarbonFiberJunctionCombiTransMatrix(i);
2513 for(Int_t j=0; j<fgkCarbonFiberJunctionCombiTransNumber; j++)
44285dfa 2514 endladdercarbonfiberjunctionassembly[i]->AddNode(j==2 ?
2515 endladdercarbonfiberjunction[i][1] :
2516 endladdercarbonfiberjunction[i][0],
2517 j+1,fEndLadderCarbonFiberJunctionCombiTransMatrix[j]);
2518 endladdercarbonfiberjunctionlist->Add(endladdercarbonfiberjunctionassembly[i]);
d7599219 2519 }
44285dfa 2520 return endladdercarbonfiberjunctionlist;
d7599219 2521}
2522////////////////////////////////////////////////////////////////////////////////
2523TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberSupport(){
44285dfa 2524 /////////////////////////////////////////////////////////////
2525 // Method generating the Carbon Fiber Support
2526 /////////////////////////////////////////////////////////////
2527 const Int_t kvertexnumber = 4;
2528 const Int_t kshapesnumber = 2;
2529 TVector3** vertexposition[kshapesnumber];
2530 for(Int_t i=0; i<kshapesnumber; i++) vertexposition[i] = new TVector3*[kvertexnumber];
2531 Double_t carbonfibersupportxaxisEdgeproj =
d7599219 2532 fgkCarbonFiberSupportEdgeLength*TMath::Cos(fgkCarbonFiberJunctionAngle[0]
2533 * TMath::DegToRad());
44285dfa 2534 Double_t theta = TMath::ATan(fgkCarbonFiberSupportYAxisLength
d7599219 2535 / fgkCarbonFiberSupportXAxisLength);
2536 /////////////////////
2537 //Vertex Positioning
2538 ////////////////////
44285dfa 2539 vertexposition[0][0] = new TVector3();
2540 vertexposition[0][1] = new TVector3(fgkCarbonFiberSupportXAxisLength,
d7599219 2541 fgkCarbonFiberSupportYAxisLength);
44285dfa 2542 vertexposition[0][2] = new TVector3(carbonfibersupportxaxisEdgeproj,
2543 carbonfibersupportxaxisEdgeproj
2544 * TMath::Tan(theta));
2545 vertexposition[0][3] = new TVector3(fgkCarbonFiberSupportXAxisLength
2546 - carbonfibersupportxaxisEdgeproj,
d7599219 2547 fgkCarbonFiberSupportYAxisLength
44285dfa 2548 - vertexposition[0][2]->Y());
d7599219 2549 ////////////////////////////////////////////////////
2550 //Setting the parameters for Isometry Transformation
2551 ////////////////////////////////////////////////////
44285dfa 2552 Double_t symmetryplaneposition = (fgkCarbonFiberSupportYAxisLength
d7599219 2553 + fgkCarbonFiberSupportTopEdgeDist[0]
2554 + fgkCarbonFiberSupportWidth);
2555 Double_t* param = new Double_t[4];
44285dfa 2556 param[0] = 0., param[1] = 1., param[2] = 0., param[3] = -symmetryplaneposition;
2557 for(Int_t j=0; j<kvertexnumber; j++) vertexposition[1][j] =
2558 new TVector3((GetReflection(vertexposition[0][j],param))->X(),
2559 (GetReflection(vertexposition[0][j],param))->Y());
2560 char* carbonfibersupportshapename[kshapesnumber] =
d7599219 2561 {"CarbonFiberSupportShape1","CarbonFiberSupportShape2"};
44285dfa 2562 TGeoArb8* carbonfibersupportshape[kshapesnumber];
2563 Double_t width[2] = {fgkCarbonFiberSupportWidth,fgkCarbonFiberSupportWidth};
2564 Double_t carbonfibersupportheight =
2565 carbonfibersupportxaxisEdgeproj*TMath::Tan(fgkCarbonFiberJunctionAngle[0]
d7599219 2566 *TMath::DegToRad());
44285dfa 2567 for(Int_t i = 0; i< kshapesnumber; i++) carbonfibersupportshape[i] =
2568 GetArbShape(vertexposition[i],width,carbonfibersupportheight,
2569 carbonfibersupportshapename[i],i==0 ? 1: -1);
d7599219 2570 /////////////////////////////////////
2571 //Setting Translations and Rotations:
2572 /////////////////////////////////////
44285dfa 2573 TGeoTranslation* carbonfibersupporttrans =
d7599219 2574 new TGeoTranslation("CarbonFiberSupportTrans",
44285dfa 2575 0.0,0.0,0.5*carbonfibersupportheight);
2576 carbonfibersupporttrans->RegisterYourself();
2577 TGeoRotation* carbonfibercompshaperot[2];
2578 carbonfibercompshaperot[0] = new TGeoRotation("CarbonFiberCompShapeRot1",
d7599219 2579 0.0,180.0,0.0);
44285dfa 2580 carbonfibercompshaperot[1] = new TGeoRotation("CarbonFiberCompShapeRot2",
d7599219 2581 90.,-fgkCarbonFiberTriangleAngle,-90.);
44285dfa 2582 Double_t transvector[3] = {fgkCarbonFiberTriangleLength
d7599219 2583 * TMath::Cos(fgkCarbonFiberTriangleAngle
2584 * TMath::DegToRad()),0.,-fgkCarbonFiberTriangleLength
2585 * TMath::Sin(fgkCarbonFiberTriangleAngle
2586 * TMath::DegToRad())};
44285dfa 2587 TGeoCombiTrans* carbonfibersupportcombitrans =
d7599219 2588 new TGeoCombiTrans("CarbonFiberSupportCombiTrans",
44285dfa 2589 transvector[0],2.*symmetryplaneposition
2590 + transvector[1],transvector[2],
2591 new TGeoRotation((*carbonfibercompshaperot[1])
2592 * (*carbonfibercompshaperot[0])));
2593 carbonfibersupportcombitrans->RegisterYourself();
d7599219 2594////////////////////////////////////////////////////////////////////////////////
44285dfa 2595 TGeoCompositeShape* carbonfibersupportcompshape =
d7599219 2596 new TGeoCompositeShape("CarbonFiberSupportCompShape",
2597 "CarbonFiberSupportShape1:CarbonFiberSupportTrans+"
2598 "CarbonFiberSupportShape2:CarbonFiberSupportTrans");
44285dfa 2599 TGeoVolume* carbonfibersupport = new TGeoVolume("CarbonFiberSupport",
2600 carbonfibersupportcompshape,fSSDCarbonFiberMedium);
2601 carbonfibersupport->SetLineColor(fColorCarbonFiber);
2602 TGeoVolume* carbonfibersupportassembly =
d7599219 2603 new TGeoVolumeAssembly("CarbonFiberSupportAssembly");
44285dfa 2604 carbonfibersupportassembly->AddNode(carbonfibersupport,1);
2605 carbonfibersupportassembly->AddNode(carbonfibersupport,2,
2606 carbonfibersupportcombitrans);
2607 return carbonfibersupportassembly;
d7599219 2608}
2609////////////////////////////////////////////////////////////////////////////////
2610TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberLowerSupport(Int_t ikind, Bool_t EndLadder){
44285dfa 2611 /////////////////////////////////////////////////////////////
2612 // Method generating the Carbon Fiber Lower Support
2613 /////////////////////////////////////////////////////////////
2614 const Int_t kvertexnumber = 4;
2615 const Int_t kshapesnumber = 2;
2616 Double_t width[2] = {fgkCarbonFiberLowerSupportWidth,
d7599219 2617 fgkCarbonFiberLowerSupportWidth};
44285dfa 2618 TVector3** vertexposition[kshapesnumber];
2619 for(Int_t i = 0; i<kshapesnumber; i++) vertexposition[i] =
2620 new TVector3*[kvertexnumber];
d7599219 2621 //First Shape Vertex Positioning
44285dfa 2622 vertexposition[0][0] = new TVector3(fgkCarbonFiberLowerSupportLowerLenght);
2623 vertexposition[0][1] = new TVector3(fgkCarbonFiberTriangleLength
d7599219 2624 - fgkCarbonFiberLowerSupportLowerLenght);
44285dfa 2625 vertexposition[0][2] = new TVector3();
2626 vertexposition[0][3] = new TVector3(fgkCarbonFiberTriangleLength);
d7599219 2627 //Second Shape Vertex Positioning
44285dfa 2628 Double_t theta = TMath::ATan((fgkCarbonFiberLowerSupportVolumePosition[1]
d7599219 2629 - fgkCarbonFiberLowerSupportVolumePosition[0])
2630 / fgkCarbonFiberTriangleLength);
44285dfa 2631 vertexposition[1][0] = new TVector3(vertexposition[0][0]->X(),
2632 vertexposition[0][0]->X()*TMath::Tan(theta)
d7599219 2633 + fgkCarbonFiberLowerSupportVolumePosition[0]);
44285dfa 2634 vertexposition[1][1] = new TVector3(vertexposition[0][1]->X(),
2635 vertexposition[0][1]->X()*TMath::Tan(theta)
d7599219 2636 + fgkCarbonFiberLowerSupportVolumePosition[0]);
44285dfa 2637 vertexposition[1][2] = new TVector3(0.,fgkCarbonFiberLowerSupportVolumePosition[0]);
2638 vertexposition[1][3] = new TVector3(fgkCarbonFiberTriangleLength,
d7599219 2639 fgkCarbonFiberLowerSupportVolumePosition[1]);
44285dfa 2640 char* carbonfiberlowersupportname[kshapesnumber] =
d7599219 2641 {"CarbonFiberLowerSupportShape1","CarbonFiberLowerSupportShape2"};
44285dfa 2642 TGeoArb8* carbonfiberlowersupportshape[kshapesnumber];
2643 for(Int_t i = 0; i< kshapesnumber; i++) carbonfiberlowersupportshape[i] =
2644 GetArbShape(vertexposition[i],width,
d7599219 2645 fgkCarbonFiberLowerSupportHeight,
44285dfa 2646 carbonfiberlowersupportname[i]);
d7599219 2647 ///////////////////////////////////////////////////////
44285dfa 2648 TGeoTranslation* carbonfiberlowersupporttrans[kshapesnumber];
2649 carbonfiberlowersupporttrans[0] =
d7599219 2650 new TGeoTranslation("CarbonFiberLowerSupportTrans1",
2651 0.0,
44285dfa 2652 vertexposition[1][3]->Y()+vertexposition[1][2]->Y(),
d7599219 2653 0.0);
44285dfa 2654 carbonfiberlowersupporttrans[1] =
d7599219 2655 new TGeoTranslation("CarbonFiberLowerSupportTrans2",
2656 0.0,
44285dfa 2657 - vertexposition[1][3]->Y()-vertexposition[1][2]->Y(),
d7599219 2658 0.0);
44285dfa 2659 for(Int_t i = 0; i< kshapesnumber; i++)
2660 carbonfiberlowersupporttrans[i]->RegisterYourself();
d7599219 2661 ///////////////////////////////////////////////////////
44285dfa 2662 TGeoCompositeShape* carbonfiberlowersupportcompshape;
d7599219 2663 if(EndLadder==false)
44285dfa 2664 carbonfiberlowersupportcompshape =
d7599219 2665 new TGeoCompositeShape("CarbonFiberLowerSupportCompShape",
2666 "CarbonFiberLowerSupportShape2+"
2667 "CarbonFiberLowerSupportShape1:CarbonFiberLowerSupportTrans1");
2668 else
2669 if(ikind==0)
44285dfa 2670 carbonfiberlowersupportcompshape =
2671 (TGeoCompositeShape*)carbonfiberlowersupportshape[0];
d7599219 2672 else
44285dfa 2673 carbonfiberlowersupportcompshape =
d7599219 2674 new TGeoCompositeShape("CarbonFiberLowerSupportCompShape",
2675 "CarbonFiberLowerSupportShape1+"
2676 "CarbonFiberLowerSupportShape1:CarbonFiberLowerSupportTrans1");
44285dfa 2677 TGeoVolume* carbonfiberlowersupport = new TGeoVolume("CarbonFiberLowerSupport",
2678 carbonfiberlowersupportcompshape,fSSDCarbonFiberMedium);
2679 carbonfiberlowersupport->SetLineColor(fColorCarbonFiber);
2680 return carbonfiberlowersupport;
d7599219 2681}
2682////////////////////////////////////////////////////////////////////////////////
2683TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberAssemblySupport(){
44285dfa 2684 /////////////////////////////////////////////////////////////
2685 // Method generating the Carbon Fiber Assembly Support
2686 /////////////////////////////////////////////////////////////
d7599219 2687 SetCarbonFiberAssemblyCombiTransMatrix();
44285dfa 2688 TGeoVolume* carbonfiberassemblysupport =
d7599219 2689 new TGeoVolumeAssembly("CarbonFiberAssembly");
44285dfa 2690 TGeoVolume* carbonfiberassemblyvolumes[fgkCarbonFiberAssemblyCombiTransNumber];
2691 carbonfiberassemblyvolumes[0] = GetCarbonFiberJunctionAssembly();
2692 carbonfiberassemblyvolumes[1] = GetCarbonFiberSupport();
2693 carbonfiberassemblyvolumes[2] = GetCarbonFiberLowerSupport();
d7599219 2694 for(Int_t i=0; i<fgkCarbonFiberAssemblyCombiTransNumber;i++)
44285dfa 2695 carbonfiberassemblysupport->AddNode(carbonfiberassemblyvolumes[i],1,
2696 fCarbonFiberAssemblyCombiTransMatrix[i]);
2697 return carbonfiberassemblysupport;
d7599219 2698}
2699////////////////////////////////////////////////////////////////////////////////
2700TGeoVolume* AliITSv11GeometrySSD::GetCoolingTubeSupport(){
44285dfa 2701 /////////////////////////////////////////////////////////////
2702 // Method generating the Cooling Tube Support
2703 /////////////////////////////////////////////////////////////
2704 const Int_t kvertexnumber = 3;
2705 Double_t phi = TMath::ASin(0.5*fgkCoolingTubeSupportHeight
d7599219 2706 / fgkCoolingTubeSupportRmax)*TMath::RadToDeg();
d7599219 2707 new TGeoTubeSeg("CoolingTubeSegShape",0.0,
2708 fgkCoolingTubeSupportRmax,
44285dfa 2709 0.5*fgkCoolingTubeSupportWidth,phi,
2710 360-phi);
d7599219 2711 new TGeoTube("CoolingTubeHoleShape",0.0,
2712 fgkCoolingTubeSupportRmin,
2713 0.5*fgkCoolingTubeSupportWidth);
44285dfa 2714 TVector3* vertexposition[kvertexnumber];
d7599219 2715 ///////////////////////////
2716 //Shape Vertex Positioning
2717 ///////////////////////////
44285dfa 2718 vertexposition[0] = new TVector3();
2719 vertexposition[1] = new TVector3(fgkCoolingTubeSupportRmax
2720 * TMath::Cos(phi*TMath::DegToRad()),
d7599219 2721 fgkCoolingTubeSupportRmax
44285dfa 2722 * TMath::Sin(phi*TMath::DegToRad()));
2723 vertexposition[2] = new TVector3(vertexposition[1]->X(),
2724 - vertexposition[1]->Y());
2725 GetTriangleShape(vertexposition,
d7599219 2726 fgkCoolingTubeSupportWidth,
2727 "CoolingTubeTriangleShape");
44285dfa 2728 Double_t* boxorigin = new Double_t[3];
2729 Double_t boxlength = fgkCoolingTubeSupportLength-fgkCoolingTubeSupportRmax
2730 - vertexposition[1]->X();
2731 boxorigin[0] = vertexposition[1]->X()+0.5*boxlength, boxorigin[1] = boxorigin[2] = 0.;
2732 new TGeoBBox("CoolingTubeBoxShape",0.5*boxlength,
d7599219 2733 0.5*fgkCoolingTubeSupportHeight,
44285dfa 2734 0.5*fgkCoolingTubeSupportWidth,boxorigin);
2735 TGeoCompositeShape* coolingtubesupportshape =
d7599219 2736 new TGeoCompositeShape("CoolingTubeSupportShape",
2737 "(CoolingTubeSegShape+CoolingTubeTriangleShape"
2738 "+CoolingTubeBoxShape)-CoolingTubeHoleShape");
44285dfa 2739 TGeoVolume* coolingtubesupport = new TGeoVolume("CoolingTubeSupport",
2740 coolingtubesupportshape,fSSDTubeHolderMedium);
2741 return coolingtubesupport;
d7599219 2742}
2743////////////////////////////////////////////////////////////////////////////////
2744TGeoVolume* AliITSv11GeometrySSD::GetCoolingTubeSupportAssembly(){
44285dfa 2745 /////////////////////////////////////////////////////////////
2746 // Method generating the Cooling Tube Support Assembly
2747 /////////////////////////////////////////////////////////////
2748 TGeoVolume* coolingtubesupportassembly =
d7599219 2749 new TGeoVolumeAssembly("CoolingTubeSupportAssembly");
44285dfa 2750 TGeoVolume* coolingtubesupport = GetCoolingTubeSupport();
d7599219 2751 SetCoolingTubeSupportCombiTransMatrix();
2752 for(Int_t i=0; i<fgkCoolingTubeSupportCombiTransNumber;i++)
44285dfa 2753 coolingtubesupportassembly->AddNode(coolingtubesupport,i+1,
2754 fCoolingTubeSupportCombiTransMatrix[i]);
2755 return coolingtubesupportassembly;
d7599219 2756}
2757////////////////////////////////////////////////////////////////////////////////
44285dfa 2758TGeoVolume* AliITSv11GeometrySSD::GetCoolingTube() const{
2759 /////////////////////////////////////////////////////////////
2760 // Method generating the Cooling Tube
2761 /////////////////////////////////////////////////////////////
2762 TGeoVolume* coolingtubeassembly = new TGeoVolumeAssembly("CoolingTubeAssembly");
2763 TGeoTube *coolingtubeshape = new TGeoTube("CoolingTubeShape", fgkCoolingTubeRmin,
d7599219 2764 fgkCoolingTubeRmax, fgkCoolingTubeLength/2.0);
44285dfa 2765 TGeoVolume* coolingtube = new TGeoVolume("CoolingTube",
2766 coolingtubeshape,fSSDCoolingTubePhynox);
2767 TGeoTube *coolingtubeinteriorshape = new TGeoTube("CoolingTubeInteriorShape",
d7599219 2768 0, fgkCoolingTubeRmin,
2769 fgkCoolingTubeLength/2.0);
44285dfa 2770 TGeoVolume *coolingtubeinterior = new TGeoVolume("CoolingTubeInterior",
2771 coolingtubeinteriorshape,fSSDCoolingTubeWater);
2772 coolingtubeassembly->AddNode(coolingtube,1);
2773 coolingtubeassembly->AddNode(coolingtubeinterior,2);
2774 return coolingtubeassembly;
d7599219 2775}
2776////////////////////////////////////////////////////////////////////////////////
2777TGeoVolume* AliITSv11GeometrySSD::GetCoolingTubeAssembly(){
44285dfa 2778 /////////////////////////////////////////////////////////////
2779 // Method generating the Cooling Tube Assembly
2780 /////////////////////////////////////////////////////////////
2781 TGeoVolume* coolingtubeassembly = new TGeoVolumeAssembly("CoolingTubeAssembly");
2782 TGeoVolume* coolingtube = GetCoolingTube();
d7599219 2783 SetCoolingTubeCombiTransMatrix();
2784 for(Int_t i=0; i<fgkCoolingTubeCombiTransNumber;i++)
44285dfa 2785 coolingtubeassembly->AddNode(coolingtube,i+1,fCoolingTubeTransMatrix[i]);
2786 return coolingtubeassembly;
d7599219 2787}
2788////////////////////////////////////////////////////////////////////////////////
2789TGeoVolume* AliITSv11GeometrySSD::GetLadderSegment(Int_t iChipCablesHeight){
44285dfa 2790 /////////////////////////////////////////////////////////////
2791 // Method generating the basic Ladder Segment element which will be replicated
2792 /////////////////////////////////////////////////////////////
2793 TGeoVolume*laddersegment = new TGeoVolumeAssembly("LadderSegment");
2794 TGeoVolume* laddersegmentvolumes[fgkLadderSegmentCombiTransNumber];
2795 laddersegmentvolumes[0] = GetCarbonFiberAssemblySupport();
2796 laddersegmentvolumes[1] = GetSSDModule(iChipCablesHeight);
2797 laddersegmentvolumes[2] = GetSSDSensorSupportAssembly(iChipCablesHeight);
2798 laddersegmentvolumes[3] = GetCoolingTubeSupportAssembly();
2799 laddersegmentvolumes[4] = GetCoolingTubeAssembly();
2800 SetLadderSegmentCombiTransMatrix();
2801 for(Int_t i=0; i<fgkLadderSegmentCombiTransNumber; i++)
2802 laddersegment->AddNode(laddersegmentvolumes[i],1,
2803 fLadderSegmentCombiTransMatrix[i]);
2804 return laddersegment;
2805 }
d7599219 2806////////////////////////////////////////////////////////////////////////////////
2807TList* AliITSv11GeometrySSD::GetEndLadderSegment(){
44285dfa 2808 /////////////////////////////////////////////////////////////
2809 // Method generating the Terminal Ladder Segment
2810 /////////////////////////////////////////////////////////////
2811 const Int_t kendladdersegmentnumber = 2;
2812 TList* endladdercarbonfiberjunctionlist = GetEndLadderCarbonFiberJunctionAssembly();
2813 TGeoVolume* endladdersegment[kendladdersegmentnumber];
2814 endladdersegment[0] = new TGeoVolumeAssembly("EndLadderSegment1");
2815 endladdersegment[1] = new TGeoVolumeAssembly("EndLadderSegment2");
2816 TGeoVolume** laddersegmentvolumes[kendladdersegmentnumber];
2817 const Int_t kladdersegmentvolumenumber = 4;
2818 for(Int_t i=0; i<kendladdersegmentnumber; i++) laddersegmentvolumes[i] =
2819 new TGeoVolume*[kladdersegmentvolumenumber];
2820 laddersegmentvolumes[0][0] = (TGeoVolume*)endladdercarbonfiberjunctionlist->At(0);
2821 laddersegmentvolumes[0][1] = GetCarbonFiberSupport();
2822 laddersegmentvolumes[0][2] = GetSSDMountingBlock();
2823 laddersegmentvolumes[0][3] = GetCarbonFiberLowerSupport(0,true);
2824 laddersegmentvolumes[1][0] = (TGeoVolume*)endladdercarbonfiberjunctionlist->At(1);
2825 laddersegmentvolumes[1][1] = laddersegmentvolumes[0][1];
2826 laddersegmentvolumes[1][2] = laddersegmentvolumes[0][2];
2827 laddersegmentvolumes[1][3] = GetCarbonFiberLowerSupport(1,true);
2828 TList* endladdersegmentlist = new TList();
2829 for(Int_t i=0; i<kendladdersegmentnumber; i++){
d7599219 2830 SetEndLadderSegmentCombiTransMatrix(i);
44285dfa 2831 for(Int_t j=0; j<kladdersegmentvolumenumber; j++)
2832 endladdersegment[i]->AddNode(laddersegmentvolumes[i][j],1,
2833 fEndLadderSegmentCombiTransMatrix[j]);
2834 endladdersegmentlist->Add(endladdersegment[i]);
d7599219 2835 }
44285dfa 2836 return endladdersegmentlist;
d7599219 2837}
2838////////////////////////////////////////////////////////////////////////////////
2839TGeoVolume* AliITSv11GeometrySSD::GetSSDMountingBlock(){
44285dfa 2840 /////////////////////////////////////////////////////////////
2841 // Method generating the Mounting Block
2842 /////////////////////////////////////////////////////////////
d7599219 2843 // Mounting Block Boxes Shapes
2844 ///////////////////////////////////////
44285dfa 2845 const Int_t kmountingblockboxnumber = 3;
2846 TGeoBBox* mountingblockboxshape[kmountingblockboxnumber];
2847 mountingblockboxshape[0] = new TGeoBBox("MountingBlockBoxShape0",
d7599219 2848 0.25*(fgkSSDMountingBlockLength[0]
2849 - fgkSSDMountingBlockLength[1]),
2850 0.5*fgkSSDMountingBlockWidth,
2851 0.5*fgkSSDMountingBlockHeight[0]);
44285dfa 2852 mountingblockboxshape[1] = new TGeoBBox("MountingBlockBoxShape1",
d7599219 2853 0.25*(fgkSSDMountingBlockLength[1]
2854 - fgkSSDMountingBlockLength[2]),
2855 0.5*fgkSSDMountingBlockWidth,
2856 0.5*(fgkSSDMountingBlockHeight[1]
2857 - fgkSSDMountingBlockHeight[3]));
44285dfa 2858 mountingblockboxshape[2] = new TGeoBBox("MountingBlockBoxShape2",
d7599219 2859 0.5*fgkSSDMountingBlockLength[2],
2860 0.5*fgkSSDMountingBlockWidth,
2861 0.5*(fgkSSDMountingBlockHeight[2]
2862 - fgkSSDMountingBlockHeight[3]));
44285dfa 2863 TGeoTranslation* mountingblockboxtrans[kmountingblockboxnumber+2];
2864 mountingblockboxtrans[0] = new TGeoTranslation("MountingBlockBoxTrans0",0.,0.,0.);
2865 mountingblockboxtrans[1] = new TGeoTranslation("MountingBlockBoxTrans1",
2866 mountingblockboxshape[0]->GetDX()
2867 + mountingblockboxshape[1]->GetDX(),
d7599219 2868 0.0,
44285dfa 2869 mountingblockboxshape[1]->GetDZ()
2870 - mountingblockboxshape[0]->GetDZ()
d7599219 2871 + fgkSSDMountingBlockHeight[3]);
44285dfa 2872 mountingblockboxtrans[2] = new TGeoTranslation("MountingBlockBoxTrans2",
2873 mountingblockboxshape[0]->GetDX()
2874 + 2.*mountingblockboxshape[1]->GetDX()
2875 + mountingblockboxshape[2]->GetDX(),
d7599219 2876 0.0,
44285dfa 2877 mountingblockboxshape[2]->GetDZ()
2878 - mountingblockboxshape[0]->GetDZ()
d7599219 2879 + fgkSSDMountingBlockHeight[3]);
44285dfa 2880 mountingblockboxtrans[3] = new TGeoTranslation("MountingBlockBoxTrans3",
2881 mountingblockboxshape[0]->GetDX()
2882 + mountingblockboxshape[1]->GetDX()
2883 + 2.*(mountingblockboxshape[1]->GetDX()
2884 + mountingblockboxshape[2]->GetDX()),
d7599219 2885 0.0,
44285dfa 2886 mountingblockboxshape[1]->GetDZ()
2887 - mountingblockboxshape[0]->GetDZ()
d7599219 2888 + fgkSSDMountingBlockHeight[3]);
44285dfa 2889 mountingblockboxtrans[4] = new TGeoTranslation("MountingBlockBoxTrans4",
2890 2.*(mountingblockboxshape[0]->GetDX()
2891 + 2.*mountingblockboxshape[1]->GetDX()
2892 + mountingblockboxshape[2]->GetDX()),
d7599219 2893 0.0,
2894 0.0);
44285dfa 2895 for(Int_t i=0; i<kmountingblockboxnumber+2; i++)
2896 mountingblockboxtrans[i]->RegisterYourself();
d7599219 2897 ///////////////////////////////////////
2898 // Mounting Block Trapezoid Hole Shapes
2899 ///////////////////////////////////////
44285dfa 2900 const Int_t kholetrapezoidvertexnumber = 4;
2901 TVector3* holetrapezoidvertex[kholetrapezoidvertexnumber];
2902 holetrapezoidvertex[0] = new TVector3();
2903 holetrapezoidvertex[1] = new TVector3(fgkSSDMountingBlockHoleTrapezoidHeight);
2904 holetrapezoidvertex[2] = new TVector3(*holetrapezoidvertex[0]);
2905 holetrapezoidvertex[3] = new TVector3(*holetrapezoidvertex[1]);
2906 Double_t holetrapezoidwidth[2] = {fgkSSDMountingBlockHoleTrapezoidUpBasis
2907 + 2.*mountingblockboxshape[1]->GetDX()
d7599219