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