Making Trigger GUI working again
[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
5ef8864c 16/* $Id$ */
d7599219 17
18//*************************************************************************
19// SSD geometry, based on ROOT geometrical modeler
20//
21// Enrico Cattaruzza ecattar@ts.infn.it
22//*************************************************************************
23#include "TMath.h"
24#include "TGeoVolume.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"
bf210566 34#include "TGeoXtru.h"
9b0c60ab 35#include "TGeoTorus.h"
36#include "TGeoPgon.h"
47f8de53 37#include "TGeoPcon.h"
9b0c60ab 38#include "TRotation.h"
44285dfa 39#include "AliITSv11GeometrySSD.h"
d7599219 40/////////////////////////////////////////////////////////////////////////////////
bf210566 41// Names of the Sensitive Volumes of Layer 5 and Layer 6
42/////////////////////////////////////////////////////////////////////////////////
02d4acf9 43const char* AliITSv11GeometrySSD::fgSSDsensitiveVolName5 = "ITSssdSensitivL5";
44const char* AliITSv11GeometrySSD::fgSSDsensitiveVolName6 = "ITSssdSensitivL6";
bf210566 45/////////////////////////////////////////////////////////////////////////////////
d7599219 46//Parameters for SSD Geometry
47/////////////////////////////////////////////////////////////////////////////////
e21cdd03 48// Variable for Vertical Disalignement of Modules
49/////////////////////////////////////////////////////////////////////////////////
ca86fdb4 50const Double_t AliITSv11GeometrySSD::fgkSSDTolerance = 0.0001*fgkmm;
51//const Double_t AliITSv11GeometrySSD::fgkSSDTolerance = 1.*fgkmm;
52const Double_t AliITSv11GeometrySSD::fgkSSDModuleVerticalDisalignment = 0.*fgkmm;
53const Double_t AliITSv11GeometrySSD::fgkSSDModuleVerticalDisalignment2 = 0.2*fgkmm;
e21cdd03 54/////////////////////////////////////////////////////////////////////////////////
d7599219 55// Layer5 (lengths are in mm and angles in degrees)
56/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 57const Double_t AliITSv11GeometrySSD::fgkSSDLay5LadderLength = 950.7*fgkmm;
d7599219 58const Int_t AliITSv11GeometrySSD::fgkSSDLay5SensorsNumber = 22;
59const Int_t AliITSv11GeometrySSD::fgkSSDLay5LadderNumber = 34;
9acf2ecc 60const Double_t AliITSv11GeometrySSD::fgkSSDLay5RadiusMin = 378.0*fgkmm;
61const Double_t AliITSv11GeometrySSD::fgkSSDLay5RadiusMax = 384.0*fgkmm;
62const Double_t AliITSv11GeometrySSD::fgkLay5CenterITSPosition = 467.85*fgkmm;
d7599219 63/////////////////////////////////////////////////////////////////////////////////
64// Layer6 (lengths are in mm and angles in degrees)
65/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 66const Double_t AliITSv11GeometrySSD::fgkSSDLay6LadderLength = 1068.0*fgkmm;
d7599219 67const Int_t AliITSv11GeometrySSD::fgkSSDLay6SensorsNumber = 25;
68const Int_t AliITSv11GeometrySSD::fgkSSDLay6LadderNumber = 38;
9acf2ecc 69const Double_t AliITSv11GeometrySSD::fgkSSDLay6RadiusMin = 428.0*fgkmm;
70const Double_t AliITSv11GeometrySSD::fgkSSDLay6RadiusMax = 434.0*fgkmm;
71const Double_t AliITSv11GeometrySSD::fgkLay6CenterITSPosition = 526.50*fgkmm;
d7599219 72/////////////////////////////////////////////////////////////////////////////////
73// SSD Chips and Hybrid (lengths are in mm and angles in degrees)
74/////////////////////////////////////////////////////////////////////////////////
75const Int_t AliITSv11GeometrySSD::fgkSSDChipNumber = 6;
9acf2ecc 76const Double_t AliITSv11GeometrySSD::fgkSSDChipLength = 11.100*fgkmm;
77const Double_t AliITSv11GeometrySSD::fgkSSDChipWidth = 3.850*fgkmm;
78const Double_t AliITSv11GeometrySSD::fgkSSDChipHeight = 0.180*fgkmm;
79const Double_t AliITSv11GeometrySSD::fgkSSDChipSeparationLength = 1.000*fgkmm;
bf210566 80const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueLength = fgkSSDChipLength;
81const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueWidth = fgkSSDChipWidth;
9acf2ecc 82const Double_t AliITSv11GeometrySSD::fgkSSDChipGlueHeight = 0.030*fgkmm;
d7599219 83/////////////////////////////////////////////////////////////////////////////////
84// Stiffener (lengths are in mm and angles in degrees)
85/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 86const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerLength = 73.000*fgkmm;
87const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerWidth = 6.500*fgkmm;
bf210566 88//const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerHeight = 3.315;
9acf2ecc 89const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerHeight = 0.315*fgkmm;
90const Double_t AliITSv11GeometrySSD::fgkSSDStiffenerToChipDist = 2.500*fgkmm;
bf210566 91const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Length = 1.600*fgkmm;
9acf2ecc 92const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Width = 0.870*fgkmm;
93const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor0603Height = 0.800*fgkmm;
94const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Length = 4.600*fgkmm;
95const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Width = 3.400*fgkmm;
bf210566 96const Double_t AliITSv11GeometrySSD::fgkSSDCapacitor1812Height = 0.700*fgkmm; // multiplied by 0.5
9acf2ecc 97const Double_t AliITSv11GeometrySSD::fgkSSDWireLength = 30.000*fgkmm;
98const Double_t AliITSv11GeometrySSD::fgkSSDWireRadius = 0.185*fgkmm;
bf210566 99const Double_t AliITSv11GeometrySSD::fgkSSDConnectorPosition[2] =
100 {44.32*fgkmm, 0.33*fgkmm};
101const Double_t AliITSv11GeometrySSD::fgkSSDConnectorSeparation = 0.44*fgkmm;
102const Double_t AliITSv11GeometrySSD::fgkSSDConnectorLength = 2.16*fgkmm;
103const Double_t AliITSv11GeometrySSD::fgkSSDConnectorWidth = 3.60*fgkmm;
d7599219 104const Double_t AliITSv11GeometrySSD::fgkSSDConnectorHeight =
bf210566 105 0.25*fgkSSDStiffenerHeight;
106const Double_t AliITSv11GeometrySSD::fgkSSDConnectorAlHeight = 0.030*fgkmm;
107const Double_t AliITSv11GeometrySSD::fgkSSDConnectorNiHeight = 0.002*fgkmm;
d7599219 108/////////////////////////////////////////////////////////////////////////////////
109// Cooling Block (lengths are in mm and angles in degrees)
110/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 111const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockLength = 3.000*fgkmm;
112const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockWidth = 4.000*fgkmm;
bf210566 113const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHeight[3] =
114 {1.950*fgkmm, 0.240*fgkmm, 0.300*fgkmm};
d7599219 115const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleRadius[2] =
bf210566 116 {1.000*fgkmm, 0.120*fgkmm};
d7599219 117const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleLength[2] =
bf210566 118 {1.900*fgkmm, 0.400*fgkmm};
d7599219 119const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleCenter =
9acf2ecc 120 1.500*fgkmm;
d7599219 121const Double_t AliITSv11GeometrySSD::fgkSSDCoolingBlockHoleHeight =
9acf2ecc 122 0.300*fgkmm;
d7599219 123/////////////////////////////////////////////////////////////////////////////////
124// SSD Sensor (lengths are in mm and angles in degrees)
125/////////////////////////////////////////////////////////////////////////////////
126const char* AliITSv11GeometrySSD::fgkSSDSensitiveVolName =
bf210566 127 "SSDSensorSensitiveVol";
9acf2ecc 128const Double_t AliITSv11GeometrySSD::fgkSSDSensorLength = 42.000*fgkmm;
129const Double_t AliITSv11GeometrySSD::fgkSSDSensorHeight = 0.300*fgkmm;
130const Double_t AliITSv11GeometrySSD::fgkSSDSensorWidth = 75.000*fgkmm;
d7599219 131const Double_t AliITSv11GeometrySSD::fgkSSDSensorOverlap =
9acf2ecc 132 fgkSSDSensorLength-39.1*fgkmm;
bf210566 133const Double_t AliITSv11GeometrySSD::fgkSSDSensorInsensitiveLength = 1.*fgkmm;
134const Double_t AliITSv11GeometrySSD::fgkSSDSensorInsensitiveWidth = 1.*fgkmm;
d7599219 135/////////////////////////////////////////////////////////////////////////////////
136// Flex (lengths are in mm and angles in degrees)
137/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 138const Double_t AliITSv11GeometrySSD::fgkSSDFlexFullLength = 106.000*fgkmm;
d7599219 139const Double_t AliITSv11GeometrySSD::fgkSSDFlexLength[4] =
bf210566 140 {0.5 * (fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
141 + (fgkSSDChipNumber-1)*fgkSSDChipSeparationLength),
142 0.5 * (fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
143 + (fgkSSDChipNumber-1)*fgkSSDChipSeparationLength)
144 - 4.000*fgkmm, 9.500*fgkmm, 10.000*fgkmm};
d7599219 145const Double_t AliITSv11GeometrySSD::fgkSSDFlexWidth[2] =
bf210566 146 { 9.340*fgkmm, 5.380*fgkmm};
d7599219 147const Double_t AliITSv11GeometrySSD::fgkSSDFlexHeight[2] =
bf210566 148 { 0.030*fgkmm, 0.020*fgkmm};
d7599219 149const Double_t AliITSv11GeometrySSD::fgkSSDFlexAngle = 30.000;
9acf2ecc 150const Double_t AliITSv11GeometrySSD::fgkSSDFlexHoleLength = 1.430*fgkmm;
151const Double_t AliITSv11GeometrySSD::fgkSSDFlexHoleWidth = 3.000*fgkmm;
d7599219 152const Double_t AliITSv11GeometrySSD::fgkSSDEndFlexCompLength[6] =
bf210566 153 {3.30*fgkmm,4.12*fgkmm,4.22*fgkmm,1.70*fgkmm,0.75*fgkmm,7.18*fgkmm};
d7599219 154const Double_t AliITSv11GeometrySSD:: fgkSSDEndFlexCompWidth[3] =
bf210566 155 {15.03*fgkmm,23.48*fgkmm,12.28*fgkmm};
d7599219 156/////////////////////////////////////////////////////////////////////////////////
157// SSD Ladder Cable (lengths are in mm and angles in degrees)
158/////////////////////////////////////////////////////////////////////////////////
bf210566 159const Double_t AliITSv11GeometrySSD::fgkSSDLadderCableWidth = 23.5*fgkmm;
d7599219 160/////////////////////////////////////////////////////////////////////////////////
161// SSD Module (lengths are in mm and angles in degrees)
162/////////////////////////////////////////////////////////////////////////////////
163const Double_t AliITSv11GeometrySSD::fgkSSDModuleStiffenerPosition[2] =
bf210566 164 { 1.000*fgkmm, 3.900*fgkmm};
d7599219 165const Double_t AliITSv11GeometrySSD::fgkSSDModuleSensorSupportDistance =
9acf2ecc 166 45.600*fgkmm;
d7599219 167const Double_t AliITSv11GeometrySSD::fgkSSDModuleCoolingBlockToSensor =
9acf2ecc 168 5.075*fgkmm;
d7599219 169/////////////////////////////////////////////////////////////////////////////////
170// Sensor Support (lengths are in mm and angles in degrees)
171/////////////////////////////////////////////////////////////////////////////////
bf210566 172const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportLength =
173 5.800*fgkmm;
d7599219 174const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportWidth =
bf210566 175 2.000*fgkmm;
d7599219 176const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportHeight[2] =
ca86fdb4 177 { 4.620*fgkmm-fgkSSDModuleVerticalDisalignment2,
178 5.180*fgkmm-fgkSSDModuleVerticalDisalignment2};
179//const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportHeight[2] =
180// { 4.520*fgkmm, 5.130*fgkmm};
bf210566 181const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportThickness[2] =
182 { 0.450*fgkmm, 0.450*fgkmm};
183const Double_t AliITSv11GeometrySSD::fgkSSDSensorSideSupportPosition
184 = 0.5 * (fgkSSDModuleSensorSupportDistance
185 + fgkSSDSensorSideSupportThickness[0])
186 - fgkSSDSensorSideSupportLength;
d7599219 187const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportLength =
bf210566 188 5.250*fgkmm;
d7599219 189const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportWidth =
bf210566 190 1.680*fgkmm;
191const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportHeight[2]
192 = {fgkSSDSensorSideSupportHeight[0]
193 + fgkSSDSensorSideSupportThickness[0],
194 fgkSSDSensorSideSupportHeight[1]
195 + fgkSSDSensorSideSupportThickness[1]};
196const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportThickness[2]
197 = {fgkSSDSensorSideSupportThickness[0],
198 fgkSSDSensorSideSupportThickness[1]};
d7599219 199const Double_t AliITSv11GeometrySSD::fgkSSDSensorCenterSupportPosition =
bf210566 200 19.000*fgkmm;
d7599219 201/////////////////////////////////////////////////////////////////////////////////
202// Chip Cables (lengths are in mm and angles in degrees)
203/////////////////////////////////////////////////////////////////////////////////
204const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesLength[2] =
bf210566 205 {73.12/fgkSSDChipNumber*fgkmm,fgkSSDChipLength+2.*0.19*fgkmm};
d7599219 206const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesHeight[4] =
bf210566 207 { 0.014*fgkmm, 0.010*fgkmm, fgkSSDModuleCoolingBlockToSensor
208 - (fgkSSDSensorSideSupportHeight[1]
209 - fgkSSDSensorSideSupportHeight[0])
ca86fdb4 210 - fgkSSDModuleVerticalDisalignment2
bf210566 211 - fgkSSDCoolingBlockHoleCenter
212 - fgkSSDStiffenerHeight
213 - fgkSSDChipHeight-fgkSSDSensorHeight,
214 fgkSSDModuleCoolingBlockToSensor
ca86fdb4 215 - fgkSSDModuleVerticalDisalignment2
bf210566 216 - fgkSSDCoolingBlockHoleCenter
217 - fgkSSDStiffenerHeight
218 - fgkSSDChipHeight-fgkSSDSensorHeight};
d7599219 219const Double_t AliITSv11GeometrySSD::fgkSSDChipCablesWidth[3] =
bf210566 220 { 11.000*fgkmm, 0.800*fgkmm, 0.600*fgkmm};
d7599219 221/////////////////////////////////////////////////////////////////////////////////
222// Carbon Fiber Junction Parameters (lengths are in mm and angles in degrees)
223/////////////////////////////////////////////////////////////////////////////////
224const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionLength =
bf210566 225 3.820*fgkmm;
226//const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionLength =
227// 3.780;
d7599219 228const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionWidth =
bf210566 229 fgkSSDSensorLength-fgkSSDSensorOverlap;
d7599219 230const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionEdge[2] =
bf210566 231 { 0.86*fgkmm, 0.30*fgkmm};
d7599219 232const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionAngle[2] =
bf210566 233 { 30.00, 90.00};
d7599219 234const Double_t AliITSv11GeometrySSD::fgkCarbonFiberJunctionToSensorSupport =
bf210566 235 1.78*fgkmm;
d7599219 236/////////////////////////////////////////////////////////////////////////////////
237//Carbon Fiber Parameters (lengths are in mm and angles in degrees)
238/////////////////////////////////////////////////////////////////////////////////
bf210566 239const Double_t AliITSv11GeometrySSD::fgkCarbonFiberTriangleLength
240 = fgkSSDModuleSensorSupportDistance
241 - 2. * fgkCarbonFiberJunctionToSensorSupport;
242const Double_t AliITSv11GeometrySSD::fgkCarbonFiberTriangleAngle = 60.00;
d7599219 243const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportTopEdgeDist[2] =
bf210566 244 { 0.751*fgkmm, 0.482*fgkmm};
245const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportEdgeLength =
246 1.630*fgkmm;
247const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportWidth = 0.950*fgkmm;
248const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportXAxisLength
249 = fgkCarbonFiberTriangleLength
250 - 0.5*fgkCarbonFiberSupportTopEdgeDist[1]
251 / TMath::Cos(fgkCarbonFiberTriangleAngle
252 * TMath::DegToRad());
253const Double_t AliITSv11GeometrySSD::fgkCarbonFiberSupportYAxisLength
254 = 0.5*(fgkCarbonFiberJunctionWidth
255 - fgkCarbonFiberSupportWidth)
256 - fgkCarbonFiberSupportTopEdgeDist[0]
257 - fgkCarbonFiberSupportWidth;
d7599219 258/////////////////////////////////////////////////////////////////////////////////
259// Carbon Fiber Lower Support Parameters (lengths are in mm)
260/////////////////////////////////////////////////////////////////////////////////
261const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportWidth
9acf2ecc 262 = 0.950*fgkmm;
d7599219 263const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportLowerLenght
9acf2ecc 264 = 1.600*fgkmm;
d7599219 265const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportHeight
9acf2ecc 266 = 0.830*fgkmm;
d7599219 267const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportVolumeSeparation
268 = 0.5*fgkCarbonFiberSupportWidth;
269const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportTransverseWidth
bf210566 270 = fgkCarbonFiberJunctionWidth
271 - 2. * (fgkCarbonFiberLowerSupportWidth
272 + fgkCarbonFiberLowerSupportVolumeSeparation);
d7599219 273const Double_t AliITSv11GeometrySSD::fgkCarbonFiberLowerSupportVolumePosition[2]
bf210566 274 = {fgkCarbonFiberLowerSupportWidth
275 + fgkCarbonFiberLowerSupportVolumeSeparation,
276 fgkCarbonFiberLowerSupportWidth
277 + fgkCarbonFiberLowerSupportVolumeSeparation
278 + fgkCarbonFiberLowerSupportTransverseWidth};
d7599219 279/////////////////////////////////////////////////////////////////////////////////
280// End Ladder Carbon Fiber Junction Parameters (lengths are in mm and angles in degrees)
281/////////////////////////////////////////////////////////////////////////////////
282const Double_t AliITSv11GeometrySSD::fgkEndLadderCarbonFiberLowerJunctionLength[2] =
bf210566 283 {0.5 * (fgkSSDLay5LadderLength
284 - fgkSSDLay5SensorsNumber
285 * fgkCarbonFiberJunctionWidth
286 - fgkCarbonFiberLowerSupportWidth),
287 0.5 * (fgkSSDLay5LadderLength
288 - fgkSSDLay5SensorsNumber
289 * fgkCarbonFiberJunctionWidth
290 + fgkCarbonFiberLowerSupportWidth)};
d7599219 291const Double_t AliITSv11GeometrySSD::fgkEndLadderCarbonFiberUpperJunctionLength[2] =
bf210566 292 {fgkEndLadderCarbonFiberLowerJunctionLength[0]-20.4*fgkmm,
293 fgkEndLadderCarbonFiberLowerJunctionLength[1]-20.6*fgkmm};
d7599219 294const Double_t AliITSv11GeometrySSD::fgkEndLadderMountingBlockPosition[2] =
bf210566 295 {fgkEndLadderCarbonFiberLowerJunctionLength[0]-16.50*fgkmm,
296 fgkEndLadderCarbonFiberLowerJunctionLength[1]-31.50*fgkmm};
9b0c60ab 297const Double_t AliITSv11GeometrySSD::fgkendladdercoolingsupportdistance[3] =
298 {15.0*fgkmm, 13.5*fgkmm, 14.5*fgkmm};
d7599219 299/////////////////////////////////////////////////////////////////////////////////
300// Cooling Tube Support (lengths are in mm and angles in degrees)
301/////////////////////////////////////////////////////////////////////////////////
bf210566 302const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportRmax = 1.45*fgkmm;
d7599219 303const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportRmin
304 = fgkSSDCoolingBlockHoleRadius[0];
bf210566 305const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportLength = 8.55*fgkmm;
306const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportHeight = 0.85*fgkmm;
307const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportWidth = 2.00*fgkmm;
d7599219 308const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportSeparation =
bf210566 309 fgkSSDSensorLength-2.*fgkSSDSensorOverlap;
310const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSupportToCarbonFiber =
311 11.70*fgkmm;
d7599219 312/////////////////////////////////////////////////////////////////////////////////
313// Cooling Tube (lengths are in mm and angles in degrees)
314/////////////////////////////////////////////////////////////////////////////////
bf210566 315const Double_t AliITSv11GeometrySSD::fgkCoolingTubeRmax = fgkCoolingTubeSupportRmin;
316const Double_t AliITSv11GeometrySSD::fgkCoolingTubeRmin = 0.96*fgkmm;
317const Double_t AliITSv11GeometrySSD::fgkCoolingTubeLength =
d7599219 318 fgkCarbonFiberJunctionWidth;
319const Double_t AliITSv11GeometrySSD::fgkCoolingTubeSeparation =
bf210566 320 fgkSSDModuleSensorSupportDistance
321 + fgkSSDCoolingBlockLength;
9b0c60ab 322const Double_t AliITSv11GeometrySSD::fgkMountingBlockToSensorSupport = 30.7*fgkmm;
d7599219 323/////////////////////////////////////////////////////////////////////////////////
324// SSD Mounting Block Parameters (lengths are in mm and angles in degrees)
325/////////////////////////////////////////////////////////////////////////////////
326const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockLength[3] =
bf210566 327 { 60.0*fgkmm, 42.2*fgkmm, 34.0*fgkmm};
d7599219 328const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHeight[4] =
bf210566 329 { 4.0*fgkmm, 8.0*fgkmm, 5.0*fgkmm, 0.2*fgkmm};
d7599219 330const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockWidth =
bf210566 331 20.0*fgkmm;
d7599219 332const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidAngle =
bf210566 333 40.0;
d7599219 334const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidHeight =
335 0.30*(fgkSSDMountingBlockHeight[1]-fgkSSDMountingBlockHeight[2]);
336const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTrapezoidUpBasis =
bf210566 337 2.5*fgkmm;
d7599219 338const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTubeLength[2] =
bf210566 339 { 56.0*fgkmm, 12.0*fgkmm};
d7599219 340const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleTubeWidth[2] =
bf210566 341 { 5.0*fgkmm, 2.9*fgkmm};
d7599219 342const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockHoleRadius =
bf210566 343 1.0*fgkmm;
d7599219 344const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleEdge =
bf210566 345 6.0*fgkmm;
d7599219 346const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleHeigth =
bf210566 347 4.0*fgkmm;
d7599219 348const Double_t AliITSv11GeometrySSD::fgkSSDMountingBlockScrewHoleRadius[2] =
bf210566 349 { 1.5*fgkmm,fgkSSDMountingBlockScrewHoleEdge/6.};
d7599219 350/////////////////////////////////////////////////////////////////////////////////
9b0c60ab 351// SSD Mounting Block Clip Parameters (lengths are in mm and angles in degrees)
352/////////////////////////////////////////////////////////////////////////////////
353const Double_t AliITSv11GeometrySSD::fgkMountingBlockClipLength = 15.1*fgkmm;
354const Double_t AliITSv11GeometrySSD::fgkMountingBlockClipThickness = 0.3*fgkmm;
355const Double_t AliITSv11GeometrySSD::fgkMountingBlockClibScrewRadius = 1.6*fgkmm;
356const Double_t AliITSv11GeometrySSD::fgkMountingBlockClibScrewPosition = 4.0*fgkmm;
357const Double_t AliITSv11GeometrySSD::fgkMountingBlockClibWidth = 9.0*fgkmm;
358/////////////////////////////////////////////////////////////////////////////////
359// SSD Mounting Block Support Parameters (lengths are in mm and angles in degrees)
360/////////////////////////////////////////////////////////////////////////////////
361const Double_t AliITSv11GeometrySSD::fgkMountingBlockSupportWidth[2] = {9.5*fgkmm,10.0*fgkmm};
362const Double_t AliITSv11GeometrySSD::fgkMountingBlockSupportDownHeight = 4.0*fgkmm;
363const Double_t AliITSv11GeometrySSD::fgkMountingBlockSupportRadius[2] = {fgkSSDLay5RadiusMin
364 - fgkSSDMountingBlockHeight[1]
365 + 0.5*fgkCoolingTubeSupportHeight
366 + fgkSSDModuleCoolingBlockToSensor
e21cdd03 367 + fgkSSDModuleVerticalDisalignment
9b0c60ab 368 - fgkMountingBlockSupportDownHeight,
369 fgkSSDLay6RadiusMin
370 - fgkSSDMountingBlockHeight[1]
371 + 0.5*fgkCoolingTubeSupportHeight
372 + fgkSSDModuleCoolingBlockToSensor
e21cdd03 373 + fgkSSDModuleVerticalDisalignment
9b0c60ab 374 - fgkMountingBlockSupportDownHeight};
375const Double_t AliITSv11GeometrySSD::fgkMountingBlockSupportUpHeight[2] = {fgkSSDLay5RadiusMax
376 - fgkSSDMountingBlockHeight[1]
377 + 0.5*fgkCoolingTubeSupportHeight
378 + fgkSSDModuleCoolingBlockToSensor
e21cdd03 379 + fgkSSDModuleVerticalDisalignment
9b0c60ab 380 - fgkMountingBlockSupportRadius[0],
381 fgkSSDLay6RadiusMax
382 - fgkSSDMountingBlockHeight[1]
383 + 0.5*fgkCoolingTubeSupportHeight
384 + fgkSSDModuleCoolingBlockToSensor
e21cdd03 385 + fgkSSDModuleVerticalDisalignment
9b0c60ab 386 - fgkMountingBlockSupportRadius[1]};
387const Double_t AliITSv11GeometrySSD::fgkLadderSupportHeigth = 10.0*fgkmm; // To be verified
388const Double_t AliITSv11GeometrySSD::fgkLadderSupportRingLay5Position = 451.35*fgkmm;
389const Double_t AliITSv11GeometrySSD::fgkLadderSupportRingLay6Position = 510.00*fgkmm;
390/////////////////////////////////////////////////////////////////////////////////
391// SSD End Cap Cover Plate Parameters (lengths are in mm and angles in degrees)
392/////////////////////////////////////////////////////////////////////////////////
393const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateSmallHoleRadius = 1.25*fgkmm;
394const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateBigHoleRadius = 2.45*fgkmm;
395const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateThickness = 0.5*fgkmm;
396const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateSmallHoleSeparation[3] =
397 {16.5*fgkmm,22.0*fgkmm,7.*fgkmm};
398const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateLength[6] =
399 {7.*fgkmm,55.*fgkmm,8.0*fgkmm,53.*fgkmm,61.0*fgkmm,25.5*fgkmm};
400const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateWidth[3] =
401 {68.5*fgkmm,75.5*fgkmm,6.5*fgkmm};
402const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateScrewRadiusMin = 0.750*fgkmm;
403const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateScrewRadiusMax = 2.*fgkmm;
404const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateClipLength = 10.4*fgkmm;
405const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateClipWidth = 6.0*fgkmm;
406const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateDownClipLength = 5.7*fgkmm;
407const Double_t AliITSv11GeometrySSD::fgkEndCapCoverPlateDownClipWidth = 5.0*fgkmm;
408/////////////////////////////////////////////////////////////////////////////////
409// SSD End Cap Kapton Foil Parameters (lengths are in mm and angles in degrees)
410/////////////////////////////////////////////////////////////////////////////////
411const Double_t AliITSv11GeometrySSD::fgkEndCapKaptonFoilThickness = 0.4*fgkmm;
412const Double_t AliITSv11GeometrySSD::fgkEndCapKaptonFoilLength = 68.0*fgkmm;
413const Double_t AliITSv11GeometrySSD::fgkEndCapKaptonFoilWidth = 75.0*fgkmm;
414/////////////////////////////////////////////////////////////////////////////////
415// SSD End Cap Cooling Tube Parameters (lengths are in mm and angles in degrees)
416/////////////////////////////////////////////////////////////////////////////////
417const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeAxialRadius[2] =
418 {10.5*fgkmm,9.25*fgkmm};
419const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeRadiusMin = 1.3*fgkmm;
420const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeRadiusMax = 1.5*fgkmm;
421const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeAngle[5] =
422 {182.3,177.9,84.4,70.0,35.0};
423const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeLength[5] =
424 {49.5*fgkmm,41.7*fgkmm,47.6*fgkmm,5.0*fgkmm};
425const Double_t AliITSv11GeometrySSD::fgkEndCapCoolingTubeToCoverSide = 13.0*fgkmm;
426/////////////////////////////////////////////////////////////////////////////////
427// SSD End Cap Cover Side Parameters (lengths are in mm and angles in degrees)
428/////////////////////////////////////////////////////////////////////////////////
429const Double_t AliITSv11GeometrySSD::fgkEndCapSideCoverLength[5] = {3.5*fgkmm,
430 6.5*fgkmm,75.0*fgkmm,8.0*fgkmm,2.0*fgkmm};
431const Double_t AliITSv11GeometrySSD::fgkEndCapSideCoverWidth[7] = {30.9*fgkmm,
432 47.5*fgkmm,12.6*fgkmm,5.6*fgkmm,
433 20.0*fgkmm,7.0*fgkmm,5.9*fgkmm};
434const Double_t AliITSv11GeometrySSD::fgkEndCapSideCoverThickness = 0.4*fgkmm;
435/////////////////////////////////////////////////////////////////////////////////
436// SSD End Cap Cards Parameters (lengths are in mm and angles in degrees)
437/////////////////////////////////////////////////////////////////////////////////
438const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardBackLength[3] =
439 {62.0*fgkmm,21.87*fgkmm};
440const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardBackWidth[2] =
7708d5f3 441 {47.0*fgkmm,0.35*fgkmm};
9b0c60ab 442const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardBackThickness =
443 1.0*fgkmm;
444const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardLength = 61.8*fgkmm;
445const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardLayerWidth[2] =
446 {43.5*fgkmm, 0.70*fgkmm};
447const Double_t AliITSv11GeometrySSD::fgkEndCapCardElectBoardLayerThickness =
448 0.15*fgkmm;
449const Double_t AliITSv11GeometrySSD::fgkEndCapCardJMDConnectorThickness =
450 19.0*fgkmm;
451const Double_t AliITSv11GeometrySSD::fgkEndCapCardJMDConnectorLength[2] =
452 {4.80*fgkmm,1.1*fgkmm};
453const Double_t AliITSv11GeometrySSD::fgkEndCapCardJMDConnectorWidth[2] =
454 {3.3*fgkmm,1.10*fgkmm};
455const Double_t AliITSv11GeometrySSD::fgkEndCapCardJMDConnectorToLayer =
456 2.1*fgkmm;
457const Double_t AliITSv11GeometrySSD::fgkEndCapCardCableConnectorLength[3] =
458 {5.2*fgkmm,3.5*fgkmm,1.2*fgkmm};
459const Double_t AliITSv11GeometrySSD::fgkEndCapCardCableConnectorWidth[2] =
460 {1.9*fgkmm,0.15*fgkmm};
461const Double_t AliITSv11GeometrySSD::fgkEndCapCardCableConnectorThickness =
462 19*fgkmm;
463const Double_t AliITSv11GeometrySSD::fgkEndCapCardCableConnectorDistance =
464 1.0*fgkmm;
465const Double_t AliITSv11GeometrySSD::fgkEndCapCardCableConnectorToLayer =
466 3.6*fgkmm;
467const Double_t AliITSv11GeometrySSD::fgkEndCapStripConnectionLength =
468 61.0*fgkmm;
469const Double_t AliITSv11GeometrySSD::fgkEndCapStripConnectionThickness =
470 5.97*fgkmm;
471const Double_t AliITSv11GeometrySSD::fgkEndCapStripConnectionWidth = 3.0*fgkmm;
472const Double_t AliITSv11GeometrySSD::fgkEndCapInterfaceCardBLength[7] =
473 {3.1*fgkmm,68.0*fgkmm,3.6*fgkmm,
474 1.9*fgkmm,2.5*fgkmm,14.2*fgkmm,1.5*fgkmm};
475const Double_t AliITSv11GeometrySSD::fgkEndCapInterfaceCardBWidth[5] =
476 {17.0*fgkmm,10.0*fgkmm,5.9*fgkmm,6.4*fgkmm,3.9*fgkmm};
477const Double_t AliITSv11GeometrySSD::fgkEndCapInterfaceCardBThickness =
478 1.0*fgkmm;
479const Double_t AliITSv11GeometrySSD::fgkEndCapInterfaceElectBoardCardBThickness
480 = 0.15*fgkmm;
481const Double_t AliITSv11GeometrySSD::fgkEndCapInterfaceCardBJMDConnectorSeparation =
482 20.0*fgkmm;
483const Double_t AliITSv11GeometrySSD::fgkEndCapStiffenerLength = 68.0*fgkmm;
484const Double_t AliITSv11GeometrySSD::fgkEndCapStiffenerWidth = 5.0*fgkmm;
485const Double_t AliITSv11GeometrySSD::fgkEndCapStiffenerThickness = 5.0*fgkmm;
486const Double_t AliITSv11GeometrySSD::fgkEndCapEffectiveCableRadiusMin = 1.25*fgkmm; // To Be Checked
487const Double_t AliITSv11GeometrySSD::fgkEndCapEffectiveCableRadiusMax = 1.575*fgkmm; // To Be Checked
488/////////////////////////////////////////////////////////////////////////////////
489// SSD End Cap SupportLayer5/6 Side Parameters (lengths are in mm and angles in degrees)
490/////////////////////////////////////////////////////////////////////////////////
491const Double_t AliITSv11GeometrySSD::fgkEndCapSupportLength[2] = {70.424*fgkmm,72.919*fgkmm};
492const Double_t AliITSv11GeometrySSD::fgkEndCapSupportMiddleRadius[2] = {377.0*fgkmm,437.0*fgkmm};
47f8de53 493const Double_t AliITSv11GeometrySSD::fgkEndCapSupportLowRadius[2] = {375.0*fgkmm,435.0*fgkmm};
9b0c60ab 494const Double_t AliITSv11GeometrySSD::fgkEndCapSupportHighWidth = 20.0*fgkmm;
495const Double_t AliITSv11GeometrySSD::fgkEndCapSupportLowWidth[2] = {3.0*fgkmm,3.0*fgkmm};
496const Double_t AliITSv11GeometrySSD::fgkEndCapSupportCenterLay5ITSPosition = 625.0*fgkmm;
497const Double_t AliITSv11GeometrySSD::fgkEndCapSupportCenterLay5Position = 2.5*fgkmm;
498const Double_t AliITSv11GeometrySSD::fgkEndCapSupportCenterLay6ITSPosition = 635.0*fgkmm;
499const Double_t AliITSv11GeometrySSD::fgkEndCapSupportCenterLay6Position = 2.5*fgkmm;
500/////////////////////////////////////////////////////////////////////////////////
47f8de53 501// SSD Cone Parameters (lengths are in mm and angles in degrees)
502/////////////////////////////////////////////////////////////////////////////////
503const Double_t AliITSv11GeometrySSD::fgkSSDLowerPConeRadius = 296.5*fgkmm;
504const Double_t AliITSv11GeometrySSD::fgkSSDPConeAngle = 39.0;
fcfbdd23 505const Double_t AliITSv11GeometrySSD::fgkSSDPConeZLength[2] = {168.0*fgkmm,153.0*fgkmm};
47f8de53 506const Double_t AliITSv11GeometrySSD::fgkSSDPConeLittleHoleRadius = 317.5*fgkmm;
507const Double_t AliITSv11GeometrySSD::fgkSSDPConeLittleHoleLength = 20.*fgkmm;
508const Double_t AliITSv11GeometrySSD::fgkSSDConeMiddleRadius = 350.*fgkmm;
509const Double_t AliITSv11GeometrySSD::fgkSSDPConeMiddleLength = 30.*fgkmm;
510const Double_t AliITSv11GeometrySSD::fgkSSDPConeMiddleWidth = 40.*fgkmm;
511const Double_t AliITSv11GeometrySSD::fgkSSDPConeUpRadius = 400.*fgkmm;
fcfbdd23 512const Double_t AliITSv11GeometrySSD::fgkSSDPConeUpMaxRadius = 459.*fgkmm;
47f8de53 513const Double_t AliITSv11GeometrySSD::fgkSSDPConeUpMiddleRadius = 472.5*fgkmm;
514const Double_t AliITSv11GeometrySSD::fgkSSDPConeDownRadius = 282.0*fgkmm;
515const Double_t AliITSv11GeometrySSD::fgkSSDPConeTrapezoidAngle = 42.0;
516const Double_t AliITSv11GeometrySSD::fgkSSDPConeTrapezoidBasis = 200.0*fgkmm;
517const Double_t AliITSv11GeometrySSD::fgkSSDPConeExternalRadius = 492.5*fgkmm;
518const Double_t AliITSv11GeometrySSD::fgkSSDPConeRadiusWidth = 16.75*fgkmm;
fcfbdd23 519const Double_t AliITSv11GeometrySSD::fgkSSDPConeLength = 168.0*fgkmm;
47f8de53 520const Double_t AliITSv11GeometrySSD::fgkSSDCentralSupportLength = 1020.*fgkmm;
521const Double_t AliITSv11GeometrySSD::fgkSSDCentralSupportRadius = 297.5*fgkmm;
522const Double_t AliITSv11GeometrySSD::fgkSSDCentralSupportWidth = 6.28*fgkmm;
523const Double_t AliITSv11GeometrySSD::fgkSSDCentralAL3SupportLength = 60.0*fgkmm;
524const Double_t AliITSv11GeometrySSD::fgkSSDCentralAL3SupportWidth = 2.5*fgkSSDCentralSupportWidth;
525/////////////////////////////////////////////////////////////////////////////////
526// SSD Cables Parameters (lengths are in mm and angles in degrees)
527/////////////////////////////////////////////////////////////////////////////////
528const Double_t AliITSv11GeometrySSD::fgkSSDCablesLay5TubeRadiusMin = 11.9*fgkmm;
529const Double_t AliITSv11GeometrySSD::fgkSSDCablesLay6TubeRadiusMin = 11.9*fgkmm;
530const Double_t AliITSv11GeometrySSD::fgkSSDCablesLay5RightSideHeight = 7.*fgkmm; // to be fixed in order to reproduce material budget
531const Double_t AliITSv11GeometrySSD::fgkSSDCablesLay6RightSideHeight = 7.*fgkmm; // to be fixed in order to reproduce material budget
532const Double_t AliITSv11GeometrySSD::fgkSSDCableAngle = 22.5;
533const Double_t AliITSv11GeometrySSD::fgkSSDCablesLay5RightSideWaterHeight = 2.5*fgkmm; // to be fixed in order to reproduce material budget
534const Double_t AliITSv11GeometrySSD::fgkSSDCablesPatchPanel2RB26Angle[2] = {25.0,53.2};
535const Double_t AliITSv11GeometrySSD::fgkSSDCablesPatchPanel2RB24Angle[2] = {23.0,53.6};
536const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB26ITSDistance = 975.0*fgkmm;
537const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB24ITSDistance = 1020.0*fgkmm;
538const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB26Radius = 451.3*fgkmm;
539const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB24Radius = 451.3*fgkmm;
540const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanelHeigth = 87.5*fgkmm;
541const Double_t AliITSv11GeometrySSD::fgkSSDCableMaterialBudgetHeight = 20.0*fgkmm;
542//const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB26Radius = fgkSSDPConeExternalRadius;
543//const Double_t AliITSv11GeometrySSD::fgkSSDPatchPanel2RB24Radius = fgkSSDPConeExternalRadius;
544/////////////////////////////////////////////////////////////////////////////////
44285dfa 545ClassImp(AliITSv11GeometrySSD)
546/////////////////////////////////////////////////////////////////////////////////
9acf2ecc 547AliITSv11GeometrySSD::AliITSv11GeometrySSD():
548 AliITSv11Geometry(),
44285dfa 549 fSSDChipMedium(),
550 fSSDChipGlueMedium(),
551 fSSDStiffenerMedium(),
552 fSSDStiffenerConnectorMedium(),
553 fSSDStiffener0603CapacitorMedium(),
554 fSSDStiffener1812CapacitorMedium(),
555 fSSDStiffenerHybridWireMedium(),
556 fSSDKaptonFlexMedium(),
557 fSSDAlTraceFlexMedium(),
558 fSSDAlTraceLadderCableMedium(),
559 fSSDKaptonLadderCableMedium(),
560 fSSDKaptonChipCableMedium(),
561 fSSDAlTraceChipCableMedium(),
562 fSSDAlCoolBlockMedium(),
563 fSSDSensorMedium(),
564 fSSDSensorSupportMedium(),
565 fSSDCarbonFiberMedium(),
566 fSSDTubeHolderMedium(),
567 fSSDCoolingTubeWater(),
568 fSSDCoolingTubePhynox(),
9b0c60ab 569 fSSDSupportRingAl(),
44285dfa 570 fSSDMountingBlockMedium(),
47f8de53 571 fSSDRohaCellCone(),
bf210566 572 fSSDAir(),
47f8de53 573 fSSDCopper(),
bf210566 574 fCreateMaterials(kFALSE),
575 fTransformationMatrices(kFALSE),
576 fBasicObjects(kFALSE),
577 fcarbonfiberjunction(),
578 fcoolingtubesupport(),
579 fhybridmatrix(),
580 fssdcoolingblocksystem(),
581 fcoolingblocksystematrix(),
582 fssdstiffenerflex(),
583 fssdendflex(),
9b0c60ab 584 fendladdercoolingtubesupportmatrix(),
bf210566 585 fendladdermountingblock(),
9b0c60ab 586 fendladdermountingblockclip(),
bf210566 587 fSSDSensor5(),
588 fSSDSensor6(),
589 fSSDLayer5(),
590 fSSDLayer6(),
591 fMotherVol(),
9b0c60ab 592 fLay5LadderSupportRing(),
593 fLay6LadderSupportRing(),
e5bf64ae 594 fgkEndCapSupportSystem(),
47f8de53 595 fSSDCone(),
44285dfa 596 fColorCarbonFiber(4),
597 fColorRyton(5),
bf210566 598 fColorPhynox(14),
44285dfa 599 fColorSilicon(3),
bf210566 600 fColorAl(38),
44285dfa 601 fColorKapton(6),
602 fColorPolyhamide(5),
603 fColorStiffener(9),
bf210566 604 fColorEpoxy(30),
605 fColorWater(7),
606 fColorG10(41)
44285dfa 607{
608 ////////////////////////
609 // Standard constructor
610 ////////////////////////
44285dfa 611}
612/////////////////////////////////////////////////////////////////////////////////
613AliITSv11GeometrySSD::AliITSv11GeometrySSD(const AliITSv11GeometrySSD &s):
9acf2ecc 614 AliITSv11Geometry(s.GetDebug()),
44285dfa 615 fSSDChipMedium(s.fSSDChipMedium),
616 fSSDChipGlueMedium(s.fSSDChipGlueMedium),
617 fSSDStiffenerMedium(s.fSSDStiffenerMedium),
618 fSSDStiffenerConnectorMedium(s.fSSDStiffenerConnectorMedium),
619 fSSDStiffener0603CapacitorMedium(s.fSSDStiffener0603CapacitorMedium),
620 fSSDStiffener1812CapacitorMedium(s.fSSDStiffener1812CapacitorMedium),
621 fSSDStiffenerHybridWireMedium(s.fSSDStiffenerHybridWireMedium),
622 fSSDKaptonFlexMedium(s.fSSDKaptonFlexMedium),
623 fSSDAlTraceFlexMedium(s.fSSDAlTraceFlexMedium),
624 fSSDAlTraceLadderCableMedium(s.fSSDAlTraceLadderCableMedium),
625 fSSDKaptonLadderCableMedium(s.fSSDKaptonLadderCableMedium),
626 fSSDKaptonChipCableMedium(s.fSSDKaptonChipCableMedium),
627 fSSDAlTraceChipCableMedium(s.fSSDAlTraceChipCableMedium),
628 fSSDAlCoolBlockMedium(s.fSSDAlCoolBlockMedium),
629 fSSDSensorMedium(s.fSSDSensorMedium),
630 fSSDSensorSupportMedium(s.fSSDSensorSupportMedium),
631 fSSDCarbonFiberMedium(s.fSSDCarbonFiberMedium),
632 fSSDTubeHolderMedium(s.fSSDTubeHolderMedium),
633 fSSDCoolingTubeWater(s.fSSDCoolingTubeWater),
634 fSSDCoolingTubePhynox(s.fSSDCoolingTubePhynox),
9b0c60ab 635 fSSDSupportRingAl(s.fSSDSupportRingAl),
44285dfa 636 fSSDMountingBlockMedium(s.fSSDMountingBlockMedium),
47f8de53 637 fSSDRohaCellCone(s.fSSDRohaCellCone),
bf210566 638 fSSDAir(s.fSSDAir),
47f8de53 639 fSSDCopper(s.fSSDCopper),
bf210566 640 fCreateMaterials(s.fCreateMaterials),
641 fTransformationMatrices(s.fTransformationMatrices),
642 fBasicObjects(s.fBasicObjects),
643 fcarbonfiberjunction(s.fcarbonfiberjunction),
644 fcoolingtubesupport(s.fcoolingtubesupport),
645 fhybridmatrix(s.fhybridmatrix),
646 fssdcoolingblocksystem(s.fssdcoolingblocksystem),
647 fcoolingblocksystematrix(s.fcoolingblocksystematrix),
648 fssdstiffenerflex(s.fssdstiffenerflex),
649 fssdendflex(s.fssdendflex),
9b0c60ab 650 fendladdercoolingtubesupportmatrix(s.fendladdercoolingtubesupportmatrix),
bf210566 651 fendladdermountingblock(s.fendladdermountingblock),
9b0c60ab 652 fendladdermountingblockclip(s.fendladdermountingblockclip),
bf210566 653 fSSDSensor5(s.fSSDSensor5),
654 fSSDSensor6(s.fSSDSensor6),
655 fSSDLayer5(s.fSSDLayer5),
656 fSSDLayer6(s.fSSDLayer6),
44285dfa 657 fMotherVol(s.fMotherVol),
9b0c60ab 658 fLay5LadderSupportRing(s.fLay5LadderSupportRing),
659 fLay6LadderSupportRing(s.fLay6LadderSupportRing),
e5bf64ae 660 fgkEndCapSupportSystem(s.fgkEndCapSupportSystem),
47f8de53 661 fSSDCone(s.fSSDCone),
44285dfa 662 fColorCarbonFiber(s.fColorCarbonFiber),
663 fColorRyton(s.fColorRyton),
664 fColorPhynox(s.fColorPhynox),
665 fColorSilicon(s.fColorSilicon),
666 fColorAl(s.fColorAl),
667 fColorKapton(s.fColorKapton),
668 fColorPolyhamide(s.fColorPolyhamide),
669 fColorStiffener(s.fColorStiffener),
bf210566 670 fColorEpoxy(s.fColorEpoxy),
671 fColorWater(s.fColorWater),
672 fColorG10(s.fColorG10)
44285dfa 673{
674 ////////////////////////
675 // Copy Constructor
676 ////////////////////////
d7599219 677}
678/////////////////////////////////////////////////////////////////////////////////
44285dfa 679AliITSv11GeometrySSD& AliITSv11GeometrySSD::
680operator=(const AliITSv11GeometrySSD &s){
681 ////////////////////////
682 // Assignment operator
683 ////////////////////////
684 this->~AliITSv11GeometrySSD();
685 new(this) AliITSv11GeometrySSD(s);
686 return *this;
687/*
688 if(&s == this) return *this;
689 fMotherVol = s.fMotherVol;
690 return *this;
691 */
692}
bf210566 693///////////////////////////////////////////////////////////////////////////////
694void AliITSv11GeometrySSD::CreateTransformationMatrices(){
695 ///////////////////////////////////////////////////////////////////////
696 // Method generating the trasformation matrix for the whole SSD Geometry
697 ///////////////////////////////////////////////////////////////////////
698 // Setting some variables for Carbon Fiber Supportmatrix creation
699 //////////////////////////////////////////////////////////////////////
700 Double_t carbonfibersupportxaxisEdgeproj = fgkCarbonFiberSupportEdgeLength
701 * CosD(fgkCarbonFiberJunctionAngle[0]);
702 Double_t symmetryplaneposition = (fgkCarbonFiberSupportYAxisLength
703 + fgkCarbonFiberSupportTopEdgeDist[0]
704 + fgkCarbonFiberSupportWidth);
705 Double_t carbonfibersupportheight = carbonfibersupportxaxisEdgeproj
706 * TanD(fgkCarbonFiberJunctionAngle[0]);
707 TGeoRotation* carbonfiberot[3];
708 for(Int_t i=0; i<3; i++) carbonfiberot[i] = new TGeoRotation();
709 carbonfiberot[0]->SetAngles(0.0,180.0,0.0);
710 carbonfiberot[1]->SetAngles(90.,-fgkCarbonFiberTriangleAngle,-90.);
711 carbonfiberot[2]->SetRotation((*carbonfiberot[1])*(*carbonfiberot[0]));
712 Double_t transvector[3] = {fgkCarbonFiberTriangleLength
713 * CosD(fgkCarbonFiberTriangleAngle),0.,
714 - fgkCarbonFiberTriangleLength
715 * SinD(fgkCarbonFiberTriangleAngle)};
716 ///////////////////////////////////////////
717 //Setting Local Translations and Rotations:
718 ///////////////////////////////////////////
719 TGeoCombiTrans* localcarbonfibersupportmatrix[3];
720 localcarbonfibersupportmatrix[0] = new TGeoCombiTrans(0.0,0.0,
721 0.5*carbonfibersupportheight,NULL);
722 localcarbonfibersupportmatrix[1] = new TGeoCombiTrans(transvector[0],
723 2.*symmetryplaneposition+transvector[1],
724 transvector[2], carbonfiberot[2]);
725 localcarbonfibersupportmatrix[2] = new TGeoCombiTrans(*carbonfiberot[1]);
726 /////////////////////////////////////////////////////////////
727 // Carbon Fiber Support Transformations
728 /////////////////////////////////////////////////////////////
729 const Int_t kcarbonfibersupportmatrixnumber[2] = {2,3};
730 for(Int_t i=0; i<fgkcarbonfibersupportnumber; i++){
731 fcarbonfibersupportmatrix[i] = new TGeoHMatrix();
732 for(Int_t j=0; j<kcarbonfibersupportmatrixnumber[i]; j++)
733 fcarbonfibersupportmatrix[i]->MultiplyLeft(localcarbonfibersupportmatrix[i==0?2*j:j]);
734 }
735 /////////////////////////////////////////////////////////////
736 // Carbon Fiber Junction Transformation
737 /////////////////////////////////////////////////////////////
738 const Int_t kcarbonfiberjunctionmatrixnumber = 2;
739 TGeoCombiTrans** localcarbonfiberjunctionmatrix[fgkcarbonfiberjunctionumber];
740 TGeoRotation** localcarbonfiberjunctionrot[fgkcarbonfiberjunctionumber];
741 TGeoTranslation** localcarbonfiberjunctiontrans[fgkcarbonfiberjunctionumber];
742 for(Int_t i=0; i<fgkcarbonfiberjunctionumber; i++){
743 localcarbonfiberjunctionmatrix[i] =
744 new TGeoCombiTrans*[kcarbonfiberjunctionmatrixnumber];
745 localcarbonfiberjunctionrot[i] =
746 new TGeoRotation*[kcarbonfiberjunctionmatrixnumber];
747 localcarbonfiberjunctiontrans[i] =
748 new TGeoTranslation*[kcarbonfiberjunctionmatrixnumber];
d7599219 749 }
bf210566 750 ///////////////////////
751 // Setting Translations
752 ///////////////////////
753 localcarbonfiberjunctiontrans[0][0] = new TGeoTranslation(0.,0.,0.);
754 localcarbonfiberjunctiontrans[1][0] =
755 new TGeoTranslation(fgkCarbonFiberTriangleLength,0.0,0.0);
756 localcarbonfiberjunctiontrans[2][0] =
757 new TGeoTranslation(fgkCarbonFiberTriangleLength
758 * TMath::Cos(fgkCarbonFiberTriangleAngle*TMath::DegToRad()),
759 fgkCarbonFiberTriangleLength
760 * TMath::Sin(fgkCarbonFiberTriangleAngle*TMath::DegToRad()),0.0);
761 localcarbonfiberjunctiontrans[0][1] =
762 new TGeoTranslation(0.0,0.5*fgkCarbonFiberJunctionWidth,0.0);
763 localcarbonfiberjunctiontrans[1][1] =
764 new TGeoTranslation(*localcarbonfiberjunctiontrans[0][1]);
765 localcarbonfiberjunctiontrans[2][1] =
766 new TGeoTranslation(*localcarbonfiberjunctiontrans[0][1]);
767 ////////////////////
768 // Setting Rotations
769 ////////////////////
770 for(Int_t i=0; i<fgkcarbonfiberjunctionumber; i++)
771 for(Int_t j=0; j<kcarbonfiberjunctionmatrixnumber; j++)
772 localcarbonfiberjunctionrot[i][j] = new TGeoRotation();
773 for(Int_t i=0; i<fgkcarbonfiberjunctionumber; i++)
774 localcarbonfiberjunctionrot[i][0]->SetAngles(120.*i,0.0,0.0);
775 localcarbonfiberjunctionrot[0][1]->SetAngles(0.0,90.0,0.0);
776 localcarbonfiberjunctionrot[1][1]->SetRotation(*localcarbonfiberjunctionrot[0][1]);
777 localcarbonfiberjunctionrot[2][1]->SetRotation(*localcarbonfiberjunctionrot[0][1]);
778 ////////////////////////////////////////
779 // Setting Carbon Fiber Junction matrix
780 ////////////////////////////////////////
781 for(Int_t i=0; i<fgkcarbonfiberjunctionumber; i++){
782 fcarbonfiberjunctionmatrix[i] = new TGeoHMatrix();
783 for(Int_t j=0; j<kcarbonfiberjunctionmatrixnumber; j++){
784 localcarbonfiberjunctionmatrix[i][j] =
785 new TGeoCombiTrans(*localcarbonfiberjunctiontrans[i][j],
786 *localcarbonfiberjunctionrot[i][j]);
787 fcarbonfiberjunctionmatrix[i]->MultiplyLeft(localcarbonfiberjunctionmatrix[i][j]);
788 }
d7599219 789 }
bf210566 790 /////////////////////////////////////////////////////////////
791 // Carbon Fiber Lower Support Transformations
792 /////////////////////////////////////////////////////////////
793 TGeoTranslation* localcarbonfiberlowersupportrans[2];
794 localcarbonfiberlowersupportrans[0] = new TGeoTranslation(0.0,
795 fgkCarbonFiberLowerSupportVolumePosition[1]
796 + fgkCarbonFiberLowerSupportVolumePosition[0],
797 0.0);
798 localcarbonfiberlowersupportrans[1] = new TGeoTranslation(0.0,
799 fgkCarbonFiberJunctionWidth
800 - fgkCarbonFiberLowerSupportWidth
801 - fgkCarbonFiberLowerSupportVolumePosition[0]
802 - fgkCarbonFiberLowerSupportVolumePosition[1],
803 - 0.5*fgkCarbonFiberLowerSupportHeight);
804 localcarbonfiberlowersupportrans[0]->Add(localcarbonfiberlowersupportrans[1]);
805 fcarbonfiberlowersupportrans[0] =
806 new TGeoTranslation(*localcarbonfiberlowersupportrans[0]);
807 fcarbonfiberlowersupportrans[1] =
808 new TGeoTranslation(*localcarbonfiberlowersupportrans[1]);
809 /////////////////////////////////////////////////////////////
810 // SSD Sensor Support Transformations
811 /////////////////////////////////////////////////////////////
812 const Int_t kssdsensorsupportmatrixnumber = 3;
813 TGeoCombiTrans** localssdsensorsupportmatrix[fgkssdsensorsupportnumber];
814 TGeoRotation** localssdsensorsupportrot[fgkssdsensorsupportnumber];
815 TGeoTranslation** localssdsensorsupportrans[fgkssdsensorsupportnumber];
816 for(Int_t i=0; i<fgkssdsensorsupportnumber; i++){
817 localssdsensorsupportmatrix[i] =
818 new TGeoCombiTrans*[kssdsensorsupportmatrixnumber];
819 localssdsensorsupportrot[i] =
820 new TGeoRotation*[kssdsensorsupportmatrixnumber];
821 localssdsensorsupportrans[i] =
822 new TGeoTranslation*[kssdsensorsupportmatrixnumber];
d7599219 823 }
bf210566 824 ///////////////////////
825 // Setting Translations
826 ///////////////////////
827 localssdsensorsupportrans[0][0] = new TGeoTranslation(0.0,
828 0.5*fgkSSDSensorSideSupportWidth,
829 0.0);
830 localssdsensorsupportrans[1][0] =
831 new TGeoTranslation(*localssdsensorsupportrans[0][0]);
832 localssdsensorsupportrans[2][0] =
833 new TGeoTranslation(*localssdsensorsupportrans[0][0]);
834 localssdsensorsupportrans[0][1] =
835 new TGeoTranslation(-0.5*fgkSSDSensorSideSupportWidth,
836 0.5*fgkSSDSensorSideSupportThickness[0],
837 0.0);
838 localssdsensorsupportrans[1][1] =
839 new TGeoTranslation(0.5*fgkSSDSensorSideSupportWidth,
840 - 0.5*fgkSSDSensorSideSupportThickness[0]
841 - fgkSSDModuleSensorSupportDistance,
842 0.0);
843 localssdsensorsupportrans[2][1] =
844 new TGeoTranslation(0.5*fgkSSDSensorCenterSupportThickness[0]
845 - fgkSSDSensorCenterSupportPosition,
846 0.5*fgkSSDSensorCenterSupportWidth
847 - 0.5*fgkSSDModuleSensorSupportDistance,
848 fgkSSDSensorCenterSupportThickness[0]);
849 localssdsensorsupportrans[0][2] =
850 new TGeoTranslation(fgkCarbonFiberTriangleLength
851 + fgkCarbonFiberJunctionToSensorSupport,
852 fgkCarbonFiberJunctionWidth
853 - 0.5*(fgkCarbonFiberLowerSupportWidth
854 + fgkSSDSensorCenterSupportLength
855 - fgkSSDSensorCenterSupportThickness[0])
856 - fgkSSDSensorCenterSupportPosition,
857 0.0);
858 localssdsensorsupportrans[1][2] =
859 new TGeoTranslation(*localssdsensorsupportrans[0][2]);
860 localssdsensorsupportrans[2][2] =
861 new TGeoTranslation(*localssdsensorsupportrans[0][2]);
862 ////////////////////
863 // Setting Rotations
864 ////////////////////
865 for(Int_t i=0; i<fgkssdsensorsupportnumber; i++)
866 for(Int_t j=0; j<kssdsensorsupportmatrixnumber; j++)
867 localssdsensorsupportrot[i][j] = new TGeoRotation();
868 for(Int_t i=0; i<fgkssdsensorsupportnumber; i++){
869 localssdsensorsupportrot[i][0]->SetAngles(0.0,90.0,0.0);
870 localssdsensorsupportrot[i][2]->SetAngles(-90.0,0.0,0.0);
d7599219 871 }
bf210566 872 localssdsensorsupportrot[0][1]->SetAngles(0.0,90.0,-90.0);
873 localssdsensorsupportrot[1][1]->SetAngles(180.0,90.0,-90.0);
874 localssdsensorsupportrot[2][1]->SetAngles(270.0,90.0,-90.0);
875 ////////////////////////////////////////
876 // SSD Sensor Support matrix
877 ////////////////////////////////////////
878 for(Int_t i=0; i<fgkssdsensorsupportnumber; i++){
879 fssdsensorsupportmatrix[i] = new TGeoHMatrix();
880 for(Int_t j=0; j<kssdsensorsupportmatrixnumber; j++){
881 localssdsensorsupportmatrix[i][j] =
882 new TGeoCombiTrans(*localssdsensorsupportrans[i][j],
883 *localssdsensorsupportrot[i][j]);
884 fssdsensorsupportmatrix[i]->MultiplyLeft(localssdsensorsupportmatrix[i][j]);
885 }
d7599219 886 }
44285dfa 887 /////////////////////////////////////////////////////////////
bf210566 888 // SSD Cooling Tube Support Transformations
44285dfa 889 /////////////////////////////////////////////////////////////
bf210566 890 const Int_t kcoolingtubesupportmatrixnumber = 2;
891 TGeoCombiTrans* localcoolingtubesupportmatrix[kcoolingtubesupportmatrixnumber];
892 TGeoTranslation* localcoolingtubesupportrans[kcoolingtubesupportmatrixnumber];
893 TGeoRotation* localcoolingtubesupportrot[kcoolingtubesupportmatrixnumber];
44285dfa 894 Double_t phi = TMath::ASin(0.5*fgkCoolingTubeSupportHeight
d7599219 895 /fgkCoolingTubeSupportRmax);
bf210566 896 localcoolingtubesupportrans[0] =
897 new TGeoTranslation(2.*fgkCoolingTubeSupportRmax*TMath::Cos(phi)
d7599219 898 + 2.*(fgkCoolingTubeSupportLength
44285dfa 899 - fgkCoolingTubeSupportRmax*(1.+TMath::Cos(phi)))
d7599219 900 + fgkCarbonFiberTriangleLength
bf210566 901 - 2.0*fgkCarbonFiberJunctionLength,0.0,0.0);
902 localcoolingtubesupportrans[1] =
903 new TGeoTranslation(fgkCarbonFiberJunctionLength
904 - (fgkCoolingTubeSupportLength-fgkCoolingTubeSupportRmax),
905 - (2.0*fgkSSDSensorLength-fgkSSDSensorOverlap)+
906 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
907 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
908 - 0.5*(fgkCarbonFiberLowerSupportWidth
909 + fgkSSDSensorCenterSupportLength
910 - fgkSSDSensorCenterSupportThickness[0])
911 + 0.5*fgkSSDSensorLength,
912 - 0.5*fgkCoolingTubeSupportHeight);
913 for(Int_t i=0; i<kcoolingtubesupportmatrixnumber; i++)
914 localcoolingtubesupportrot[i] = new TGeoRotation();
915 localcoolingtubesupportrot[0]->SetAngles(180.0,0.0,0.0);
916 localcoolingtubesupportrot[1]->SetAngles(0.0,90.0,0.0);
917 for(Int_t i=0; i<kcoolingtubesupportmatrixnumber; i++)
918 localcoolingtubesupportmatrix[i] =
919 new TGeoCombiTrans(*localcoolingtubesupportrans[i],
920 *localcoolingtubesupportrot[i]);
921 fcoolingtubesupportmatrix[0] = new TGeoHMatrix(*localcoolingtubesupportmatrix[1]);
922 fcoolingtubesupportmatrix[1] = new TGeoHMatrix((*localcoolingtubesupportmatrix[1])*
923 (*localcoolingtubesupportmatrix[0]));
924 /////////////////////////////////////////////////////////////
9b0c60ab 925 // End Ladder SSD Cooling Tube Support Transformations
926 /////////////////////////////////////////////////////////////
927 TGeoTranslation** localendladdercooltubetrans[2];
928 localendladdercooltubetrans[0] = new TGeoTranslation*[4];
929 localendladdercooltubetrans[1] = new TGeoTranslation*[2];
930 for(Int_t i=0; i<4; i++) localendladdercooltubetrans[0][i] = new TGeoTranslation();
931 localendladdercooltubetrans[0][0]->SetTranslation(fgkCarbonFiberJunctionLength
932 - (fgkCoolingTubeSupportLength
933 - fgkCoolingTubeSupportRmax),
934 fgkEndLadderMountingBlockPosition[0]
935 - fgkendladdercoolingsupportdistance[0]
936 + 0.5*fgkCoolingTubeSupportWidth,
937 - 0.5*fgkCoolingTubeSupportHeight);
938 localendladdercooltubetrans[0][1]->SetTranslation(fgkCarbonFiberJunctionLength
939 - (fgkCoolingTubeSupportLength
940 - fgkCoolingTubeSupportRmax),
941 fgkEndLadderMountingBlockPosition[0]
942 + fgkendladdercoolingsupportdistance[1]
943 + 0.5*fgkCoolingTubeSupportWidth,
944 - 0.5*fgkCoolingTubeSupportHeight);
945 localendladdercooltubetrans[0][2]->SetTranslation(2*(fgkCoolingTubeSupportLength
946 - fgkCoolingTubeSupportRmax)
947 + fgkCarbonFiberTriangleLength
948 - 2.0*fgkCarbonFiberJunctionLength,
949 0.0,
950 0.0);
951 localendladdercooltubetrans[0][3]->SetTranslation(0.0,
952 fgkendladdercoolingsupportdistance[0]
953 + fgkendladdercoolingsupportdistance[1],
954 0.0);
955 for(Int_t i=0; i<2; i++) localendladdercooltubetrans[1][i] = new TGeoTranslation();
956 localendladdercooltubetrans[1][0]->SetTranslation(fgkCoolingTubeSupportRmax
957 + fgkCarbonFiberJunctionLength
958 - fgkCoolingTubeSupportLength,
959 fgkEndLadderCarbonFiberLowerJunctionLength[1]
960 - 0.5*fgkCoolingTubeSupportWidth
961 -fgkendladdercoolingsupportdistance[2],
962 - 0.5*fgkCoolingTubeSupportHeight);
963 localendladdercooltubetrans[1][1]->SetTranslation(fgkCarbonFiberTriangleLength
964 + fgkCoolingTubeSupportLength
965 - fgkCoolingTubeSupportRmax
966 - fgkCarbonFiberJunctionLength,
967 fgkEndLadderCarbonFiberLowerJunctionLength[1]
968 - 0.5*fgkCoolingTubeSupportWidth
969 - fgkendladdercoolingsupportdistance[2],
970 - 0.5*fgkCoolingTubeSupportHeight);
971 fendladdercoolingtubesupportmatrix = new TGeoHMatrix**[kcoolingtubesupportmatrixnumber];
972 fendladdercoolingtubesupportmatrix[0] = new TGeoHMatrix*[4];
973 fendladdercoolingtubesupportmatrix[1] = new TGeoHMatrix*[2];
974 fendladdercoolingtubesupportmatrix[0][0] = new TGeoHMatrix((*localendladdercooltubetrans[0][0])*
975 (*localcoolingtubesupportrot[1]));
976 fendladdercoolingtubesupportmatrix[0][1] = new TGeoHMatrix((*localendladdercooltubetrans[0][1])*
977 (*localcoolingtubesupportrot[1]));
978 fendladdercoolingtubesupportmatrix[0][2] = new TGeoHMatrix(*fendladdercoolingtubesupportmatrix[0][0]);
979 fendladdercoolingtubesupportmatrix[0][2]->Multiply(localcoolingtubesupportrot[0]);
980 fendladdercoolingtubesupportmatrix[0][2]->MultiplyLeft(localendladdercooltubetrans[0][2]);
981 fendladdercoolingtubesupportmatrix[0][3] = new TGeoHMatrix(*fendladdercoolingtubesupportmatrix[0][2]);
982 fendladdercoolingtubesupportmatrix[0][3]->MultiplyLeft(localendladdercooltubetrans[0][3]);
983
984 fendladdercoolingtubesupportmatrix[1][0] =
985 new TGeoHMatrix((*localendladdercooltubetrans[1][0])
986 *(*localcoolingtubesupportrot[1]));
987 fendladdercoolingtubesupportmatrix[1][1] = new TGeoHMatrix(*localcoolingtubesupportrot[1]);
988 fendladdercoolingtubesupportmatrix[1][1]->Multiply(localcoolingtubesupportrot[0]);
989 fendladdercoolingtubesupportmatrix[1][1]->MultiplyLeft(localendladdercooltubetrans[1][1]);
990 /////////////////////////////////////////////////////////////
bf210566 991 // SSD Cooling Tube Transformations
992 /////////////////////////////////////////////////////////////
993 TGeoRotation* localcoolingtuberot = new TGeoRotation();
994 localcoolingtuberot->SetAngles(0.,90.,0.);
995 TGeoTranslation** localcoolingtubetrans[4];
996 TVector3** localcoolingtubevect[4];
997 for(Int_t i=0; i<4; i++){
998 localcoolingtubevect[i] = new TVector3*[2];
999 localcoolingtubetrans[i] = new TGeoTranslation*[2];
1000 fcoolingtubematrix[i] = new TGeoHMatrix*[2];
d7599219 1001 }
bf210566 1002 localcoolingtubevect[0][0] = new TVector3(-0.5*(fgkCoolingTubeSeparation
1003 -fgkCarbonFiberTriangleLength),
1004 - (2.0*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1005 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1006 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1007 - 0.5*(fgkCarbonFiberLowerSupportWidth
1008 + fgkSSDSensorCenterSupportLength
1009 - fgkSSDSensorCenterSupportThickness[0])+
1010 0.5*fgkSSDSensorLength-0.25*(fgkSSDSensorLength
1011 - 2.0*fgkSSDModuleStiffenerPosition[1]
1012 - 2.0*fgkSSDCoolingBlockWidth-fgkCoolingTubeSupportWidth)
1013 - 0.5*fgkCoolingTubeSupportWidth,
1014 - 0.5*fgkCoolingTubeSupportHeight);
1015 localcoolingtubevect[0][1] = new TVector3(localcoolingtubevect[0][0]->X(),
1016 localcoolingtubevect[0][0]->Y()+0.5*(fgkSSDSensorLength
1017 - 2.0*fgkSSDModuleStiffenerPosition[1]
1018 - 2.0*fgkSSDCoolingBlockWidth-fgkCoolingTubeSupportWidth)
1019 + fgkCoolingTubeSupportWidth,
1020 localcoolingtubevect[0][0]->Z());
1021 localcoolingtubevect[1][0] = new TVector3(-localcoolingtubevect[0][0]->X()
1022 + fgkCarbonFiberTriangleLength,
1023 localcoolingtubevect[0][0]->Y(),
1024 localcoolingtubevect[0][0]->Z());
1025 localcoolingtubevect[1][1] = new TVector3(-localcoolingtubevect[0][1]->X()
1026 + fgkCarbonFiberTriangleLength,
1027 localcoolingtubevect[0][1]->Y(),
1028 localcoolingtubevect[0][1]->Z());
1029 localcoolingtubevect[2][0] = new TVector3(-0.5*(fgkCoolingTubeSeparation
1030 - fgkCarbonFiberTriangleLength),
1031 - (2.0*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1032 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1033 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1034 - 0.5*(fgkCarbonFiberLowerSupportWidth
1035 + fgkSSDSensorCenterSupportLength
1036 - fgkSSDSensorCenterSupportThickness[0])
1037 + fgkSSDModuleStiffenerPosition[1]
1038 - 0.5*(fgkSSDModuleStiffenerPosition[1]-fgkSSDSensorOverlap),
1039 - 0.5*fgkCoolingTubeSupportHeight);
1040 localcoolingtubevect[2][1] = new TVector3(-localcoolingtubevect[2][0]->X()
1041 + fgkCarbonFiberTriangleLength,
1042 localcoolingtubevect[2][0]->Y(),
1043 localcoolingtubevect[2][0]->Z());
1044 localcoolingtubevect[3][0] = new TVector3(-0.5*(fgkCoolingTubeSeparation
1045 - fgkCarbonFiberTriangleLength),
1046 - (2.0*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1047 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1048 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1049 - 0.5*(fgkCarbonFiberLowerSupportWidth
1050 + fgkSSDSensorCenterSupportLength
1051 - fgkSSDSensorCenterSupportThickness[0])
1052 + fgkSSDSensorLength
1053 - 0.5*fgkSSDModuleStiffenerPosition[1],
1054 - 0.5*fgkCoolingTubeSupportHeight);
1055 localcoolingtubevect[3][1] = new TVector3(-localcoolingtubevect[3][0]->X()
1056 + fgkCarbonFiberTriangleLength,
1057 localcoolingtubevect[3][0]->Y(),
1058 - 0.5*fgkCoolingTubeSupportHeight);
1059 for(Int_t i=0; i<4; i++)
1060 for(Int_t j=0; j<2; j++){
1061 localcoolingtubetrans[i][j] =
1062 new TGeoTranslation(localcoolingtubevect[i][j]->X(),
1063 localcoolingtubevect[i][j]->Y(),
1064 localcoolingtubevect[i][j]->Z());
1065 fcoolingtubematrix[i][j] = new TGeoHMatrix((*localcoolingtubetrans[i][j])
1066 * (*localcoolingtuberot));
1067 }
1068 /////////////////////////////////////////////////////////////
9b0c60ab 1069 // SSD End Ladder Cooling Tube Transformations
1070 /////////////////////////////////////////////////////////////
1071 TGeoRotation* localendlladdercoolingtuberot = new TGeoRotation();
1072 localendlladdercoolingtuberot->SetAngles(0.,90.,0.);
1073 TGeoTranslation** localendlladdercoolingtubetrans[2];
1074 localendlladdercoolingtubetrans[0] = new TGeoTranslation*[6];
1075 localendlladdercoolingtubetrans[1] = new TGeoTranslation*[4];
1076 for(Int_t i=0; i<2; i++)
1077 for(Int_t j=0; j<(i==0?6:4); j++)
1078 localendlladdercoolingtubetrans[i][j] = new TGeoTranslation();
1079 localendlladdercoolingtubetrans[0][0]->SetTranslation(-(fgkCoolingTubeSupportLength
1080 - fgkCoolingTubeSupportRmax)
1081 + fgkCarbonFiberJunctionLength,
1082 0.5*(fgkEndLadderMountingBlockPosition[0]
1083 - fgkendladdercoolingsupportdistance[0]),
1084 - 0.5*fgkCoolingTubeSupportHeight);
1085 localendlladdercoolingtubetrans[0][1]->SetTranslation((fgkCoolingTubeSupportLength
1086 - fgkCoolingTubeSupportRmax)
1087 - fgkCarbonFiberJunctionLength
1088 + fgkCarbonFiberTriangleLength,
1089 0.5*(fgkEndLadderMountingBlockPosition[0]
1090 - fgkendladdercoolingsupportdistance[0]),
1091 - 0.5*fgkCoolingTubeSupportHeight);
1092 localendlladdercoolingtubetrans[0][2]->SetTranslation(-(fgkCoolingTubeSupportLength
1093 - fgkCoolingTubeSupportRmax)
1094 + fgkCarbonFiberJunctionLength,
1095 fgkEndLadderMountingBlockPosition[0]
1096 - fgkendladdercoolingsupportdistance[0]
1097 + 0.5*(fgkendladdercoolingsupportdistance[0]
1098 + fgkendladdercoolingsupportdistance[1]
1099 + fgkCoolingTubeSupportWidth),
1100 - 0.5*fgkCoolingTubeSupportHeight);
1101 localendlladdercoolingtubetrans[0][3]->SetTranslation((fgkCoolingTubeSupportLength
1102 - fgkCoolingTubeSupportRmax)
1103 - fgkCarbonFiberJunctionLength
1104 + fgkCarbonFiberTriangleLength,
1105 fgkEndLadderMountingBlockPosition[0]
1106 - fgkendladdercoolingsupportdistance[0]
1107 + 0.5*(fgkendladdercoolingsupportdistance[0]
1108 + fgkendladdercoolingsupportdistance[1]
1109 + fgkCoolingTubeSupportWidth),
1110 - 0.5*fgkCoolingTubeSupportHeight);
1111 localendlladdercoolingtubetrans[0][4]->SetTranslation(-(fgkCoolingTubeSupportLength
1112 - fgkCoolingTubeSupportRmax)
1113 + fgkCarbonFiberJunctionLength,
1114 fgkEndLadderCarbonFiberLowerJunctionLength[0]
1115 - 0.50 * (fgkEndLadderCarbonFiberLowerJunctionLength[0]
1116 - fgkEndLadderMountingBlockPosition[0]
1117 - fgkendladdercoolingsupportdistance[1]
1118 - fgkCoolingTubeSupportWidth),
1119 - 0.5*fgkCoolingTubeSupportHeight);
1120 localendlladdercoolingtubetrans[0][5]->SetTranslation((fgkCoolingTubeSupportLength
1121 - fgkCoolingTubeSupportRmax)
1122 - fgkCarbonFiberJunctionLength
1123 + fgkCarbonFiberTriangleLength,
1124 fgkEndLadderCarbonFiberLowerJunctionLength[0]
1125 - 0.50 * (fgkEndLadderCarbonFiberLowerJunctionLength[0]
1126 - fgkEndLadderMountingBlockPosition[0]
1127 - fgkendladdercoolingsupportdistance[1]
1128 - fgkCoolingTubeSupportWidth),
1129 - 0.5*fgkCoolingTubeSupportHeight);
1130 localendlladdercoolingtubetrans[1][0]->SetTranslation(-(fgkCoolingTubeSupportLength
1131 - fgkCoolingTubeSupportRmax)
1132 + fgkCarbonFiberJunctionLength,
1133 - 0.50 * (fgkMountingBlockToSensorSupport
1134 - 0.50 * (fgkSSDFlexHoleWidth-fgkSSDSensorSideSupportWidth)
1135 - fgkSSDStiffenerWidth-fgkSSDModuleStiffenerPosition[1]
1136 + fgkSSDSensorOverlap
1137 + fgkEndLadderCarbonFiberLowerJunctionLength[1]
1138 - fgkendladdercoolingsupportdistance[2]
1139 - fgkEndLadderMountingBlockPosition[1]
1140 - fgkCoolingTubeSupportWidth)
1141 + fgkEndLadderCarbonFiberLowerJunctionLength[1]
1142 - fgkendladdercoolingsupportdistance[2]
1143 - fgkCoolingTubeSupportWidth,
1144 - 0.5*fgkCoolingTubeSupportHeight);
1145 localendlladdercoolingtubetrans[1][1]->SetTranslation((fgkCoolingTubeSupportLength
1146 - fgkCoolingTubeSupportRmax)
1147 - fgkCarbonFiberJunctionLength
1148 + fgkCarbonFiberTriangleLength,
1149 - 0.50 * (fgkMountingBlockToSensorSupport
1150 - 0.50 * (fgkSSDFlexHoleWidth-fgkSSDSensorSideSupportWidth)
1151 - fgkSSDStiffenerWidth-fgkSSDModuleStiffenerPosition[1]
1152 + fgkSSDSensorOverlap
1153 + fgkEndLadderCarbonFiberLowerJunctionLength[1]
1154 - fgkendladdercoolingsupportdistance[2]
1155 - fgkEndLadderMountingBlockPosition[1]
1156 - fgkCoolingTubeSupportWidth)
1157 + fgkEndLadderCarbonFiberLowerJunctionLength[1]
1158 - fgkendladdercoolingsupportdistance[2]
1159 - fgkCoolingTubeSupportWidth,
1160 - 0.5*fgkCoolingTubeSupportHeight);
1161 localendlladdercoolingtubetrans[1][2]->SetTranslation(-(fgkCoolingTubeSupportLength
1162 - fgkCoolingTubeSupportRmax)
1163 + fgkCarbonFiberJunctionLength,
1164 fgkEndLadderCarbonFiberLowerJunctionLength[1]
1165 - 0.5*fgkendladdercoolingsupportdistance[2],
1166 - 0.5*fgkCoolingTubeSupportHeight);
1167 localendlladdercoolingtubetrans[1][3]->SetTranslation((fgkCoolingTubeSupportLength
1168 - fgkCoolingTubeSupportRmax)
1169 - fgkCarbonFiberJunctionLength
1170 + fgkCarbonFiberTriangleLength,
1171 fgkEndLadderCarbonFiberLowerJunctionLength[1]
1172 - 0.5*fgkendladdercoolingsupportdistance[2],
1173 - 0.5*fgkCoolingTubeSupportHeight);
1174 fendladdercoolingtubematrix[0] = new TGeoHMatrix*[6];
1175 fendladdercoolingtubematrix[1] = new TGeoHMatrix*[4];
1176 for(Int_t i=0; i<2; i++)
1177 for(Int_t j=0; j<(i==0?6:4); j++){
1178 fendladdercoolingtubematrix[i][j] = new TGeoHMatrix(*localendlladdercoolingtuberot);
1179 fendladdercoolingtubematrix[i][j]->MultiplyLeft(localendlladdercoolingtubetrans[i][j]);
1180 }
1181 /////////////////////////////////////////////////////////////
bf210566 1182 // SSD Hybrid Components Transformations
1183 /////////////////////////////////////////////////////////////
1184 const Int_t khybridmatrixnumber = 3;
1185 TGeoTranslation* localhybridtrans[khybridmatrixnumber];
1186 localhybridtrans[0] = new TGeoTranslation(0.5*fgkSSDStiffenerLength,
1187 0.5*fgkSSDStiffenerWidth,
1188 0.5*fgkSSDStiffenerHeight);
1189 localhybridtrans[1] = new TGeoTranslation(fgkSSDModuleStiffenerPosition[0],
1190 fgkSSDModuleStiffenerPosition[1],0.0);
1191
1192 localhybridtrans[2] = new TGeoTranslation(
1193 - 0.5*(fgkSSDSensorWidth-fgkCarbonFiberTriangleLength),
1194 - (2.*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1195 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1196 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1197 - 0.5*(fgkCarbonFiberLowerSupportWidth+fgkSSDSensorCenterSupportLength
1198 - fgkSSDSensorCenterSupportThickness[0]),
1199 - (fgkSSDModuleCoolingBlockToSensor+0.5*fgkCoolingTubeSupportHeight
ca86fdb4 1200 - fgkSSDSensorHeight-fgkSSDChipCablesHeight[3]-fgkSSDChipHeight
1201 - fgkSSDModuleVerticalDisalignment2));
bf210566 1202 fhybridmatrix = new TGeoHMatrix();
1203 for(Int_t i=0; i<khybridmatrixnumber; i++) fhybridmatrix->MultiplyLeft(localhybridtrans[i]);
1204 /////////////////////////////////////////////////////////////
1205 // SSD Cooling Block Transformations
1206 /////////////////////////////////////////////////////////////
1207 const Int_t kcoolingblockmatrixnumber = 4;
1208 TGeoTranslation* localcoolingblocktrans[kcoolingblockmatrixnumber];
1209 localcoolingblocktrans[0] = new TGeoTranslation(-2.*(fgkCoolingTubeSupportRmax
1210 - fgkCoolingTubeSupportRmin),0.0,
1211 0.5*(fgkSSDCoolingBlockHoleCenter+fgkCoolingTubeRmax));
1212 localcoolingblocktrans[1] = new TGeoTranslation(0.5*fgkSSDStiffenerLength
1213 - 0.5*fgkSSDModuleSensorSupportDistance-fgkSSDCoolingBlockLength,
1214 0.0,fgkSSDStiffenerHeight);
1215 localcoolingblocktrans[2] = new TGeoTranslation(*localhybridtrans[1]);
1216 localcoolingblocktrans[3] = new TGeoTranslation(*localhybridtrans[2]);
1217 fcoolingblocksystematrix = new TGeoHMatrix();
1218 for(Int_t i=0; i<kcoolingblockmatrixnumber; i++)
1219 fcoolingblocksystematrix->MultiplyLeft(localcoolingblocktrans[i]);
1220 /////////////////////////////////////////////////////////////
1221 // SSD Stiffener Flex Transformations
1222 /////////////////////////////////////////////////////////////
1223 const Int_t klocalflexmatrixnumber = 4;
1224 TGeoCombiTrans** localflexmatrix[fgkflexnumber];
1225 for(Int_t i=0; i<fgkflexnumber; i++)
1226 localflexmatrix[i] = new TGeoCombiTrans*[klocalflexmatrixnumber];
1227 for(Int_t i=0; i<fgkflexnumber; i++)
1228 for(Int_t j =0; j<klocalflexmatrixnumber; j++)
1229 localflexmatrix[i][j] = new TGeoCombiTrans();
1230 Double_t ssdstiffenerseparation = fgkSSDSensorLength
1231 - 2.*fgkSSDModuleStiffenerPosition[1]
1232 - fgkSSDStiffenerWidth;
1233 localflexmatrix[0][0]->SetTranslation(-fgkSSDFlexLength[0]
1234 +0.5*fgkSSDStiffenerLength,
1235 0.5*fgkSSDStiffenerWidth,
1236 -0.5*fgkSSDStiffenerHeight
1237 -0.5*fgkSSDFlexHeight[0]);
1238 localflexmatrix[1][0]->SetTranslation(-(fgkSSDStiffenerLength-fgkSSDFlexLength[0])
1239 +0.5*fgkSSDStiffenerLength,ssdstiffenerseparation
1240 -0.5*fgkSSDStiffenerWidth,
1241 -0.5*fgkSSDStiffenerHeight
1242 -0.5*fgkSSDFlexHeight[0]);
1243 TGeoRotation* localflexrot = new TGeoRotation();
1244 localflexrot->SetAngles(180.,0.,0.);
1245 localflexmatrix[1][0]->SetRotation(localflexrot);
1246 for(Int_t i=0; i<fgkflexnumber; i++)
1247 for(Int_t j =1; j<klocalflexmatrixnumber; j++)
1248 localflexmatrix[i][j]->SetTranslation(*localhybridtrans[j-1]);
1249 for(Int_t i=0; i<fgkflexnumber; i++){
1250 fstiffenerflexmatrix[i] = new TGeoHMatrix();
1251 for(Int_t j =0; j<klocalflexmatrixnumber; j++)
1252 fstiffenerflexmatrix[i]->MultiplyLeft(localflexmatrix[i][j]);
d7599219 1253 }
bf210566 1254 /////////////////////////////////////////////////////////////
1255 // SSD End Flex Transformations
1256 /////////////////////////////////////////////////////////////
1257 TGeoRotation* localendflexrot = new TGeoRotation();
1258 localendflexrot->SetAngles(0.0,90.0,0.0);
1259 TGeoCombiTrans* localendflexmatrix = new TGeoCombiTrans();
1260 Double_t ssdflexradiusmax = (fgkSSDFlexLength[3]-fgkSSDFlexLength[2])
1261 / TMath::Tan(fgkSSDFlexAngle*TMath::DegToRad());
1262 Double_t ssdflexboxlength = fgkSSDFlexFullLength-2.*fgkSSDFlexAngle
1263 * TMath::DegToRad()*ssdflexradiusmax
1264 - fgkSSDFlexLength[2]-TMath::Pi()
1265 * fgkSSDStiffenerHeight-fgkSSDFlexLength[0];
1266 Double_t trans = ssdflexboxlength*CosD(2.*fgkSSDFlexAngle)
1267 + (ssdflexradiusmax-fgkSSDStiffenerHeight)*SinD(2.*fgkSSDFlexAngle)
1268 + fgkSSDFlexLength[2];
1269 localendflexmatrix->SetTranslation(fgkSSDFlexLength[0]-trans,
1270 0.5*fgkSSDFlexWidth[0],
1271 2.*fgkSSDStiffenerHeight
1272 + 0.5*fgkSSDFlexHeight[0]);
1273 localendflexmatrix->SetRotation(localendflexrot);
1274 for(Int_t i=0; i<fgkflexnumber; i++)
1275 fendflexmatrix[i] = new TGeoHMatrix((*fstiffenerflexmatrix[i])*(*localendflexmatrix));
1276 /////////////////////////////////////////////////////////////
1277 // End Ladder Carbon Fiber Junction
1278 /////////////////////////////////////////////////////////////
1279 TGeoCombiTrans** localendladdercarbonfiberjunctionmatrix[fgkendlabbercarbonfiberjunctionumber];
1280 TGeoRotation** localendladdercarbonfiberjunctionrot[fgkendlabbercarbonfiberjunctionumber];
1281 TGeoTranslation** localendladdercarbonfiberjunctiontrans[fgkendlabbercarbonfiberjunctionumber];
1282 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++){
1283 localendladdercarbonfiberjunctionmatrix[i]
1284 = new TGeoCombiTrans*[fgkendladdercabonfiberjunctionmatrixnumber];
1285 localendladdercarbonfiberjunctionrot[i]
1286 = new TGeoRotation*[fgkendladdercabonfiberjunctionmatrixnumber];
1287 localendladdercarbonfiberjunctiontrans[i]
1288 = new TGeoTranslation*[fgkendladdercabonfiberjunctionmatrixnumber];
1289 fendladdercarbonfiberjunctionmatrix[i]
1290 = new TGeoHMatrix*[fgkendladdercabonfiberjunctionmatrixnumber];
d7599219 1291 }
bf210566 1292 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++)
1293 for(Int_t j=0; j<fgkendladdercabonfiberjunctionmatrixnumber; j++){
1294 localendladdercarbonfiberjunctionrot[i][j] = new TGeoRotation();
1295 localendladdercarbonfiberjunctiontrans[i][j] = new TGeoTranslation();
1296 }
1297 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++)
1298 for(Int_t j=0; j<fgkendladdercabonfiberjunctionmatrixnumber; j++)
1299 localendladdercarbonfiberjunctionrot[i][j]->SetAngles(120.*j,0.,0.);
1300 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++){
1301 localendladdercarbonfiberjunctiontrans[i][1]->SetTranslation(fgkCarbonFiberTriangleLength,
1302 0.0,0.0);
1303 localendladdercarbonfiberjunctiontrans[i][2]->SetTranslation(fgkCarbonFiberTriangleLength
1304 * CosD(fgkCarbonFiberTriangleAngle),fgkCarbonFiberTriangleLength
1305 * SinD(fgkCarbonFiberTriangleAngle),
1306 0.5*(fgkEndLadderCarbonFiberLowerJunctionLength[i]
1307 - fgkEndLadderCarbonFiberUpperJunctionLength[i]));
1308 }
1309 TGeoCombiTrans* localendladdercarbonfiberjunctionglobalmatrix[fgkendlabbercarbonfiberjunctionumber];
1310 TGeoRotation* localendladdercarbonfiberjunctionglobalrot[fgkendlabbercarbonfiberjunctionumber];
1311 TGeoTranslation* localendladdercarbonfiberjunctionglobaltrans[fgkendlabbercarbonfiberjunctionumber];
1312 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++){
1313 localendladdercarbonfiberjunctionglobalrot[i] = new TGeoRotation();
1314 localendladdercarbonfiberjunctionglobaltrans[i] = new TGeoTranslation();
1315 localendladdercarbonfiberjunctionglobalrot[i]->SetAngles(0.0,90.0,0.0);
1316 localendladdercarbonfiberjunctionglobaltrans[i]->SetTranslation(0.0,
1317 0.5*fgkEndLadderCarbonFiberLowerJunctionLength[i],0.0);
1318 localendladdercarbonfiberjunctionglobalmatrix[i] =
1319 new TGeoCombiTrans(*localendladdercarbonfiberjunctionglobaltrans[i],
1320 *localendladdercarbonfiberjunctionglobalrot[i]);
1321 }
1322 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++)
1323 for(Int_t j=0; j<fgkendladdercabonfiberjunctionmatrixnumber; j++){
1324 localendladdercarbonfiberjunctionmatrix[i][j] =
1325 new TGeoCombiTrans(*localendladdercarbonfiberjunctiontrans[i][j],
1326 *localendladdercarbonfiberjunctionrot[i][j]);
1327 fendladdercarbonfiberjunctionmatrix[i][j] =
1328 new TGeoHMatrix((*localendladdercarbonfiberjunctionglobalmatrix[i])
1329 * (*localendladdercarbonfiberjunctionmatrix[i][j]));
1330 }
1331 /////////////////////////////////////////////////////////////
1332 // End Ladder Carbon Fiber Support
1333 /////////////////////////////////////////////////////////////
1334 TGeoTranslation* localendladdercarbonfibertrans[fgkendladdercarbonfibermatrixnumber];
1335 for(Int_t i=0; i<fgkendladdercarbonfibermatrixnumber; i++){
1336 localendladdercarbonfibertrans[i] = new TGeoTranslation();
1337 localendladdercarbonfibertrans[i]->SetTranslation(0.0,
1338 i==0 ? 0.0 :fgkCarbonFiberLowerSupportWidth,0.0);
1339 fendladdercarbonfibermatrix[i] = new TGeoHMatrix*[fgkcarbonfibersupportnumber];
1340 }
1341 for(Int_t i=0; i<fgkendladdercarbonfibermatrixnumber; i++)
1342 for(Int_t j=0; j<fgkcarbonfibersupportnumber; j++)
1343 fendladdercarbonfibermatrix[i][j] =
1344 new TGeoHMatrix((*localendladdercarbonfibertrans[i])
1345 *(*fcarbonfibersupportmatrix[j]));
1346 /////////////////////////////////////////////////////////////
1347 // End Ladder SSD Mounting Block
1348 /////////////////////////////////////////////////////////////
1349 for(Int_t i=0; i<fgkendladdermountingblocknumber; i++)
9b0c60ab 1350 fendladdermountingblockcombitrans[i] = new TGeoCombiTrans();
1351 for(Int_t i=0; i<fgkendladdermountingblocknumber; i++)
1352 fendladdermountingblockcombitrans[i]->SetTranslation(- 0.25*(fgkSSDMountingBlockLength[0]
bf210566 1353 + fgkSSDMountingBlockLength[1])
1354 + 0.5*fgkCarbonFiberTriangleLength,
1355 fgkEndLadderMountingBlockPosition[i],
1356 - fgkSSDMountingBlockHeight[1]
1357 + 0.5*fgkSSDMountingBlockHeight[0]);
9b0c60ab 1358 TGeoRotation* endladdermountingblockrot = new TGeoRotation();
1359 endladdermountingblockrot->SetAngles(0.,90.,0.);
1360 for(Int_t i=0; i<fgkendladdermountingblocknumber; i++)
1361 fendladdermountingblockcombitrans[i]->SetRotation(*endladdermountingblockrot);
1362 /////////////////////////////////////////////////////////////
1363 // End Ladder SSD Mounting Block Clip Matrix
1364 /////////////////////////////////////////////////////////////
1365 for(Int_t i=0; i<fgkendladdermountingblocknumber; i++)
1366 fendladdermountingblockclipmatrix[i] = new TGeoHMatrix*[2];
1367
1368 TGeoRotation* localendladdercliprot = new TGeoRotation();
1369 TGeoTranslation* localendladdercliptrans = new TGeoTranslation();
1370 localendladdercliptrans->SetTranslation(-0.5*(fgkSSDMountingBlockLength[0]
1371 - fgkSSDMountingBlockLength[1])
1372 + fgkSSDMountingBlockLength[0],0.,0.);
1373 localendladdercliprot->SetAngles(90.,180.,-90.);
1374 TGeoCombiTrans* localendladderclipcombitrans =
1375 new TGeoCombiTrans(*localendladdercliptrans,*localendladdercliprot);
1376 for(Int_t i=0; i<fgkendladdermountingblocknumber; i++)
1377 for(Int_t j=0; j<2; j++){
1378 fendladdermountingblockclipmatrix[i][j] =
1379 new TGeoHMatrix(*fendladdermountingblockcombitrans[i]);
1380 if(j!=0) fendladdermountingblockclipmatrix[i][j]->Multiply(localendladderclipcombitrans);
1381 }
bf210566 1382 /////////////////////////////////////////////////////////////
1383 // End Ladder Carbon Fiber Lower Support
1384 /////////////////////////////////////////////////////////////
1385 for(Int_t i=0; i<fgkendladderlowersuppnumber; i++)
1386 fendladderlowersupptrans[i] =
1387 new TGeoTranslation(0.0,(1-i)*(fgkEndLadderMountingBlockPosition[i]
1388 + 0.5*fgkSSDMountingBlockWidth),
1389 - 0.5*fgkCarbonFiberLowerSupportHeight);
1390 fendladderlowersupptrans[2] = new TGeoTranslation(0.0,
1391 fgkCarbonFiberLowerSupportVolumePosition[1]
1392 + fgkCarbonFiberLowerSupportVolumePosition[0],
1393 0.0);
1394 fendladderlowersupptrans[2]->Add(fendladderlowersupptrans[1]);
1395 /////////////////////////////////////////////////////////////
1396 // Matrix for positioning Ladder into mother volume
1397 /////////////////////////////////////////////////////////////
1398 TGeoHMatrix** ladderglobalmatrix[fgkladdernumber];
1399 for(Int_t i=0; i<fgkladdernumber; i++)
1400 ladderglobalmatrix[i] = new TGeoHMatrix*[fgkladdernumber];
1401 TGeoRotation* localladdermotherrot = new TGeoRotation();
1402 localladdermotherrot->SetAngles(0.,90.,0.);
1403 TGeoTranslation* localladdermothertrans[fgkladdernumber];
1404 TGeoCombiTrans* localladdermothercombitrans[fgkladdernumber];
1405 for(Int_t i=0; i<fgkladdernumber; i++){
1406 localladdermothertrans[i] = new TGeoTranslation(0.,
1407 - fgkEndLadderCarbonFiberLowerJunctionLength[1]
1408 + fgkEndLadderCarbonFiberLowerJunctionLength[0]
1409 + (i==0?fgkSSDLay5SensorsNumber:fgkSSDLay6SensorsNumber)
1410 * fgkCarbonFiberJunctionWidth,0.);
1411 localladdermothercombitrans[i] = new TGeoCombiTrans(*localladdermothertrans[i],
1412 *localladdermotherrot);
1413 ladderglobalmatrix[0][i] = new TGeoHMatrix(*localladdermothercombitrans[i]);
1414 ladderglobalmatrix[1][i] = new TGeoHMatrix(ladderglobalmatrix[0][i]->Inverse());
d7599219 1415 }
44285dfa 1416 /////////////////////////////////////////////////////////////
bf210566 1417 // Ladder Cables Matrices
44285dfa 1418 /////////////////////////////////////////////////////////////
44285dfa 1419 Double_t ssdflexradius = fgkSSDStiffenerHeight+2*fgkSSDFlexHeight[0]
d7599219 1420 + fgkSSDFlexHeight[1];
44285dfa 1421 Double_t ssdladdercabletransx[3];
1422 ssdladdercabletransx[0] = (ssdflexradiusmax-fgkSSDFlexHeight[1]-ssdflexradius)
bf210566 1423 * SinD(2.*fgkSSDFlexAngle)
1424 * CosD(2.*fgkSSDFlexAngle);
44285dfa 1425 ssdladdercabletransx[1] = ((ssdflexradiusmax-fgkSSDFlexHeight[1]-ssdflexradius)
1426 - ssdladdercabletransx[0]
bf210566 1427 / SinD(2.*fgkSSDFlexAngle))
1428 * CosD(fgkSSDFlexAngle);
44285dfa 1429 ssdladdercabletransx[2] = (fgkSSDFlexFullLength-2.*fgkSSDFlexAngle
1430 * TMath::DegToRad()*ssdflexradiusmax
d7599219 1431 - fgkSSDFlexLength[2]-TMath::Pi()
1432 * fgkSSDStiffenerHeight-fgkSSDFlexLength[0]
1433 - fgkSSDLadderCableWidth)
bf210566 1434 * CosD(2.*fgkSSDFlexAngle);
44285dfa 1435 Double_t ssdladdercabletransz[3] = {ssdladdercabletransx[0]
bf210566 1436 * TanD(2.*fgkSSDFlexAngle),
44285dfa 1437 ssdladdercabletransx[1]
bf210566 1438 * TanD(fgkSSDFlexAngle),
44285dfa 1439 ssdladdercabletransx[2]
bf210566 1440 * TanD(2.*fgkSSDFlexAngle)};
44285dfa 1441 TGeoRotation* localladdercablerot[3];
bf210566 1442 for(Int_t i=0; i<3; i++) localladdercablerot[i] = new TGeoRotation();
1443 localladdercablerot[0]->SetAngles(90.,0.,0.);
1444 localladdercablerot[1]->SetAngles(90.,60.,-90.);
44285dfa 1445 localladdercablerot[2]->SetRotation((*localladdercablerot[1])
1446 * (*localladdercablerot[0]));
1447 ////////////////////////////////////////////
1448 // LocalLadderCableCombiTransMatrix
1449 ////////////////////////////////////////////
1450 const Int_t klocalladdersidecablesnumber = 2;
1451 const Int_t klocalladdercombitransnumber = 5;
1452 TGeoCombiTrans** localladdercablecombitransmatrix[klocalladdersidecablesnumber];
1453 for(Int_t i=0; i<klocalladdersidecablesnumber; i++)
1454 localladdercablecombitransmatrix[i] =
1455 new TGeoCombiTrans*[klocalladdercombitransnumber];
1456 ///////////////////////////////////////////
1457 // Left Side Ladder Cables Transformations
1458 ///////////////////////////////////////////
1459 localladdercablecombitransmatrix[0][0] =
d7599219 1460 new TGeoCombiTrans(-0.5*fgkCarbonFiberTriangleLength,
1461 0.,0.,NULL);
bf210566 1462 localladdercablecombitransmatrix[0][1] =
1463 new TGeoCombiTrans(-0.5*(fgkSSDSensorWidth-fgkCarbonFiberTriangleLength),
1464 - (2.*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1465 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1466 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1467 - 0.5*(fgkCarbonFiberLowerSupportWidth
1468 + fgkSSDSensorCenterSupportLength
1469 - fgkSSDSensorCenterSupportThickness[0]),
1470 - (fgkSSDModuleCoolingBlockToSensor
1471 + 0.5*fgkCoolingTubeSupportHeight
1472 - fgkSSDSensorHeight-fgkSSDChipCablesHeight[3]
1473 - fgkSSDChipHeight),NULL);
44285dfa 1474 localladdercablecombitransmatrix[0][2] =
d7599219 1475 new TGeoCombiTrans(fgkSSDModuleStiffenerPosition[0],
1476 fgkSSDModuleStiffenerPosition[1],0.,0);
bf210566 1477 localladdercablecombitransmatrix[0][3] = new TGeoCombiTrans(
1478 0.5*(fgkSSDStiffenerLength+fgkSSDChipNumber*fgkSSDChipLength
1479 +(fgkSSDChipNumber-1)*fgkSSDChipSeparationLength),
1480 fgkSSDSensorLength-2.*fgkSSDModuleStiffenerPosition[1]
1481 - fgkSSDStiffenerWidth,- 0.5*fgkSSDChipHeight,
1482 new TGeoRotation("",180.,0.,0.));
44285dfa 1483 localladdercablecombitransmatrix[0][4] =
1484 new TGeoCombiTrans(-ssdladdercabletransx[0]
1485 - ssdladdercabletransx[1]-ssdladdercabletransx[2]
d7599219 1486 + fgkSSDFlexLength[0]-fgkSSDFlexLength[2],
1487 0.,
1488 0.5*fgkSSDFlexHeight[0]+2.*(fgkSSDFlexHeight[0]
1489 + fgkSSDFlexHeight[1])+2.*fgkSSDStiffenerHeight
44285dfa 1490 + ssdladdercabletransz[0]-ssdladdercabletransz[1]
1491 + ssdladdercabletransz[2],localladdercablerot[2]);
1492 ///////////////////////////////////////////
1493 // Rigth Side Ladder Cables Transformations
1494 ///////////////////////////////////////////
bf210566 1495 TGeoCombiTrans* localladdercablessdmodulematrix =
1496 new TGeoCombiTrans(0.5*(fgkSSDStiffenerLength-fgkSSDChipNumber*fgkSSDChipLength
1497 - (fgkSSDChipNumber-1)*fgkSSDChipSeparationLength),
1498 fgkSSDStiffenerWidth,
1499 - 0.5*fgkSSDFlexHeight[0],NULL);
44285dfa 1500 for(Int_t i=0; i<klocalladdercombitransnumber; i++)
1501 localladdercablecombitransmatrix[1][i] =
bf210566 1502 (i!=3 ? new TGeoCombiTrans(*localladdercablecombitransmatrix[0][i]):
1503 new TGeoCombiTrans(*localladdercablessdmodulematrix));
44285dfa 1504 ///////////////////////////////////////////
bf210566 1505 // Setting LadderCableHMatrix
44285dfa 1506 ///////////////////////////////////////////
bf210566 1507 Int_t beamaxistrans[2][3];
1508 beamaxistrans[0][0] = fgkSSDLay5SensorsNumber/2;
1509 beamaxistrans[0][1] = beamaxistrans[0][0]+1;
1510 beamaxistrans[0][2] = beamaxistrans[0][0]-1;
1511 beamaxistrans[1][0] = (fgkSSDLay6SensorsNumber-1)/2;
1512 beamaxistrans[1][1] = beamaxistrans[1][0]+1;
1513 beamaxistrans[1][2] = beamaxistrans[1][0];
1514 TGeoHMatrix** localladdercablehmatrix[fgkladdercablesnumber];
1515 TGeoRotation* laddercablerot = new TGeoRotation();
1516 TGeoTranslation* laddercabletrans = new TGeoTranslation();
1517 TGeoCombiTrans* laddercablecombitrans = new TGeoCombiTrans();
1518 Double_t* laddercabletransvector;
1519 for(Int_t i=0; i<fgkladdercablesnumber; i++){
1520 localladdercablehmatrix[i] = new TGeoHMatrix*[klocalladdersidecablesnumber];
1521 fladdercablematrix[i] = new TGeoHMatrix*[fgkladdercablematrixnumber];
1522 }
1523 for(Int_t i=0; i<fgkladdercablesnumber; i++){
1524 for(Int_t j=0; j<klocalladdersidecablesnumber; j++){
1525 localladdercablehmatrix[i][j] = new TGeoHMatrix();
1526 for(Int_t k=0; k<klocalladdercombitransnumber; k++){
1527 localladdercablehmatrix[i][j]->MultiplyLeft(
1528 localladdercablecombitransmatrix[j][klocalladdercombitransnumber-k-1]);
1529 }
1530 laddercablerot->SetMatrix(localladdercablehmatrix[i][j]->GetRotationMatrix());
1531 laddercabletransvector = localladdercablehmatrix[i][j]->GetTranslation();
1532 laddercabletrans->SetTranslation(laddercabletransvector[0],
44285dfa 1533 laddercabletransvector[1]
bf210566 1534 + (j==0 ? beamaxistrans[i][0] : 0.)
d7599219 1535 * fgkCarbonFiberJunctionWidth,
bf210566 1536 laddercabletransvector[2]);
1537 laddercablecombitrans->SetRotation(*laddercablerot);
1538 laddercablecombitrans->SetTranslation(*laddercabletrans);
1539 fladdercablematrix[i][j] = new TGeoHMatrix(*laddercablecombitrans);
1540 }
1541 fladdercablematrix[i][2] =
1542 AddTranslationToHMatrix(fladdercablematrix[i][1],0.,
1543 beamaxistrans[i][1]*fgkCarbonFiberJunctionWidth,0.);
1544 fladdercablematrix[i][3] =
1545 AddTranslationToHMatrix(fladdercablematrix[i][0],0.,
1546 beamaxistrans[i][2]*fgkCarbonFiberJunctionWidth,0.);
d7599219 1547 }
bf210566 1548 for(Int_t i=0; i<fgkladdercablesnumber; i++)
1549 for(Int_t j=0; j<klocalladdercombitransnumber-1; j++)
1550 fladdercablematrix[i][j]->MultiplyLeft(ladderglobalmatrix[1][i]);
1551 ///////////////////////////////////////////
1552 // Setting Ladder HMatrix
1553 ///////////////////////////////////////////
1554 Int_t ssdlaysensorsnumber[fgkladdernumber] = {fgkSSDLay5SensorsNumber,
1555 fgkSSDLay6SensorsNumber};
1556 for(Int_t i=0; i<fgkladdernumber; i++){
1557 fladdermatrix[i] = new TGeoHMatrix*[ssdlaysensorsnumber[i]];
1558 for(Int_t j=0; j<ssdlaysensorsnumber[i]; j++){
1559 fladdermatrix[i][j] = new TGeoHMatrix();
1560 fladdermatrix[i][j]->SetDx(-0.5*fgkCarbonFiberTriangleLength);
1561 fladdermatrix[i][j]->SetDy(fgkCarbonFiberJunctionWidth*j);
1562 fladdermatrix[i][j]->MultiplyLeft(ladderglobalmatrix[1][i]);
1563 }
d7599219 1564 }
bf210566 1565 ///////////////////////////////////////////
1566 // Setting SSD Sensor Matrix
1567 ///////////////////////////////////////////
1568 TGeoCombiTrans* localssdsensorcombitrans[2];
1569 TGeoRotation* localssdsensorrot = new TGeoRotation();
1570 localssdsensorrot->SetAngles(0.,90.,0.);
1571 TGeoTranslation* localssdsensortrans[2];
1572 for(Int_t i=0; i<2; i++) localssdsensortrans[i] = new TGeoTranslation();
1573 localssdsensortrans[0]->SetTranslation(0.5*fgkCarbonFiberTriangleLength,
1574 - (2.*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1575 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1576 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1577 - 0.5*(fgkCarbonFiberLowerSupportWidth+fgkSSDSensorCenterSupportLength
1578 - fgkSSDSensorCenterSupportThickness[0])+0.5*fgkSSDSensorLength,
1579 0.5*fgkSSDSensorHeight-0.5*fgkCoolingTubeSupportHeight
02d4acf9 1580 - fgkSSDModuleCoolingBlockToSensor-0.5*fgkSSDModuleVerticalDisalignment
e21cdd03 1581 + (fgkSSDSensorSideSupportHeight[1]
ca86fdb4 1582 - fgkSSDSensorSideSupportHeight[0])
1583 + 0.5*fgkSSDModuleVerticalDisalignment2);
bf210566 1584 localssdsensortrans[1]->SetTranslation(0.5*fgkCarbonFiberTriangleLength,
1585 - (2.*fgkSSDSensorLength-fgkSSDSensorOverlap)+
1586 fgkSSDModuleStiffenerPosition[1]+fgkSSDStiffenerWidth
1587 + 0.5*fgkSSDFlexHoleLength+2.*fgkCarbonFiberJunctionWidth
1588 - 0.5*(fgkCarbonFiberLowerSupportWidth+fgkSSDSensorCenterSupportLength
1589 - fgkSSDSensorCenterSupportThickness[0])+0.5*fgkSSDSensorLength,
1590 0.5*fgkSSDSensorHeight-0.5*fgkCoolingTubeSupportHeight
ca86fdb4 1591 -fgkSSDModuleCoolingBlockToSensor-0.5*fgkSSDModuleVerticalDisalignment
1592 + 0.5*fgkSSDModuleVerticalDisalignment2);
bf210566 1593 for(Int_t i=0; i<2; i++)
1594 localssdsensorcombitrans[i] = new TGeoCombiTrans(*localssdsensortrans[i],
1595 *localssdsensorrot);
1596 for(Int_t i=0; i<fgkladdernumber; i++){
1597 fssdsensormatrix[i] = new TGeoHMatrix*[ssdlaysensorsnumber[i]];
1598 for(Int_t j=0; j<ssdlaysensorsnumber[i]; j++){
1599 switch(i){
1600 case 0: //Ladder of Layer5
1601 fssdsensormatrix[i][j] = new TGeoHMatrix((*fladdermatrix[i][j])
1602 * ((j%2==0 ? *localssdsensorcombitrans[0] :
1603 *localssdsensorcombitrans[1])));
1604 break;
1605 case 1: //Ladder of Layer6
1606 fssdsensormatrix[i][j] = new TGeoHMatrix((*fladdermatrix[i][j])
1607 * ((j%2==0 ? *localssdsensorcombitrans[1] :
1608 *localssdsensorcombitrans[0])));
1609 break;
1610 }
1611 }
1612 }
1613 //////////////////////////
1614 // Setting SSD End Ladder
1615 //////////////////////////
1616 for(Int_t i=0; i<2; i++) fendladdersegmentmatrix[i] = new TGeoHMatrix*[2];
1617 for(Int_t i=0; i<2; i++){
1618 fendladdersegmentmatrix[0][i] = new TGeoHMatrix();
1619 fendladdersegmentmatrix[0][i]->SetDx(-0.5*fgkCarbonFiberTriangleLength);
1620 fendladdersegmentmatrix[0][i]->SetDy(fgkCarbonFiberJunctionWidth*ssdlaysensorsnumber[i]);
1621 fendladdersegmentmatrix[0][i]->MultiplyLeft(ladderglobalmatrix[1][i]);
1622 fendladdersegmentmatrix[1][i] = new TGeoHMatrix();
1623 fendladdersegmentmatrix[1][i]->SetDx(-0.5*fgkCarbonFiberTriangleLength);
1624 fendladdersegmentmatrix[1][i]->RotateZ(180.0);
1625 fendladdersegmentmatrix[1][i]->MultiplyLeft(ladderglobalmatrix[1][i]);
1626 }
1627 /////////////////////////////////////////////////////
1628 // Setting the CombiTransformation to pass ITS center
1629 /////////////////////////////////////////////////////
1630 Double_t itscentertransz[fgklayernumber];
1631 itscentertransz[0] = fgkSSDLay5LadderLength
1632 - fgkLay5CenterITSPosition;
1633 itscentertransz[1] = fgkSSDLay6LadderLength
1634 - fgkLay6CenterITSPosition;
1635 Double_t itssensortransy = fgkSSDModuleCoolingBlockToSensor
1636 + 0.5*fgkCoolingTubeSupportHeight;
1637 TGeoRotation* itscenterrot[3];
1638 for(Int_t i=0; i<fgklayernumber; i++) itscenterrot[i] = new TGeoRotation();
1639 itscenterrot[0]->SetAngles(90.,180.,-90.);
1640 itscenterrot[1]->SetAngles(0.,90.,0.);
1641 itscenterrot[2] = new TGeoRotation((*itscenterrot[1])*(*itscenterrot[0]));
1642 TGeoCombiTrans* itscentercombitrans[fgklayernumber];
1643 for(Int_t i=0; i<fgklayernumber; i++)
1644 itscentercombitrans[i] = new TGeoCombiTrans(0.,
1645 itssensortransy,
1646 fgkEndLadderCarbonFiberLowerJunctionLength[1]
1647 - itscentertransz[i],itscenterrot[2]);
1648 TGeoRotation** locallayerrot[fgklayernumber];
1649 TGeoTranslation** locallayertrans[fgklayernumber];
1650 TGeoCombiTrans** locallayercombitrans[fgklayernumber];
1651 TGeoTranslation* localbeamaxistrans[fgklayernumber];
1652 localbeamaxistrans[0] = new TGeoTranslation(0.,0.,0.5*fgkSSDLay5LadderLength
1653 - fgkLay5CenterITSPosition);
1654 localbeamaxistrans[1] = new TGeoTranslation(0.,0.,0.5*fgkSSDLay6LadderLength
1655 - fgkLay6CenterITSPosition);
1656 const Int_t kssdlayladdernumber[fgklayernumber] =
1657 {fgkSSDLay5LadderNumber,fgkSSDLay6LadderNumber};
1658 for(Int_t i=0; i<fgklayernumber; i++){
1659 locallayerrot[i] = new TGeoRotation*[kssdlayladdernumber[i]];
1660 locallayertrans[i] = new TGeoTranslation*[kssdlayladdernumber[i]];
1661 locallayercombitrans[i] = new TGeoCombiTrans*[kssdlayladdernumber[i]];
1662 flayermatrix[i] = new TGeoHMatrix*[kssdlayladdernumber[i]];
d7599219 1663 }
bf210566 1664 Double_t layerladderangleposition[fgklayernumber] =
1665 {360./fgkSSDLay5LadderNumber,360./fgkSSDLay6LadderNumber};
1666 Double_t layerradius = 0.;
1667 for(Int_t i=0; i<fgklayernumber; i++){
1668 for(Int_t j=0; j<kssdlayladdernumber[i]; j++){
1669 switch(i){
1670 case 0: //Ladder of Layer5
1671 layerradius = (j%2==0 ? fgkSSDLay5RadiusMin: fgkSSDLay5RadiusMax);
1672 break;
1673 case 1: //Ladder of Layer6
1674 layerradius = (j%2==0 ? fgkSSDLay6RadiusMin: fgkSSDLay6RadiusMax);
1675 break;
1676 }
1677 locallayerrot[i][j] = new TGeoRotation();
1678 locallayertrans[i][j] = new TGeoTranslation();
1679 locallayerrot[i][j]->SetAngles(j*layerladderangleposition[i],0.,0.);
1680 locallayertrans[i][j]->SetTranslation(layerradius
1681 * CosD(90.0+j*layerladderangleposition[i]),
1682 layerradius
1683 * SinD(90.0+j*layerladderangleposition[i]),0.);
1684 locallayercombitrans[i][j] = new TGeoCombiTrans(*locallayertrans[i][j],
1685 *locallayerrot[i][j]);
1686 flayermatrix[i][j] = new TGeoHMatrix((*locallayercombitrans[i][j])*(*itscentercombitrans[i]));
1687 flayermatrix[i][j]->Multiply(ladderglobalmatrix[0][i]);
1688 flayermatrix[i][j]->MultiplyLeft(localbeamaxistrans[i]);
d7599219 1689 }
bf210566 1690 }
44285dfa 1691 /////////////////////////////////////////////////////////////
bf210566 1692 // Deallocating memory
44285dfa 1693 /////////////////////////////////////////////////////////////
bf210566 1694 for(Int_t i=0; i< kcarbonfibersupportmatrixnumber[1]; i++){
1695 delete carbonfiberot[i];
1696 delete localcarbonfibersupportmatrix[i];
d7599219 1697 }
bf210566 1698 for(Int_t i=0; i< fgkcarbonfiberjunctionumber; i++){
1699 for(Int_t j=0; j< kcarbonfiberjunctionmatrixnumber; j++){
1700 delete localcarbonfiberjunctionmatrix[i][j];
1701 delete localcarbonfiberjunctionrot[i][j];
1702 delete localcarbonfiberjunctiontrans[i][j];
1703 }
1704 delete [] localcarbonfiberjunctionmatrix[i];
1705 delete [] localcarbonfiberjunctionrot[i];
1706 delete [] localcarbonfiberjunctiontrans[i];
d7599219 1707 }
bf210566 1708 for(Int_t i=0; i<fgkcarbonfiberlowersupportnumber; i++)
1709 delete localcarbonfiberlowersupportrans[i];
1710 for(Int_t i=0; i< fgkssdsensorsupportnumber; i++){
1711 for(Int_t j=0; j< kssdsensorsupportmatrixnumber; j++){
1712 delete localssdsensorsupportmatrix[i][j];
1713 delete localssdsensorsupportrot[i][j];
1714 delete localssdsensorsupportrans[i][j];
1715 }
1716 delete [] localssdsensorsupportmatrix[i];
1717 delete [] localssdsensorsupportrot[i];
1718 delete [] localssdsensorsupportrans[i];
d7599219 1719 }
bf210566 1720 for(Int_t i=0; i<kcoolingtubesupportmatrixnumber; i++){
1721 delete localcoolingtubesupportmatrix[i];
1722 delete localcoolingtubesupportrot[i];
1723 delete localcoolingtubesupportrans[i];
1724 }
1725 for(Int_t i=0; i<4; i++){
1726 for(Int_t j=0; j<2; j++){
1727 delete localcoolingtubevect[i][j];
1728 delete localcoolingtubetrans[i][j];
1729 }
1730 delete [] localcoolingtubevect[i];
1731 delete [] localcoolingtubetrans[i];
1732 }
9b0c60ab 1733 delete endladdermountingblockrot;
bf210566 1734 for(Int_t i=0; i<khybridmatrixnumber; i++) delete localhybridtrans[i];
1735 for(Int_t i=0; i<kcoolingblockmatrixnumber; i++) delete localcoolingblocktrans[i];
1736 for(Int_t i=0; i<fgkflexnumber; i++){
1737 for(Int_t j=1; j<klocalflexmatrixnumber; j++)
1738 delete localflexmatrix[i][j];
1739 delete [] localflexmatrix[i];
1740 }
9b0c60ab 1741 delete localendlladdercoolingtuberot;
1742 for(Int_t i=0; i<2; i++){
1743 for(Int_t j=0; j<(i==0?6:4); j++)
1744 delete localendlladdercoolingtubetrans[i][j];
1745 delete [] localendlladdercoolingtubetrans[i];
1746 }
1747
bf210566 1748 delete localflexrot;
1749 delete localendflexrot;
1750 delete localendflexmatrix;
1751 for(Int_t i=0; i<fgkladdernumber; i++){
1752 delete localladdermothertrans[i];
1753 delete localladdermothercombitrans[i];
1754 }
1755 delete localladdermotherrot;
1756 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++){
1757 for(Int_t j=0; j<fgkendladdercabonfiberjunctionmatrixnumber; j++){
1758 delete localendladdercarbonfiberjunctionmatrix[i][j];
1759 delete localendladdercarbonfiberjunctionrot[i][j];
1760 delete localendladdercarbonfiberjunctiontrans[i][j];
1761 }
1762 delete [] localendladdercarbonfiberjunctionmatrix[i];
1763 delete [] localendladdercarbonfiberjunctionrot[i];
1764 delete [] localendladdercarbonfiberjunctiontrans[i];
1765 delete localendladdercarbonfiberjunctionglobalrot[i];
1766 delete localendladdercarbonfiberjunctionglobaltrans[i];
1767 delete localendladdercarbonfiberjunctionglobalmatrix[i];
1768 }
9b0c60ab 1769 for(Int_t i=0; i<2; i++){
1770 for(Int_t j=0; j<(i==0?4:2); j++) delete localendladdercooltubetrans[i][j];
1771 delete [] localendladdercooltubetrans[i];
1772 }
1773 for(Int_t i=0; i<fgkendladdercarbonfibermatrixnumber; i++)
bf210566 1774 delete localendladdercarbonfibertrans[i];
1775 for(Int_t i=0; i<3; i++) delete localladdercablerot[i];
1776 for(Int_t i=0; i<klocalladdersidecablesnumber; i++){
1777 for(Int_t j=0; j<klocalladdercombitransnumber; j++)
1778 delete localladdercablecombitransmatrix[i][j];
1779 delete []localladdercablecombitransmatrix[i];
1780 }
9b0c60ab 1781 delete localendladdercliprot;
1782 delete localendladdercliptrans;
bf210566 1783 for(Int_t i=0; i<fgkladdercablesnumber; i++){
1784 for(Int_t j=0; j<klocalladdersidecablesnumber; j++)
1785 delete localladdercablehmatrix[i][j];
1786 delete []localladdercablehmatrix[i];
1787 }
1788 delete laddercablerot;
1789 delete laddercabletrans;
1790 delete laddercablecombitrans;
1791 delete localladdercablessdmodulematrix;
1792 delete localssdsensorrot;
1793 for(Int_t i=0; i<2; i++){
1794 delete localssdsensortrans[i];
1795 delete localssdsensorcombitrans[i];
1796 }
1797 for(Int_t i=0; i<fgklayernumber; i++){
1798 for(Int_t j=0; j<kssdlayladdernumber[i]; j++){
1799 delete locallayerrot[i][j];
1800 delete locallayertrans[i][j];
1801 delete locallayercombitrans[i][j];
d7599219 1802 }
bf210566 1803 delete [] locallayerrot[i];
1804 delete [] locallayertrans[i];
1805 delete [] locallayercombitrans[i];
1806 delete localbeamaxistrans[i];
1807 }
1808 for(Int_t i=0; i<3; i++) delete itscenterrot[i];
1809 for(Int_t i=0; i<fgkladdernumber; i++){
1810 for(Int_t j=0; j<fgkladdernumber; j++)
1811 delete ladderglobalmatrix[i][j];
1812 delete [] ladderglobalmatrix[i];
1813 }
1814 /////////////////////////////////////////////////////////////
1815 fTransformationMatrices = kTRUE;
d7599219 1816}
bf210566 1817///////////////////////////////////////////////////////////////////////////////
1818void AliITSv11GeometrySSD::CreateBasicObjects(){
1819 /////////////////////////////////////////////////////////////
1820 // Method generating the Objects of SSD Geometry
44285dfa 1821 /////////////////////////////////////////////////////////////
bf210566 1822 // SSD Sensor
1823 ///////////////////////////////////
1824 SetSSDSensor();
1825 /////////////////////////////////////////////////////////////
1826 // Carbon Fiber Support
1827 /////////////////////////////////////////////////////////////
1828 TList* carbonfibersupportlist = GetCarbonFiberSupportList();
1829 for(Int_t i=0; i<fgkcarbonfibersupportnumber; i++)
1830 fcarbonfibersupport[i] = (TGeoVolume*)carbonfibersupportlist->At(i);
44285dfa 1831 /////////////////////////////////////////////////////////////
bf210566 1832 // Carbon Fiber Junction
44285dfa 1833 /////////////////////////////////////////////////////////////
ca86fdb4 1834 fcarbonfiberjunction = GetCarbonFiberJunction(fgkCarbonFiberJunctionWidth-fgkSSDTolerance);
44285dfa 1835 /////////////////////////////////////////////////////////////
bf210566 1836 // Carbon Fiber Lower Support
44285dfa 1837 /////////////////////////////////////////////////////////////
bf210566 1838 TList* carbonfiberlowersupportlist = GetCarbonFiberLowerSupportList();
1839 for(Int_t i=0; i<fgkcarbonfiberlowersupportnumber; i++)
1840 fcarbonfiberlowersupport[i] = (TGeoVolume*)carbonfiberlowersupportlist->At(i);
d7599219 1841 /////////////////////////////
bf210566 1842 // SSD Sensor Support
d7599219 1843 /////////////////////////////
bf210566 1844 for(Int_t i=0; i<fgkvolumekind; i++) fssdsensorsupport[i] =
1845 new TGeoVolume*[fgkssdsensorsupportnumber];
1846 Double_t sidesupporthickness[2] = {fgkSSDSensorSideSupportThickness[0],
1847 fgkSSDSensorSideSupportThickness[1]};
1848 for(Int_t i=0; i<fgkssdsensorsupportnumber-1; i++){
1849 fssdsensorsupport[0][i] = GetSSDSensorSupport(fgkSSDSensorSideSupportLength,
1850 fgkSSDSensorSideSupportHeight[i],
1851 fgkSSDSensorSideSupportWidth,
1852 sidesupporthickness);
1853 fssdsensorsupport[1][i] = GetSSDSensorSupport(fgkSSDSensorCenterSupportLength,
1854 fgkSSDSensorCenterSupportHeight[i],
1855 fgkSSDSensorCenterSupportWidth,
1856 sidesupporthickness);
1857 }
44285dfa 1858 /////////////////////////////////////////////////////////////
bf210566 1859 // SSD Cooling Tube Support
44285dfa 1860 /////////////////////////////////////////////////////////////
bf210566 1861 Int_t edgesnumber = 16;
1862 fcoolingtubesupport = GetCoolingTubeSupport(edgesnumber);
44285dfa 1863 /////////////////////////////////////////////////////////////
bf210566 1864 // SSD Hybrid
44285dfa 1865 /////////////////////////////////////////////////////////////
bf210566 1866 TList* ssdhybridcomponentslist = GetSSDHybridParts();
1867 for(Int_t i=0; i<fgkhybridcompnumber; i++)
1868 fssdhybridcomponent[i] = (TGeoVolume*)ssdhybridcomponentslist->At(i);
44285dfa 1869 /////////////////////////////////////////////////////////////
bf210566 1870 // SSD Cooling Block System
44285dfa 1871 /////////////////////////////////////////////////////////////
bf210566 1872 fssdcoolingblocksystem = GetCoolingBlockSystem();
1873 /////////////////////////////////////////////////////////////
1874 // SSD Cooling Tube
44285dfa 1875 /////////////////////////////////////////////////////////////
bf210566 1876 TList* coolingtubelist = GetCoolingTubeList();
1877 for(Int_t i=0; i<fgkcoolingtubenumber; i++)
1878 fcoolingtube[i] = (TGeoVolume*)coolingtubelist->At(i);
9b0c60ab 1879 for(Int_t i=0; i<fgkendladdercoolingtubenumber; i++)
1880 fendladdercoolingtube[i] =
1881 (TGeoVolume*)coolingtubelist->At(fgkcoolingtubenumber+i);
44285dfa 1882 /////////////////////////////////////////////////////////////
bf210566 1883 // SSD Flex
1884 /////////////////////////////////////////////////////////////
1885 fssdstiffenerflex = GetSSDStiffenerFlex();
1886 fssdendflex = GetSSDEndFlex();
1887 ///////////////////////////////////
1888 // End Ladder Carbon Fiber Junction
1889 ///////////////////////////////////
1890 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++)
1891 fendladdercarbonfiberjunction[i] =
1892 new TGeoVolume*[fgkendlabbercarbonfiberjunctionumber];
1893 for(Int_t i=0; i<fgkendlabbercarbonfiberjunctionumber; i++){
1894 fendladdercarbonfiberjunction[i][0] =
ca86fdb4 1895 GetCarbonFiberJunction(fgkEndLadderCarbonFiberLowerJunctionLength[i]-fgkSSDTolerance);
bf210566 1896 fendladdercarbonfiberjunction[i][1] =
ca86fdb4 1897 GetCarbonFiberJunction(fgkEndLadderCarbonFiberUpperJunctionLength[i]-fgkSSDTolerance);
d7599219 1898 }
bf210566 1899 ///////////////////////////////////
1900 // End Ladder Mounting Block
1901 ///////////////////////////////////
1902 fendladdermountingblock = GetSSDMountingBlock();
9b0c60ab 1903 ///////////////////////////////////
1904 // End Ladder Mounting Block
1905 ///////////////////////////////////
1906 fendladdermountingblockclip = GetMountingBlockClip();
1907 ///////////////////////////////////
1908 // Ladder Support
1909 ///////////////////////////////////
1910 TList* laddersupportlist = GetMountingBlockSupport(20);
1911 fLay5LadderSupport[0] = (TGeoVolume*)laddersupportlist->At(0);
1912 fLay5LadderSupport[1] = (TGeoVolume*)laddersupportlist->At(1);
1913 fLay6LadderSupport[0] = (TGeoVolume*)laddersupportlist->At(2);
1914 fLay6LadderSupport[1] = (TGeoVolume*)laddersupportlist->At(3);
44285dfa 1915 /////////////////////////////////////////////////////////////
bf210566 1916 // Deallocating memory
1917 /////////////////////////////////////////////////////////////
1918 delete carbonfibersupportlist;
1919 delete carbonfiberlowersupportlist;
1920 delete ssdhybridcomponentslist;
9b0c60ab 1921 delete laddersupportlist;
bf210566 1922 /////////////////////////////////////////////////////////////
1923 fBasicObjects = kTRUE;
d7599219 1924}
1925/////////////////////////////////////////////////////////////////////////////////
bf210566 1926void AliITSv11GeometrySSD::SetSSDSensor(){
1927 ////////////////////////////////////////////////////////////////
1928 // Method generating SSD Sensors: it sets the private variables
1929 // fSSDSensor5, fSSDSensor6
1930 ////////////////////////////////////////////////////////////////
1931 Double_t ssdsensitivelength = fgkSSDSensorLength-2.*fgkSSDSensorInsensitiveLength;
1932 Double_t ssdsensitivewidth = fgkSSDSensorWidth-2.*fgkSSDSensorInsensitiveWidth;
1933 TGeoBBox* ssdsensorsensitiveshape = new TGeoBBox("SSDSensorSensitiveShape",
1934 0.5*ssdsensitivewidth,
1935 0.5*fgkSSDSensorHeight,
1936 0.5*ssdsensitivelength);
1937 TGeoVolume* ssdsensorsensitiveLay5 =
02d4acf9 1938 new TGeoVolume(fgSSDsensitiveVolName5,ssdsensorsensitiveshape,fSSDSensorMedium);
bf210566 1939 TGeoVolume* ssdsensorsensitiveLay6 =
02d4acf9 1940 new TGeoVolume(fgSSDsensitiveVolName6,ssdsensorsensitiveshape,fSSDSensorMedium);
bf210566 1941 ssdsensorsensitiveLay5->SetLineColor(fColorSilicon);
1942 ssdsensorsensitiveLay6->SetLineColor(fColorSilicon);
1943 TGeoBBox* ssdsensorinsensitiveshape[2];
1944 ssdsensorinsensitiveshape[0] = new TGeoBBox("SSDSensorInsensitiveShape1",
1945 0.5*fgkSSDSensorInsensitiveWidth,
1946 0.5*fgkSSDSensorHeight,
1947 0.5*fgkSSDSensorLength);
1948 ssdsensorinsensitiveshape[1] = new TGeoBBox("SSDSensorInsensitiveShape2",
1949 0.5*ssdsensitivewidth,
1950 0.5*fgkSSDSensorHeight,
1951 0.5*fgkSSDSensorInsensitiveWidth);
1952 const char* ssdsensorinsensitivename[2] = {"SSDSensorInsensitive1",
1953 "SSDSensorInsensitive2"};
1954 TGeoVolume* ssdsensorinsensitive[2];
1955 for(Int_t i=0; i<2; i++){ ssdsensorinsensitive[i] =
1956 new TGeoVolume(ssdsensorinsensitivename[i],ssdsensorinsensitiveshape[i],
1957 fSSDSensorMedium);
1958 ssdsensorinsensitive[i]->SetLineColor(fColorCarbonFiber);
1959 }
44285dfa 1960 /////////////////////////////////////////////////////////////
bf210566 1961 // Virtual Volume containing SSD Sensor
1962 /////////////////////////////////////////////////////////////
1963 TGeoBBox* virtualSSDSensorShape = new TGeoBBox("SSDSensorShape",
1964 0.5*fgkSSDSensorWidth,
1965 0.5*fgkSSDSensorHeight,
1966 0.5*fgkSSDSensorLength);
ef9451a3 1967 fSSDSensor5 = new TGeoVolume("ITSssdSensor5",virtualSSDSensorShape,
bf210566 1968 fSSDAir);
ef9451a3 1969 fSSDSensor6 = new TGeoVolume("ITSssdSensor6",virtualSSDSensorShape,
bf210566 1970 fSSDAir);
1971 /////////////////////////////////////////////////////////////
1972 for(Int_t i=0; i<4; i++){
1973 fSSDSensor5->AddNode(i%2==0 ? ssdsensorinsensitive[0]:
1974 ssdsensorinsensitive[1],i<2?1:2,
1975 new TGeoTranslation(
1976 0.5*(1.+TMath::Power(-1.,i))*(i==0?-1.: 1.)
1977 * (ssdsensorsensitiveshape->GetDX()+ssdsensorinsensitiveshape[0]->GetDX()),0.,
1978 0.5*(1.-TMath::Power(-1.,i))*(i==1? 1.:-1.)
1979 * (ssdsensorsensitiveshape->GetDZ()+ssdsensorinsensitiveshape[1]->GetDZ())));
1980 fSSDSensor6->AddNode(i%2==0 ? ssdsensorinsensitive[0]:
1981 ssdsensorinsensitive[1],i<2?1:2,
1982 new TGeoTranslation(
1983 0.5*(1.+TMath::Power(-1.,i))*(i==0?-1.: 1.)
1984 * (ssdsensorsensitiveshape->GetDX()+ssdsensorinsensitiveshape[0]->GetDX()),0.,
1985 0.5*(1.-TMath::Power(-1.,i))*(i==1? 1.:-1.)
1986 * (ssdsensorsensitiveshape->GetDZ()+ssdsensorinsensitiveshape[1]->GetDZ())));
d7599219 1987 }
bf210566 1988 fSSDSensor5->AddNode(ssdsensorsensitiveLay5,1);
1989 fSSDSensor6->AddNode(ssdsensorsensitiveLay6,1);
d7599219 1990}
bf210566 1991///////////////////////////////////////////////////////////////////////////////
1992TList* AliITSv11GeometrySSD::GetCarbonFiberSupportList(){
1993 /////////////////////////////////////////////////////////////
44285dfa 1994 // Method generating the Carbon Fiber Support
1995 /////////////////////////////////////////////////////////////
1996 const Int_t kvertexnumber = 4;
1997 const Int_t kshapesnumber = 2;
1998 TVector3** vertexposition[kshapesnumber];
1999 for(Int_t i=0; i<kshapesnumber; i++) vertexposition[i] = new TVector3*[kvertexnumber];
2000 Double_t carbonfibersupportxaxisEdgeproj =
d7599219 2001 fgkCarbonFiberSupportEdgeLength*TMath::Cos(fgkCarbonFiberJunctionAngle[0]
2002 * TMath::DegToRad());
44285dfa 2003 Double_t theta = TMath::ATan(fgkCarbonFiberSupportYAxisLength
d7599219 2004 / fgkCarbonFiberSupportXAxisLength);
2005 /////////////////////
2006 //Vertex Positioning
2007 ////////////////////
44285dfa 2008 vertexposition[0][0] = new TVector3();
2009 vertexposition[0][1] = new TVector3(fgkCarbonFiberSupportXAxisLength,
d7599219 2010 fgkCarbonFiberSupportYAxisLength);
44285dfa 2011 vertexposition[0][2] = new TVector3(carbonfibersupportxaxisEdgeproj,
2012 carbonfibersupportxaxisEdgeproj
2013 * TMath::Tan(theta));
2014 vertexposition[0][3] = new TVector3(fgkCarbonFiberSupportXAxisLength
2015 - carbonfibersupportxaxisEdgeproj,
d7599219 2016 fgkCarbonFiberSupportYAxisLength
44285dfa 2017 - vertexposition[0][2]->Y());
d7599219 2018 ////////////////////////////////////////////////////
2019 //Setting the parameters for Isometry Transformation
2020 ////////////////////////////////////////////////////
44285dfa 2021 Double_t symmetryplaneposition = (fgkCarbonFiberSupportYAxisLength
d7599219 2022 + fgkCarbonFiberSupportTopEdgeDist[0]
2023 + fgkCarbonFiberSupportWidth);
2024 Double_t* param = new Double_t[4];
44285dfa 2025 param[0] = 0., param[1] = 1., param[2] = 0., param[3] = -symmetryplaneposition;
2026 for(Int_t j=0; j<kvertexnumber; j++) vertexposition[1][j] =
2027 new TVector3((GetReflection(vertexposition[0][j],param))->X(),
2028 (GetReflection(vertexposition[0][j],param))->Y());
2029 char* carbonfibersupportshapename[kshapesnumber] =
d7599219 2030 {"CarbonFiberSupportShape1","CarbonFiberSupportShape2"};
bf210566 2031 char* carbonfibersupportname[kshapesnumber] =
2032 {"CarbonFiberSupport1","CarbonFiberSupport2"};
44285dfa 2033 TGeoArb8* carbonfibersupportshape[kshapesnumber];
bf210566 2034 TGeoVolume* carbonfibersupport[kshapesnumber];
2035 TList* carbonfibersupportlist = new TList();
44285dfa 2036 Double_t width[2] = {fgkCarbonFiberSupportWidth,fgkCarbonFiberSupportWidth};
2037 Double_t carbonfibersupportheight =
2038 carbonfibersupportxaxisEdgeproj*TMath::Tan(fgkCarbonFiberJunctionAngle[0]
d7599219 2039 *TMath::DegToRad());
bf210566 2040 for(Int_t i = 0; i< kshapesnumber; i++){
2041 carbonfibersupportshape[i] =
44285dfa 2042 GetArbShape(vertexposition[i],width,carbonfibersupportheight,
bf210566 2043 carbonfibersupportshapename[i],i==0 ? 1: -1);
2044 carbonfibersupport[i] = new TGeoVolume(carbonfibersupportname[i],
2045 carbonfibersupportshape[i],fSSDCarbonFiberMedium);
2046 carbonfibersupport[i]->SetLineColor(fColorCarbonFiber);
2047 carbonfibersupportlist->Add(carbonfibersupport[i]);
2048 }
2049 /////////////////////////////////////////////////////////////
2050 // Deallocating memory
2051 /////////////////////////////////////////////////////////////
2052 for(Int_t i=0; i< kshapesnumber; i++){
2053 for(Int_t j=0; j< kvertexnumber; j++)
2054 delete vertexposition[i][j];
2055 delete [] vertexposition[i];
2056 }
2057 delete [] param;
2058 /////////////////////////////////////////////////////////////
2059 return carbonfibersupportlist;
2060}
2061/////////////////////////////////////////////////////////////////////////////////
2062TGeoVolume* AliITSv11GeometrySSD::GetCarbonFiberJunction(Double_t width){
2063 /////////////////////////////////////////////////////////////
2064 // Method generating SSD Carbon Fiber Junction
2065 /////////////////////////////////////////////////////////////
2066 const Int_t kvertexnumber = 6;
2067 TGeoXtru* carbonfiberjunctionshape = new TGeoXtru(2);
2068 Double_t reflectionparam[3] = {TMath::Tan(fgkCarbonFiberJunctionAngle[0]
2069 * TMath::DegToRad()),-1.,0.};
2070 TVector3* vertex[kvertexnumber];
2071 vertex[0] = new TVector3();
2072 vertex[3] = new TVector3(fgkCarbonFiberJunctionEdge[0]
2073 * TMath::Cos(fgkCarbonFiberJunctionAngle[0]
2074 * TMath::DegToRad()),
2075 fgkCarbonFiberJunctionEdge[0]
2076 * TMath::Sin(fgkCarbonFiberJunctionAngle[0]
2077 * TMath::DegToRad()));
2078 vertex[4] = new TVector3(fgkCarbonFiberJunctionLength,
2079 fgkCarbonFiberJunctionEdge[1]);
2080 vertex[5] = new TVector3(fgkCarbonFiberJunctionLength);
2081 vertex[1] = GetReflection(vertex[5],reflectionparam);
2082 vertex[2] = GetReflection(vertex[4],reflectionparam);
2083 Double_t xvertexpoints[6], yvertexpoints[6];
2084 for(Int_t i=0; i<kvertexnumber; i++)
2085 xvertexpoints[i] = vertex[i]->X(), yvertexpoints[i] = vertex[i]->Y();
2086 carbonfiberjunctionshape->DefinePolygon(kvertexnumber,xvertexpoints,yvertexpoints);
2087 carbonfiberjunctionshape->DefineSection(0,-0.5*width);
2088 carbonfiberjunctionshape->DefineSection(1,0.5*width);
2089 TGeoVolume* carbonfiberjunction = new TGeoVolume("CarbonFiberJunction",
2090 carbonfiberjunctionshape,fSSDCarbonFiberMedium);
2091 carbonfiberjunction->SetLineColor(fColorCarbonFiber);
2092 /////////////////////////////////////////////////////////////
2093 // Deallocating memory
2094 /////////////////////////////////////////////////////////////
2095 for (Int_t i=0; i<kvertexnumber; i++) delete vertex[i];
2096 /////////////////////////////////////////////////////////////
2097 return carbonfiberjunction;
d7599219 2098}
2099////////////////////////////////////////////////////////////////////////////////
bf210566 2100TList* AliITSv11GeometrySSD::GetCarbonFiberLowerSupportList(){
44285dfa 2101 /////////////////////////////////////////////////////////////
2102 // Method generating the Carbon Fiber Lower Support
2103 /////////////////////////////////////////////////////////////
2104 const Int_t kvertexnumber = 4;
2105 const Int_t kshapesnumber = 2;
2106 Double_t width[2] = {fgkCarbonFiberLowerSupportWidth,
d7599219 2107 fgkCarbonFiberLowerSupportWidth};
44285dfa 2108 TVector3** vertexposition[kshapesnumber];
2109 for(Int_t i = 0; i<kshapesnumber; i++) vertexposition[i] =
2110 new TVector3*[kvertexnumber];
d7599219 2111 //First Shape Vertex Positioning
44285dfa 2112 vertexposition[0][0] = new TVector3(fgkCarbonFiberLowerSupportLowerLenght);
2113 vertexposition[0][1] = new TVector3(fgkCarbonFiberTriangleLength
d7599219 2114 - fgkCarbonFiberLowerSupportLowerLenght);
44285dfa 2115 vertexposition[0][2] = new TVector3();
2116 vertexposition[0][3] = new TVector3(fgkCarbonFiberTriangleLength);
d7599219 2117 //Second Shape Vertex Positioning
44285dfa 2118 Double_t theta = TMath::ATan((fgkCarbonFiberLowerSupportVolumePosition[1]
d7599219 2119 - fgkCarbonFiberLowerSupportVolumePosition[0])
2120 / fgkCarbonFiberTriangleLength);
44285dfa 2121 vertexposition[1][0] = new TVector3(vertexposition[0][0]->X(),
2122 vertexposition[0][0]->X()*TMath::Tan(theta)
d7599219 2123 + fgkCarbonFiberLowerSupportVolumePosition[0]);
44285dfa 2124 vertexposition[1][1] = new TVector3(vertexposition[0][1]->X(),
2125 vertexposition[0][1]->X()*TMath::Tan(theta)
d7599219 2126 + fgkCarbonFiberLowerSupportVolumePosition[0]);
44285dfa 2127 vertexposition[1][2] = new TVector3(0.,fgkCarbonFiberLowerSupportVolumePosition[0]);
2128 vertexposition[1][3] = new TVector3(fgkCarbonFiberTriangleLength,
d7599219 2129 fgkCarbonFiberLowerSupportVolumePosition[1]);
bf210566 2130 char* carbonfiberlowersupportshapename[kshapesnumber] =
d7599219 2131 {"CarbonFiberLowerSupportShape1","CarbonFiberLowerSupportShape2"};
bf210566 2132 char* carbonfiberlowersupportname[kshapesnumber] =
2133 {"CarbonFiberLowerSupport1","CarbonFiberLowerSupport2"};
44285dfa 2134 TGeoArb8* carbonfiberlowersupportshape[kshapesnumber];
bf210566 2135 TGeoVolume* carbonfiberlowersupport[kshapesnumber];
2136 TList* carbonfiberlowersupportlist = new TList();
2137 for(Int_t i = 0; i< kshapesnumber; i++){
2138 carbonfiberlowersupportshape[i] =
44285dfa 2139 GetArbShape(vertexposition[i],width,
d7599219 2140 fgkCarbonFiberLowerSupportHeight,
bf210566 2141 carbonfiberlowersupportshapename[i]);
2142 carbonfiberlowersupport[i] = new TGeoVolume(carbonfiberlowersupportname[i],
2143 carbonfiberlowersupportshape[i],fSSDCarbonFiberMedium);
2144 carbonfiberlowersupport[i]->SetLineColor(fColorCarbonFiber);
2145 carbonfiberlowersupportlist->Add(carbonfiberlowersupport[i]);
2146 }
2147 /////////////////////////////////////////////////////////////
2148 // Deallocating memory
2149 /////////////////////////////////////////////////////////////
2150 for(Int_t i=0; i< kshapesnumber; i++){
2151 for(Int_t j=0; j< kvertexnumber; j++)
2152 delete vertexposition[i][j];
2153 delete [] vertexposition[i];
2154 }
2155 /////////////////////////////////////////////////////////////
2156 return carbonfiberlowersupportlist;
d7599219 2157}
bf210566 2158///////////////////////////////////////////////////////////////////////////////
2159TGeoVolume* AliITSv11GeometrySSD::GetSSDSensorSupport(Double_t length, Double_t height,
2160 Double_t width, Double_t* thickness)const{
44285dfa 2161 /////////////////////////////////////////////////////////////
bf210566 2162 // Method generating the Sensor Support
44285dfa 2163 /////////////////////////////////////////////////////////////
bf210566 2164 const Int_t kvertexnumber = 6;
2165 TGeoXtru* ssdsensorsupportshape = new TGeoXtru(2);
2166 TVector3* vertexposition[kvertexnumber];
2167 vertexposition[0] = new TVector3();
2168 vertexposition[1] = new TVector3(0.0,length);
2169 vertexposition[2] = new TVector3(thickness[1],vertexposition[1]->Y());
2170 vertexposition[3] = new TVector3(vertexposition[2]->X(),thickness[0]);
2171 vertexposition[4] = new TVector3(height,vertexposition[3]->Y());
2172 vertexposition[5] = new TVector3(vertexposition[4]->X());
2173 Double_t xvertexpoints[6], yvertexpoints[6];
2174 for(Int_t i=0; i<kvertexnumber; i++)
2175 xvertexpoints[i] = vertexposition[i]->X(),
2176 yvertexpoints[i] = vertexposition[i]->Y();
2177 ssdsensorsupportshape->DefinePolygon(kvertexnumber,xvertexpoints,yvertexpoints);
2178 ssdsensorsupportshape->DefineSection(0,-0.5*width);
2179 ssdsensorsupportshape->DefineSection(1,0.5*width);
2180 TGeoVolume* ssdsensorsupport = new TGeoVolume("SSDSensorSupport",
2181 ssdsensorsupportshape,fSSDSensorSupportMedium);
2182 /////////////////////////////////////////////////////////////
2183 // Deallocating memory
2184 /////////////////////////////////////////////////////////////
2185 for (Int_t i=0; i<kvertexnumber; i++)
2186 delete vertexposition[i];
2187 /////////////////////////////////////////////////////////////
2188 return ssdsensorsupport;
d7599219 2189}
2190////////////////////////////////////////////////////////////////////////////////
bf210566 2191TGeoVolume* AliITSv11GeometrySSD::GetCoolingTubeSupport(Int_t nedges){
44285dfa 2192 /////////////////////////////////////////////////////////////
2193 // Method generating the Cooling Tube Support
bf210566 2194 /////////////////////////////////////////////////////////////
2195 if(nedges%2!=0) nedges--;
2196 const Int_t kvertexnumber = nedges+5;
44285dfa 2197 Double_t phi = TMath::ASin(0.5*fgkCoolingTubeSupportHeight
d7599219 2198 / fgkCoolingTubeSupportRmax)*TMath::RadToDeg();
bf210566 2199 Double_t angle = 90.+phi;
2200 Double_t psi = 90.-phi;
2201 ///////////////////////////////////////
2202 // Vertex Positioning for TGeoXTru
2203 ///////////////////////////////////////
2204 TVector3** vertexposition = new TVector3*[kvertexnumber];
2205 vertexposition[0] = new TVector3(fgkCoolingTubeSupportRmin*CosD(angle),
2206 fgkCoolingTubeSupportRmin*SinD(angle));
2207 vertexposition[1] = new TVector3(fgkCoolingTubeSupportRmax*CosD(angle),
2208 fgkCoolingTubeSupportRmax*SinD(angle));
44285dfa 2209 vertexposition[2] = new TVector3(vertexposition[1]->X(),
bf210566 2210 fgkCoolingTubeSupportRmax);
2211 vertexposition[3] = new TVector3(-vertexposition[1]->X(),
2212 fgkCoolingTubeSupportRmax);
2213 vertexposition[4] = new TVector3(-vertexposition[1]->X(),
2214 vertexposition[1]->Y());
2215 for(Int_t i=0; i<nedges; i++)
2216 vertexposition[i+5] =
2217 new TVector3(fgkCoolingTubeSupportRmin*CosD(psi+i*(2.*phi/nedges)),
2218 fgkCoolingTubeSupportRmin*SinD(psi+i*(2.*phi/nedges)));
2219 ///////////////////////////////////////////////////////////////////////
2220 // TGeoXTru Volume definition for Cooling Tube Support Arc Part
2221 ///////////////////////////////////////////////////////////////////////
2222 TGeoXtru* coolingtubesupportarcshape = new TGeoXtru(2);
2223 Double_t* xvertexpoints = new Double_t[kvertexnumber];
2224 Double_t* yvertexpoints = new Double_t[kvertexnumber];
2225 for(Int_t i=0; i<kvertexnumber; i++){
2226 xvertexpoints[i] = vertexposition[i]->X();
2227 yvertexpoints[i] = vertexposition[i]->Y();
2228 }
2229 coolingtubesupportarcshape->DefinePolygon(kvertexnumber,xvertexpoints,
2230 yvertexpoints);
2231 coolingtubesupportarcshape->DefineSection(0,-0.5*fgkCoolingTubeSupportWidth);
2232 coolingtubesupportarcshape->DefineSection(1,0.5*fgkCoolingTubeSupportWidth);
2233 TGeoVolume* coolingtubesupportarc = new TGeoVolume("CoolingTubeSupportArc",
2234 coolingtubesupportarcshape,
2235 fSSDTubeHolderMedium);
2236 coolingtubesupportarc->SetLineColor(fColorG10);
2237 //////////////////////////////////////////////////////////////////////////
2238 // TGeoTubeSeg Volume definition for Cooling Tube Support TGeoTubeSeg Part
2239 //////////////////////////////////////////////////////////////////////////
2240 TGeoTubeSeg* coolingtubesupportsegshape =
2241 new TGeoTubeSeg(fgkCoolingTubeSupportRmin,
2242 fgkCoolingTubeSupportRmax,
2243 0.5*fgkCoolingTubeSupportWidth,
2244 phi,360-phi);
2245 TGeoVolume* coolingtubesupportseg = new TGeoVolume("CoolingTubeSupportSeg",
2246 coolingtubesupportsegshape,
2247 fSSDTubeHolderMedium);
2248 coolingtubesupportseg->SetLineColor(fColorG10);
2249 //////////////////////////////////////////////////////////////////////////
2250 // TGeoBBox Volume definition for Cooling Tube Support Box Part
2251 //////////////////////////////////////////////////////////////////////////
44285dfa 2252 Double_t* boxorigin = new Double_t[3];
bf210566 2253 Double_t boxlength = fgkCoolingTubeSupportLength-2.*fgkCoolingTubeSupportRmax;
2254 boxorigin[0] = fgkCoolingTubeSupportRmax+0.5*boxlength, boxorigin[1] = boxorigin[2] = 0.;
2255 TGeoBBox* coolingtubesupportboxshape = new TGeoBBox(0.5*boxlength,
2256 0.5*fgkCoolingTubeSupportHeight,
2257 0.5*fgkCoolingTubeSupportWidth,boxorigin);
2258 TGeoVolume* coolingtubesupportbox = new TGeoVolume("CoolingTubeSupportBox",
2259 coolingtubesupportboxshape,fSSDTubeHolderMedium);
2260 coolingtubesupportbox->SetLineColor(fColorG10);
2261 //////////////////////////////////////////////////////////////////////////
2262 // Cooling Tube for Cooling Tube Support
2263 //////////////////////////////////////////////////////////////////////////
2264 TGeoXtru* coolingtubearcshape[2];
2265 coolingtubearcshape[0] = new TGeoXtru(2);
2266 Double_t* xvert = new Double_t[nedges+2];
2267 Double_t* yvert = new Double_t[nedges+2];
2268 Double_t ratio = fgkCoolingTubeRmin/fgkCoolingTubeSupportRmin;
2269 ////////////////////////////////////////
2270 // Positioning the vertices for TGeoXTru
2271 ////////////////////////////////////////
2272 xvert[0] = 0., yvert[0] = 0.;
2273 xvert[1] = vertexposition[0]->X()*ratio, yvert[1] = vertexposition[0]->Y()*ratio;
2274 for(Int_t i=0; i< nedges; i++)
2275 xvert[i+2] = vertexposition[kvertexnumber-i-1]->X()*ratio,
2276 yvert[i+2] = vertexposition[kvertexnumber-i-1]->Y()*ratio;
2277 ////////////////////////////////////////
2278 // Defining TGeoXTru PolyGone
2279 ////////////////////////////////////////
2280 coolingtubearcshape[0]->DefinePolygon(nedges+2,xvert,yvert);
2281 coolingtubearcshape[0]->DefineSection(0,-0.5*fgkCoolingTubeSupportWidth);
2282 coolingtubearcshape[0]->DefineSection(1,0.5*fgkCoolingTubeSupportWidth);
2283 coolingtubearcshape[1] = GetArcShape(2.*phi,fgkCoolingTubeRmin,
2284 fgkCoolingTubeRmax,nedges,fgkCoolingTubeSupportWidth);
2285 TGeoVolume* coolingtubearc[2];
2286 coolingtubearc[0] = new TGeoVolume("CoolingTubeWaterArcPart",
2287 coolingtubearcshape[0],fSSDCoolingTubeWater);
2288 coolingtubearc[1] = new TGeoVolume("CoolingTubePhynoxArcPart",
2289 coolingtubearcshape[1],fSSDCoolingTubePhynox);
2290 coolingtubearc[0]->SetLineColor(fColorWater);
2291 coolingtubearc[1]->SetLineColor(fColorPhynox);
2292 ////////////////////////////////////////////
2293 // Defining TGeoTubeSeg Part of Cooling Tube
2294 ////////////////////////////////////////////
2295 TGeoTubeSeg* coolingtubesegshape[2];
2296 coolingtubesegshape[0] = new TGeoTubeSeg(fgkCoolingTubeRmin,fgkCoolingTubeRmax,
2297 0.5*fgkCoolingTubeSupportWidth,phi,360-phi);
2298 coolingtubesegshape[1] = new TGeoTubeSeg(0.,fgkCoolingTubeRmin,
2299 0.5*fgkCoolingTubeSupportWidth,phi,360-phi);
2300 TGeoVolume* coolingtubeseg[2];
2301 coolingtubeseg[0] = new TGeoVolume("CoolingTubePhynoxPart",
2302 coolingtubesegshape[0],fSSDCoolingTubePhynox);
2303 coolingtubeseg[1] = new TGeoVolume("CoolingTubeWaterPart",
2304 coolingtubesegshape[1],fSSDCoolingTubeWater);
2305 coolingtubeseg[0]->SetLineColor(fColorPhynox);
2306 coolingtubeseg[1]->SetLineColor(fColorWater);
2307 /////////////////////////////////////////////////////////////
2308 // Virtual Volume containing Cooling Tube Support
2309 /////////////////////////////////////////////////////////////
2310 TGeoXtru* virtualCoolingTubeSupportShape = new TGeoXtru(2);
2311 const Int_t kvirtualvertexnumber = 8;
2312 TVector3* virtualvertex[kvirtualvertexnumber];
2313 ////////////////////////////////////////
2314 // Positioning the vertices for TGeoXTru
2315 ////////////////////////////////////////
2316 virtualvertex[0] = new TVector3(-fgkCoolingTubeSupportRmax,-fgkCoolingTubeSupportRmax);
2317 virtualvertex[1] = new TVector3(virtualvertex[0]->X(),-virtualvertex[0]->Y());
2318 virtualvertex[2] = new TVector3(-virtualvertex[0]->X(),virtualvertex[1]->Y());
2319 virtualvertex[3] = new TVector3(virtualvertex[2]->X(),0.5*fgkCoolingTubeSupportHeight);
2320 virtualvertex[4] = new TVector3(virtualvertex[3]->X()+boxlength,virtualvertex[3]->Y());
2321 virtualvertex[5] = new TVector3(virtualvertex[4]->X(),-virtualvertex[4]->Y());
2322 virtualvertex[6] = new TVector3(virtualvertex[3]->X(),-virtualvertex[3]->Y());
2323 virtualvertex[7] = new TVector3(virtualvertex[2]->X(),-virtualvertex[2]->Y());
2324 Double_t xmothervertex[kvirtualvertexnumber], ymothervertex[kvirtualvertexnumber];
2325 for(Int_t i=0; i< kvirtualvertexnumber; i++)
2326 xmothervertex[i] = virtualvertex[i]->X(),
2327 ymothervertex[i] = virtualvertex[i]->Y();
2328 ////////////////////////////////////////
2329 // Defining TGeoXTru PolyGone
2330 ////////////////////////////////////////
2331 virtualCoolingTubeSupportShape->DefinePolygon(kvirtualvertexnumber,xmothervertex,
2332 ymothervertex);
2333 virtualCoolingTubeSupportShape->DefineSection(0,-0.5*fgkCoolingTubeSupportWidth);
2334 virtualCoolingTubeSupportShape->DefineSection(1,0.5*fgkCoolingTubeSupportWidth);
2335 TGeoVolume* virtualcoolingtubesupport = new TGeoVolume("CoolingTubeSupport",
2336 virtualCoolingTubeSupportShape,fSSDAir);
2337 ////////////////////////////////////////
2338 // Positioning Volumes in Virtual Volume
2339 ////////////////////////////////////////
2340 TGeoRotation* coolingtubesupportrot = new TGeoRotation();
2341 coolingtubesupportrot->SetAngles(-90.0,0.0,0.0);
2342 virtualcoolingtubesupport->AddNode(coolingtubesupportarc,1,coolingtubesupportrot);
2343 virtualcoolingtubesupport->AddNode(coolingtubesupportbox,1);
2344 virtualcoolingtubesupport->AddNode(coolingtubesupportseg,1);
2345 virtualcoolingtubesupport->AddNode(coolingtubearc[0],1,coolingtubesupportrot);
2346 virtualcoolingtubesupport->AddNode(coolingtubearc[1],1,coolingtubesupportrot);
2347 virtualcoolingtubesupport->AddNode(coolingtubeseg[0],1);
2348 virtualcoolingtubesupport->AddNode(coolingtubeseg[1],1);
2349 /////////////////////////////////////////////////////////////
2350 // Deallocating memory
2351 /////////////////////////////////////////////////////////////
2352 delete [] vertexposition;
2353 delete xvertexpoints;
2354 delete yvertexpoints;
2355 delete xvert;
2356 delete yvert;
2357 for(Int_t i=0; i< kvirtualvertexnumber; i++)
2358 delete virtualvertex[i];
2359 /////////////////////////////////////////////////////////////
2360 return virtualcoolingtubesupport;
d7599219 2361}
bf210566 2362/////////////////////////////////////////////////////////////////////////////////
2363TList* AliITSv11GeometrySSD::GetSSDHybridParts(){
2364 /////////////////////////////////////////////////////////////
2365 // Method generating List containing SSD Hybrid Components
2366 /////////////////////////////////////////////////////////////
2367 TList* ssdhybridlist = new TList();
2368 const Int_t kssdstiffenernumber = 2;
2369 Double_t ssdstiffenerseparation = fgkSSDSensorLength
2370 - 2.*fgkSSDModuleStiffenerPosition[1]
2371 - fgkSSDStiffenerWidth;
2372 Double_t ssdchipcablesradius[kssdstiffenernumber];
2373 for(Int_t i=0; i<kssdstiffenernumber; i++)
2374 ssdchipcablesradius[i] = 0.25*(fgkSSDChipCablesHeight[i+2]
2375 - fgkSSDChipCablesHeight[0]
2376 - fgkSSDChipCablesHeight[1]);
2377 /////////////////////////////////////////////////////////////
2378 // Mother Volumes Containers
2379 /////////////////////////////////////////////////////////////
2380 const Int_t kmothernumber = 2;
2381 const Int_t kmothervertexnumber = 12;
2382 Double_t xmothervertex[kmothernumber][kmothervertexnumber];
2383 Double_t ymothervertex[kmothernumber][kmothervertexnumber];
2384 ///////////////////////
2385 // Setting the vertices
2386 ///////////////////////
2387 xmothervertex[0][0] = -0.5*fgkSSDStiffenerLength;
2388 xmothervertex[0][1] = xmothervertex[0][0];
2389 xmothervertex[0][2] = fgkSSDFlexLength[0]-0.5*fgkSSDStiffenerLength;
2390 xmothervertex[0][3] = xmothervertex[0][2];
2391 xmothervertex[0][4] = xmothervertex[0][0];
2392 xmothervertex[0][5] = xmothervertex[0][4];
2393 xmothervertex[0][6] = -xmothervertex[0][0];
2394 xmothervertex[0][7] = xmothervertex[0][6];
2395 xmothervertex[0][8] = -xmothervertex[0][2];
2396 xmothervertex[0][9] = xmothervertex[0][8];
2397 xmothervertex[0][10] = xmothervertex[0][7];
2398 xmothervertex[0][11] = xmothervertex[0][10];
2399 for(Int_t i=0; i<kmothervertexnumber; i++) xmothervertex[1][i] = xmothervertex[0][i];
2400 for(Int_t i = 0; i<kmothernumber; i++){
2401 ymothervertex[i][0] = -(fgkSSDChipWidth-(0.5*fgkSSDStiffenerWidth-fgkSSDStiffenerToChipDist)
2402 + ssdchipcablesradius[i]+fgkSSDChipCablesWidth[1]+fgkSSDChipCablesWidth[2]);
2403 ymothervertex[i][1] = ssdstiffenerseparation-0.5*fgkSSDStiffenerWidth-fgkSSDFlexWidth[0];
2404 ymothervertex[i][2] = ymothervertex[i][1];
2405 ymothervertex[i][3] = ssdstiffenerseparation-0.5*fgkSSDStiffenerWidth;
2406 ymothervertex[i][4] = ymothervertex[i][3];
2407 ymothervertex[i][5] = ymothervertex[i][4]+0.5*fgkSSDStiffenerWidth-ymothervertex[i][0];
2408 ymothervertex[i][6] = ymothervertex[i][5];
2409 ymothervertex[i][7] = 0.5*fgkSSDStiffenerWidth+fgkSSDFlexWidth[0];
2410 ymothervertex[i][8] = ymothervertex[i][7];
2411 ymothervertex[i][9] = 0.5*fgkSSDStiffenerWidth;
2412 ymothervertex[i][10] = ymothervertex[i][9];
2413 ymothervertex[i][11] = ymothervertex[i][0];
2414 }
2415 TGeoXtru* ssdhybridmothershape[kmothernumber];
ca86fdb4 2416// TGeoVolume* ssdhybridmother[kmothernumber];
2417 TGeoVolumeAssembly* ssdhybridmother[kmothernumber];
bf210566 2418 const char* ssdhybridmothername[kmothernumber] = {"SSDHybridMother1","SSDHybridMother2"};
2419 for(Int_t i=0; i<kmothernumber; i++){
2420 ssdhybridmothershape[i] = new TGeoXtru(2);
2421 ssdhybridmothershape[i]->DefinePolygon(kmothervertexnumber,xmothervertex[i],
2422 ymothervertex[i]);
2423 ssdhybridmothershape[i]->DefineSection(0,-0.5*fgkSSDStiffenerHeight-fgkSSDChipHeight
2424 -fgkSSDChipCablesHeight[i+2]);
2425 ssdhybridmothershape[i]->DefineSection(1, 0.5*fgkSSDStiffenerHeight);
ca86fdb4 2426// ssdhybridmother[i] = new TGeoVolume(ssdhybridmothername[i],ssdhybridmothershape[i],
2427// fSSDAir);
2428 ssdhybridmother[i] = new TGeoVolumeAssembly(ssdhybridmothername[i]);
bf210566 2429 }
2430 /////////////////////////////////////////////////////////////
2431 // SSD Stiffener
2432 /////////////////////////////////////////////////////////////
2433 TGeoBBox* ssdstiffenershape = new TGeoBBox("SSDStiffenerShape",
2434 0.5*fgkSSDStiffenerLength,
ca86fdb4 2435 0.5*(fgkSSDStiffenerWidth-fgkSSDTolerance),
bf210566 2436 0.5*fgkSSDStiffenerHeight);
2437 TGeoVolume* ssdstiffener = new TGeoVolume("SSDStiffener",ssdstiffenershape,
2438 fSSDStiffenerMedium);
2439 ssdstiffener->SetLineColor(fColorStiffener);
2440 TGeoTranslation* ssdstiffenertrans[kssdstiffenernumber];
2441 for(Int_t i=0; i<kssdstiffenernumber; i++)
2442 ssdstiffenertrans[i] = new TGeoTranslation(0.,i*ssdstiffenerseparation,0.);
2443 /////////////////////////////////////////////////////////////
2444 // SSD Chip System
2445 /////////////////////////////////////////////////////////////
2446 TList* ssdchipsystemlist = GetSSDChipSystem();
2447 Double_t ssdchipseparation = fgkSSDSensorLength
2448 - 2.*fgkSSDModuleStiffenerPosition[1]
2449 - 2.*(fgkSSDStiffenerWidth-fgkSSDStiffenerToChipDist
2450 - 0.5*fgkSSDChipWidth);
2451 Double_t ssdchipsystemlength = (fgkSSDChipNumber-1)*(fgkSSDChipLength
2452 + fgkSSDChipSeparationLength)+fgkSSDChipCablesLength[1];
2453 TGeoTranslation* ssdchipsystemtrans = new TGeoTranslation(0.5*fgkSSDChipCablesLength[1]
2454 - 0.5*ssdchipsystemlength,
2455 0.5*(ssdstiffenerseparation-ssdchipseparation),
2456 - 0.5*(fgkSSDChipHeight+fgkSSDStiffenerHeight));
2457////////////////////////////
2458// Capacitor 0603-2200 nF
2459///////////////////////////
2460 const Int_t knapacitor0603number = 5;
2461 TGeoBBox* capacitor0603shape = new TGeoBBox("Capacitor0603Shape",
2462 0.5*fgkSSDCapacitor0603Length,
9f5fafaf 2463 0.5*(fgkSSDCapacitor0603Width),
bf210566 2464 0.5*fgkSSDCapacitor0603Height);
2465 TGeoVolume* capacitor0603 = new TGeoVolume("Capacitor0603",capacitor0603shape,
2466 fSSDStiffener0603CapacitorMedium);
2467 capacitor0603->SetLineColor(fColorAl);
2468 for(Int_t i=0; i<kmothernumber; i++){
2469 for(Int_t j=0; j<kssdstiffenernumber; j++){
2470 ssdhybridmother[i]->AddNode(ssdstiffener,j+1,ssdstiffenertrans[j]);
2471 for(Int_t k=1; k<knapacitor0603number+1; k++){
9f5fafaf 2472 ssdhybridmother[i]->AddNode(capacitor0603,knapacitor0603number*j+k,
2473 new TGeoTranslation((k-3.)/6*fgkSSDStiffenerLength,
2474 j*ssdstiffenerseparation
2475 + 0.5*((j==0? 1:-1)*fgkSSDStiffenerWidth
2476 + (j==0? -1:+1)*fgkSSDCapacitor0603Width),
2477 - 0.5*(fgkSSDStiffenerHeight+fgkSSDCapacitor0603Height)));
bf210566 2478 }
2479 }
2480 ssdhybridmother[i]->AddNode((TGeoVolume*)ssdchipsystemlist->At(i),i+1,ssdchipsystemtrans);
2481 ssdhybridlist->Add(ssdhybridmother[i]);
2482 }
2483/////////////////////////////////////////////////////////////
2484// Mother Volume Containing Capacitor Part
2485/////////////////////////////////////////////////////////////
2486 const Int_t kcapacitormothernumber = 8;
2487 Double_t xcapacitorvertex[kcapacitormothernumber];
2488 Double_t ycapacitorvertex[kcapacitormothernumber];
2489 ///////////////////////
2490 // Setting the vertices
2491 ///////////////////////
2492 xcapacitorvertex[0] = -fgkSSDConnectorPosition[0]+ssdstiffenershape->GetDX();
2493 xcapacitorvertex[1] = xcapacitorvertex[0];
2494 xcapacitorvertex[2] = 0.5*fgkSSDFlexHoleWidth;
2495 xcapacitorvertex[3] = xcapacitorvertex[2];
2496 xcapacitorvertex[4] = xcapacitorvertex[0];
2497 xcapacitorvertex[5] = xcapacitorvertex[0];
2498 xcapacitorvertex[6] = -xcapacitorvertex[0];
2499 xcapacitorvertex[7] = xcapacitorvertex[6];
2500 ycapacitorvertex[0] = -0.5*fgkSSDStiffenerWidth;
2501 ycapacitorvertex[1] = ssdstiffenerseparation-0.5*fgkSSDStiffenerWidth-fgkSSDFlexHoleLength;
2502 ycapacitorvertex[2] = ycapacitorvertex[1];
2503 ycapacitorvertex[3] = ycapacitorvertex[2]+fgkSSDFlexHoleLength;
2504 ycapacitorvertex[4] = ycapacitorvertex[3];
2505 ycapacitorvertex[5] = ycapacitorvertex[4]+fgkSSDStiffenerWidth;
2506 ycapacitorvertex[6] = ycapacitorvertex[5];
2507 ycapacitorvertex[7] = ycapacitorvertex[0];
2508 TGeoXtru* ssdhybridcapacitormothershape = new TGeoXtru(2);
2509 ssdhybridcapacitormothershape->DefinePolygon(kcapacitormothernumber,xcapacitorvertex,
2510 ycapacitorvertex);
2511 ssdhybridcapacitormothershape->DefineSection(0,0.5*fgkSSDStiffenerHeight);
2512 ssdhybridcapacitormothershape->DefineSection(1, 0.5*fgkSSDStiffenerHeight+fgkSSDCapacitor1812Height);
ca86fdb4 2513// TGeoVolume* ssdhybridcapacitormother = new TGeoVolume("SSDHybridCapacitorMother",ssdhybridcapacitormothershape,
2514// fSSDAir);
2515 TGeoVolumeAssembly* ssdhybridcapacitormother = new TGeoVolumeAssembly("SSDHybridCapacitorMother");
bf210566 2516////////////////////////////
2517// Connector
2518///////////////////////////
2519 const Int_t kssdconnectornumber = 2;
2520 TGeoBBox* ssdconnectorshape[kssdconnectornumber];
2521 Double_t ssdAlconnectororigin[3] = {0.0,0.0,0.5*(fgkSSDStiffenerHeight+fgkSSDConnectorAlHeight)};
2522 Double_t ssdNiconnectororigin[3] = {0.0,0.0,0.5*(fgkSSDStiffenerHeight+fgkSSDConnectorNiHeight)
2523 + fgkSSDConnectorAlHeight};
2524 const char* ssdconnectorname[kssdconnectornumber] = {"SSDConnectorAl","SSDConnectorNi"};
2525 TGeoVolume* ssdconnector[kssdconnectornumber];
2526 for(Int_t i=0; i<kssdconnectornumber; i++){
2527 ssdconnectorshape[i] = new TGeoBBox(0.5*fgkSSDConnectorLength,
2528 0.5*fgkSSDConnectorWidth,
2529 0.5*((1-i)*fgkSSDConnectorAlHeight
2530 + i*fgkSSDConnectorNiHeight),
2531 i==0? ssdAlconnectororigin : ssdNiconnectororigin);
2532 ssdconnector[i] = new TGeoVolume(ssdconnectorname[i],ssdconnectorshape[i],
2533 i==0 ? fSSDAlTraceFlexMedium
2534 : fSSDStiffenerConnectorMedium);
2535 ssdconnector[i]->SetLineColor(i==0 ? fColorAl : fColorPhynox);
2536 }
2537 TGeoTranslation* ssdconnectortrans[2*kssdconnectornumber];
2538 ssdconnectortrans[0] = new TGeoTranslation(-ssdstiffenershape->GetDX()
2539 + fgkSSDConnectorPosition[0]
2540 - fgkSSDConnectorSeparation
2541 - 1.5*fgkSSDConnectorLength,
2542 ssdstiffenerseparation+ssdstiffenershape->GetDY()
2543 - fgkSSDConnectorPosition[1]
2544 - ssdconnectorshape[0]->GetDY(),0.0);
2545 ssdconnectortrans[1] = new TGeoTranslation(
2546 - ssdstiffenershape->GetDX()
2547 + fgkSSDConnectorPosition[0]
2548 - 0.5*fgkSSDConnectorLength,
2549 ssdstiffenerseparation+ssdstiffenershape->GetDY()
2550 - fgkSSDConnectorPosition[1]
2551 - ssdconnectorshape[0]->GetDY(),0.0);
2552 ssdconnectortrans[2] = new TGeoTranslation(+ssdstiffenershape->GetDX()
2553 - fgkSSDConnectorPosition[0]
2554 + fgkSSDConnectorSeparation
2555 + 1.5*fgkSSDConnectorLength,
2556 -(ssdstiffenershape->GetDY()
2557 - fgkSSDConnectorPosition[1]
2558 - ssdconnectorshape[0]->GetDY()),0.0);
2559 ssdconnectortrans[3] = new TGeoTranslation(+ssdstiffenershape->GetDX()
2560 - fgkSSDConnectorPosition[0]
2561 + 0.5*fgkSSDConnectorLength,
2562 -(ssdstiffenershape->GetDY()
2563 - fgkSSDConnectorPosition[1]
2564 - ssdconnectorshape[0]->GetDY()),0.0);
2565 for(Int_t i=0; i<2*kssdconnectornumber; i++)
2566 for(Int_t j=0; j<kssdconnectornumber; j++)
2567 ssdhybridcapacitormother->AddNode(ssdconnector[j],i+1,ssdconnectortrans[i]);
2568////////////////////////////
2569// Capacitor 1812-330 nF
2570///////////////////////////
2571 Double_t ssdcapacitor1812origin[3] = {0.0,0.0,0.5*(fgkSSDStiffenerHeight+fgkSSDCapacitor1812Height)};
2572 TGeoBBox* capacitor1812shape = new TGeoBBox("Capacitor1812Shape",
2573 0.5*fgkSSDCapacitor1812Length,
2574 0.5*fgkSSDCapacitor1812Width,
2575 0.5*fgkSSDCapacitor1812Height,
2576 ssdcapacitor1812origin);
2577 TGeoVolume* capacitor1812 = new TGeoVolume("Capacitor1812",capacitor1812shape,
2578 fSSDStiffener1812CapacitorMedium);
2579 capacitor1812->SetLineColor(fColorAl);
2580 TGeoTranslation* capacitor1812trans = new TGeoTranslation(0.0,
2581 0.5*fgkSSDStiffenerWidth+ssdstiffenerseparation
2582 - capacitor1812shape->GetDY()-fgkSSDConnectorPosition[1],0.0);
2583 ssdhybridcapacitormother->AddNode(capacitor1812,1,capacitor1812trans);
2584////////////////////////////
2585//Hybrid Wire
2586////////////////////////////
2587 Double_t wirex = 2.*(fgkSSDConnectorPosition[0]-0.5*fgkSSDStiffenerLength
2588 - 0.5*fgkSSDConnectorLength)-fgkSSDConnectorLength
2589 - fgkSSDConnectorSeparation;
2590 Double_t wirey = ssdstiffenerseparation+fgkSSDStiffenerWidth
2591 - 2.*fgkSSDConnectorPosition[1]-fgkSSDConnectorWidth;
2592 Double_t ssdwireradius = TMath::Sqrt(TMath::Power(wirex,2.)
2593 + TMath::Power(wirey,2));
2594 Double_t wireangle = TMath::ATan(wirex/wirey);
2595 TGeoTube *hybridwireshape = new TGeoTube("HybridWireShape", 0.,
2596 fgkSSDWireRadius, 0.5*ssdwireradius);
2597 TGeoVolume* hybridwire = new TGeoVolume("HybridWire",hybridwireshape,
2598 fSSDStiffenerHybridWireMedium);
2599 hybridwire->SetLineColor(fColorPhynox);
2600 TGeoCombiTrans* hybridwirecombitrans[2];
2601 hybridwirecombitrans[0] = new TGeoCombiTrans("HybridWireCombiTrans1",
2602 0.5*fgkSSDStiffenerLength-fgkSSDConnectorPosition[0]
2603 + 1.5*fgkSSDConnectorLength+fgkSSDConnectorSeparation,
2604 0.5*ssdwireradius-0.5*fgkSSDStiffenerWidth
2605 + fgkSSDConnectorPosition[1]+0.5*fgkSSDConnectorWidth,
2606 ssdstiffenershape->GetDZ()
2607 + fgkSSDWireRadius+fgkSSDConnectorAlHeight+fgkSSDConnectorNiHeight,
2608 new TGeoRotation("HybridWireRot1",0.,90.,0.));
2609 hybridwirecombitrans[1] = new TGeoCombiTrans("HybridWireCombiTrans2",
2610 0.0,
2611 - 0.5*fgkSSDConnectorWidth+fgkSSDWireRadius,
2612 0.0,
2613 new TGeoRotation("HybridWireRot2",
2614 - wireangle*TMath::RadToDeg(),0.,0.));
2615 TGeoHMatrix* hybridwirematrix = new TGeoHMatrix();
2616 hybridwirematrix->MultiplyLeft(hybridwirecombitrans[0]);
2617 hybridwirematrix->MultiplyLeft(hybridwirecombitrans[1]);
2618 ssdhybridcapacitormother->AddNode(hybridwire,1,hybridwirematrix);
2619 ssdhybridlist->Add(ssdhybridcapacitormother);
2620 /////////////////////////////////////////////////////////////
2621 // Deallocating memory
2622 /////////////////////////////////////////////////////////////
2623 delete hybridwirecombitrans[0];
2624 delete hybridwirecombitrans[1];
2625 delete ssdchipsystemlist;
2626 return ssdhybridlist;
44285dfa 2627 /////////////////////////////////////////////////////////////
d7599219 2628}
bf210566 2629///////////////////////////////////////////////////////////////////////////////
2630TGeoVolume* AliITSv11GeometrySSD::GetCoolingBlockSystem(){
2631 /////////////////////////////////////////////////////////////
2632 // SSD Cooling Block System
2633 /////////////////////////////////////////////////////////////
2634 // SSD Cooling Block and Cooling Tube Transformations
2635 /////////////////////////////////////////////////////////////
2636 TGeoRotation* localcoolingblockrot = new TGeoRotation();
2637 localcoolingblockrot->SetAngles(0.,90.,0.);
535e8862 2638 TGeoCombiTrans localcoolingblockmatrix(0.,0.5*fgkSSDCoolingBlockWidth,0.,localcoolingblockrot);
bf210566 2639 TVector3* coolingblocktransvector;
2640 coolingblocktransvector = new TVector3(fgkSSDModuleSensorSupportDistance
2641 + fgkSSDCoolingBlockLength,
2642 fgkSSDSensorLength
2643 - 2.*fgkSSDModuleStiffenerPosition[1]
2644 - fgkSSDCoolingBlockWidth);
2645 const Int_t kcoolingblocktransnumber = 2;
2646 const Int_t kcoolingblocknumber = 4;
2647 TGeoHMatrix* coolingblockmatrix[kcoolingblocknumber];
2648 TGeoHMatrix* coolingtubematrix[kcoolingblocknumber];
2649 TGeoRotation* localcoolingtuberot = new TGeoRotation();
2650 localcoolingtuberot->SetAngles(0.0,90.0,0.0);
2651 TGeoTranslation* localcoolingtubetrans = new TGeoTranslation();
2652 localcoolingtubetrans->SetTranslation(0.5*fgkSSDCoolingBlockLength,
535e8862 2653 0.5*fgkSSDCoolingBlockWidth,
2654 fgkSSDCoolingBlockHoleCenter);
2655 TGeoCombiTrans localcoolingtubematrix (*localcoolingtubetrans,*localcoolingtuberot);
bf210566 2656 Double_t coolingtubedistance = fgkCoolingTubeSupportRmax-fgkCoolingTubeSupportRmin;
2657 for(Int_t i=0; i<kcoolingblocktransnumber; i++){
535e8862 2658 for(Int_t j=0; j<kcoolingblocktransnumber; j++){
2659 TGeoTranslation localcoolingblocktrans(i*coolingblocktransvector->X()+2*coolingtubedistance,
2660 j*coolingblocktransvector->Y(),
2661 - 0.5*(fgkSSDCoolingBlockHoleCenter
2662 + fgkCoolingTubeRmax));
2663 coolingblockmatrix[2*i+j] = new TGeoHMatrix(localcoolingblocktrans*localcoolingblockmatrix);
2664 coolingtubematrix[2*i+j] = new TGeoHMatrix(localcoolingblocktrans*localcoolingtubematrix);
2665 }
bf210566 2666 }
44285dfa 2667 /////////////////////////////////////////////////////////////
bf210566 2668 // Virtual Volume containing CoolingBlock System
44285dfa 2669 /////////////////////////////////////////////////////////////
bf210566 2670 TGeoXtru* coolingsystemothershape = new TGeoXtru(2);
2671 const Int_t kmothervertexnumber = 16;
2672 Double_t xmothervertex[kmothervertexnumber];
2673 Double_t ymothervertex[kmothervertexnumber];
2674 ///////////////////////
2675 // Setting the vertices
2676 ///////////////////////fgkCoolingTubeSupportRmax
2677 xmothervertex[0] = 0.0,ymothervertex[0] = 0.0;
2678 xmothervertex[1] = xmothervertex[0], ymothervertex[1] = coolingblocktransvector->Y()
2679 + fgkSSDCoolingBlockWidth;
2680 xmothervertex[2] = coolingblocktransvector->X()
2681 + fgkSSDCoolingBlockLength
2682 + 4*coolingtubedistance;
2683 ymothervertex[2] = ymothervertex[1];
2684 xmothervertex[3] = xmothervertex[2], ymothervertex[3] = ymothervertex[0];
2685 xmothervertex[4] = xmothervertex[3]-2.*coolingtubedistance-fgkSSDCoolingBlockLength;
2686 ymothervertex[4] = ymothervertex[0];
2687 xmothervertex[5] = xmothervertex[4], ymothervertex[5] = fgkSSDCoolingBlockWidth;
2688 xmothervertex[6] = xmothervertex[3]-coolingtubedistance;
2689 ymothervertex[6] = ymothervertex[5];
2690 xmothervertex[7] = xmothervertex[6], ymothervertex[7] = ymothervertex[2]
2691 - fgkSSDCoolingBlockWidth;
2692 xmothervertex[8] = xmothervertex[5], ymothervertex[8] = ymothervertex[7];
2693 xmothervertex[9] = xmothervertex[8], ymothervertex[9] = ymothervertex[2]
2694 - coolingtubedistance;
2695 xmothervertex[10] = fgkSSDCoolingBlockLength+2.*coolingtubedistance;
2696 ymothervertex[10] = ymothervertex[9];
2697 xmothervertex[11] = xmothervertex[10], ymothervertex[11] = ymothervertex[8];
2698 xmothervertex[12] = coolingtubedistance, ymothervertex[12] = ymothervertex[11];
2699 xmothervertex[13] = xmothervertex[12], ymothervertex[13] = fgkSSDCoolingBlockWidth;
2700 xmothervertex[14] = 2.*coolingtubedistance+fgkSSDCoolingBlockLength;
2701 ymothervertex[14] = ymothervertex[13];
2702 xmothervertex[15] = xmothervertex[14], ymothervertex[15] = ymothervertex[0];
2703 //////////////////////////////////////////////////////////
2704 coolingsystemothershape->DefinePolygon(kmothervertexnumber,
2705 xmothervertex,ymothervertex);
2706 coolingsystemothershape->DefineSection(0,-0.5*(fgkSSDCoolingBlockHoleCenter
2707 + fgkCoolingTubeRmax));
2708 coolingsystemothershape->DefineSection(1, 0.5*(fgkSSDCoolingBlockHoleCenter
2709 + fgkCoolingTubeRmax));
ca86fdb4 2710 TGeoVolume* coolingsystemother = new TGeoVolumeAssembly("CoolingBlockSystem");
2711// TGeoVolume* coolingsystemother = new TGeoVolume("CoolingBlockSystem",
2712// coolingsystemothershape,fSSDAir);
bf210566 2713 /////////////////////////////////////////////////////////////
2714 // SSD Cooling Tube Part
2715 /////////////////////////////////////////////////////////////
2716 TGeoTube* coolingtubeshape[fgkcoolingtubenumber];
2717 coolingtubeshape[0] = new TGeoTube(fgkCoolingTubeRmin,fgkCoolingTubeRmax,
ca86fdb4 2718 0.5*(fgkSSDCoolingBlockWidth-fgkSSDTolerance));
bf210566 2719 coolingtubeshape[1] = new TGeoTube(0.0,fgkCoolingTubeRmin,
ca86fdb4 2720 0.5*(fgkSSDCoolingBlockWidth-fgkSSDTolerance));
bf210566 2721 TGeoVolume* coolingtube[fgkcoolingtubenumber];
2722 coolingtube[0] = new TGeoVolume("OuterCoolingTube",coolingtubeshape[0],
2723 fSSDCoolingTubePhynox);
2724 coolingtube[1] = new TGeoVolume("InnerCoolingTube",coolingtubeshape[1],
2725 fSSDCoolingTubeWater);
2726 coolingtube[0]->SetLineColor(fColorPhynox);
2727 coolingtube[1]->SetLineColor(fColorWater);
2728 TGeoVolume* ssdcoolingblock = GetSSDCoolingBlock(30);
2729 /////////////////////////////////////////////////////////////
2730 // Adding Cooling block to mother volume
2731 /////////////////////////////////////////////////////////////
2732 for(Int_t i=0; i<kcoolingblocknumber; i++){
9f5fafaf 2733 coolingsystemother->AddNode(ssdcoolingblock,i+1,coolingblockmatrix[i]);
bf210566 2734 coolingsystemother->AddNode(coolingtube[0],i+1,coolingtubematrix[i]);
2735 coolingsystemother->AddNode(coolingtube[1],i+1,coolingtubematrix[i]);
2736 }
2737 /////////////////////////////////////////////////////////////
2738 // Deallocating memory
2739 /////////////////////////////////////////////////////////////
2740 delete coolingblocktransvector;
bf210566 2741 delete localcoolingblockrot;
bf210566 2742 delete localcoolingtubetrans;
2743 delete localcoolingtuberot;
2744 /////////////////////////////////////////////////////////////
2745 // Checking overlaps
2746 /////////////////////////////////////////////////////////////
6727e2db 2747 //coolingsystemother->CheckOverlaps(0.01);
bf210566 2748 /////////////////////////////////////////////////////////////
2749 return coolingsystemother;
d7599219 2750}
bf210566 2751/////////////////////////////////////////////////////////////////////////////////
2752TGeoVolume* AliITSv11GeometrySSD::GetSSDStiffenerFlex()const{
44285dfa 2753 /////////////////////////////////////////////////////////////
bf210566 2754 // SSD Flex
44285dfa 2755 /////////////////////////////////////////////////////////////
bf210566 2756 const Int_t kssdflexlayernumber = 2;
2757 TGeoXtru* ssdflexshape[kssdflexlayernumber];
2758 for(Int_t i=0; i<kssdflexlayernumber; i++) ssdflexshape[i] = new TGeoXtru(2);
2759 const Int_t kmothervertexnumber = 17;
2760 Double_t xmothervertex[kmothervertexnumber];
2761 Double_t ymothervertex[kmothervertexnumber];
2762 /////////////////////////////////////////////
2763 // Auxiliary variables for vertex positioning
2764 /////////////////////////////////////////////
2765 const Int_t kssdflexboxnumber = 5;
2766 Double_t ssdflexboxlength[kssdflexboxnumber];
2767 ssdflexboxlength[0] = 0.5*(fgkSSDChipNumber
2768 * fgkSSDChipLength+(fgkSSDChipNumber-1)
2769 * fgkSSDChipSeparationLength
2770 - fgkSSDModuleSensorSupportDistance-fgkSSDFlexHoleLength)
2771 - (fgkSSDFlexLength[0]-fgkSSDFlexLength[1]);
2772 ssdflexboxlength[1] = fgkSSDModuleSensorSupportDistance+fgkSSDFlexHoleLength;
2773 ssdflexboxlength[2] = 0.5*(fgkSSDModuleSensorSupportDistance
2774 - fgkSSDFlexHoleLength-fgkSSDFlexHoleWidth);
2775 ssdflexboxlength[3] = fgkSSDFlexHoleWidth;
2776 ssdflexboxlength[4] = fgkSSDFlexLength[1]-ssdflexboxlength[0]
2777 - ssdflexboxlength[1];
2778 Double_t ssdflexboxwidth[kssdflexboxnumber];
2779 ssdflexboxwidth[0] = fgkSSDFlexWidth[0];
2780 ssdflexboxwidth[1] = fgkSSDFlexWidth[0]-fgkSSDFlexHoleWidth;
2781 ssdflexboxwidth[2] = fgkSSDFlexHoleWidth;
2782 ssdflexboxwidth[3] = ssdflexboxwidth[2]-fgkSSDFlexHoleLength;
2783 ssdflexboxwidth[4] = fgkSSDFlexWidth[0];
2784 ///////////////////////
2785 // Setting the vertices
2786 ///////////////////////
2787 xmothervertex[0] = 0.0;
2788 xmothervertex[1] = xmothervertex[0];
2789 xmothervertex[2] = fgkSSDFlexLength[0]-fgkSSDFlexLength[1];
2790 xmothervertex[3] = xmothervertex[2]+ssdflexboxlength[0]+ssdflexboxlength[1]
2791 + ssdflexboxlength[4];
2792 xmothervertex[4] = xmothervertex[3];
2793 xmothervertex[5] = xmothervertex[4]-ssdflexboxlength[4];
2794 xmothervertex[6] = xmothervertex[5];
2795 xmothervertex[7] = xmothervertex[6]-fgkSSDFlexHoleLength;
2796 xmothervertex[8] = xmothervertex[7];
2797 xmothervertex[9] = xmothervertex[8]-ssdflexboxlength[2];
2798 xmothervertex[10] = xmothervertex[9];
2799 xmothervertex[11] = xmothervertex[10]-ssdflexboxlength[3];
2800 xmothervertex[12] = xmothervertex[11];
2801 xmothervertex[13] = xmothervertex[12]-ssdflexboxlength[2];
2802 xmothervertex[14] = xmothervertex[13];
2803 xmothervertex[15] = xmothervertex[14]-fgkSSDFlexHoleLength;
2804 xmothervertex[16] = xmothervertex[15];
2805 ymothervertex[0] = 0.0;
2806 ymothervertex[1] = fgkSSDFlexWidth[1];
2807 ymothervertex[2] = fgkSSDFlexWidth[0];
2808 ymothervertex[3] = ymothervertex[2];
2809 ymothervertex[4] = ymothervertex[0];
2810 ymothervertex[5] = ymothervertex[4];
2811 ymothervertex[6] = ssdflexboxwidth[2];
2812 ymothervertex[7] = ymothervertex[6];
2813 ymothervertex[8] = ymothervertex[0];
2814 ymothervertex[9] = ymothervertex[8];
2815 ymothervertex[10] = ssdflexboxwidth[2]-ssdflexboxwidth[3];
2816 ymothervertex[11] = ymothervertex[10];
2817 ymothervertex[12] = ymothervertex[0];
2818 ymothervertex[13] = ymothervertex[12];
2819 ymothervertex[14] = ymothervertex[7];
2820 ymothervertex[15] = ymothervertex[14];
2821 ymothervertex[16] = ymothervertex[0];
2822 /////////////////////////////////////////////////////////////
2823 // First Mother Volume containing SSDFlex
2824 /////////////////////////////////////////////////////////////
2825 TGeoXtru* ssdflexmothershape = new TGeoXtru(2);
2826 ssdflexmothershape->DefinePolygon(kmothervertexnumber,xmothervertex,
2827 ymothervertex);
2828 ssdflexmothershape->DefineSection(0,-1.5*fgkSSDFlexHeight[0]-2.*fgkSSDFlexHeight[1]);
2829 ssdflexmothershape->DefineSection(1, 0.5*fgkSSDFlexHeight[0]);
ca86fdb4 2830 TGeoVolumeAssembly* ssdflexmother = new TGeoVolumeAssembly("SSDFlexMother");
2831// TGeoVolume* ssdflexmother = new TGeoVolume("SSDFlexMother",ssdflexmothershape,
2832// fSSDAir);
bf210566 2833 /////////////////////////////////////////////////////////////
2834 // SSDFlex Layer Shapes
2835 /////////////////////////////////////////////////////////////
2836 for(Int_t i=0; i<kssdflexlayernumber; i++){
2837 ssdflexshape[i]->DefinePolygon(kmothervertexnumber,xmothervertex,
2838 ymothervertex);
2839 ssdflexshape[i]->DefineSection(0,-0.5*fgkSSDFlexHeight[i]);
2840 ssdflexshape[i]->DefineSection(1, 0.5*fgkSSDFlexHeight[i]);
2841 }
2842 /////////////////////////////////////
2843 // Setting Layers into Mother Volume
2844 /////////////////////////////////////
2845 Int_t ssdflexcolor[kssdflexlayernumber] = {fColorAl,fColorPolyhamide};
2846 TGeoMedium* ssdflexmed[kssdflexlayernumber] = {fSSDAlTraceFlexMedium,
2847 fSSDKaptonFlexMedium};
2848 const char* ssdflexname[2*kssdflexlayernumber] = {"AlFlexLay1","KaptonFlexLay1",
2849 "AlFlexLay2","KaptonFlexLay2"};
2850 TGeoVolume* ssdflex[2*kssdflexlayernumber];
2851 TGeoTranslation* ssdflextrans[2*kssdflexlayernumber];
2852 for(Int_t i=0; i<2*kssdflexlayernumber; i++){
2853 ssdflex[i] = new TGeoVolume(ssdflexname[i],
2854 i%2==0 ? ssdflexshape[0] : ssdflexshape[1],
2855 i%2==0 ? ssdflexmed[0] : ssdflexmed[1]);
2856 ssdflex[i]->SetLineColor(i%2==0 ? ssdflexcolor[0] : ssdflexcolor[1]);
2857 ssdflextrans[i] = new TGeoTranslation(0.,0.,-0.5*i*(fgkSSDFlexHeight[0]
2858 + fgkSSDFlexHeight[1]));
2859 ssdflexmother->AddNode(ssdflex[i],1,ssdflextrans[i]);
2860 }
bf210566 2861 return ssdflexmother;
2862}
2863/////////////////////////////////////////////////////////////////////////////////
2864TGeoVolume* AliITSv11GeometrySSD::GetSSDEndFlex(){
2865 /////////////////////////////////////////////////////////////
2866 // Method generating SSD End Flex
2867 /////////////////////////////////////////
2868 Double_t ssdflexradiusmax = (fgkSSDFlexLength[3]-fgkSSDFlexLength[2])
2869 / TMath::Tan(fgkSSDFlexAngle*TMath::DegToRad());
2870 Double_t ssdflexboxlength = fgkSSDFlexFullLength-2.*fgkSSDFlexAngle
2871 * TMath::DegToRad()*ssdflexradiusmax
2872 - fgkSSDFlexLength[2]-TMath::Pi()
2873 * fgkSSDStiffenerHeight-fgkSSDFlexLength[0];
2874 const Int_t knedges = 20;
2875 const Int_t karcnumber = 2;
2876 TVector3* vertexposition[karcnumber*(knedges+1)];
2877 Double_t deltangle[karcnumber] = {2.*fgkSSDFlexAngle/knedges,180.0/knedges};
2878 Double_t angle[karcnumber] = {90.-2.*fgkSSDFlexAngle,180.0};
2879 Double_t radius[karcnumber] = {ssdflexradiusmax-fgkSSDStiffenerHeight,fgkSSDStiffenerHeight};
2880 Double_t referenceangle[karcnumber] = {-180.0*TMath::DegToRad(),
2881 - 90.0*TMath::DegToRad()};
2882 TVector3* referencetrans[karcnumber];
2883 referencetrans[0] = new TVector3(ssdflexboxlength*CosD(2.*fgkSSDFlexAngle)
2884 + radius[0]*SinD(2.*fgkSSDFlexAngle),
2885 radius[0]);
2886 referencetrans[1] = new TVector3(referencetrans[0]->X()
2887 + fgkSSDFlexLength[2],
2888 - fgkSSDStiffenerHeight);
2889for(Int_t i=0; i<karcnumber; i++){
2890 for(Int_t j=0; j<knedges+1; j++){
2891 vertexposition[j+i*(knedges+1)] = new TVector3(radius[i]*CosD(angle[i]),
2892 radius[i]*SinD(angle[i]));
2893 angle[i] += deltangle[i]*(1.0-2.0*i);
2894 }
2895 }
2896 ///////////////////////
2897 // Setting the vertices
2898 ///////////////////////
2899 const Int_t kendflexlayernumber = 4;
2900 const Int_t kendflexvertexnumber = 4*(knedges+1)+2;
2901 TVector3** vertex[kendflexlayernumber];
2902 for(Int_t i=0; i<kendflexlayernumber; i++)
2903 vertex[i] = new TVector3*[kendflexvertexnumber];
2904 TVector3* transvector[kendflexlayernumber+1];
2905 TVector3* deltatransvector = new TVector3();
2906 for(Int_t i=0; i<kendflexlayernumber+1; i++) transvector[i] = new TVector3();
2907 transvector[0]->SetXYZ(0.0,ssdflexboxlength*SinD(2.*fgkSSDFlexAngle)
2908 + radius[0]*(1.0-CosD(2.*fgkSSDFlexAngle)),0.0);
2909 for(Int_t i=1; i<kendflexlayernumber+1; i++){
2910 deltatransvector->SetXYZ((i%2!=0?fgkSSDFlexHeight[0]:fgkSSDFlexHeight[1])
2911 * CosD(fgkSSDFlexAngle),
2912 (i%2!=0?fgkSSDFlexHeight[0]:fgkSSDFlexHeight[1])
2913 * SinD(fgkSSDFlexAngle),0.0);
2914 *transvector[i] = *transvector[i-1]+*deltatransvector;
2915 }
2916 Double_t ratioradius[karcnumber][kendflexlayernumber+1];
2917 ratioradius[0][0] = 1., ratioradius[1][0] = 1.;
2918 for(Int_t i=0; i<karcnumber; i++){
2919 for(Int_t j=1; j<kendflexlayernumber+1; j++){
2920 ratioradius[i][j] = ratioradius[i][j-1]-TMath::Power(-1.0,i)
2921 * (j%2!=0?fgkSSDFlexHeight[0]:fgkSSDFlexHeight[1])
2922 /radius[i];
2923 }
2924 }
2925 for(Int_t i=0; i<kendflexlayernumber; i++){
2926 vertex[i][0] = new TVector3(transvector[i]->X(),transvector[i]->Y());
2927 vertex[i][1] = new TVector3(transvector[i+1]->X(),transvector[i+1]->Y());
2928 for(Int_t j=0; j<karcnumber*(knedges+1); j++){
2929 if(j<(knedges+1)){
2930 vertex[i][j+2] = new TVector3(vertexposition[j]->X()*ratioradius[0][i+1],
2931 vertexposition[j]->Y()*ratioradius[0][i+1]);
2932 vertex[i][j+2]->RotateZ(referenceangle[0]);
2933 *vertex[i][j+2] += *referencetrans[0];
2934 vertex[i][4*(knedges+1)-j+1] =
2935 new TVector3(vertexposition[j]->X()*ratioradius[0][i],
2936 vertexposition[j]->Y()*ratioradius[0][i]);
2937 vertex[i][4*(knedges+1)-j+1]->RotateZ(referenceangle[0]);
2938 *vertex[i][4*(knedges+1)-j+1] += *referencetrans[0];
2939 }
2940 else{
2941
2942 vertex[i][j+2] = new TVector3(vertexposition[j]->X()*ratioradius[1][i+1],
2943 vertexposition[j]->Y()*ratioradius[1][i+1]);
2944 vertex[i][j+2]->RotateZ(referenceangle[1]);
2945 *vertex[i][j+2] += *referencetrans[1];
2946 vertex[i][4*(knedges+1)-j+1] =
2947 new TVector3(vertexposition[j]->X()*ratioradius[1][i],
2948 vertexposition[j]->Y()*ratioradius[1][i]);
2949 vertex[i][4*(knedges+1)-j+1]->RotateZ(referenceangle[1]);
2950 *vertex[i][4*(knedges+1)-j+1] += *referencetrans[1];
2951 }
2952 }
2953 }
2954 /////////////////////////////////////////////////////////////
2955 // First Mother Volume containing SSDEndFlex
2956 /////////////////////////////////////////////////////////////
2957 TGeoXtru* ssdendflexmothershape = new TGeoXtru(2);
2958 Double_t xmothervertex[kendflexvertexnumber];
2959 Double_t ymothervertex[kendflexvertexnumber];
2960 xmothervertex[0] = vertex[0][0]->X();
2961 ymothervertex[0] = vertex[0][0]->Y();
2962 for(Int_t i=1; i<kendflexvertexnumber; i++){
2963 if(i<2*(knedges+1)+2){
2964 xmothervertex[i] = vertex[3][i]->X();
2965 ymothervertex[i] = vertex[3][i]->Y();
2966 }
2967 else{
2968 xmothervertex[i] = vertex[0][i]->X();
2969 ymothervertex[i] = vertex[0][i]->Y();
2970 }
2971 }
2972 ssdendflexmothershape->DefinePolygon(kendflexvertexnumber,
2973 xmothervertex,ymothervertex);
2974 ssdendflexmothershape->DefineSection(0,-0.5*fgkSSDFlexWidth[0]);
2975 ssdendflexmothershape->DefineSection(1, 0.5*fgkSSDFlexWidth[0]);
2976 TGeoVolume* ssdendflexmother = new TGeoVolume("SSDEndFlexMother",
2977 ssdendflexmothershape,fSSDAir);
2978 //////////////////////////////////////
2979 // End Flex TGeoXtru Layer Definition
2980 //////////////////////////////////////
2981 TGeoXtru* ssdendflexshape[kendflexlayernumber];
2982 TGeoVolume* ssdendflex[kendflexlayernumber];
2983 for(Int_t i=0; i<kendflexlayernumber; i++) ssdendflexshape[i] = new TGeoXtru(2);
2984 Double_t xvertex[kendflexlayernumber][kendflexvertexnumber];
2985 Double_t yvertex[kendflexlayernumber][kendflexvertexnumber];
2986 Int_t ssdendflexcolor[kendflexlayernumber] = {fColorAl,fColorPolyhamide};
2987 TGeoMedium* ssdendflexmed[kendflexlayernumber] = {fSSDAlTraceFlexMedium,
2988 fSSDKaptonFlexMedium};
2989 const char* ssdendflexname[kendflexlayernumber] = {"AlEndFlexLay1","KaptonEndFlexLay1",
2990 "AlEndFlexLay2","KaptonEndFlexLay2"};
2991 for(Int_t i=0; i<kendflexlayernumber; i++){
2992 for(Int_t j=0; j<4*(knedges+1)+2; j++){
2993 xvertex[i][j] = vertex[i][j]->X();
2994 yvertex[i][j] = vertex[i][j]->Y();
2995 }
2996 ssdendflexshape[i]->DefinePolygon(kendflexvertexnumber,xvertex[i],yvertex[i]);
2997 ssdendflexshape[i]->DefineSection(0,-0.5*fgkSSDFlexWidth[0]);
2998 ssdendflexshape[i]->DefineSection(1, 0.5*fgkSSDFlexWidth[0]);
2999 ssdendflex[i] = new TGeoVolume(ssdendflexname[i],ssdendflexshape[i],
3000 i%2==0 ? ssdendflexmed[0] : ssdendflexmed[1]);
3001 ssdendflex[i]->SetLineColor(i%2==0 ? ssdendflexcolor[0] : ssdendflexcolor[1]);
3002 ssdendflexmother->AddNode(ssdendflex[i],1);
3003 }
3004 /////////////////////////////////////////////////////////////
3005 // Deallocating memory
3006 /////////////////////////////////////////////////////////////
3007 for(Int_t i=0; i<karcnumber*(knedges+1); i++) delete vertexposition[i];
3008 for(Int_t i=0; i<karcnumber; i++) delete referencetrans[i];
3009 for(Int_t i=0; i<kendflexlayernumber; i++){
3010 for(Int_t j=0; j<kendflexvertexnumber; j++) delete vertex[i][j];
3011 delete [] vertex[i];
3012 }
3013 for(Int_t i=0; i<kendflexlayernumber+1; i++) delete transvector[i];
3014 delete deltatransvector;
3015 /////////////////////////////////////////////////////////////
6727e2db 3016 //ssdendflexmother->CheckOverlaps(0.01);
bf210566 3017 return ssdendflexmother;
d7599219 3018}
9b0c60ab 3019///////////////////////////////////////////////////////////////////////////////
d7599219 3020TGeoVolume* AliITSv11GeometrySSD::GetSSDMountingBlock(){
44285dfa 3021 /////////////////////////////////////////////////////////////
9b0c60ab 3022 // Method generating the Mounting Block
44285dfa 3023 /////////////////////////////////////////////////////////////
9b0c60ab 3024 const Int_t kvertexnumber = 8;
3025 Double_t xvertex[kvertexnumber];
3026 Double_t yvertex[kvertexnumber];
3027 xvertex[0] = -0.25*(fgkSSDMountingBlockLength[0]-fgkSSDMountingBlockLength[1]);
3028 xvertex[1] = xvertex[0];
3029 xvertex[2] = -xvertex[0];
3030 xvertex[3] = xvertex[2];
3031 xvertex[4] = xvertex[3]+0.5*(fgkSSDMountingBlockLength[1]
3032 - fgkSSDMountingBlockLength[2]);
3033 xvertex[5] = xvertex[4];
3034 xvertex[6] = 0.5*fgkSSDMountingBlockLength[0]-xvertex[2]
3035 - 0.5*fgkSSDMountingBlockScrewHoleEdge
3036 - fgkSSDMountingBlockScrewHoleRadius[0];
3037 xvertex[7] = xvertex[6];
3038 yvertex[0] = -0.5*fgkCoolingTubeSupportHeight-fgkSSDModuleCoolingBlockToSensor
e21cdd03 3039 + fgkSSDMountingBlockHeight[1]-0.5*fgkSSDMountingBlockHeight[0]
3040 - fgkSSDModuleVerticalDisalignment;
9b0c60ab 3041 yvertex[1] = 0.5*fgkSSDMountingBlockHeight[0];
3042 yvertex[2] = yvertex[1];
3043 yvertex[3] = fgkSSDMountingBlockHeight[1]-yvertex[1];
3044 yvertex[4] = yvertex[3];
3045 yvertex[5] = yvertex[2]+fgkSSDMountingBlockHeight[2]
3046 - fgkSSDMountingBlockHeight[0];
3047 yvertex[6] = yvertex[5];
3048 yvertex[7] = yvertex[0];
3049 ///////////////////////////////////////////////////////////////////////
3050 // TGeoXTru Volume definition for Mounting Block Part
3051 ///////////////////////////////////////////////////////////////////////
3052 TGeoXtru* ssdmountingblockshape = new TGeoXtru(2);
3053 ssdmountingblockshape->DefinePolygon(kvertexnumber,xvertex,yvertex);
3054 ssdmountingblockshape->DefineSection(0,-0.5*fgkSSDMountingBlockWidth);
3055 ssdmountingblockshape->DefineSection(1,0.5*fgkSSDMountingBlockWidth);
44285dfa 3056 TGeoVolume* ssdmountingblock = new TGeoVolume("SSDMountingBlock",
9b0c60ab 3057 ssdmountingblockshape,
3058 fSSDMountingBlockMedium);
3059 ssdmountingblock->SetLineColor(fColorG10);
3060 TGeoCombiTrans* mountingblockcombitrans = new TGeoCombiTrans();
3061 mountingblockcombitrans->SetTranslation(2.*xvertex[2]+fgkSSDMountingBlockLength[1],0.,0.);
3062 TGeoRotation* mountingblockrot = new TGeoRotation();
3063 mountingblockrot->SetAngles(90.,180.,-90.);
3064 mountingblockcombitrans->SetRotation(*mountingblockrot);
3065 /////////////////////////////////////////////////////////////
3066 // Generating the Mounting Block Screw Vertices
3067 /////////////////////////////////////////////////////////////
3068 const Int_t kscrewvertexnumber = 15;
3069 Double_t alpha = TMath::ACos(0.5*(fgkSSDMountingBlockHeight[1]
3070 - fgkSSDMountingBlockScrewHoleEdge)
3071 / fgkSSDMountingBlockScrewHoleRadius[0])
3072 * TMath::RadToDeg();
3073 Double_t phi0 = 90.+alpha;
3074 Double_t phi = 270.-2*alpha;
3075 Double_t deltaphi = phi/kscrewvertexnumber;
3076 TVector3* screwvertex[kscrewvertexnumber+1];
3077 for(Int_t i=0; i<kscrewvertexnumber+1; i++)
3078 screwvertex[i] = new TVector3(fgkSSDMountingBlockScrewHoleRadius[0]
3079 *CosD(phi0+i*deltaphi),
3080 fgkSSDMountingBlockScrewHoleRadius[0]
3081 *SinD(phi0+i*deltaphi));
3082 Double_t xscrewvertex[kscrewvertexnumber+6];
3083 Double_t yscrewvertex[kscrewvertexnumber+6];
3084 xscrewvertex[0] = - fgkSSDMountingBlockScrewHoleRadius[0];
3085 yscrewvertex[0] = -0.5*(fgkSSDMountingBlockWidth
3086 - fgkSSDMountingBlockScrewHoleEdge);
3087 xscrewvertex[1] = xscrewvertex[0];
3088 yscrewvertex[1] = 0.5*fgkSSDMountingBlockScrewHoleEdge;
3089 xscrewvertex[2] = screwvertex[0]->X();
3090 yscrewvertex[2] = yscrewvertex[1];
3091 for(Int_t i=0; i<kscrewvertexnumber+1; i++){
3092 xscrewvertex[i+3] = screwvertex[i]->X();
3093 yscrewvertex[i+3] = screwvertex[i]->Y();
3094 }
3095 xscrewvertex[kscrewvertexnumber+4] = 0.5*fgkSSDMountingBlockScrewHoleEdge;
3096 yscrewvertex[kscrewvertexnumber+4] = yscrewvertex[kscrewvertexnumber+3];
3097 xscrewvertex[kscrewvertexnumber+5] = xscrewvertex[kscrewvertexnumber+4];
3098 yscrewvertex[kscrewvertexnumber+5] = yscrewvertex[0];
3099 TGeoXtru* ssdmountingblockscrewshape = new TGeoXtru(2);
3100 ssdmountingblockscrewshape->DefinePolygon(kscrewvertexnumber+6,xscrewvertex,yscrewvertex);
3101 ssdmountingblockscrewshape->DefineSection(0,yvertex[0]);
3102 ssdmountingblockscrewshape->DefineSection(1,-0.5*fgkSSDMountingBlockHeight[0]
3103 + fgkSSDMountingBlockHeight[2]);
3104 TGeoVolume* ssdmountingblockscrew = new TGeoVolume("SSDMountingBlockScrew",
3105 ssdmountingblockscrewshape,
3106 fSSDMountingBlockMedium);
3107 ssdmountingblockscrew->SetLineColor(fColorG10);
3108 TGeoCombiTrans* ssdmountingblockscrewcombitrans[4];
3109 for(Int_t i=0; i<4; i++) ssdmountingblockscrewcombitrans[i] = new TGeoCombiTrans();
3110 ssdmountingblockscrewcombitrans[0]->SetTranslation(-0.5*fgkSSDMountingBlockScrewHoleEdge,
3111 - yscrewvertex[1],
3112 0.5*fgkSSDMountingBlockHeight[0]
3113 - fgkSSDMountingBlockHeight[2]
3114 + 0.5*(-0.5*fgkSSDMountingBlockHeight[0]
3115 + fgkSSDMountingBlockHeight[2]
3116 - yvertex[0]));
3117 ssdmountingblockscrewcombitrans[1]->SetTranslation(0.5*fgkSSDMountingBlockScrewHoleEdge,
3118 -0.5*fgkSSDMountingBlockScrewHoleEdge,
3119 yscrewvertex[1]
3120 -0.5*(-0.5*fgkSSDMountingBlockHeight[0]
3121 +fgkSSDMountingBlockHeight[2]
3122 -yvertex[0]));
3123 ssdmountingblockscrewcombitrans[2]->SetTranslation(-0.5*fgkSSDMountingBlockScrewHoleEdge,
3124 yscrewvertex[1],
3125 - 0.5*fgkSSDMountingBlockHeight[0]
3126 + fgkSSDMountingBlockHeight[2]
3127 - 0.5*(-0.5*fgkSSDMountingBlockHeight[0]
3128 + fgkSSDMountingBlockHeight[2]
3129 - yvertex[0]));
3130 ssdmountingblockscrewcombitrans[3]->SetTranslation(0.5*fgkSSDMountingBlockScrewHoleEdge,
3131 yscrewvertex[1],
3132 - yscrewvertex[1]
3133 + 0.5*(-0.5*fgkSSDMountingBlockHeight[0]
3134 + fgkSSDMountingBlockHeight[2]
3135 - yvertex[0]));
3136 TGeoRotation* ssdmountingblockscrewrot[4];
3137 for(Int_t i=0; i<4; i++) ssdmountingblockscrewrot[i] = new TGeoRotation();
3138 ssdmountingblockscrewrot[1]->SetAngles(90.,-180.,-90.);
3139 ssdmountingblockscrewrot[2]->SetAngles(0.,180.,0.);
3140 ssdmountingblockscrewrot[3]->SetAngles(180.,0.,0.);
3141 for(Int_t i=1; i<4; i++)
3142 ssdmountingblockscrewcombitrans[i]->SetRotation(*ssdmountingblockscrewrot[i]);
3143 TGeoRotation* ssdmountingblockglobalrot = new TGeoRotation();
3144 ssdmountingblockglobalrot->SetAngles(0.,90.,0.);
3145 TGeoTranslation* ssdmountingblockglobaltrans = new TGeoTranslation();
3146 ssdmountingblockglobaltrans->SetTranslation(0.5*fgkSSDMountingBlockLength[0]
3147 + xvertex[0],yscrewvertex[1]
3148 - 0.5*(-0.5*fgkSSDMountingBlockHeight[0]
3149 + fgkSSDMountingBlockHeight[2]
3150 - yvertex[0]),0.);
3151 TGeoHMatrix* ssdmountingblockscrewmatrix[4];
3152 for(Int_t i=0; i<4; i++){
3153 ssdmountingblockscrewmatrix[i] =
3154 new TGeoHMatrix((*ssdmountingblockglobalrot)*(*ssdmountingblockscrewcombitrans[i]));
3155 ssdmountingblockscrewmatrix[i]->MultiplyLeft(ssdmountingblockglobaltrans);
3156 }
3157 ///////////////////////////////////////////////////////////////////////
3158 // TGeoXtru for Mother Volume
3159 ///////////////////////////////////////////////////////////////////////
3160 const Int_t kvertexmothernumber = 12;
3161 Double_t xmothervertex[kvertexmothernumber];
3162 Double_t ymothervertex[kvertexmothernumber];
3163 for(Int_t i=0; i<6; i++){
3164 xmothervertex[i] = xvertex[i];
3165 ymothervertex[i] = yvertex[i];
3166 }
3167 xmothervertex[6] = xvertex[5]+fgkSSDMountingBlockLength[2];
3168 ymothervertex[6] = ymothervertex[5];
3169 xmothervertex[7] = xmothervertex[6];
3170 ymothervertex[7] = ymothervertex[4];
3171 xmothervertex[8] = xmothervertex[7]
3172 + 0.5*(fgkSSDMountingBlockLength[1]
3173 - fgkSSDMountingBlockLength[2]);
3174 ymothervertex[8] = ymothervertex[4];
3175 xmothervertex[9] = xmothervertex[8];
3176 ymothervertex[9] = ymothervertex[2];
3177 xmothervertex[10] = xvertex[0]+fgkSSDMountingBlockLength[0];
3178 ymothervertex[10] = ymothervertex[1];
3179 xmothervertex[11] = xmothervertex[10];
3180 ymothervertex[11] = ymothervertex[0];
3181 TGeoXtru* ssdmountingblockmothershape = new TGeoXtru(2);
3182 ssdmountingblockmothershape->DefinePolygon(kvertexmothernumber,xmothervertex,ymothervertex);
3183 ssdmountingblockmothershape->DefineSection(0,-0.5*fgkSSDMountingBlockWidth);
3184 ssdmountingblockmothershape->DefineSection(1,0.5*fgkSSDMountingBlockWidth);
3185 TGeoVolume* ssdmountingblockmother = new TGeoVolume("SSDMountingBlockMother",
3186 ssdmountingblockmothershape,
3187 fSSDAir);
3188 /////////////////////////////////////////////////////////////
3189 // Placing the Volumes into Mother Volume
3190 /////////////////////////////////////////////////////////////
3191 ssdmountingblockmother->AddNode(ssdmountingblock,1);
3192 ssdmountingblockmother->AddNode(ssdmountingblock,2,mountingblockcombitrans);
3193 for(Int_t i=0; i<4; i++)
3194 ssdmountingblockmother->AddNode(ssdmountingblockscrew,i+1,
3195 ssdmountingblockscrewmatrix[i]);
3196 /////////////////////////////////////////////////////////////
3197 // Deallocating memory
3198 /////////////////////////////////////////////////////////////
3199 delete mountingblockrot;
3200 for(Int_t i=0; i<4; i++) delete ssdmountingblockscrewrot[i];
3201 delete ssdmountingblockglobalrot;
3202 delete ssdmountingblockglobaltrans;
3203 /////////////////////////////////////////////////////////////
3204 return ssdmountingblockmother;
3205}
3206///////////////////////////////////////////////////////////////////////////////
3207 TGeoVolume* AliITSv11GeometrySSD::GetMountingBlockClip() const {
3208 /////////////////////////////////////////////////////////////
3209 // Method generating the Mounting Block Clip
3210 /////////////////////////////////////////////////////////////
3211 const Int_t kmothervertexnumber = 10;
3212 Double_t xmothervertex[kmothervertexnumber];
3213 Double_t ymothervertex[kmothervertexnumber];
3214 xmothervertex[0] = -0.25*(fgkSSDMountingBlockLength[0]-fgkSSDMountingBlockLength[1])
3215 - 0.5*(fgkSSDSensorWidth-fgkSSDMountingBlockLength[0]);
3216 xmothervertex[1] = xmothervertex[0];
3217 xmothervertex[2] = xmothervertex[0]+0.5*(fgkMountingBlockClibScrewPosition
3218 - fgkMountingBlockClibScrewRadius);
3219 xmothervertex[3] = xmothervertex[2];
3220 xmothervertex[4] = xmothervertex[3]+2.*fgkMountingBlockClibScrewRadius;
3221 xmothervertex[5] = xmothervertex[4];
3222 xmothervertex[6] = xmothervertex[0]+fgkMountingBlockClipLength;
3223 xmothervertex[7] = xmothervertex[6];
3224 xmothervertex[8] = -0.25*(fgkSSDMountingBlockLength[0]-fgkSSDMountingBlockLength[1]);
3225 xmothervertex[9] = xmothervertex[8];
3226 ymothervertex[0] = -0.5*fgkCoolingTubeSupportHeight-fgkSSDModuleCoolingBlockToSensor
e21cdd03 3227 + fgkSSDMountingBlockHeight[1]-0.5*fgkSSDMountingBlockHeight[0]
3228 - fgkSSDModuleVerticalDisalignment;
9b0c60ab 3229 ymothervertex[1] = 0.5*fgkSSDMountingBlockHeight[0]+fgkMountingBlockClipThickness;
3230 ymothervertex[2] = ymothervertex[1];
3231 ymothervertex[3] = ymothervertex[2]+(fgkSSDMountingBlockHeight[1]
3232 - fgkSSDMountingBlockHeight[0]-fgkMountingBlockClipThickness
3233 - 0.5*fgkCoolingTubeSupportHeight-fgkCoolingTubeSupportRmax);
3234 ymothervertex[4] = ymothervertex[3];
3235 ymothervertex[5] = ymothervertex[2];
3236 ymothervertex[6] = ymothervertex[5];
3237 ymothervertex[7] = ymothervertex[6]-fgkMountingBlockClipThickness;
3238 ymothervertex[8] = ymothervertex[7];
3239 ymothervertex[9] = ymothervertex[0];
3240 ///////////////////////////////////////////////////////////////////////
3241 // TGeoXTru Volume definition for Mounting Block Clip Part
3242 ///////////////////////////////////////////////////////////////////////
3243 TGeoXtru* ssdmountingblockclipshape = new TGeoXtru(2);
3244 ssdmountingblockclipshape->DefinePolygon(kmothervertexnumber,xmothervertex,ymothervertex);