compilation warnings
[u/mrichter/AliRoot.git] / ITS / AliITSv11GeometrySDD.cxx
CommitLineData
db486a6e 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. *
108bd0fe 14 *********************************s*****************************************/
db486a6e 15
b7943f00 16
db486a6e 17//*************************************************************************
effd7456 18//
db486a6e 19// SDD geometry, based on ROOT geometrical modeler
20//
effd7456 21//
22// This geometry has no dependence with aliroot, you can run it with root
23// only, provided that the AliITSv11GeomCable classes are also compiled
24//
b7943f00 25// Ludovic Gaudichet gaudichet@to.infn.it
db486a6e 26//*************************************************************************
27
28
73dfc864 29// $Id$
30
db486a6e 31
32// General Root includes
db486a6e 33#include <TMath.h>
34
35// Root Geometry includes
36#include <TGeoManager.h>
37#include <TGeoVolume.h>
db486a6e 38#include <TGeoCone.h>
39#include <TGeoTube.h>
108bd0fe 40#include <TGeoTrd1.h>
db486a6e 41#include <TGeoArb8.h>
42#include <TGeoCompositeShape.h>
43#include <TGeoMatrix.h>
c789ee28 44#include <TGeoNode.h>
bf210566 45#include <TGeoPcon.h>
db486a6e 46
b7943f00 47#include "AliITSgeom.h"
48#include "AliITSgeomSDD.h"
db486a6e 49#include "AliITSv11GeometrySDD.h"
b7943f00 50#include "AliITSv11GeomCableFlat.h"
51#include "AliITSv11GeomCableRound.h"
b7943f00 52
108bd0fe 53const char* AliITSv11GeometrySDD::fgSDDsensitiveVolName3 = "ITSsddSensitivL3";
54const char* AliITSv11GeometrySDD::fgSDDsensitiveVolName4 = "ITSsddSensitivL4";
b7943f00 55const Double_t AliITSv11GeometrySDD::fgkSegmentLength = 37.2*2*fgkmm;
56const Double_t AliITSv11GeometrySDD::fgkLadderWidth = 50.0*fgkmm;
57const Double_t AliITSv11GeometrySDD::fgkLadderHeight = 30.0*fgkmm;
58const Double_t AliITSv11GeometrySDD::fgkLadderSegBoxDW = 3.5*fgkmm;
59const Double_t AliITSv11GeometrySDD::fgkLadderSegBoxDH = 3.*fgkmm;
60
61const Double_t AliITSv11GeometrySDD::fgkLadderBeamRadius = 0.6*fgkmm;
62const Double_t AliITSv11GeometrySDD::fgkLadderLa = 3.*fgkmm;
fa4639a3 63const Double_t AliITSv11GeometrySDD::fgkLadderHa = 0.721979*fgkmm;
b7943f00 64const Double_t AliITSv11GeometrySDD::fgkLadderLb = 3.7*fgkmm;
fa4639a3 65const Double_t AliITSv11GeometrySDD::fgkLadderHb = 0.890428*fgkmm;
b7943f00 66const Double_t AliITSv11GeometrySDD::fgkLadderl = 0.25*fgkmm;
67
68const Double_t AliITSv11GeometrySDD::fgkBottomBeamAngle = 56.5;
69const Double_t AliITSv11GeometrySDD::fgkBeamSidePhi = 65;
70
71const Double_t AliITSv11GeometrySDD::fgkLadWaferSep = 2*fgkmm;
fa4639a3 72const Double_t AliITSv11GeometrySDD::fgkPinSuppWidth = 2.5*fgkmm;
73const Double_t AliITSv11GeometrySDD::fgkPinSuppHeight = 2.*fgkmm;
b7943f00 74const Double_t AliITSv11GeometrySDD::fgkPinSuppRmax = 2.5/2.*fgkmm;
75const Double_t AliITSv11GeometrySDD::fgkPinR = 1.5/2.*fgkmm;
76const Double_t AliITSv11GeometrySDD::fgkPinSuppLength = 5.*fgkmm;
77const Double_t AliITSv11GeometrySDD::fgkPinSuppThickness = 0.5*fgkmm;
78const Double_t AliITSv11GeometrySDD::fgkPinSuppConeAngle = 4;
79const Double_t AliITSv11GeometrySDD::fgkPinDXminOnSensor = (39./2.)*fgkmm;
80const Double_t AliITSv11GeometrySDD::fgkPinPinDDXOnSensor = 3*fgkmm;
81const Double_t AliITSv11GeometrySDD::fgkPinDYOnSensor = (52.5/2.)*fgkmm;
db486a6e 82
b7943f00 83// parameters from ALR-0752/3
84const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppHeight = 3.2*fgkmm;
85const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppMaxLength = 14*fgkmm;
86const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppWidthExt = 0.4*fgkmm;
87const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppWidthIn = 0.65*fgkmm;
88const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppHoleDiam = 2*fgkmm;
89const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppFulWidth = 5.15*fgkmm;
90const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppTongW = 0.8*fgkmm;
91const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppAngle = 22.5;
92const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppSlitL = 4.9*fgkmm;
93const Double_t AliITSv11GeometrySDD::fgkCoolPipeSuppAxeDist = 3.05*fgkmm;
94const Double_t AliITSv11GeometrySDD::fgkCoolPipeInnerDiam = 1.84*fgkmm;
95const Double_t AliITSv11GeometrySDD::fgkCoolPipeOuterDiam = 2.*fgkmm;
96
97const Double_t AliITSv11GeometrySDD::fgkBTBthick = 0.25 *fgkmm;
98const Double_t AliITSv11GeometrySDD::fgkBTBlength = 55. *fgkmm;
99const Double_t AliITSv11GeometrySDD::fgkBTBwidth = 18*fgkmm;
100const Double_t AliITSv11GeometrySDD::fgkBTBaxisAtoBottom = 4*fgkmm;
101const Double_t AliITSv11GeometrySDD::fgkBTBaxisAtoBase = 1.2*fgkmm;
102const Double_t AliITSv11GeometrySDD::fgkRadiusAminBTB = 1. *fgkmm;
103const Double_t AliITSv11GeometrySDD::fgkRadiusBminBTB = 0.53 *fgkmm;
104const Double_t AliITSv11GeometrySDD::fgkBTBHoleLength = 15 *fgkmm;
105const Double_t AliITSv11GeometrySDD::fgkBTBHolewidth = 6 *fgkmm;
106const Double_t AliITSv11GeometrySDD::fgkBTBHoleRefX = 10 *fgkmm;
107const Double_t AliITSv11GeometrySDD::fgkBTBHoleRefY = 6.5 *fgkmm;
108
bf210566 109const Double_t AliITSv11GeometrySDD::fgkLay3Rmin = 145.*fgkmm;
110const Double_t AliITSv11GeometrySDD::fgkLay3Rmax = 200.*fgkmm;
b7943f00 111const Double_t AliITSv11GeometrySDD::fgkLay3Length = (524.+0.)*fgkmm; // ladder+supporting rings (length of the virtual tube)
112const Double_t AliITSv11GeometrySDD::fgkLay3LadderLength = 524.*fgkmm;
113const Double_t AliITSv11GeometrySDD::fgkLay3DetShortRadius = 146.0*fgkmm;
114const Double_t AliITSv11GeometrySDD::fgkLay3DetLongRadius = 152.0*fgkmm;
115const Double_t AliITSv11GeometrySDD::fgkLay3LaddTopCornerEnd = 15.6*fgkmm;
116const Int_t AliITSv11GeometrySDD::fgkLay3Ndet = 6;
117const Int_t AliITSv11GeometrySDD::fgkLay3Nladd = 14;
118const Double_t AliITSv11GeometrySDD::fgkLay3CoolPipeSuppH = 7.5*fgkmm;
119
bf210566 120const Double_t AliITSv11GeometrySDD::fgkLay4Rmin = 235.*fgkmm;
121const Double_t AliITSv11GeometrySDD::fgkLay4Rmax = 286.*fgkmm;
b7943f00 122const Double_t AliITSv11GeometrySDD::fgkLay4Length = (671.+0.)*fgkmm; // ladder+supporting rings (length of the virtual tube)
123const Double_t AliITSv11GeometrySDD::fgkLay4LadderLength = 671.*fgkmm;
124const Double_t AliITSv11GeometrySDD::fgkLay4DetShortRadius = 235.0*fgkmm;
125const Double_t AliITSv11GeometrySDD::fgkLay4DetLongRadius = 240.5*fgkmm;
126const Double_t AliITSv11GeometrySDD::fgkLay4LaddTopCornerEnd = 15.6*fgkmm;
127const Int_t AliITSv11GeometrySDD::fgkLay4Ndet = 8;
128const Int_t AliITSv11GeometrySDD::fgkLay4Nladd = 22;
129const Double_t AliITSv11GeometrySDD::fgkLay4CoolPipeSuppH = 7.5*fgkmm;
130
bf210566 131const Double_t AliITSv11GeometrySDD::fgkEndLaddCardsShortRadiusLay3 = fgkLay3DetShortRadius;
132const Double_t AliITSv11GeometrySDD::fgkEndLaddCardsShortRadiusLay4 = fgkLay4DetShortRadius;
133const Double_t AliITSv11GeometrySDD::fgkDistEndLaddCardsLadd = 0.*fgkmm;
134
b7943f00 135//hybrid
136const Double_t AliITSv11GeometrySDD::fgkHybridAngle = 46; // approx !!!
137// Origine taken at the hybrid corner :
138const Double_t AliITSv11GeometrySDD::fgkHybridLength = 65*fgkmm;
139const Double_t AliITSv11GeometrySDD::fgkHybridWidth = 41*fgkmm;
140const Double_t AliITSv11GeometrySDD::fgkHybRndHoleRad = 1.05*fgkmm;
141const Double_t AliITSv11GeometrySDD::fgkHybRndHoleZ = 2.5*fgkmm;
142const Double_t AliITSv11GeometrySDD::fgkHybRndHoleX = fgkHybridWidth-23.599*fgkmm;
143
144const Double_t AliITSv11GeometrySDD::fgkHybFLlowHoleDZ = 9.698*fgkmm;
145const Double_t AliITSv11GeometrySDD::fgkHybFLlowHolePasDX = 10.754*fgkmm;
146const Double_t AliITSv11GeometrySDD::fgkHybFLlowHoleAmbDX = 9.122*fgkmm;
147 // center of ships to the border
148const Double_t AliITSv11GeometrySDD::fgkHybFLlowChipZ4 = fgkHybridLength-(4.654 )*fgkmm-fgkHybFLlowHoleDZ/2;
149const Double_t AliITSv11GeometrySDD::fgkHybFLlowChipZ3 = fgkHybridLength-(4.654+15. )*fgkmm-fgkHybFLlowHoleDZ/2;
150const Double_t AliITSv11GeometrySDD::fgkHybFLlowChipZ2 = fgkHybridLength-(4.654+15.*2)*fgkmm-fgkHybFLlowHoleDZ/2;
151const Double_t AliITSv11GeometrySDD::fgkHybFLlowChipZ1 = fgkHybridLength-(4.654+15.*3)*fgkmm-fgkHybFLlowHoleDZ/2;
152const Double_t AliITSv11GeometrySDD::fgkHybFLlowPasX = fgkHybridWidth-32.775*fgkmm;
153const Double_t AliITSv11GeometrySDD::fgkHybFLlowAmbX = fgkHybridWidth-20.791*fgkmm;
154const Double_t AliITSv11GeometrySDD::fgkHybChipsDZ = 9.221*fgkmm;
155const Double_t AliITSv11GeometrySDD::fgkHybPascalDX = 10.245*fgkmm;
156const Double_t AliITSv11GeometrySDD::fgkHybAmbraDX = 8.51*fgkmm;
157const Double_t AliITSv11GeometrySDD::fgkHybFLUpperWidth = 15.012*fgkmm;
158const Double_t AliITSv11GeometrySDD::fgkHybFLUpperLength = 59.878*fgkmm;
159const Double_t AliITSv11GeometrySDD::fgkHybFLUpperAlDZ = 11.183*fgkmm;
160const Double_t AliITSv11GeometrySDD::fgkHybFLUpperAldx = 2.307*fgkmm;
531d6cdc 161
162const Double_t AliITSv11GeometrySDD::fgkmu = 1*fgkmicron; // 1*fgkmicron; // can be increase for checking thin objects
b7943f00 163const Double_t AliITSv11GeometrySDD::fgkHybridThBridgeThick = 0.25*fgkmm; // ???
164const Double_t AliITSv11GeometrySDD::fgkHybAlThick = 30*fgkmu;
165const Double_t AliITSv11GeometrySDD::fgkHybUpThick = 20*fgkmu;
166const Double_t AliITSv11GeometrySDD::fgkHybGlueScrnThick = 50*fgkmu; // ??? ?????
167const Double_t AliITSv11GeometrySDD::fgkHybGlueLowThick = 90*fgkmu;
168const Double_t AliITSv11GeometrySDD::fgkHybGlueUpThick = 90*fgkmu; // sur ?????
169const Double_t AliITSv11GeometrySDD::fgkHybAlCCThick = 12*fgkmu;
170const Double_t AliITSv11GeometrySDD::fgkHybUpCCThick = 12*fgkmu;
171const Double_t AliITSv11GeometrySDD::fgkHybChipThick = 150*fgkmu;
172const Double_t AliITSv11GeometrySDD::fgkHybGlueAgThick = 50*fgkmu; // ??? ????
173const Double_t AliITSv11GeometrySDD::fgkHybUnderNiThick = 20*fgkmu; // ??? ????
174const Int_t AliITSv11GeometrySDD::fgkNHybSMD = 25;
175const Double_t AliITSv11GeometrySDD::fgkHybSMDposX[fgkNHybSMD] =
176 {2.92*fgkmm,6.5*fgkmm,10.13*fgkmm,13.59*fgkmm,21.40*fgkmm,
177 2.92*fgkmm,6.5*fgkmm,10.13*fgkmm,13.59*fgkmm,19.91*fgkmm,
178 2.92*fgkmm,6.5*fgkmm,10.13*fgkmm,13.59*fgkmm,17.09*fgkmm,21.40*fgkmm,
179 2.92*fgkmm,6.5*fgkmm,10.13*fgkmm,13.59*fgkmm,19.91*fgkmm,
180 1.63*fgkmm,5.22*fgkmm,13.59*fgkmm,21.40*fgkmm};
181const Double_t AliITSv11GeometrySDD::fgkHybSMDposZ[fgkNHybSMD] =
182 { 2.3 *fgkmm, 2.3 *fgkmm, 2.3 *fgkmm, 2.3 *fgkmm, 2.3 *fgkmm,
183 17.315*fgkmm,17.315*fgkmm,17.315*fgkmm,17.315*fgkmm,17.315*fgkmm,
184 32.31*fgkmm,32.31*fgkmm,32.31*fgkmm,32.31*fgkmm,32.31*fgkmm,32.31*fgkmm,
185 47.38*fgkmm,47.38*fgkmm,47.38*fgkmm,47.38*fgkmm,47.38*fgkmm,
186 62.68*fgkmm,62.06*fgkmm,62.06*fgkmm,62.06*fgkmm};
187const Double_t AliITSv11GeometrySDD::fgkHybSMDmiddleW = 0.954*fgkmm;
188const Double_t AliITSv11GeometrySDD::fgkHybSMDmiddleL = 0.47 *fgkmm;
189const Double_t AliITSv11GeometrySDD::fgkHybSMDendW = 1.132*fgkmm;
190const Double_t AliITSv11GeometrySDD::fgkHybSMDendL = 0.925*fgkmm;
191const Double_t AliITSv11GeometrySDD::fgkHybSMDheight = 400.*fgkmu; // ??? ????!!!!!!!
192
193const Double_t AliITSv11GeometrySDD::fgkWaferThickness = 300.*fgkmu;
194const Double_t AliITSv11GeometrySDD::fgkWaferWidth = 72.5 *fgkmm;
195const Double_t AliITSv11GeometrySDD::fgkWaferLength = 87.6 *fgkmm;
196const Double_t AliITSv11GeometrySDD::fgkWaferThickSens = 299.8*fgkmu;
197const Double_t AliITSv11GeometrySDD::fgkWaferWidthSens = 70.17*fgkmm;
03d34d83 198// 256 anodes times 294 microns of pitch
199const Double_t AliITSv11GeometrySDD::fgkWaferLengthSens = 256*294*fgkmicron;
b7943f00 200
201const Double_t AliITSv11GeometrySDD::fgkDigitCablWidth = 18.4*fgkmm;
202const Double_t AliITSv11GeometrySDD::fgkDigitCablAlThick = (30+30*8./10.)*fgkmicron; // will probably change
203const Double_t AliITSv11GeometrySDD::fgkDigitCablPolyThick = (20+12)*fgkmicron; // will probably change
204
205const Double_t AliITSv11GeometrySDD::fgkWaHVcableAlThick = 30*2./10.*fgkmu; // will probably change // Al ratio is random !!!
206const Double_t AliITSv11GeometrySDD::fgkWaHVcablePolyThick = 175*fgkmu; // will probably change
207const Double_t AliITSv11GeometrySDD::fgkWaHVcableLength = 67.08*fgkmm;
108bd0fe 208const Double_t AliITSv11GeometrySDD::fgkWaHVcableWitdh = 17.4*fgkmm; // check !!!
209const Double_t AliITSv11GeometrySDD::fgkWaHVcableDW = 5.24*fgkmm; //5.24*fgkmm;// check !!!
b7943f00 210
211const Double_t AliITSv11GeometrySDD::fgkSensorGlassLX = 5. *fgkmm;
212const Double_t AliITSv11GeometrySDD::fgkSensorGlassLZ = 5. *fgkmm;
213const Double_t AliITSv11GeometrySDD::fgkSensorGlassLY = 150. *fgkmu;
214const Double_t AliITSv11GeometrySDD::fgkGlassDXOnSensor = 26.28*fgkmm; // check !!!
215const Double_t AliITSv11GeometrySDD::fgkGlassDZOnSensor = 22.50*fgkmm; // check !!!
216
217const Double_t AliITSv11GeometrySDD::fgkTransitHVAlThick = 30*2./10.*fgkmu; // check // will probably change //Al ratio is random
218const Double_t AliITSv11GeometrySDD::fgkTransitHVPolyThick = 100*fgkmu; // check // will probably change
219const Double_t AliITSv11GeometrySDD::fgkTransitHVHeadLX = 71.46*fgkmm; // check !!!
220const Double_t AliITSv11GeometrySDD::fgkTransitHVHeadLZ = 21.3*fgkmm;
221const Double_t AliITSv11GeometrySDD::fgkTransitHVBondingLZ = 3.6*fgkmm;
222const Double_t AliITSv11GeometrySDD::fgkTransitHVtailLength = 27*fgkmm; // ???, not yet fixed ...
223const Double_t AliITSv11GeometrySDD::fgkTransitHVtailWidth = 26*fgkmm;
108bd0fe 224const Double_t AliITSv11GeometrySDD::fgkTransitHVtailXpos = 8*fgkmm; //8*fgkmm // ???, a mesurer !!!
b7943f00 225const Double_t AliITSv11GeometrySDD::fgkTransitHVsideLZ = 10.34*fgkmm;
226const Double_t AliITSv11GeometrySDD::fgkTransitHVsideLeftZ = 4.11*fgkmm;
227const Double_t AliITSv11GeometrySDD::fgkTransitHVsideRightZ = 3.5*fgkmm; // ???, a mesurer !!!
228
229const Double_t AliITSv11GeometrySDD::fgkLongHVcablePolyThick= (20+30+125+30+20+30+125+30+20)*fgkmu; // check // will probably change
230const Double_t AliITSv11GeometrySDD::fgkLongHVcableAlThick = (30+30*2/10+30)*fgkmu; // check // will probably change
231const Double_t AliITSv11GeometrySDD::fgkLongHVcableSeparation = 600*fgkmicron;
c789ee28 232
108bd0fe 233const Double_t AliITSv11GeometrySDD::fgkRubyDX = 14.*fgkmm;
234const Double_t AliITSv11GeometrySDD::fgkRubyZladd3 = 250*fgkmm;
235const Double_t AliITSv11GeometrySDD::fgkRubyZladd4 = 325*fgkmm;
236
237// the stesalite ladder foot at its end
effd7456 238const Double_t AliITSv11GeometrySDD::fgkLadFootX = 60.*fgkmm;
239const Double_t AliITSv11GeometrySDD::fgkLadFootZ = 20.*fgkmm;
240const Double_t AliITSv11GeometrySDD::fgkLadFootY = 8.*fgkmm;
108bd0fe 241const Double_t AliITSv11GeometrySDD::fgkLadFootMiddleY = 4.5*fgkmm;
effd7456 242const Double_t AliITSv11GeometrySDD::fgkLadBox1X = 23.*fgkmm;
243const Double_t AliITSv11GeometrySDD::fgkLadFingerPrintX = 6.*fgkmm;
244const Double_t AliITSv11GeometrySDD::fgkLadFingerPrintY = 1.*fgkmm;
108bd0fe 245const Double_t AliITSv11GeometrySDD::fgkLadFingerPrintBorder = 4.*fgkmm;
246const Double_t AliITSv11GeometrySDD::fgkRubyCageHoleZ = 8.*fgkmm;
247const Double_t AliITSv11GeometrySDD::fgkRubyCageHoleX = 9.*fgkmm;
248const Double_t AliITSv11GeometrySDD::fgkRubyCageHoleY = 6.5*fgkmm;
249const Double_t AliITSv11GeometrySDD::fgkRubyCageAxisShift = 0.5*fgkmm;
250const Double_t AliITSv11GeometrySDD::fgkScrewM4diam = 4.*fgkmm;
251
252const Double_t AliITSv11GeometrySDD::fgkRubyScrewShiftToCenterY = 0.1;
73dfc864 253const Double_t AliITSv11GeometrySDD::fgkRubyHoleDiam = 0.5;
108bd0fe 254
73dfc864 255// the U cooling pipe and its heat exchanger in end-ladder cards system
108bd0fe 256const Double_t AliITSv11GeometrySDD::fgkEndLadPipeUlengthLay3 = 138*fgkmm;
257const Double_t AliITSv11GeometrySDD::fgkEndLadPipeUlengthLay4 = 150*fgkmm;
258const Double_t AliITSv11GeometrySDD::fgkEndLadPipeUwidth = 59*fgkmm;
259const Double_t AliITSv11GeometrySDD::fgkEndLadPipeRadius = 5*fgkmm;
260const Double_t AliITSv11GeometrySDD::fgkEndLadPipeInnerDiam = 2.8*fgkmm;
261const Double_t AliITSv11GeometrySDD::fgkEndLadPipeOuterDiam = 3.*fgkmm;
262//--- The al body of the cooling syst.of the heat exchanger :
73dfc864 263const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmZLay3 = 112.*fgkmm; //
264const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmZLay4 = 125.*fgkmm; //
bf210566 265const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmX = 4.75*fgkmm; // the arms of the U cooling tube
73dfc864 266const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmY = 6.8*fgkmm;
267const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmBoxDY = 1.03*fgkmm; // shift in Y of the arms from the axis
bf210566 268const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmBoxDX = 0.125*fgkmm;// shift in X of the arms from the axis
269const Double_t AliITSv11GeometrySDD::fgkEndLadPipeArmZpos = 8.9*fgkmm; //
108bd0fe 270
271// LV card :
73dfc864 272const Double_t AliITSv11GeometrySDD::fgkLVcardX = 26.525*fgkmm;
273const Double_t AliITSv11GeometrySDD::fgkLVcardY = 44.95*fgkmm;
274const Double_t AliITSv11GeometrySDD::fgkLVcardZ = 1.*fgkmm; // all except Cu layer //???
275const Double_t AliITSv11GeometrySDD::fgkLVcardCuZ = 0.1*fgkmm; //???
effd7456 276
277const Double_t AliITSv11GeometrySDD::fgkLVChip0X = 16.525*fgkmm;
278const Double_t AliITSv11GeometrySDD::fgkLVChip0Y = 10.8*fgkmm;
279const Double_t AliITSv11GeometrySDD::fgkLVChip0Z = 3.5*fgkmm; // all except si layer //???
280const Double_t AliITSv11GeometrySDD::fgkLVChip0SiZ = 0.2*fgkmm; //???????????????????????????????????????????????????
281const Double_t AliITSv11GeometrySDD::fgkLVChip0PosX = 13.*fgkmm; //19.95*fgkmm; ???
282const Double_t AliITSv11GeometrySDD::fgkLVChip0PosY = 10.3*fgkmm;
283
284const Double_t AliITSv11GeometrySDD::fgkLVChip1X = 6.00*fgkmm;
285const Double_t AliITSv11GeometrySDD::fgkLVChip1Y = 6.00*fgkmm;
286const Double_t AliITSv11GeometrySDD::fgkLVChip1Z = 1*fgkmm; // ???
287const Double_t AliITSv11GeometrySDD::fgkLVChip1SiZ = 0.2*fgkmm; // ???
288const Double_t AliITSv11GeometrySDD::fgkLVChip1PosX = 18.*fgkmm;
289const Double_t AliITSv11GeometrySDD::fgkLVChip1PosY = 27.6*fgkmm;
290
291const Double_t AliITSv11GeometrySDD::fgkLVChip2X = 6.00*fgkmm;
292const Double_t AliITSv11GeometrySDD::fgkLVChip2Y = 6.00*fgkmm;
293const Double_t AliITSv11GeometrySDD::fgkLVChip2Z = 1*fgkmm; // ???
294const Double_t AliITSv11GeometrySDD::fgkLVChip2SiZ = 0.2*fgkmm; //???
295const Double_t AliITSv11GeometrySDD::fgkLVChip2PosX = 18.0*fgkmm;
296const Double_t AliITSv11GeometrySDD::fgkLVChip2PosY = 39.0*fgkmm;
297
298const Double_t AliITSv11GeometrySDD::fgkLVChip3X = 4.01*fgkmm;
299const Double_t AliITSv11GeometrySDD::fgkLVChip3Y = 4.01*fgkmm;
300const Double_t AliITSv11GeometrySDD::fgkLVChip3Z = 1*fgkmm; // ???
301const Double_t AliITSv11GeometrySDD::fgkLVChip3SiZ = 0.2*fgkmm;
302const Double_t AliITSv11GeometrySDD::fgkLVChip3PosX = 20.7*fgkmm;
303const Double_t AliITSv11GeometrySDD::fgkLVChip3PosY = 21.4*fgkmm;
304
73dfc864 305const Double_t AliITSv11GeometrySDD::fgkLVcoolX1 = 17.25*fgkmm;
306const Double_t AliITSv11GeometrySDD::fgkLVcoolY1 = 8.7*fgkmm;
307const Double_t AliITSv11GeometrySDD::fgkLVcoolZ1 = 1.*fgkmm;
effd7456 308
73dfc864 309const Double_t AliITSv11GeometrySDD::fgkLVcoolX2 = 3.5*fgkmm;
310const Double_t AliITSv11GeometrySDD::fgkLVcoolY2 = 8.7*fgkmm;
311const Double_t AliITSv11GeometrySDD::fgkLVcoolZ2 = 2.3*fgkmm;
effd7456 312
73dfc864 313const Double_t AliITSv11GeometrySDD::fgkLVcoolX3 = 4.75*fgkmm;
314const Double_t AliITSv11GeometrySDD::fgkLVcoolY3 = 3.1*fgkmm; //+0.1=glue
108bd0fe 315const Double_t AliITSv11GeometrySDD::fgkLVcoolPosY = 6.5*fgkmm;
316
317// HV card :
318const Double_t AliITSv11GeometrySDD::fgkHVCardCeramX = 54.01*fgkmm;
319const Double_t AliITSv11GeometrySDD::fgkHVCardCeramY = 40.89*fgkmm;
320const Double_t AliITSv11GeometrySDD::fgkHVCardCeramZ = 0.7*fgkmm; // ???
321
322const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1X = 6.8*fgkmm;
323const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1Z = 1.*fgkmm; // ???
324const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1Ymid = 4.1*fgkmm;
325const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1Yend = 0.95*fgkmm; // doesn't take into account the soldering
326const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1PosX = 13.1*fgkmm;
327const Double_t AliITSv11GeometrySDD::fgkHVCardCapa1PosY = 14.5*fgkmm;
328
329const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2X = 6.8*fgkmm;
330const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2Z = 1.*fgkmm; // ???
331const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2Ymid = 2.9*fgkmm;
332const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2Yend = 0.95*fgkmm;
333const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2PosX = -12.6*fgkmm;
334const Double_t AliITSv11GeometrySDD::fgkHVCardCapa2PosY = 16.54*fgkmm;
335
336const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3Xmid = 3.0*fgkmm;
337const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3Xend = 0.91*fgkmm;
338const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3Z = 2.*fgkmm; // ???
339const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3Y = 3.43*fgkmm;
340
341const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosX1 = 14.6*fgkmm;
342const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosX2 = 7.2*fgkmm;
343const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosX3 = 2.52*fgkmm;
344const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosX4 = -4.96*fgkmm;
345const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosX5 = -13.82*fgkmm;
346const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosY1 = 6.27*fgkmm;
347const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosY2 = 0.7*fgkmm;
348const Double_t AliITSv11GeometrySDD::fgkHVCardCapa3PosY3 = 9.1*fgkmm;
349
350const Double_t AliITSv11GeometrySDD::fgkHVCardCool1X = 14.*fgkmm;
351const Double_t AliITSv11GeometrySDD::fgkHVCardCool1Y = 9.5*fgkmm;
352const Double_t AliITSv11GeometrySDD::fgkHVCardCool1Z = 2.*fgkmm;
353const Double_t AliITSv11GeometrySDD::fgkHVCardCool2X = 14.25*fgkmm;
354const Double_t AliITSv11GeometrySDD::fgkHVCardCool2Y = 3.5*fgkmm;
355const Double_t AliITSv11GeometrySDD::fgkHVCardCool2Z = 4.5*fgkmm;
356const Double_t AliITSv11GeometrySDD::fgkHVCardCool3X = 4.5*fgkmm;
357const Double_t AliITSv11GeometrySDD::fgkHVCardCool3Y = 3.5*fgkmm;
358const Double_t AliITSv11GeometrySDD::fgkHVCardCool3Z = 7.2*fgkmm;
359const Double_t AliITSv11GeometrySDD::fgkHVCardCoolDY = 6.*fgkmm;
360
73dfc864 361const Double_t AliITSv11GeometrySDD::fgkCarlosSuppX1 = 19.5*fgkmm;
362const Double_t AliITSv11GeometrySDD::fgkCarlosSuppY1 = 2*fgkmm;
363const Double_t AliITSv11GeometrySDD::fgkCarlosSuppX2 = 35.*fgkmm;
364const Double_t AliITSv11GeometrySDD::fgkCarlosSuppY2 = 3.9*fgkmm;
365const Double_t AliITSv11GeometrySDD::fgkCarlosSuppZ = 17.*fgkmm;
366const Double_t AliITSv11GeometrySDD::fgkCarlosSuppAngle = 45;
367const Double_t AliITSv11GeometrySDD::fgkCarlosSuppX3 = 4.5*fgkmm;
368const Double_t AliITSv11GeometrySDD::fgkCarlosSuppY3 = 3.*fgkmm;
369const Double_t AliITSv11GeometrySDD::fgkCarlosSuppZ3 = 12.*fgkmm;
108bd0fe 370const Double_t AliITSv11GeometrySDD::fgkCarlosSuppTopLen = 8.65*fgkmm;
371
73dfc864 372// screws fixing boards to the end-ladder on the U tube
373const Double_t AliITSv11GeometrySDD::fgkLittleScrewHeadR = 1.85*fgkmm;
374const Double_t AliITSv11GeometrySDD::fgkLittleScrewHeadH = 1.5*fgkmm;
375const Double_t AliITSv11GeometrySDD::fgkLittleScrewR = 0.7*fgkmm;
376const Double_t AliITSv11GeometrySDD::fgkShiftLittleScrewLV = 3*fgkmm; // ???
377const Double_t AliITSv11GeometrySDD::fgkLittleLVScrewHeadR = 1.2*fgkmm; // ???
378
379// CARLOS board
380const Double_t AliITSv11GeometrySDD::fgkCarlosCardX1 = (25.50+28.50)*fgkmm; // length (first part of Carlos card)
381const Double_t AliITSv11GeometrySDD::fgkCarlosCardY1 = 1.6*fgkmm; // thickness
382const Double_t AliITSv11GeometrySDD::fgkCarlosCardZ1 = 40.8*fgkmm; // width
383const Double_t AliITSv11GeometrySDD::fgkCarlosCardCuY = 0.1*fgkmm; // thickness of Cu layer (strips)
384const Double_t AliITSv11GeometrySDD::fgkCarlosCardX2 = 25.50*fgkmm; // length (2nd part of Carlos card)
385const Double_t AliITSv11GeometrySDD::fgkCarlosCardZ2 = 8.20*fgkmm; // width
386
387const Double_t AliITSv11GeometrySDD::fgkCarlosCardChipSiThick = 0.1*fgkmm; // ??? idem for all chips ???
388const Double_t AliITSv11GeometrySDD::fgkCarlosCardShift = 9*fgkmm; // ??? shift in z w.r.t. heat bridge
389
390// size and position of various chips on carlos end-ladder board
391const Double_t AliITSv11GeometrySDD::fgkCarlosU1X = 13*fgkmm;
392const Double_t AliITSv11GeometrySDD::fgkCarlosU1Y = 1.68*fgkmm;
393const Double_t AliITSv11GeometrySDD::fgkCarlosU1Z = 13*fgkmm;
394const Double_t AliITSv11GeometrySDD::fgkCarlosU1posX = 18.4*fgkmm;
395const Double_t AliITSv11GeometrySDD::fgkCarlosU1posZ = -7.2*fgkmm;
396
397const Double_t AliITSv11GeometrySDD::fgkCarlosU2X = 13.75*fgkmm;
398const Double_t AliITSv11GeometrySDD::fgkCarlosU2Y = 1.60*fgkmm;
399const Double_t AliITSv11GeometrySDD::fgkCarlosU2Z = 13.85*fgkmm;
400const Double_t AliITSv11GeometrySDD::fgkCarlosU2posX = -0.375*fgkmm;
401const Double_t AliITSv11GeometrySDD::fgkCarlosU2posZ = -9.725*fgkmm;
402
403const Double_t AliITSv11GeometrySDD::fgkCarlosU3X = 5*fgkmm;
404const Double_t AliITSv11GeometrySDD::fgkCarlosU3Y = 1.*fgkmm;
405const Double_t AliITSv11GeometrySDD::fgkCarlosU3Z = 5*fgkmm;
406const Double_t AliITSv11GeometrySDD::fgkCarlosU3posX = 6.4*fgkmm;
407const Double_t AliITSv11GeometrySDD::fgkCarlosU3posZ = 9.9*fgkmm;
408
409// U4 like U3
410const Double_t AliITSv11GeometrySDD::fgkCarlosU4posX = -12*fgkmm;
411const Double_t AliITSv11GeometrySDD::fgkCarlosU4posZ = 3.6*fgkmm;
412
413const Double_t AliITSv11GeometrySDD::fgkCarlosU17X = 16*fgkmm;
414const Double_t AliITSv11GeometrySDD::fgkCarlosU17Y = 3.5*fgkmm;
415const Double_t AliITSv11GeometrySDD::fgkCarlosU17Z = 10.9*fgkmm;
416const Double_t AliITSv11GeometrySDD::fgkCarlosU17posX = -17.84*fgkmm;
417const Double_t AliITSv11GeometrySDD::fgkCarlosU17posZ = -10.95*fgkmm;
418
419const Double_t AliITSv11GeometrySDD::fgkCarlosU35X = 4*fgkmm;
420const Double_t AliITSv11GeometrySDD::fgkCarlosU35Y = 1.*fgkmm;
421const Double_t AliITSv11GeometrySDD::fgkCarlosU35Z = 4*fgkmm;
422const Double_t AliITSv11GeometrySDD::fgkCarlosU35posX = -21.6*fgkmm;
423const Double_t AliITSv11GeometrySDD::fgkCarlosU35posZ = 2.3*fgkmm;
424
425const Double_t AliITSv11GeometrySDD::fgkCarlosU36X = 6*fgkmm;
426const Double_t AliITSv11GeometrySDD::fgkCarlosU36Y = 1.*fgkmm;
427const Double_t AliITSv11GeometrySDD::fgkCarlosU36Z = 6*fgkmm;
428const Double_t AliITSv11GeometrySDD::fgkCarlosU36posX = -21.6*fgkmm;
429const Double_t AliITSv11GeometrySDD::fgkCarlosU36posZ = 9.6*fgkmm;
430
431const Double_t AliITSv11GeometrySDD::fgkCarlosQZ1X = 8*fgkmm;
432const Double_t AliITSv11GeometrySDD::fgkCarlosQZ1Y = 1.7*fgkmm; // look thicker than design number (0.7) ! ???
433const Double_t AliITSv11GeometrySDD::fgkCarlosQZ1Z = 3.7*fgkmm;
434const Double_t AliITSv11GeometrySDD::fgkCarlosQZ1posX = -12*fgkmm;
435const Double_t AliITSv11GeometrySDD::fgkCarlosQZ1posZ = 10.6*fgkmm;
436
437// distance from the heat bridge center to the card center :
438const Double_t AliITSv11GeometrySDD::fgkCarlosCard2HeatBridge = fgkCarlosSuppY2/2+fgkCarlosCardY1/2+fgkCarlosU1Y+0.1*fgkmm;
439
440// some pieces at the end of the carbon fiber ladder
441 const Double_t AliITSv11GeometrySDD::fgkCoolPipeLay3Len = 467.*fgkmm; // ???
442 const Double_t AliITSv11GeometrySDD::fgkCoolPipeLay4Len = 616.*fgkmm; // ???
443 const Double_t AliITSv11GeometrySDD::fgkHVguideX1 = 42.5*fgkmm;
444 const Double_t AliITSv11GeometrySDD::fgkHVguideY1 = 7.*fgkmm;
445 const Double_t AliITSv11GeometrySDD::fgkHVguideZ1 = 10.*fgkmm;
446 const Double_t AliITSv11GeometrySDD::fgkHVguideZ2 = 6.*fgkmm;
447 const Double_t AliITSv11GeometrySDD::fgkHVguideDX = -8.5*fgkmm;
448 const Double_t AliITSv11GeometrySDD::fgkHVguideSuppFullZ = 37.5*fgkmm;
449
450// Cooling connector between phynox and plastic cooling water tubes
451const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeRmin = 1 *fgkmm;
452const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeR1 = 2.5*fgkmm; // ???
453const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeL1 = 3.*fgkmm; // ???
454const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeR2 = 3.5*fgkmm; // ???
455const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeL2 = 2.*fgkmm; // ???
456const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeR3 = 3.*fgkmm; // ???
457const Double_t AliITSv11GeometrySDD::fgkConnectorCoolTubeL3 = 5 *fgkmm; // ???
108bd0fe 458
c789ee28 459
e118532f 460// parameters for coding SDD cables on SDD and SSD cones
461const Double_t AliITSv11GeometrySDD::fgkSectionCuPerMod = 3*2*0.006 + 3*2*0.0005 + 2*0.002;
462// copper : LV + signal + HV(HV ???)
463const Double_t AliITSv11GeometrySDD::fgkSectionPlastPerMod = (TMath::Pi()*(3*0.36*0.36/4 + 3*0.21*0.21/4 + 2*0.115*0.115/4)
464 - fgkSectionCuPerMod);
465
466const Double_t AliITSv11GeometrySDD::fgkSectionGlassPerMod = 3*0.006; // ???
467// (sections are given in cm square)
468const Double_t AliITSv11GeometrySDD::fgkCableBendRatio = 1.3; // ??? this factor account for the bending of cables
469
470const Double_t AliITSv11GeometrySDD::fgkConeSDDr1 = 11.87574*fgkcm;
471const Double_t AliITSv11GeometrySDD::fgkConeSDDr2 = 26.07574*fgkcm;
472const Double_t AliITSv11GeometrySDD::fgkConeSDDz1 = 3.36066*fgkcm + 186.0*fgkmm + 0.5*790.0*fgkmm - 19.18934*fgkcm - 1.6;
473const Double_t AliITSv11GeometrySDD::fgkConeSDDz2 = 17.56066*fgkcm + 186.0*fgkmm + 0.5*790.0*fgkmm - 19.18934*fgkcm - 1.6;
474// These last parameters come from cone's code and define the slope
475// and position of the SDD cone end. For some unknown reason, this doesn't
476// allow to stick on the SDD cone. This has to be checked when a correct
477// version of the cone is available ... For now 'm applying some approximative
478// corrections
479
480const Double_t AliITSv11GeometrySDD::fgkSDDCableR1 = 16*fgkcm; // ??? // part 1 of "cable cone"
481const Double_t AliITSv11GeometrySDD::fgkSDDCableR2 = 23*fgkcm; // ??? // part 1/2 of "cable cone"
482const Double_t AliITSv11GeometrySDD::fgkSDDCableR3 = 26*fgkcm; // ??? // part 2 of "cable cone"
483
484const Double_t AliITSv11GeometrySDD::fgkSDDCableDZint = 3.5*fgkcm;
485const Double_t AliITSv11GeometrySDD::fgkSDDCableR5 = 37*fgkcm; // third part of "cable cone"
486const Double_t AliITSv11GeometrySDD::fgkSDDCableZ5 = 65*fgkcm; // third part of "cable cone"
487
488
489
490
491
492
493
b7943f00 494ClassImp(AliITSv11GeometrySDD)
c789ee28 495
b7943f00 496//________________________________________________________________________
33ddec7d 497AliITSv11GeometrySDD::AliITSv11GeometrySDD():
498 AliITSv11Geometry(),
499 fPinSupport(0),
500 fCoolPipeSupportL(0),
501 fCoolPipeSupportR(0),
108bd0fe 502 fSDDsensor3(0),
503 fSDDsensor4(0),
33ddec7d 504 fBaseThermalBridge(0),
505 fHybrid(0),
73dfc864 506 fCardLVR(0),
507 fCardLVL(0),
508 fCardHV(0),
509 fCardCarlos(0),
510 fRaccordoL(0),
33ddec7d 511 fDigitCableLay3A(0),
512 fDigitCableLay3B(0),
513 fDigitCableLay4A(0),
514 fDigitCableLay4B(0),
515 fMotherVol(0),
516 fAddHybrids(kTRUE),
517 fAddSensors(kTRUE),
518 fAddHVcables(kTRUE),
519 fAddCables(kTRUE),
520 fAddCoolingSyst(kTRUE),
521 fCoolingOn(kTRUE),
522 fAddOnlyLadder3min(-1),
523 fAddOnlyLadder3max(-1),
524 fAddOnlyLadder4min(-1),
525 fAddOnlyLadder4max(-1),
108bd0fe 526 fColorCarbonFiber(4),
527 fColorRyton(5),
528 fColorPhynox(7),
529 fColorSilicon(3),
530 fColorAl(7),
531 fColorPolyhamide(5),
33ddec7d 532 fColorGlass(2),
108bd0fe 533 fColorSMD(12),
534 fColorSMDweld(17),
535 fColorStesalite(20),
33ddec7d 536 fLay3LadderUnderSegDH(0),
537 fLay4LadderUnderSegDH(0),
538 fLay3LaddShortRadius(0),
539 fLay3LaddLongRadius(0),
540 fLay4LaddShortRadius(0),
541 fLay4LaddLongRadius(0)
c789ee28 542{
b7943f00 543 //
544 // Standard constructor
545 //
b7943f00 546 SetParameters();
531d6cdc 547}
c789ee28 548
108bd0fe 549
b7943f00 550//________________________________________________________________________
551AliITSv11GeometrySDD::AliITSv11GeometrySDD(Int_t debug) :
33ddec7d 552 AliITSv11Geometry(debug),
553 fPinSupport(0),
554 fCoolPipeSupportL(0),
555 fCoolPipeSupportR(0),
108bd0fe 556 fSDDsensor3(0),
557 fSDDsensor4(0),
33ddec7d 558 fBaseThermalBridge(0),
559 fHybrid(0),
73dfc864 560 fCardLVR(0),
561 fCardLVL(0),
562 fCardHV(0),
563 fCardCarlos(0),
564 fRaccordoL(0),
33ddec7d 565 fDigitCableLay3A(0),
566 fDigitCableLay3B(0),
567 fDigitCableLay4A(0),
568 fDigitCableLay4B(0),
569 fMotherVol(0),
570 fAddHybrids(kTRUE),
571 fAddSensors(kTRUE),
572 fAddHVcables(kTRUE),
573 fAddCables(kTRUE),
574 fAddCoolingSyst(kTRUE),
b7943f00 575 fCoolingOn(kTRUE),
33ddec7d 576 fAddOnlyLadder3min(-1),
577 fAddOnlyLadder3max(-1),
578 fAddOnlyLadder4min(-1),
579 fAddOnlyLadder4max(-1),
108bd0fe 580 fColorCarbonFiber(4),
581 fColorRyton(5),
582 fColorPhynox(7),
583 fColorSilicon(3),
584 fColorAl(7),
585 fColorPolyhamide(5),
33ddec7d 586 fColorGlass(2),
108bd0fe 587 fColorSMD(12),
588 fColorSMDweld(17),
589 fColorStesalite(20),
33ddec7d 590 fLay3LadderUnderSegDH(0),
591 fLay4LadderUnderSegDH(0),
592 fLay3LaddShortRadius(0),
593 fLay3LaddLongRadius(0),
594 fLay4LaddShortRadius(0),
595 fLay4LaddLongRadius(0)
c789ee28 596{
b7943f00 597 //
598 // Constructor setting debugging level
599 //
b7943f00 600 SetParameters();
531d6cdc 601}
c789ee28 602
c789ee28 603//________________________________________________________________________
b7943f00 604AliITSv11GeometrySDD::AliITSv11GeometrySDD(const AliITSv11GeometrySDD &s) :
108bd0fe 605 AliITSv11Geometry(s.GetDebug()),
33ddec7d 606 fPinSupport(s.fPinSupport),
607 fCoolPipeSupportL(s.fCoolPipeSupportL),
608 fCoolPipeSupportR(s.fCoolPipeSupportR),
108bd0fe 609 fSDDsensor3(s.fSDDsensor3),
610 fSDDsensor4(s.fSDDsensor4),
33ddec7d 611 fBaseThermalBridge(s.fBaseThermalBridge),
612 fHybrid(s.fHybrid),
73dfc864 613 fCardLVR(s.fCardLVR),
614 fCardLVL(s.fCardLVL),
615 fCardHV(s.fCardHV),
616 fCardCarlos(s.fCardCarlos),
617 fRaccordoL(s.fRaccordoL),
33ddec7d 618 fDigitCableLay3A(s.fDigitCableLay3A),
619 fDigitCableLay3B(s.fDigitCableLay3B),
620 fDigitCableLay4A(s.fDigitCableLay4A),
621 fDigitCableLay4B(s.fDigitCableLay4B),
622 fMotherVol(s.fMotherVol),
623 fAddHybrids(s.fAddHybrids),
624 fAddSensors(s.fAddSensors),
625 fAddHVcables(s.fAddHVcables),
626 fAddCables(s.fAddCables),
627 fAddCoolingSyst(s.fAddCoolingSyst),
628 fCoolingOn(s.fCoolingOn),
629 fAddOnlyLadder3min(s.fAddOnlyLadder3min),
630 fAddOnlyLadder3max(s.fAddOnlyLadder3max),
631 fAddOnlyLadder4min(s.fAddOnlyLadder4min),
108bd0fe 632 fAddOnlyLadder4max(s.fAddOnlyLadder4max),
33ddec7d 633 fColorCarbonFiber(s.fColorCarbonFiber),
634 fColorRyton(s.fColorRyton),
635 fColorPhynox(s.fColorPhynox),
636 fColorSilicon(s.fColorSilicon),
637 fColorAl(s.fColorAl),
638 fColorPolyhamide(s.fColorPolyhamide),
639 fColorGlass(s.fColorGlass),
640 fColorSMD(s.fColorSMD),
641 fColorSMDweld(s.fColorSMDweld),
108bd0fe 642 fColorStesalite(s.fColorStesalite),
33ddec7d 643 fLay3LadderUnderSegDH(s.fLay3LadderUnderSegDH),
644 fLay4LadderUnderSegDH(s.fLay4LadderUnderSegDH),
645 fLay3LaddShortRadius(s.fLay3LaddShortRadius),
646 fLay3LaddLongRadius(s.fLay3LaddLongRadius),
647 fLay4LaddShortRadius(s.fLay4LaddShortRadius),
648 fLay4LaddLongRadius(s.fLay4LaddLongRadius)
b7943f00 649{
33ddec7d 650 // Copy Constructor
651 // do only a "shallow copy" ...
b7943f00 652 SetParameters();
653}
c789ee28 654
b7943f00 655//________________________________________________________________________
656AliITSv11GeometrySDD& AliITSv11GeometrySDD::
657operator=(const AliITSv11GeometrySDD &s) {
658 // Assignment operator
659 if(&s == this) return *this;
660 fMotherVol = s.fMotherVol;
661 fAddHybrids = s.fAddHybrids;
662 fAddSensors = s.fAddSensors;
663 fAddHVcables = s.fAddHVcables;
664 fAddCables = s.fAddCables;
665 fAddCoolingSyst = s.fAddCoolingSyst;
666 fCoolingOn = s.fCoolingOn;
667 fAddOnlyLadder3min = s.fAddOnlyLadder3min;
668 fAddOnlyLadder3max = s.fAddOnlyLadder3max;
669 fAddOnlyLadder4min = s.fAddOnlyLadder4min;
670 fAddOnlyLadder4max = s.fAddOnlyLadder4max;
671 return *this;
672}
db486a6e 673
c789ee28 674//________________________________________________________________________
b7943f00 675AliITSv11GeometrySDD::~AliITSv11GeometrySDD() {
676 // Look like a destructor
677 // Smell like a destructor
678 // And actually is the destructor
679 if (fDigitCableLay3A) delete [] fDigitCableLay3A;
680 if (fDigitCableLay3B) delete [] fDigitCableLay3B;
681 if (fDigitCableLay4A) delete [] fDigitCableLay4A;
682 if (fDigitCableLay4B) delete [] fDigitCableLay4B;
531d6cdc 683}
c789ee28 684
c789ee28 685//________________________________________________________________________
b7943f00 686void AliITSv11GeometrySDD::SetParameters() {
687 //
688 // Define display colors and the non constant geometry parameters
689 //
690
b7943f00 691 Double_t detLadderDist = 8*fgkmm;
692
693 fLay3LadderUnderSegDH = detLadderDist - (fgkWaHVcableAlThick+fgkWaHVcablePolyThick);
694 fLay4LadderUnderSegDH = detLadderDist - (fgkWaHVcableAlThick+fgkWaHVcablePolyThick);
695
696 // radius from the center to the CF ladder :
697 fLay3LaddShortRadius = (fgkLay3DetShortRadius
698 + fgkLadWaferSep+2*fgkWaferThickness
699 + detLadderDist);
700 fLay3LaddLongRadius = (fgkLay3DetLongRadius
701 + fgkLadWaferSep+2*fgkWaferThickness
702 + detLadderDist);
703 fLay4LaddShortRadius = (fgkLay4DetShortRadius
704 + fgkLadWaferSep+2*fgkWaferThickness
705 + detLadderDist);
706 fLay4LaddLongRadius = (fgkLay4DetLongRadius
707 + fgkLadWaferSep+2*fgkWaferThickness
708 + detLadderDist);
c789ee28 709
710 fLay3sensorZPos[0]= ( 35.8+72.4+75.8 )*fgkmm;
711 fLay3sensorZPos[1]= ( 35.8+72.4 )*fgkmm;
712 fLay3sensorZPos[2]= ( 35.8 )*fgkmm;
713 fLay3sensorZPos[3]= ( -37.9 )*fgkmm;
714 fLay3sensorZPos[4]= ( -37.9-74.9 )*fgkmm;
715 fLay3sensorZPos[5]= ( -37.9-74.9-71.1 )*fgkmm;
716
717 fLay4sensorZPos[0] = ( 38.5+73.2+75.4+71.6 )*fgkmm;
718 fLay4sensorZPos[1] = ( 38.5+73.2+75.4 )*fgkmm;
719 fLay4sensorZPos[2] = ( 38.5+73.2 )*fgkmm;
720 fLay4sensorZPos[3] = ( 38.5 )*fgkmm;
721 fLay4sensorZPos[4] = ( -35.6 )*fgkmm;
722 fLay4sensorZPos[5] = ( -35.6-74.8 )*fgkmm;
723 fLay4sensorZPos[6] = ( -35.6-74.8-72.4 )*fgkmm;
724 fLay4sensorZPos[7] = ( -35.6-74.8-72.4-76. )*fgkmm;
531d6cdc 725}
726
c789ee28 727
c789ee28 728//________________________________________________________________________
b7943f00 729TGeoMedium* AliITSv11GeometrySDD::GetMedium(const char* mediumName) {
730 //
731 // Called to get a medium, checks that it exists.
732 // If not, prints an error and returns 0
733 //
c789ee28 734
531d6cdc 735 char ch[30];
736 sprintf(ch, "ITS_%s",mediumName);
737 TGeoMedium* medium = gGeoManager->GetMedium(ch);
b7943f00 738 if (! medium)
739 printf("Error(AliITSv11GeometrySDD)::medium %s not found !\n", mediumName);
b7943f00 740 return medium;
531d6cdc 741}
742
c789ee28 743
b7943f00 744//________________________________________________________________________
fa4639a3 745Int_t AliITSv11GeometrySDD::GetLay3NLadders() const{
746 // Get the actual number of ladder in layer 3
747 if ( (fAddOnlyLadder3min<0) ||
748 (fAddOnlyLadder3min >= fgkLay3Nladd) ||
749 (fAddOnlyLadder3max<0) ||
750 (fAddOnlyLadder3max >= fgkLay3Nladd) )
751 return fgkLay3Nladd;
752 else return (fAddOnlyLadder3max-fAddOnlyLadder3min+1);
753}
754
531d6cdc 755
fa4639a3 756//________________________________________________________________________
757Int_t AliITSv11GeometrySDD::GetLay4NLadders() const{
758 // Get the actual number of ladder in layer 4
759 if ( (fAddOnlyLadder4min<0) ||
760 (fAddOnlyLadder4min >= fgkLay4Nladd) ||
761 (fAddOnlyLadder4max<0) ||
762 (fAddOnlyLadder4max >= fgkLay4Nladd) )
763 return fgkLay4Nladd;
764 else return (fAddOnlyLadder4max-fAddOnlyLadder4min+1);
765}
766
531d6cdc 767
fa4639a3 768//________________________________________________________________________
b7943f00 769void AliITSv11GeometrySDD::CreateBasicObjects() {
770 //
771 // Create basics objets which will be assembled together
772 // in Layer3 and Layer4 functions
773 //
774
531d6cdc 775
fa4639a3 776 fDigitCableLay3A = new AliITSv11GeomCableFlat[fgkLay3Ndet];
777 fDigitCableLay3B = new AliITSv11GeomCableFlat[fgkLay3Ndet];
778 fDigitCableLay4A = new AliITSv11GeomCableFlat[fgkLay4Ndet];
779 fDigitCableLay4B = new AliITSv11GeomCableFlat[fgkLay4Ndet];
780
b7943f00 781 fPinSupport = CreatePinSupport();
782 fCoolPipeSupportL = CreateCoolPipeSupportL();
783 fCoolPipeSupportR = CreateCoolPipeSupportR();
108bd0fe 784 CreateSDDsensor();
b7943f00 785 fBaseThermalBridge = CreateBaseThermalBridge();
786 fHybrid = CreateHybrid(0);
787
108bd0fe 788 TGeoMedium *carbonFiberLadderStruct = GetMedium("SDD C AL (M55J)$"); //ITSsddCarbonM55J
73dfc864 789 TGeoMedium *polyhamideSDD = GetMedium("SDDKAPTON (POLYCH2)$");//ITSsddKAPTON_POLYCH2
790 TGeoMedium *alSDD = GetMedium("AL$"); //ITSal
791 TGeoMedium *stainless = GetMedium("INOX$"); // for screws, what is the material ???????????
792 TGeoMedium *coolerMediumSDD = GetMedium("WATER$");
e118532f 793 TGeoMedium *raccordMedium = GetMedium("INOX$"); // ??? material of raccordo ???
b7943f00 794
795 //********************************************************************
796 // pieces of the carbon fiber structure
797 //********************************************************************
798 Double_t dy = fgkLadderSegBoxDH/2;
799 Double_t triangleHeight = fgkLadderHeight - fgkLadderBeamRadius;
800 Double_t halfTheta = TMath::ATan( 0.5*fgkLadderWidth/triangleHeight );
801 Double_t alpha = TMath::Pi()*3./4. - halfTheta/2.;
802 Double_t beta = (TMath::Pi() - 2.*halfTheta)/4.;
803 Double_t dYTranslation = (fgkLadderHeight/2.
804 -0.5*fgkLadderWidth*TMath::Tan(beta)
805 -fgkLadderBeamRadius);
806 Double_t distCenterSideDown = 0.5*fgkLadderWidth/TMath::Cos(beta);
807
808 //--- the top V of the Carbon Fiber Ladder (segment)
809 TGeoArb8 *cfLaddTop1 = CreateLadderSide( fgkSegmentLength/2., halfTheta,
810 -1, fgkLadderLa, fgkLadderHa, fgkLadderl);
811 TGeoVolume *cfLaddTopVol1 = new TGeoVolume("ITSsddCFladdTopCornerVol1",
812 cfLaddTop1,carbonFiberLadderStruct);
813 TGeoArb8 *cfLaddTop2 = CreateLadderSide( fgkSegmentLength/2., halfTheta,
814 1, fgkLadderLa, fgkLadderHa, fgkLadderl);
815 TGeoVolume *cfLaddTopVol2 = new TGeoVolume("ITSsddCFladdTopCornerVol2",
816 cfLaddTop2, carbonFiberLadderStruct);
817 cfLaddTopVol1->SetLineColor(fColorCarbonFiber);
818 cfLaddTopVol2->SetLineColor(fColorCarbonFiber);
819 TGeoTranslation *trTop1 = new TGeoTranslation(0, fgkLadderHeight/2-dy, 0);
820
821 //--- the 2 side V
822 TGeoArb8 *cfLaddSide1 = CreateLadderSide( fgkSegmentLength/2., beta, -1,
823 fgkLadderLb, fgkLadderHb, fgkLadderl);
824 TGeoVolume *cfLaddSideVol1 = new TGeoVolume( "ITSsddCFladdSideCornerVol1",
825 cfLaddSide1,carbonFiberLadderStruct);
826 TGeoArb8 *cfLaddSide2 = CreateLadderSide( fgkSegmentLength/2., beta, 1,
827 fgkLadderLb, fgkLadderHb, fgkLadderl);
828 TGeoVolume *cfLaddSideVol2 = new TGeoVolume( "ITSsddCFladdSideCornerVol2",
829 cfLaddSide2,carbonFiberLadderStruct);
830 cfLaddSideVol1->SetLineColor(fColorCarbonFiber);
831 cfLaddSideVol2->SetLineColor(fColorCarbonFiber);
832 TGeoCombiTrans *ctSideR = CreateCombiTrans("", distCenterSideDown, 0,
833 alpha*TMath::RadToDeg());
834 AddTranslationToCombiTrans(ctSideR, 0, -dYTranslation-dy, 0);
835 TGeoCombiTrans *ctSideL = CreateCombiTrans("", distCenterSideDown,0,
836 -alpha*TMath::RadToDeg());
837 AddTranslationToCombiTrans(ctSideL, 0, -dYTranslation-dy, 0);
838
839 //--- The beams
840 // Beams on the sides
841 Double_t beamPhiPrime = TMath::ASin(1./TMath::Sqrt( (1+TMath::Sin(2*beta)*
842 TMath::Sin(2*beta)/(TanD(fgkBeamSidePhi)*TanD(fgkBeamSidePhi))) ));
843 //cout<<"Phi prime = "<<beamPhiPrime*TMath::RadToDeg()<<endl;
844 Double_t beamLength = TMath::Sqrt( fgkLadderHeight*fgkLadderHeight/
845 ( TMath::Sin(beamPhiPrime)*TMath::Sin(beamPhiPrime))
846 + fgkLadderWidth*fgkLadderWidth/4.)-fgkLadderLa/2-fgkLadderLb/2;
847 TGeoTubeSeg *sideBeamS = new TGeoTubeSeg(0, fgkLadderBeamRadius,beamLength/2.,
848 0, 180);
849 TGeoVolume *sideBeam = new TGeoVolume("ITSsddCFSideBeamVol", sideBeamS,
850 carbonFiberLadderStruct);
851 sideBeam->SetLineColor(fColorCarbonFiber);
852
853 //Euler rotation : about Z, then new X, then new Z
531d6cdc 854 TGeoRotation *beamRot1 = new TGeoRotation("", 90-2.*beta*TMath::RadToDeg(),
855 -beamPhiPrime*TMath::RadToDeg(),-90);
856 TGeoRotation *beamRot2 = new TGeoRotation("", 90-2.*beta*TMath::RadToDeg(),
857 beamPhiPrime*TMath::RadToDeg(), -90);
858 TGeoRotation *beamRot3 = new TGeoRotation("", 90+2.*beta*TMath::RadToDeg(),
859 beamPhiPrime*TMath::RadToDeg(), -90);
860 TGeoRotation *beamRot4 = new TGeoRotation("", 90+2.*beta*TMath::RadToDeg(),
861 -beamPhiPrime*TMath::RadToDeg(),-90);
b7943f00 862
863 TGeoCombiTrans *beamTransf[8];
864 beamTransf[0] = new TGeoCombiTrans( 0.5*triangleHeight*
865 TMath::Tan(halfTheta),
866 fgkLadderBeamRadius/2. - dy,
531d6cdc 867 -3*fgkSegmentLength/8, beamRot1);
73dfc864 868
869 beamTransf[1] = new TGeoCombiTrans( 0.5*triangleHeight*
870 TMath::Tan(halfTheta),
871 fgkLadderBeamRadius/2. - dy,
872 -3*fgkSegmentLength/8, beamRot1);
b7943f00 873 AddTranslationToCombiTrans(beamTransf[1], 0, 0, fgkSegmentLength/2);
874
875 beamTransf[2] = new TGeoCombiTrans(0.5*triangleHeight*
876 TMath::Tan(halfTheta),
877 fgkLadderBeamRadius/2. - dy,
531d6cdc 878 -fgkSegmentLength/8, beamRot2);
73dfc864 879
880 beamTransf[3] = new TGeoCombiTrans(0.5*triangleHeight*
881 TMath::Tan(halfTheta),
882 fgkLadderBeamRadius/2. - dy,
883 -fgkSegmentLength/8, beamRot2);
b7943f00 884 AddTranslationToCombiTrans(beamTransf[3], 0, 0, fgkSegmentLength/2);
885
886 beamTransf[4] = new TGeoCombiTrans(-0.5*triangleHeight*
887 TMath::Tan(halfTheta),
888 fgkLadderBeamRadius/2. - dy,
531d6cdc 889 -3*fgkSegmentLength/8, beamRot3);
73dfc864 890
891 beamTransf[5] = new TGeoCombiTrans(-0.5*triangleHeight*
892 TMath::Tan(halfTheta),
893 fgkLadderBeamRadius/2. - dy,
894 -3*fgkSegmentLength/8, beamRot3);
b7943f00 895 AddTranslationToCombiTrans(beamTransf[5], 0, 0, fgkSegmentLength/2);
896
897 beamTransf[6] = new TGeoCombiTrans(-0.5*triangleHeight*
531d6cdc 898 TMath::Tan(halfTheta),fgkLadderBeamRadius/2.-dy, -fgkSegmentLength/8,beamRot4);
b7943f00 899 beamTransf[7] = new TGeoCombiTrans(-0.5*triangleHeight*
531d6cdc 900 TMath::Tan(halfTheta),fgkLadderBeamRadius/2.-dy,3*fgkSegmentLength/8,beamRot4);
b7943f00 901
902 //--- Beams of the bottom
903 TGeoTubeSeg *bottomBeam1 = new TGeoTubeSeg(0, fgkLadderBeamRadius,
904 fgkLadderWidth/2.-fgkLadderLb/3, 0, 180);
905 TGeoVolume *bottomBeam1Vol = new TGeoVolume("ITSsddBottomBeam1Vol",
906 bottomBeam1, carbonFiberLadderStruct);
907 bottomBeam1Vol->SetLineColor(fColorCarbonFiber);
908 TGeoTubeSeg *bottomBeam2 = new TGeoTubeSeg(0, fgkLadderBeamRadius,
909 fgkLadderWidth/2.-fgkLadderLb/3, 0, 90);
910 TGeoVolume *bottomBeam2Vol = new TGeoVolume("ITSsddBottomBeam2Vol",
911 bottomBeam2, carbonFiberLadderStruct);
912 bottomBeam2Vol->SetLineColor(fColorCarbonFiber);
913 TGeoTubeSeg *bottomBeam3 = new TGeoTubeSeg(0, fgkLadderBeamRadius,
914 0.5*fgkLadderWidth/SinD(fgkBottomBeamAngle)
915 - fgkLadderLb/3, 0, 180);
916 TGeoVolume *bottomBeam3Vol = new TGeoVolume("ITSsddBottomBeam3Vol",
917 bottomBeam3, carbonFiberLadderStruct);
918 bottomBeam3Vol->SetLineColor(fColorCarbonFiber);
919 //bottomBeam3Vol->SetLineColor(2);
531d6cdc 920 TGeoRotation *bottomBeamRot1 = new TGeoRotation("", 90, 90, 90);
921 TGeoRotation *bottomBeamRot2 = new TGeoRotation("",-90, 90, -90);
b7943f00 922
b7943f00 923 TGeoCombiTrans *bottomBeamTransf1 = new TGeoCombiTrans
531d6cdc 924 (0,-(fgkLadderHeight/2-fgkLadderBeamRadius)-dy,0, bottomBeamRot1);
b7943f00 925 TGeoCombiTrans *bottomBeamTransf2 = new TGeoCombiTrans(0,
926 -(fgkLadderHeight/2-fgkLadderBeamRadius)-dy,
531d6cdc 927 -fgkSegmentLength/2, bottomBeamRot1);
b7943f00 928 TGeoCombiTrans *bottomBeamTransf3 = new TGeoCombiTrans(0,
929 -(fgkLadderHeight/2 - fgkLadderBeamRadius)
531d6cdc 930 - dy, fgkSegmentLength/2, bottomBeamRot2);
b7943f00 931 // be careful for beams #3: when "reading" from -z to +z and
932 // from the bottom of the ladder, it should draw a Lambda, and not a V
531d6cdc 933 TGeoRotation *bottomBeamRot4 = new TGeoRotation("", -90, fgkBottomBeamAngle, -90);
934 TGeoRotation *bottomBeamRot5 = new TGeoRotation("" ,-90,-fgkBottomBeamAngle, -90);
b7943f00 935 TGeoCombiTrans *bottomBeamTransf4 = new TGeoCombiTrans
531d6cdc 936 (0,-(fgkLadderHeight/2-fgkLadderBeamRadius)-dy,-fgkSegmentLength/4,bottomBeamRot4);
b7943f00 937 TGeoCombiTrans *bottomBeamTransf5 = new TGeoCombiTrans
531d6cdc 938 (0,-(fgkLadderHeight/2-fgkLadderBeamRadius)-dy,fgkSegmentLength/4, bottomBeamRot5);
b7943f00 939
940 fLaddSegCommonVol[0] = cfLaddTopVol1; fLaddSegCommonTr[0] = trTop1;
941 fLaddSegCommonVol[1] = cfLaddTopVol2; fLaddSegCommonTr[1] = trTop1;
942 fLaddSegCommonVol[2] = cfLaddSideVol1; fLaddSegCommonTr[2] = ctSideR;
943 fLaddSegCommonVol[3] = cfLaddSideVol1; fLaddSegCommonTr[3] = ctSideL;
944 fLaddSegCommonVol[4] = cfLaddSideVol2; fLaddSegCommonTr[4] = ctSideR;
945 fLaddSegCommonVol[5] = cfLaddSideVol2; fLaddSegCommonTr[5] = ctSideL;
946 fLaddSegCommonVol[6] = sideBeam; fLaddSegCommonTr[6] = beamTransf[0];
947 fLaddSegCommonVol[7] = sideBeam; fLaddSegCommonTr[7] = beamTransf[1];
948 fLaddSegCommonVol[8] = sideBeam; fLaddSegCommonTr[8] = beamTransf[2];
949 fLaddSegCommonVol[9] = sideBeam; fLaddSegCommonTr[9] = beamTransf[3];
950 fLaddSegCommonVol[10]= sideBeam; fLaddSegCommonTr[10]= beamTransf[4];
951 fLaddSegCommonVol[11]= sideBeam; fLaddSegCommonTr[11]= beamTransf[5];
952 fLaddSegCommonVol[12]= sideBeam; fLaddSegCommonTr[12]= beamTransf[6];
953 fLaddSegCommonVol[13]= sideBeam; fLaddSegCommonTr[13]= beamTransf[7];
954 fLaddSegCommonVol[14]= bottomBeam1Vol; fLaddSegCommonTr[14]= bottomBeamTransf1;
955 fLaddSegCommonVol[15]= bottomBeam2Vol; fLaddSegCommonTr[15]= bottomBeamTransf2;
956 fLaddSegCommonVol[16]= bottomBeam2Vol; fLaddSegCommonTr[16]= bottomBeamTransf3;
957 fLaddSegCommonVol[17]= bottomBeam3Vol; fLaddSegCommonTr[17]= bottomBeamTransf4;
958 fLaddSegCommonVol[18]= bottomBeam3Vol; fLaddSegCommonTr[18]= bottomBeamTransf5;
c789ee28 959
b7943f00 960
961 //********************************************************************
962 // cables
963 //********************************************************************
964 char cableName[30];
965 for (Int_t i=0; i<fgkLay3Ndet; i++) {
966 sprintf(cableName, "digitCableLay3A_%i",i);
967 fDigitCableLay3A[i].SetName(cableName);
968 fDigitCableLay3A[i].SetWidth(fgkDigitCablWidth);
969 fDigitCableLay3A[i].SetThickness(fgkDigitCablPolyThick+fgkDigitCablAlThick);
970 fDigitCableLay3A[i].SetNLayers(2);
971 fDigitCableLay3A[i].SetLayer( 0, fgkDigitCablPolyThick, polyhamideSDD,
972 fColorPolyhamide);
973 fDigitCableLay3A[i].SetLayer(1, fgkDigitCablAlThick, alSDD, fColorAl);
974 sprintf(cableName, "digitCableLay3B_%i",i);
975 fDigitCableLay3B[i].SetName(cableName);
976 fDigitCableLay3B[i].SetWidth(fgkDigitCablWidth);
977 fDigitCableLay3B[i].SetThickness(fgkDigitCablPolyThick+fgkDigitCablAlThick);
978 fDigitCableLay3B[i].SetNLayers(2);
979 fDigitCableLay3B[i].SetLayer( 0, fgkDigitCablPolyThick, polyhamideSDD,
980 fColorPolyhamide);
981 fDigitCableLay3B[i].SetLayer(1, fgkDigitCablAlThick, alSDD, fColorAl);
982 };
983 for (Int_t i=0; i<fgkLay4Ndet; i++) {
984 sprintf(cableName, "digitCableLay4A_%i",i);
985 fDigitCableLay4A[i].SetName(cableName);
986 fDigitCableLay4A[i].SetWidth(fgkDigitCablWidth);
987 fDigitCableLay4A[i].SetThickness(fgkDigitCablPolyThick+fgkDigitCablAlThick);
988 fDigitCableLay4A[i].SetNLayers(2);
989 fDigitCableLay4A[i].SetLayer( 0, fgkDigitCablPolyThick, polyhamideSDD,
990 fColorPolyhamide);
991 fDigitCableLay4A[i].SetLayer(1, fgkDigitCablAlThick, alSDD, fColorAl);
992 sprintf(cableName, "digitCableLay4B_%i",i);
993 fDigitCableLay4B[i].SetName(cableName);
994 fDigitCableLay4B[i].SetWidth(fgkDigitCablWidth);
995 fDigitCableLay4B[i].SetThickness(fgkDigitCablPolyThick+fgkDigitCablAlThick);
996 fDigitCableLay4B[i].SetNLayers(2);
997 fDigitCableLay4B[i].SetLayer( 0, fgkDigitCablPolyThick, polyhamideSDD,
998 fColorPolyhamide);
999 fDigitCableLay4B[i].SetLayer(1, fgkDigitCablAlThick, alSDD, fColorAl);
1000 };
1001 // Well, those digit cables could also include the analog cables
1002 // which have the same width and the same path, at least in the ladder.
1003 // It will gain some computing ressources (less volumes) and some
1004 // coding efforts ... !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1005 // The only thing to do is to change the names and put the correct total
1006 // thicknesses
73dfc864 1007
1008 // some transformations and volumes used in several places
1009 fCommonTr[0] = new TGeoRotation("CarlosSuppRotN",
1010 0, -fgkCarlosSuppAngle, 0);
1011
1012 TGeoTube *littleScrewHead = new TGeoTube("littleScrewHead", 0, fgkLittleScrewHeadR,
1013 fgkLittleScrewHeadH/2);
1014 fCommonVol[0] = new TGeoVolume("vLittleScrewHead",
1015 littleScrewHead, stainless);
1016 fCommonVol[0]->SetLineColor(kGray);
1017
1018 fLadderFoot = CreateLadderFoot();
1019 CreateLVCard();
1020 fCardHV = CreateHVCard(0);
1021 fCardCarlos = CreateCarlosCard(0);
1022
1023 //==================
1024 // link beteen phynox and plastic cooling tubes
1025 //==================
1026
1027 fRaccordoL = new TGeoVolumeAssembly("RaccordoL");
1028 Double_t fullRacLen = fgkConnectorCoolTubeL1+fgkConnectorCoolTubeL2+fgkConnectorCoolTubeL3;
1029 TGeoTube *waterRac = new TGeoTube("waterRac", 0, fgkConnectorCoolTubeRmin, fullRacLen/2);
1030 TGeoVolume * vwaterRac = new TGeoVolume("vwaterRac", waterRac, coolerMediumSDD);
1031 vwaterRac->SetLineColor(kBlue);
1032
1033 TGeoTube *tube1Rac = new TGeoTube("tube1Rac", fgkConnectorCoolTubeRmin,
1034 fgkConnectorCoolTubeR1, fgkConnectorCoolTubeL1/2);
1035 TGeoTube *tube2Rac = new TGeoTube("tube2Rac", fgkConnectorCoolTubeRmin,
1036 fgkConnectorCoolTubeR2, fgkConnectorCoolTubeL2/2);
1037 TGeoTube *tube3Rac = new TGeoTube("tube3Rac", fgkConnectorCoolTubeRmin,
1038 fgkConnectorCoolTubeR3, fgkConnectorCoolTubeL3/2);
1039 TGeoVolume * vtube1Rac = new TGeoVolume("vtube1Rac", tube1Rac, raccordMedium);
1040 TGeoVolume * vtube2Rac = new TGeoVolume("vtube2Rac", tube2Rac, raccordMedium);
1041 TGeoVolume * vtube3Rac = new TGeoVolume("vtube3Rac", tube3Rac, raccordMedium);
1042 vtube1Rac->SetLineColor(kGray);
1043 vtube2Rac->SetLineColor(kGray);
1044 vtube3Rac->SetLineColor(kGray);
1045
1046 TGeoTranslation *trTube1Rac = new TGeoTranslation("trTube1Rac",0,0,
1047 -fullRacLen/2+fgkConnectorCoolTubeL1/2);
1048 TGeoTranslation *trTube2Rac = new TGeoTranslation("trTube2Rac",0,0,
1049 (-fullRacLen/2+fgkConnectorCoolTubeL1+fgkConnectorCoolTubeL2/2));
1050 TGeoTranslation *trTube3Rac = new TGeoTranslation("trTube3Rac",0,0,
1051 (-fullRacLen/2+fgkConnectorCoolTubeL1+
1052 fgkConnectorCoolTubeL2+fgkConnectorCoolTubeL3/2));
1053 fRaccordoL->AddNode(vwaterRac, 1,0);
1054 fRaccordoL->AddNode(vtube1Rac, 1,trTube1Rac);
1055 fRaccordoL->AddNode(vtube2Rac, 1,trTube2Rac);
1056 fRaccordoL->AddNode(vtube3Rac, 1,trTube3Rac);
531d6cdc 1057}
c789ee28 1058
c789ee28 1059
b7943f00 1060//________________________________________________________________________
1061void AliITSv11GeometrySDD::CheckOverlaps(Double_t precision){
1062 //
1063 // a debugging function for checking some possible overlaps
1064 //
108bd0fe 1065 if (fSDDsensor3) fSDDsensor3->CheckOverlaps(precision);
1066 if (fSDDsensor4) fSDDsensor4->CheckOverlaps(precision);
b7943f00 1067 if (fHybrid) fHybrid->CheckOverlaps(precision);
531d6cdc 1068}
c789ee28 1069
1070
db486a6e 1071//________________________________________________________________________
1072TGeoCombiTrans *AliITSv11GeometrySDD::
108bd0fe 1073CreateCombiTrans(const char *name, Double_t dy, Double_t dz, Double_t dphi,
1074 Bool_t planeSym) {
db486a6e 1075 //
1076 // return the TGeoCombiTrans which make a translation in y and z
1077 // and a rotation in phi in the global coord system
108bd0fe 1078 // If planeSym = true, the rotation places the object symetrically
1079 // (with respect to the transverse plane) to its position in the
1080 // case planeSym = false
db486a6e 1081 //
1082
1083 TGeoTranslation t1(dy*CosD(90.+dphi),dy*SinD(90.+dphi), dz);
1084 TGeoRotation r1("",0.,0.,dphi);
108bd0fe 1085 TGeoRotation r2("",90, 180, -90-dphi);
db486a6e 1086
1087 TGeoCombiTrans *combiTrans1 = new TGeoCombiTrans(name);
1088 combiTrans1->SetTranslation(t1);
108bd0fe 1089 if (planeSym) combiTrans1->SetRotation(r1);
1090 else combiTrans1->SetRotation(r2);
db486a6e 1091 return combiTrans1;
531d6cdc 1092}
c789ee28 1093
1094
db486a6e 1095//________________________________________________________________________
c789ee28 1096void AliITSv11GeometrySDD::AddTranslationToCombiTrans(TGeoCombiTrans* ct,
db486a6e 1097 Double_t dx,
1098 Double_t dy,
b7943f00 1099 Double_t dz) const{
1100 // Add a dx,dy,dz translation to the initial TGeoCombiTrans
1101 const Double_t *vect = ct->GetTranslation();
1102 Double_t newVect[3] = {vect[0]+dx, vect[1]+dy, vect[2]+dz};
1103 ct->SetTranslation(newVect);
531d6cdc 1104}
c789ee28 1105
1106
1107//________________________________________________________________________
1108void AliITSv11GeometrySDD::ShowOnePiece(TGeoVolume *moth) {
1109// for code developpment and debugging purposes
1110
108bd0fe 1111 if (! fSDDsensor3) CreateBasicObjects();
531d6cdc 1112
1113 // moth->AddNode(fPinSupport, 1, 0);
1114 // moth->AddNode(fCoolPipeSupportL, 1, 0);
73dfc864 1115 // moth->AddNode(fSDDsensor3, 1, 0);
1116 // moth->AddNode(fSDDsensor4, 1, 0);
531d6cdc 1117 // moth->AddNode(fBaseThermalBridge, 1, 0);
1118 // moth->AddNode(fHybrid,100,0);
73dfc864 1119 // moth->AddNode(fLadderFoot,1,0);
1120 //moth->AddNode(fCardLVL,1,0);
1121 //moth->AddNode(fCardLVR,1,0);
b7943f00 1122
e118532f 1123 TGeoVolume* seg = CreateLadderSegment( 3, 0);
1124 moth->AddNode(seg, 1, 0);
b7943f00 1125
108bd0fe 1126// TGeoVolumeAssembly *lay3Ladder = CreateLadder(3);
531d6cdc 1127// moth->AddNode(lay3Ladder, 1, 0);
1128
108bd0fe 1129// TGeoVolumeAssembly *lay3Detectors = CreateDetectorsAssembly(3);
531d6cdc 1130// moth->AddNode(lay3Detectors, 1, 0);
1131
73dfc864 1132// TGeoVolumeAssembly *lay3Detectors = CreateDetectorsAssembly(3);
1133// moth->AddNode(lay3Detectors, 1, 0);
108bd0fe 1134
1135
bf210566 1136// TGeoVolumeAssembly *endLadder = CreateEndLadder( 4 );
1137// moth->AddNode(endLadder, 1, 0);
108bd0fe 1138
1139// TGeoVolumeAssembly *highVCard = CreateHVCard( 4 );
1140// moth->AddNode(highVCard, 1, 0);
1141
73dfc864 1142// TGeoVolumeAssembly *supportRing = CreateSupportRing( 4 );
1143// moth->AddNode(supportRing, 1, 0);
1144
e118532f 1145// TGeoVolume *endLadderCards = CreateEndLadderCardsV( 4 );
108bd0fe 1146// moth->AddNode(endLadderCards, 1, 0);
1147
73dfc864 1148// TGeoVolumeAssembly *carlosCard = CreateCarlosCard( 4 );
1149// moth->AddNode(carlosCard, 1, 0);
bf210566 1150
1151
1152
1153 /*
1154 //==================================
1155 //--- test of flat cable curvature
1156 //==================================
1157
1158 double angle = 90;
1159 AliITSv11GeomCableFlat cable("test", 3, 0.3);
1160 cable.SetNLayers(1);
1161 cable.SetNLayers(2);
1162 cable.SetLayer(0, 0.2, coolerMediumSDD, 2);
1163 cable.SetLayer(1, 0.1, coolerMediumSDD, 3);
1164 cable.SetInitialNode(endLadderCards);
1165
1166 Double_t p1[3], p2[3], vX[3] = {1,0,0},vY[3] = {0,5,0};
1167
1168 p1[0] = -3;
1169 p1[1] = 1;
1170 p1[2] = 10;
1171
1172 p2[0] = 0;
1173 p2[1] = 1;
1174 p2[2] = 10;
1175 cable.AddCheckPoint(endLadderCards, 0, p1, vX);
1176 cable.AddCheckPoint(endLadderCards, 1, p2, vX);
1177 cable.CreateAndInsertBoxCableSegment(1,angle);
1178
1179 Double_t p3[3], p4[3];
1180
1181 p3[0] = 2;
1182 p3[1] = 3;
1183 p3[2] = 10;
1184 cable.AddCheckPoint(endLadderCards, 2, p3, vY);
1185 cable.CreateAndInsertCableCylSegment(2,angle);
1186
1187 p4[0] = 2;
1188 p4[1] = 6;
1189 p4[2] = 10;
1190 cable.AddCheckPoint(endLadderCards, 3, p4, vY);
1191 cable.CreateAndInsertCableSegment(3,angle);
1192 */
531d6cdc 1193}
c789ee28 1194
1195
db486a6e 1196//________________________________________________________________________
b7943f00 1197void AliITSv11GeometrySDD::Layer3(TGeoVolume *moth) {
1198 //
1199 // Insert the layer 3 in the mother volume. This is a virtual volume
1200 // containing ladders of layer 3 and the supporting rings
1201 //
1202
1203 if (! moth) {
1204 printf("Error::AliITSv11GeometrySDD: Can't insert layer3, mother is null!\n");
1205 return;
1206 };
1207
108bd0fe 1208 TGeoMedium *airSDD = GetMedium("SDD AIR$");
b7943f00 1209
1210 fMotherVol = moth;
108bd0fe 1211 if (! fSDDsensor3) CreateBasicObjects();
b7943f00 1212
108bd0fe 1213 //====================================
1214 // First we create the central barrel
1215 //====================================
1216
1217 TGeoVolumeAssembly *lay3Ladder = CreateLadder(3);
1218 TGeoVolumeAssembly *lay3Detectors = CreateDetectorsAssembly(3);
1219 //TGeoVolume *lay3Detectors = CreateDetectors(3);
b7943f00 1220 TGeoTube *virtualLayer3Shape = new TGeoTube("ITSsddLayer3Shape",
1221 fgkLay3Rmin,fgkLay3Rmax,fgkLay3Length*0.5);
1222 TGeoVolume *virtualLayer3 = new TGeoVolume("ITSsddLayer3",
1223 virtualLayer3Shape, airSDD);
1224
1225 Double_t dPhi = 360./fgkLay3Nladd;
1226 Double_t detectorsThick = fgkLadWaferSep + 2*fgkWaferThickness;
1227 // Placing virtual ladder and detectors volumes following
1228 // ladder ordering convention
1229 char rotName[30];
1230 Int_t iLaddMin = 0;
1231 Int_t iLaddMax = fgkLay3Nladd;
1232 if ((fAddOnlyLadder3min>=0)&&(fAddOnlyLadder3max<fgkLay3Nladd)) {
1233 iLaddMin = fAddOnlyLadder3min;
1234 iLaddMax = fAddOnlyLadder3max+1;
1235 };
1236
1237 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1238
108bd0fe 1239 Double_t ladderPhi = -3*dPhi+iLadd*dPhi;
b7943f00 1240 sprintf(rotName, "ITSsddLay3Ladd%i",iLadd);
1241 Double_t minRadiusLadBox = fLay3LaddShortRadius-fLay3LadderUnderSegDH;
1242 if (iLadd%2 != 0)
1243 minRadiusLadBox = fLay3LaddLongRadius-fLay3LadderUnderSegDH;
1244 minRadiusLadBox += ((TGeoBBox*)lay3Ladder->GetShape())->GetDY();
73dfc864 1245 TGeoCombiTrans *ctLadd;
1246 //=============================================================
1247 //
1248 // Special modification for ladder 2 of layer 3:
1249 // It has been inverted (pi rotation around y axis)
1250 //
1251 //=============================================================
1252 if (iLadd != 2)
1253 ctLadd = CreateCombiTrans(rotName,minRadiusLadBox,
1254 0, ladderPhi, kTRUE);
1255 else
1256 ctLadd = CreateCombiTrans(rotName,minRadiusLadBox,
1257 0, ladderPhi, kFALSE);
b7943f00 1258 virtualLayer3->AddNode(lay3Ladder, iLadd, ctLadd);
1259 ///////////////////////////////////////////////////
1260 sprintf(rotName, "ITSsddLay3DetBox%i",iLadd);
1261 Double_t minRadiusDetBox = fgkLay3DetShortRadius;
1262 if (iLadd%2 != 0) minRadiusDetBox = fgkLay3DetLongRadius;
1263 minRadiusDetBox += detectorsThick/2;
73dfc864 1264 TGeoCombiTrans *ctDet;
1265 if (iLadd != 2)
1266 ctDet = CreateCombiTrans(rotName, minRadiusDetBox,
1267 0, ladderPhi, kTRUE);
1268 else
1269 ctDet = CreateCombiTrans(rotName, minRadiusDetBox,
1270 0, ladderPhi, kFALSE);
1271
b7943f00 1272 virtualLayer3->AddNode(lay3Detectors, iLadd, ctDet);
1273 ///////////////////////////////////////////////////
1274 }
1275
bf210566 1276 /*
108bd0fe 1277 //====================================
1278 // Then the forward rapidity pieces
1279 // (cooling, Carlos, LV, HV ...)
1280 //====================================
1281
bf210566 1282 Double_t fgkForwardLay3Length = fgkEndLadPipeUlengthLay3+10*fgkmm; // this has to be tune
1283 Double_t fgkForwardLay3Rmin = fgkLay3Rmin-7*fgkmm;
1284 Double_t fgkForwardLay3Rmax = fgkLay3Rmax-5*fgkmm;
108bd0fe 1285
1286 TGeoVolumeAssembly* lay3EndLadder = CreateEndLadderCards(3);
1287 TGeoTube *virtualForward3Shape = new TGeoTube("virtualForward3Shape",
1288 fgkForwardLay3Rmin, fgkForwardLay3Rmax,
1289 fgkForwardLay3Length/2.);
bf210566 1290
1291// TGeoPcon *virtualForward3Shape = new TGeoPcon("virtualForward3Shape",0,360,2);
1292// // virtualForward3Shape->DefineSection(Int_t snum, Double_t z, Double_t rmin, Double_t rmax);
1293// virtualForward3Shape->DefineSection(0, Double_t z, Double_t rmin, Double_t rmax);
1294
1295
108bd0fe 1296 TGeoVolume *virtualForward3Pos = new TGeoVolume("ITSsddForward3Pos",
1297 virtualForward3Shape, airSDD);
1298 TGeoVolume *virtualForward3Neg = new TGeoVolume("ITSsddForward3Neg",
1299 virtualForward3Shape, airSDD);
bf210566 1300// TGeoVolume *virtualForward3Neg = new TGeoVolumeAssembly("ITSsddForward3Neg");
1301// TGeoVolume *virtualForward3Pos = new TGeoVolumeAssembly("ITSsddForward3Pos");
1302
108bd0fe 1303 TGeoTranslation *virtualForward3TrPos = new TGeoTranslation("virtualForward3TrPos",0,0,
1304 fgkLay3Length/2+fgkForwardLay3Length/2);
1305 TGeoTranslation *virtualForward3TrNeg = new TGeoTranslation("virtualForward3TrNeg",0,0,
1306 -fgkLay3Length/2-fgkForwardLay3Length/2);
1307
1308 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1309
1310 Double_t ladderPhi = -3*dPhi+iLadd*dPhi;
1311 Double_t minRadiusDetBox = fgkLay3DetShortRadius;
1312 if (iLadd%2 != 0) minRadiusDetBox = fgkLay3DetLongRadius;
1313 minRadiusDetBox += detectorsThick/2;
1314
1315 sprintf(rotName, "ITSsddLay3EndLadd%i",iLadd);
1316
1317 TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1318 -fgkForwardLay3Length/2, ladderPhi, kTRUE);
1319 TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1320 fgkForwardLay3Length/2, ladderPhi, kFALSE);
1321
1322 virtualForward3Pos->AddNode(lay3EndLadder, iLadd*2, ctEndLaddPos);
1323 virtualForward3Neg->AddNode(lay3EndLadder, iLadd*2, ctEndLaddNeg);
1324 }
1325
bf210566 1326 */
1327
1328
108bd0fe 1329 if(GetDebug(1)) {
1330 virtualLayer3->CheckOverlaps(0.01);
bf210566 1331 //virtualForward3Pos->CheckOverlaps(0.01);
1332 //virtualForward3Neg->CheckOverlaps(0.01);
108bd0fe 1333 }
1334
b7943f00 1335 virtualLayer3->SetVisibility(kFALSE);
bf210566 1336 //virtualForward3Pos->SetVisibility(kFALSE);
1337 //virtualForward3Neg->SetVisibility(kFALSE);
1338
108bd0fe 1339
b7943f00 1340 moth->AddNode(virtualLayer3, 1, 0);
bf210566 1341 //moth->AddNode(virtualForward3Pos, 1, virtualForward3TrPos);
1342 //moth->AddNode(virtualForward3Neg, 1, virtualForward3TrNeg);
531d6cdc 1343}
c789ee28 1344
1345
bf210566 1346// //________________________________________________________________________
1347// void AliITSv11GeometrySDD::ForwardLayer3(TGeoVolume *moth) {
1348// //
1349// // Insert the forward pieces of layer 3 in the mother volume.
1350// // (cooling, Carlos, LV, HV ...)
1351// //
1352
1353// if (! moth) {
1354// printf("Error::AliITSv11GeometrySDD: Can't insert layer3, mother is null!\n");
1355// return;
1356// };
1357
1358// TGeoMedium *airSDD = GetMedium("SDD AIR$");
1359
1360// if (! fSDDsensor3) CreateBasicObjects();
1361
1362// Double_t dPhi = 360./fgkLay3Nladd;
1363// Double_t detectorsThick = fgkLadWaferSep + 2*fgkWaferThickness;
1364// Int_t iLaddMin = 0;
1365// Int_t iLaddMax = fgkLay3Nladd;
1366// if ((fAddOnlyLadder3min>=0)&&(fAddOnlyLadder3max<fgkLay3Nladd)) {
1367// iLaddMin = fAddOnlyLadder3min;
1368// iLaddMax = fAddOnlyLadder3max+1;
1369// };
1370// char rotName[30];
1371
1372
1373// //=================
1374
1375// Double_t fgkForwardLay3Length = fgkEndLadPipeUlengthLay3+10*fgkmm; // this has to be tune
1376// Double_t fgkForwardLay3Rmin = fgkLay3Rmin-7*fgkmm;
1377// Double_t fgkForwardLay3Rmax = fgkLay3Rmax-5*fgkmm;
1378
1379// TGeoVolumeAssembly* lay3EndLadder = CreateEndLadderCards(3);
1380// TGeoTube *virtualForward3Shape = new TGeoTube("virtualForward3Shape",
1381// fgkForwardLay3Rmin, fgkForwardLay3Rmax,
1382// fgkForwardLay3Length/2.);
1383
1384// // TGeoPcon *virtualForward3Shape = new TGeoPcon("virtualForward3Shape",0,360,2);
1385// // // virtualForward3Shape->DefineSection(Int_t snum, Double_t z, Double_t rmin, Double_t rmax);
1386// // virtualForward3Shape->DefineSection(0, Double_t z, Double_t rmin, Double_t rmax);
1387
1388
1389// TGeoVolume *virtualForward3Pos = new TGeoVolume("ITSsddForward3Pos",
1390// virtualForward3Shape, airSDD);
1391// TGeoVolume *virtualForward3Neg = new TGeoVolume("ITSsddForward3Neg",
1392// virtualForward3Shape, airSDD);
1393// // TGeoVolume *virtualForward3Neg = new TGeoVolumeAssembly("ITSsddForward3Neg");
1394// // TGeoVolume *virtualForward3Pos = new TGeoVolumeAssembly("ITSsddForward3Pos");
1395
1396// TGeoTranslation *virtualForward3TrPos = new TGeoTranslation("virtualForward3TrPos",0,0,
1397// fgkLay3Length/2+fgkForwardLay3Length/2);
1398// TGeoTranslation *virtualForward3TrNeg = new TGeoTranslation("virtualForward3TrNeg",0,0,
1399// -fgkLay3Length/2-fgkForwardLay3Length/2);
1400
1401// for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1402
1403// Double_t ladderPhi = -3*dPhi+iLadd*dPhi;
1404// Double_t minRadiusDetBox = fgkLay3DetShortRadius;
1405// if (iLadd%2 != 0) minRadiusDetBox = fgkLay3DetLongRadius;
1406// minRadiusDetBox += detectorsThick/2;
1407
1408// sprintf(rotName, "ITSsddLay3EndLadd%i",iLadd);
1409
1410// TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1411// -fgkForwardLay3Length/2, ladderPhi, kTRUE);
1412// TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1413// fgkForwardLay3Length/2, ladderPhi, kFALSE);
1414
1415// virtualForward3Pos->AddNode(lay3EndLadder, iLadd*2, ctEndLaddPos);
1416// virtualForward3Neg->AddNode(lay3EndLadder, iLadd*2, ctEndLaddNeg);
1417// }
1418
1419// if(GetDebug(1)) {
1420// virtualForward3Pos->CheckOverlaps(0.01);
1421// virtualForward3Neg->CheckOverlaps(0.01);
1422// }
1423
1424// virtualForward3Pos->SetVisibility(kFALSE);
1425// virtualForward3Neg->SetVisibility(kFALSE);
1426
1427// moth->AddNode(virtualForward3Pos, 1, virtualForward3TrPos);
1428// moth->AddNode(virtualForward3Neg, 1, virtualForward3TrNeg);
1429// }
1430
1431
1432
1433//________________________________________________________________________
1434void AliITSv11GeometrySDD::ForwardLayer3(TGeoVolume *moth) {
1435 //
1436 // Insert the end-ladder of layer 3 in the mother volume.
1437 // (cooling, Carlos, LV, HV ...)
1438 //
1439
1440 if (! moth) {
1441 printf("Error::AliITSv11GeometrySDD: Can't insert layer3, mother is null!\n");
1442 return;
1443 };
1444
1445 if (! fSDDsensor3) CreateBasicObjects();
1446
1447 Int_t iLaddMin = 0;
1448 Int_t iLaddMax = fgkLay3Nladd;
1449 if ((fAddOnlyLadder3min>=0)&&(fAddOnlyLadder3max<fgkLay3Nladd)) {
1450 iLaddMin = fAddOnlyLadder3min;
1451 iLaddMax = fAddOnlyLadder3max+1;
1452 };
1453
1454 TGeoVolume *virtualForward3Neg = new TGeoVolumeAssembly("ITSsddForward3Neg");
1455 TGeoVolume *virtualForward3Pos = new TGeoVolumeAssembly("ITSsddForward3Pos");
1456
1457 char rotName[30];
1458 Double_t dPhi = 360./fgkLay3Nladd;
1459 TGeoVolume* lay3EndLadder = CreateEndLadderCardsV(3);
1460
1461 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1462
1463 Double_t ladderPhi = -3*dPhi+iLadd*dPhi;
1464 Double_t dR = 0;
1465 if (iLadd%2 != 0) dR = fgkLay3DetLongRadius-fgkLay3DetShortRadius;
1466
1467 sprintf(rotName, "ITSsddLay3EndLadd%i",iLadd);
1468
1469 TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, dR,
1470 fgkLay3Length/2, ladderPhi, kTRUE);
1471 TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, dR,
1472 -fgkLay3Length/2, ladderPhi, kFALSE);
1473
1474 virtualForward3Pos->AddNode(lay3EndLadder, iLadd*2, ctEndLaddPos);
1475 virtualForward3Neg->AddNode(lay3EndLadder, iLadd*2, ctEndLaddNeg);
1476 }
1477
1478 if(GetDebug(1)) {
1479 virtualForward3Pos->CheckOverlaps(0.01);
1480 virtualForward3Neg->CheckOverlaps(0.01);
1481 }
1482
1483 moth->AddNode(virtualForward3Pos, 1);
1484 moth->AddNode(virtualForward3Neg, 1);
1485}
1486
db486a6e 1487//________________________________________________________________________
b7943f00 1488void AliITSv11GeometrySDD::Layer4(TGeoVolume *moth) {
1489 //
1490 // Insert the layer 4 in the mother volume. This is a virtual volume
1491 // containing ladders of layer 4 and the supporting rings
1492 //
1493
1494 if (! moth) {
1495 printf("Error::AliITSv11GeometrySDD: Can't insert layer4, mother is null!\n");
1496 return;
1497 };
1498
1499 fMotherVol = moth;
1500
108bd0fe 1501 if (! fSDDsensor3) CreateBasicObjects();
b7943f00 1502
1503 TGeoTube *virtualLayer4Shape =new TGeoTube("ITSsddLayer4Shape",
1504 fgkLay4Rmin,fgkLay4Rmax,fgkLay4Length*0.5);
108bd0fe 1505 TGeoMedium *airSDD = GetMedium("SDD AIR$");
b7943f00 1506 TGeoVolume *virtualLayer4 = new TGeoVolume("ITSsddLayer4",
1507 virtualLayer4Shape, airSDD);
108bd0fe 1508
1509 //====================================
1510 // First we create the central barrel
1511 //====================================
1512
1513 TGeoVolumeAssembly *lay4Ladder = CreateLadder(4);
1514 //TGeoVolume *lay4Detectors = CreateDetectors(4);
1515 TGeoVolumeAssembly *lay4Detectors = CreateDetectorsAssembly(4);
1516
b7943f00 1517 Double_t dPhi = 360./fgkLay4Nladd;
1518 Double_t detBoxThickness = fgkLadWaferSep + 2*fgkWaferThickness;
108bd0fe 1519
b7943f00 1520 // placing virtual ladder and detectors volumes following ladder
1521 // ordering convention
1522 char rotName[20];
1523 Int_t iLaddMin = 0;
1524 Int_t iLaddMax = fgkLay4Nladd;
1525 if ((fAddOnlyLadder4min >= 0)&&(fAddOnlyLadder4max < fgkLay4Nladd)) {
1526 iLaddMin = fAddOnlyLadder4min;
1527 iLaddMax = fAddOnlyLadder4max+1;
1528 }
1529 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
108bd0fe 1530
1531 Double_t ladderPhi = -5*dPhi + iLadd*dPhi;
b7943f00 1532 sprintf(rotName, "ITSsddLay4Ladd%i",iLadd);
1533 Double_t minRadiusLadBox = fLay4LaddShortRadius-fLay4LadderUnderSegDH;
1534 if (iLadd%2 != 0)
1535 minRadiusLadBox = fLay4LaddLongRadius-fLay4LadderUnderSegDH;
1536 minRadiusLadBox += ((TGeoBBox*)lay4Ladder->GetShape())->GetDY();
1537 TGeoCombiTrans *ctLadd = CreateCombiTrans(rotName, minRadiusLadBox,
108bd0fe 1538 0, ladderPhi, kTRUE);
b7943f00 1539 virtualLayer4->AddNode(lay4Ladder, iLadd, ctLadd);
108bd0fe 1540 ///////////////////////////////////////////////////
b7943f00 1541 sprintf(rotName, "ITSsddLay4DetBox%i",iLadd);
1542 Double_t minRadiusDetBox = fgkLay4DetShortRadius;
1543 if (iLadd%2 != 0)
1544 minRadiusDetBox = fgkLay4DetLongRadius;
1545 minRadiusDetBox += detBoxThickness/2;
1546 TGeoCombiTrans *ctDet = CreateCombiTrans(rotName, minRadiusDetBox,
108bd0fe 1547 0, ladderPhi, kTRUE);
b7943f00 1548 virtualLayer4->AddNode(lay4Detectors, iLadd, ctDet);
108bd0fe 1549 ///////////////////////////////////////////////////
1550 }
1551
bf210566 1552 /*
108bd0fe 1553 //====================================
1554 // Then the pieces at forward rapidity
1555 // (cooling, Carlos, LV, HV ...)
1556 //====================================
1557
bf210566 1558 Double_t fgkForwardLay4Length = fgkEndLadPipeUlengthLay4+10*fgkmm; // this has to be tuned
1559 Double_t fgkForwardLay4Rmin = fgkLay4Rmin-9*fgkmm;
1560 Double_t fgkForwardLay4Rmax = fgkLay4Rmax-5*fgkmm;
108bd0fe 1561
1562 TGeoVolumeAssembly* lay4EndLadder = CreateEndLadderCards(4);
1563 TGeoTube *virtualForward4Shape = new TGeoTube("virtualForward3Shape",
1564 fgkForwardLay4Rmin, fgkForwardLay4Rmax,
1565 fgkForwardLay4Length/2.);
1566 TGeoVolume *virtualForward4Pos = new TGeoVolume("ITSsddForward4Pos",
1567 virtualForward4Shape, airSDD);
1568 TGeoVolume *virtualForward4Neg = new TGeoVolume("ITSsddForward4Neg",
1569 virtualForward4Shape, airSDD);
bf210566 1570// TGeoVolume *virtualForward4Pos = new TGeoVolumeAssembly("ITSsddForward4Pos");
1571// TGeoVolume *virtualForward4Neg = new TGeoVolumeAssembly("ITSsddForward4Neg");
1572
108bd0fe 1573 TGeoTranslation *virtualForward4TrPos = new TGeoTranslation("virtualForward4TrPos",0,0,
1574 fgkLay4Length/2+fgkForwardLay4Length/2);
1575 TGeoTranslation *virtualForward4TrNeg = new TGeoTranslation("virtualForward4TrNeg",0,0,
1576 -fgkLay4Length/2-fgkForwardLay4Length/2);
1577
1578 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1579
1580 Double_t ladderPhi = -5*dPhi + iLadd*dPhi;
1581 Double_t minRadiusDetBox = fgkLay4DetShortRadius;
1582 if (iLadd%2 != 0)
1583 minRadiusDetBox = fgkLay4DetLongRadius;
1584 minRadiusDetBox += detBoxThickness/2;
1585
1586 sprintf(rotName, "ITSsddLay4EndLadd%i",iLadd);
1587
1588 TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1589 -fgkForwardLay4Length/2, ladderPhi, kTRUE);
1590 TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1591 fgkForwardLay4Length/2, ladderPhi, kFALSE);
1592 virtualForward4Pos->AddNode(lay4EndLadder, iLadd*2, ctEndLaddPos);
1593 virtualForward4Neg->AddNode(lay4EndLadder, iLadd*2+1, ctEndLaddNeg);
b7943f00 1594 }
bf210566 1595 */
b7943f00 1596
1597 if(GetDebug(1)) virtualLayer4->CheckOverlaps(0.01);
108bd0fe 1598
b7943f00 1599 virtualLayer4->SetVisibility(kFALSE);
bf210566 1600 //virtualForward4Pos->SetVisibility(kFALSE);
1601 //virtualForward4Neg->SetVisibility(kFALSE);
108bd0fe 1602
b7943f00 1603 moth->AddNode(virtualLayer4,1,0);
bf210566 1604 //moth->AddNode(virtualForward4Pos, 1, virtualForward4TrPos);
1605 //moth->AddNode(virtualForward4Neg, 1, virtualForward4TrNeg);
1606}
1607
1608
1609// //________________________________________________________________________
1610// void AliITSv11GeometrySDD::ForwardLayer4(TGeoVolume *moth) {
1611// //
1612// // Insert the layer 4 in the mother volume. This is a virtual volume
1613// // containing ladders of layer 4 and the supporting rings
1614// // (cooling, Carlos, LV, HV ...)
1615// //
1616
1617// if (! moth) {
1618// printf("Error::AliITSv11GeometrySDD: Can't insert layer4, mother is null!\n");
1619// return;
1620// };
1621
1622// TGeoMedium *airSDD = GetMedium("SDD AIR$");
1623
1624// if (! fSDDsensor3) CreateBasicObjects();
1625
1626// Double_t dPhi = 360./fgkLay4Nladd;
1627// Double_t detBoxThickness = fgkLadWaferSep + 2*fgkWaferThickness;
1628
1629// // placing virtual ladder and detectors volumes following ladder
1630// // ordering convention
1631// char rotName[20];
1632// Int_t iLaddMin = 0;
1633// Int_t iLaddMax = fgkLay4Nladd;
1634// if ((fAddOnlyLadder4min >= 0)&&(fAddOnlyLadder4max < fgkLay4Nladd)) {
1635// iLaddMin = fAddOnlyLadder4min;
1636// iLaddMax = fAddOnlyLadder4max+1;
1637// }
1638
1639// //=================
1640// Double_t fgkForwardLay4Length = fgkEndLadPipeUlengthLay4+10*fgkmm; // this has to be tuned
1641// Double_t fgkForwardLay4Rmin = fgkLay4Rmin-9*fgkmm;
1642// Double_t fgkForwardLay4Rmax = fgkLay4Rmax-5*fgkmm;
1643
1644// TGeoVolumeAssembly* lay4EndLadder = CreateEndLadderCards(4);
1645// TGeoTube *virtualForward4Shape = new TGeoTube("virtualForward3Shape",
1646// fgkForwardLay4Rmin, fgkForwardLay4Rmax,
1647// fgkForwardLay4Length/2.);
1648// TGeoVolume *virtualForward4Pos = new TGeoVolume("ITSsddForward4Pos",
1649// virtualForward4Shape, airSDD);
1650// TGeoVolume *virtualForward4Neg = new TGeoVolume("ITSsddForward4Neg",
1651// virtualForward4Shape, airSDD);
1652// // TGeoVolume *virtualForward4Pos = new TGeoVolumeAssembly("ITSsddForward4Pos");
1653// // TGeoVolume *virtualForward4Neg = new TGeoVolumeAssembly("ITSsddForward4Neg");
1654
1655// TGeoTranslation *virtualForward4TrPos = new TGeoTranslation("virtualForward4TrPos",0,0,
1656// fgkLay4Length/2+fgkForwardLay4Length/2);
1657// TGeoTranslation *virtualForward4TrNeg = new TGeoTranslation("virtualForward4TrNeg",0,0,
1658// -fgkLay4Length/2-fgkForwardLay4Length/2);
1659
1660// for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1661
1662// Double_t ladderPhi = -5*dPhi + iLadd*dPhi;
1663// Double_t minRadiusDetBox = fgkLay4DetShortRadius;
1664// if (iLadd%2 != 0)
1665// minRadiusDetBox = fgkLay4DetLongRadius;
1666// minRadiusDetBox += detBoxThickness/2;
1667
1668// sprintf(rotName, "ITSsddLay4EndLadd%i",iLadd);
1669
1670// TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1671// -fgkForwardLay4Length/2, ladderPhi, kTRUE);
1672// TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, minRadiusDetBox-0.1,
1673// fgkForwardLay4Length/2, ladderPhi, kFALSE);
1674// virtualForward4Pos->AddNode(lay4EndLadder, iLadd*2, ctEndLaddPos);
1675// virtualForward4Neg->AddNode(lay4EndLadder, iLadd*2+1, ctEndLaddNeg);
1676// }
1677
1678// virtualForward4Pos->SetVisibility(kFALSE);
1679// virtualForward4Neg->SetVisibility(kFALSE);
1680
1681// moth->AddNode(virtualForward4Pos, 1, virtualForward4TrPos);
1682// moth->AddNode(virtualForward4Neg, 1, virtualForward4TrNeg);
1683// }
1684
1685
1686//________________________________________________________________________
1687void AliITSv11GeometrySDD::ForwardLayer4(TGeoVolume *moth) {
1688 //
1689 // Insert the end-ladder of layer 4 in the mother volume.
1690 // (cooling, Carlos, LV, HV ...)
1691 //
1692
1693 if (! moth) {
1694 printf("Error::AliITSv11GeometrySDD: Can't insert layer4, mother is null!\n");
1695 return;
1696 };
1697
1698 if (! fSDDsensor3) CreateBasicObjects();
1699
1700 // placing virtual ladder and detectors volumes following ladder
1701 // ordering convention
1702 Int_t iLaddMin = 0;
1703 Int_t iLaddMax = fgkLay4Nladd;
1704 if ((fAddOnlyLadder4min >= 0)&&(fAddOnlyLadder4max < fgkLay4Nladd)) {
1705 iLaddMin = fAddOnlyLadder4min;
1706 iLaddMax = fAddOnlyLadder4max+1;
1707 }
1708
1709 TGeoVolume *virtualForward4Pos = new TGeoVolumeAssembly("ITSsddForward4Pos");
1710 TGeoVolume *virtualForward4Neg = new TGeoVolumeAssembly("ITSsddForward4Neg");
1711
1712 char rotName[30];
1713 Double_t dPhi = 360./fgkLay4Nladd;
1714 TGeoVolume* lay4EndLadder = CreateEndLadderCardsV(4);
1715
1716 for (Int_t iLadd = iLaddMin; iLadd < iLaddMax; iLadd++) {
1717
1718 Double_t ladderPhi = -5*dPhi + iLadd*dPhi;
1719 Double_t dR = 0;
1720 if (iLadd%2 != 0)
1721 dR = fgkLay4DetLongRadius-fgkLay4DetShortRadius;
1722
1723 sprintf(rotName, "ITSsddLay4EndLadd%i",iLadd);
1724
1725 TGeoCombiTrans *ctEndLaddPos = CreateCombiTrans(rotName, dR,
1726 fgkLay4Length/2, ladderPhi, kTRUE);
1727 TGeoCombiTrans *ctEndLaddNeg = CreateCombiTrans(rotName, dR,
1728 -fgkLay4Length/2, ladderPhi, kFALSE);
1729 virtualForward4Pos->AddNode(lay4EndLadder, iLadd*2, ctEndLaddPos);
1730 virtualForward4Neg->AddNode(lay4EndLadder, iLadd*2, ctEndLaddNeg);
1731 }
1732
1733 moth->AddNode(virtualForward4Pos, 1);
1734 moth->AddNode(virtualForward4Neg, 1);
531d6cdc 1735}
b7943f00 1736
1737
1738//________________________________________________________________________
108bd0fe 1739TGeoVolumeAssembly *AliITSv11GeometrySDD::CreateLadder(Int_t iLay) {
b7943f00 1740 //
73dfc864 1741 // return an assembly volume containing the CF ladder
b7943f00 1742 //
1743
1744 Int_t nDetectors = fgkLay3Ndet;
1745 Double_t ladderLength = fgkLay3LadderLength;
1746 Double_t underSegDH = fLay3LadderUnderSegDH;
1747 Double_t *sensorZPos = fLay3sensorZPos;
1748 AliITSv11GeomCableFlat *digitCableA = fDigitCableLay3A;
1749 AliITSv11GeomCableFlat *digitCableB = fDigitCableLay3B;
1750
1751 if (iLay==3) {}
1752 else if (iLay==4) {
1753 nDetectors = fgkLay4Ndet;
1754 ladderLength = fgkLay4LadderLength;
1755 digitCableA = fDigitCableLay4A;
1756 digitCableB = fDigitCableLay4B;
1757 underSegDH = fLay4LadderUnderSegDH;
1758 sensorZPos = fLay4sensorZPos;
1759 }
1760 else {
1761 printf("AliITSv11GeometrySDD::CreateLadder : error=wrong layer\n");
1762 };
1763 Double_t ladderBoxDH = fgkLadderHeight+fgkLadderSegBoxDH+underSegDH;
108bd0fe 1764 TGeoVolumeAssembly *virtualLadder = new TGeoVolumeAssembly("ITSsddLadder");
b7943f00 1765
1766 // placing virtual ladder segment following detector ordering convention
1767 //=======================================================================
1768 char transName[30];
1769
1770 // adding segment this way to create cable points in the correct order ...
1771 for (Int_t iSegment = nDetectors/2-1; iSegment >= 0; iSegment-- ) {
1772
73dfc864 1773 //TGeoVolumeAssembly *laddSegment = CreateLadderSegment(iLay, iSegment);
1774 TGeoVolume *laddSegment = CreateLadderSegment(iLay, iSegment);
b7943f00 1775 sprintf(transName, "ITSsddLay%iLaddSeg%i", iLay, iSegment);
1776 Double_t segmentPos = fgkSegmentLength*(nDetectors/2-1-iSegment)
1777 + fgkSegmentLength/2;
1778 TGeoTranslation *segTr = new TGeoTranslation(transName, 0,
1779 underSegDH/2,segmentPos);
1780 ////
1781 virtualLadder->AddNode(laddSegment, iSegment, segTr);
1782 };
1783 for (Int_t iSegment = nDetectors/2; iSegment < nDetectors; iSegment++ ) {
1784
73dfc864 1785 TGeoVolume *laddSegment = CreateLadderSegment(iLay, iSegment);
1786 //TGeoVolumeAssembly *laddSegment = CreateLadderSegment(iLay, iSegment);
b7943f00 1787 sprintf(transName, "ITSsddLay%iLaddSeg%i", iLay, iSegment);
1788 Double_t segmentPos = fgkSegmentLength*(nDetectors/2-1-iSegment)
1789 + fgkSegmentLength/2;
1790 TGeoTranslation *segTr = new TGeoTranslation(transName, 0,
1791 underSegDH/2,segmentPos);
1792 ////
1793 virtualLadder->AddNode(laddSegment, iSegment, segTr);
1794 };
1795
1796 // putting virtual volume corresponding to the end of ladder
1797 //=======================================================================
108bd0fe 1798 TGeoVolumeAssembly *endLadder = CreateEndLadder( iLay );
b7943f00 1799 Double_t endLength = (ladderLength - nDetectors*fgkSegmentLength)/2.;
1800 TGeoTranslation *endTrZPos = new TGeoTranslation("ITSsddEndTrZPos",0,0,
1801 fgkSegmentLength*(nDetectors/2)+endLength/2.);
1802 // Euler rotation : about Z, then new X, then new Z
1803 TGeoRotation *endZNegRot = new TGeoRotation("",90, 180, -90);
1804 TGeoCombiTrans *endTrZNeg = new TGeoCombiTrans(0,0,
1805 -fgkSegmentLength*(nDetectors/2)-endLength/2.,endZNegRot);
1806 virtualLadder->AddNode(endLadder, 1, endTrZPos);
1807 virtualLadder->AddNode(endLadder, 2, endTrZNeg);
1808
1809 // creating and inserting cable segments
1810 // (check points are placed while creating segments)
1811 //=======================================================================
1812 if (fAddCables)
1813 for (Int_t iSegment = 0; iSegment < nDetectors; iSegment++ ) {
1814
1815 digitCableA[iSegment].SetInitialNode(virtualLadder);
1816 digitCableB[iSegment].SetInitialNode(virtualLadder);
1817
1818 for (Int_t iPt=1; iPt<digitCableA[iSegment].GetNCheckPoints(); iPt++ ) {
1819 Double_t rotation = 0;
73dfc864 1820 if (iPt>1) {
1821 rotation = 90-fgkHybridAngle;
1822 digitCableA[iSegment].CreateAndInsertCableSegment(iPt, rotation);
1823 } else
bf210566 1824 digitCableA[iSegment].CreateAndInsertCableSegment(iPt);
73dfc864 1825
b7943f00 1826 };
1827
1828 for (Int_t iPt=1; iPt<digitCableB[iSegment].GetNCheckPoints(); iPt++ ) {
1829 Double_t rotation = 0;
73dfc864 1830 if (iPt>1) {
1831 rotation = fgkHybridAngle-90;
1832 digitCableB[iSegment].CreateAndInsertCableSegment(iPt, rotation);
1833 } else
bf210566 1834 digitCableB[iSegment].CreateAndInsertCableSegment(iPt);
b7943f00 1835 };
1836 };
1837
1838 // HV cable
1839 //=======================================================================
fa4639a3 1840 if (fAddHVcables) {
108bd0fe 1841 TGeoMedium *polyhamideSDD = GetMedium("SDDKAPTON (POLYCH2)$"); //ITSsddKAPTON_POLYCH2
1842 TGeoMedium *alSDD = GetMedium("AL$"); //ITSal
b7943f00 1843
1844 AliITSv11GeomCableFlat cableHV[fgkLay4Ndet]; // temp !!!
1845 char cableHVname[30];
1846 for (Int_t iSegment = 0; iSegment<nDetectors; iSegment++) {
1847 sprintf(cableHVname,"ITSsddHVcable%i", iSegment);
1848 cableHV[iSegment].SetName(cableHVname);
1849 cableHV[iSegment].SetThickness(fgkLongHVcablePolyThick+fgkLongHVcableAlThick);
1850 cableHV[iSegment].SetWidth(fgkTransitHVtailWidth);
1851 cableHV[iSegment].SetNLayers(2);
1852 cableHV[iSegment].SetLayer(0, fgkLongHVcablePolyThick, polyhamideSDD,
1853 fColorPolyhamide);
1854 cableHV[iSegment].SetLayer(1, fgkLongHVcableAlThick, alSDD, fColorAl);
1855 cableHV[iSegment].SetInitialNode(virtualLadder);
1856 };
1857 Double_t x1[3], x2[3], x3[3],
1858 vY[3] = {0,1,0}, vZ[3] = {0,0,1}, vYZ[3]={0,1,1};
1859
fa4639a3 1860 x1[0] = -fgkTransitHVtailXpos;
1861 x2[0] = -fgkTransitHVtailXpos;
1862 x3[0] = -fgkTransitHVtailXpos;
b7943f00 1863 for (Int_t iSegment = nDetectors/2-1; iSegment >= 0; iSegment-- ) {
1864 Double_t cableSeparation = TMath::Abs(iSegment - (nDetectors/2-1))
1865 *fgkLongHVcableSeparation;
73dfc864 1866 // adjust where HV long cable starts in Y
1867 // useful if you want to let some space for alignment
1868 x1[1] = - ladderBoxDH/2 + 2*fgkmm;
b7943f00 1869 x2[1] = - ladderBoxDH/2 + underSegDH - cableSeparation
1870 - (fgkLongHVcablePolyThick+fgkLongHVcableAlThick)/2;
1871 x3[1] = x2[1];
1872 x1[2] = sensorZPos[iSegment]+fgkTransitHVtailLength-5*fgkmm;
1873 x2[2] = x1[2]+5*fgkmm;
1874 x3[2] = ladderLength/2-endLength;
1875 cableHV[iSegment].AddCheckPoint( virtualLadder, 0, x1, vY );
73dfc864 1876 cableHV[iSegment].AddCheckPoint( virtualLadder, 1, x2, vZ ); // vYZ
b7943f00 1877 cableHV[iSegment].AddCheckPoint( virtualLadder, 2, x3, vZ );
1878
73dfc864 1879 //cableHV[iSegment].CreateAndInsertCableSegment(1,0);
1880 cableHV[iSegment].CreateAndInsertCableCylSegment(1, -45+180);
1881 //cableHV[iSegment].CreateAndInsertCableSegment(2,0);
1882 cableHV[iSegment].CreateAndInsertBoxCableSegment(2,0);
b7943f00 1883 };
1884
1885 vYZ[2] = -1;
fa4639a3 1886 x1[0] = fgkTransitHVtailXpos;
1887 x2[0] = fgkTransitHVtailXpos;
1888 x3[0] = fgkTransitHVtailXpos;
1889
b7943f00 1890 for (Int_t iSegment = nDetectors/2; iSegment < nDetectors; iSegment++ ) {
1891 Double_t cableSeparation = TMath::Abs(iSegment - (nDetectors/2-1))
1892 *fgkLongHVcableSeparation;
73dfc864 1893 x1[1] = - ladderBoxDH/2 + 2*fgkmm; // adjust where HV long cable starts in Y
b7943f00 1894 x2[1] = - ladderBoxDH/2 + underSegDH - cableSeparation
1895 - (fgkLongHVcablePolyThick+fgkLongHVcableAlThick)/2;
1896 x3[1] = x2[1];
1897 x1[2] = sensorZPos[iSegment]-fgkTransitHVtailLength+5*fgkmm;
1898 x2[2] = x1[2]-5*fgkmm;
1899 x3[2] = -ladderLength/2+endLength;
1900 cableHV[iSegment].AddCheckPoint( virtualLadder, 0, x1, vY );
73dfc864 1901 cableHV[iSegment].AddCheckPoint( virtualLadder, 1, x2, vZ ); // vYZ
b7943f00 1902 cableHV[iSegment].AddCheckPoint( virtualLadder, 2, x3, vZ );
1903
73dfc864 1904 cableHV[iSegment].CreateAndInsertCableCylSegment(1, -45);
1905 cableHV[iSegment].CreateAndInsertBoxCableSegment(2,0);
b7943f00 1906 };
fa4639a3 1907 };
c789ee28 1908
b7943f00 1909 //**********************************
1910 if(GetDebug(1)) virtualLadder->CheckOverlaps(0.01);
b7943f00 1911 return virtualLadder;
531d6cdc 1912}
c789ee28 1913
1914
db486a6e 1915//________________________________________________________________________
b7943f00 1916TGeoArb8 *AliITSv11GeometrySDD::CreateLadderSide(Double_t dz, Double_t angle,
1917 Double_t xSign, Double_t L, Double_t H, Double_t l) {
db486a6e 1918 // Create one half of the V shape corner of CF ladder
1919
1920 TGeoArb8 *cfLaddSide = new TGeoArb8(dz);
c789ee28 1921 cfLaddSide->SetVertex( 0, 0, 0);
1922 cfLaddSide->SetVertex( 1, 0, -H);
1923 cfLaddSide->SetVertex( 2, xSign*(L*TMath::Sin(angle)-l*TMath::Cos(angle)),
1924 -L*TMath::Cos(angle)-l*TMath::Sin(angle));
1925 cfLaddSide->SetVertex( 3, xSign*L*TMath::Sin(angle), -L*TMath::Cos(angle));
1926 cfLaddSide->SetVertex( 4, 0, 0);
1927 cfLaddSide->SetVertex( 5, 0, -H);
1928 cfLaddSide->SetVertex( 6, xSign*(L*TMath::Sin(angle)-l*TMath::Cos(angle)),
1929 -L*TMath::Cos(angle)-l*TMath::Sin(angle));
1930 cfLaddSide->SetVertex(7, xSign*L*TMath::Sin(angle), -L*TMath::Cos(angle));
db486a6e 1931 return cfLaddSide;
531d6cdc 1932}
c789ee28 1933
1934
db486a6e 1935//________________________________________________________________________
b7943f00 1936TGeoVolume* AliITSv11GeometrySDD::CreateHybrid(Int_t iLRSide) {
1937 //
1938 // return a box containing the front-end hybrid
1939 //
1940
1941 Double_t roundHoleX = -fgkHybridWidth/2+fgkHybRndHoleX;
1942
1943 Double_t screenTotalThick = fgkHybGlueScrnThick+fgkHybUpThick+fgkHybAlThick;
1944 Double_t lowFLTotalThick = fgkHybGlueLowThick+fgkHybUpThick+fgkHybAlThick;
1945// Double_t upFLTotalThick = fgkHybGlueUpThick +fgkHybUpThick+fgkHybAlThick;
1946 Double_t chipsCCTotThick = fgkHybUnderNiThick+fgkHybGlueAgThick
1947 +fgkHybChipThick+2*(fgkHybUpCCThick+fgkHybAlCCThick);
1948 Double_t ccUpLayerTotThick = fgkHybUpCCThick+fgkHybAlCCThick+fgkHybUpCCThick;
1949// Double_t volumeThick = (fgkHybridThBridgeThick+screenTotalThick+lowFLTotalThick
1950// + upFLTotalThick + ccUpLayerTotThick);
1951 Double_t volumeThick = (fgkHybridThBridgeThick+screenTotalThick+lowFLTotalThick
1952 +fgkHybSMDheight);
1953 Double_t lowLayerYmin = -volumeThick/2+fgkHybridThBridgeThick
1954 +screenTotalThick;
1955 Double_t flUpThick = fgkHybGlueUpThick+fgkHybUpThick;
1956
1957 //**************************************************** media :
108bd0fe 1958 TGeoMedium *airSDD = GetMedium("SDD AIR$");
1959 TGeoMedium *carbonFiberLadderStruct = GetMedium("SDDKAPTON (POLYCH2)$"); //ITSsddCarbonM55J
1960 TGeoMedium *alSDD = GetMedium("AL$"); //ITSal
1961 TGeoMedium *alSDD80p100 = GetMedium("AL$"); // to code !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1962 TGeoMedium *alSDD50p100 = GetMedium("AL$"); // to code !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1963 TGeoMedium *polyhamideSDD = GetMedium("SDDKAPTON (POLYCH2)$"); //ITSsddKAPTON_POLYCH2
1964 TGeoMedium *niSDD = GetMedium("COPPER$"); // to code !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1965 TGeoMedium *glueAG = GetMedium("SDDKAPTON (POLYCH2)$"); // to code !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1966 TGeoMedium *siliconSDD = GetMedium("SDD SI CHIP$"); //ITSsddSiChip
1967 TGeoMedium *medSMD = GetMedium("SDD X7R capacitors$"); // SDDX7Rcapacitors TO CHECK !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1968 TGeoMedium *medSMDweld = GetMedium("SDD X7R capacitors$"); // SDDX7Rcapacitors TO CHECK !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
b7943f00 1969
1970 //**************************************************** main volume :
1971 TGeoBBox *hybridBox = new TGeoBBox("",fgkHybridWidth/2, volumeThick/2,
1972 (fgkHybridLength)/2);
1973 TGeoVolume *hybrid = new TGeoVolume("ITSsddHybridVol", hybridBox,
1974 airSDD);
1975
1976 TGeoBBox *sThermalBridge = new TGeoBBox( "", fgkHybridWidth/2,
1977 fgkHybridThBridgeThick/2,
1978 fgkHybridLength/2);
c789ee28 1979
b7943f00 1980 //**************************************************** Thermal bridge :
c789ee28 1981 TGeoVolume *vThermalBridge = new TGeoVolume("ITSsddHybridThBridge",
1982 sThermalBridge,
1983 carbonFiberLadderStruct);
1984 vThermalBridge->SetLineColor(fColorCarbonFiber);
b7943f00 1985 TGeoTranslation *thBridgeTr = new TGeoTranslation(0, -volumeThick/2
1986 +fgkHybridThBridgeThick/2, 0);
1987 hybrid->AddNode(vThermalBridge, 1, thBridgeTr);
1988
1989 //**************************************************** Screen layer :
1990 TGeoBBox *sAlScreenLayer = new TGeoBBox("sAlScreenLayer", fgkHybridWidth/2,
1991 fgkHybAlThick/2, fgkHybridLength/2);
1992 //here the upedex and glue layers are both assumed to be polyimide
1993 TGeoBBox *sUpGlueScreenLayer = new TGeoBBox("sUpGlueScreenLayer",
1994 fgkHybridWidth/2,
1995 (fgkHybUpThick+fgkHybGlueScrnThick)/2,
1996 fgkHybridLength/2);
1997 TGeoTube *sRoundHole = new TGeoTube("sRoundHole", 0, fgkHybRndHoleRad,
1998 (screenTotalThick+lowFLTotalThick)/2);
1999
2000 TGeoTranslation *upGlueScreenTr = new TGeoTranslation("upGlueScreenTr",0,
2001 -volumeThick/2+fgkHybridThBridgeThick+(fgkHybUpThick+fgkHybGlueScrnThick)/2,0);
2002
2003 TGeoTranslation *alScreenTr = new TGeoTranslation("AlScreenTr", 0,
2004 -volumeThick/2+fgkHybridThBridgeThick+fgkHybUpThick+fgkHybGlueScrnThick
2005 +fgkHybAlThick/2, 0);
2006
2007 TGeoTranslation hybHolePos1Tr(roundHoleX,
2008 -volumeThick/2+fgkHybridThBridgeThick+(screenTotalThick+lowFLTotalThick)/2,
2009 -fgkHybridLength/2+fgkHybRndHoleZ);
2010 TGeoTranslation hybHolePos2Tr(roundHoleX,
2011 -volumeThick/2+fgkHybridThBridgeThick+(screenTotalThick+lowFLTotalThick)/2,
2012 fgkHybridLength/2-fgkHybRndHoleZ);
531d6cdc 2013
2014 TGeoRotation *rotHole = new TGeoRotation("", 0, 90, 0);
2015 TGeoCombiTrans *hybHolePos1 = new TGeoCombiTrans(hybHolePos1Tr, *rotHole);
b7943f00 2016 hybHolePos1->SetName("hybHolePos1");
531d6cdc 2017 TGeoCombiTrans *hybHolePos2 = new TGeoCombiTrans(hybHolePos2Tr, *rotHole);
b7943f00 2018 hybHolePos2->SetName("hybHolePos2");
2019
2020 upGlueScreenTr->RegisterYourself();
2021 alScreenTr->RegisterYourself();
2022 hybHolePos1->RegisterYourself();
2023 hybHolePos2->RegisterYourself();
531d6cdc 2024 delete rotHole;
b7943f00 2025
2026 TGeoCompositeShape *sScreenAl = new TGeoCompositeShape(
2027 "sAlScreenLayer:AlScreenTr-(sRoundHole:hybHolePos1"
2028 "+sRoundHole:hybHolePos2)");
2029 TGeoVolume *vScreenAl = new TGeoVolume("vScreenAl",sScreenAl, alSDD);
2030 vScreenAl->SetLineColor(fColorAl);
2031 TGeoCompositeShape *sScreenUpGlue = new TGeoCompositeShape(
2032 "sUpGlueScreenLayer:upGlueScreenTr-(sRoundHole:hybHolePos1"
2033 "+sRoundHole:hybHolePos2)");
2034 TGeoVolume *vScreenUpGlue = new TGeoVolume("vScreenUpGlue",
2035 sScreenUpGlue,polyhamideSDD);
2036 vScreenUpGlue->SetLineColor(fColorPolyhamide);
2037
2038 hybrid->AddNode(vScreenUpGlue, 1, 0);
2039 hybrid->AddNode(vScreenAl, 1, 0);
2040
2041 //**************************************************** FL low layer :
2042 Double_t sideWidth1 = fgkHybFLlowChipZ1 - fgkHybFLlowHoleDZ/2;
2043 Double_t sideWidth2 = fgkHybridLength - fgkHybFLlowChipZ4 - fgkHybFLlowHoleDZ/2;
2044
2045 //here the upedex and glue layers are both assumed to be polyimide
2046 TGeoBBox *sUpGlueBar1 = new TGeoBBox("sUpGlueBar1", fgkHybridWidth/2,
2047 (fgkHybGlueLowThick+fgkHybUpThick)/2,
2048 sideWidth1/2);
2049 TGeoBBox *sAlBar1 = new TGeoBBox("sAlBar1", fgkHybridWidth/2,
2050 fgkHybAlThick/2, sideWidth1/2);
2051
2052 TGeoTranslation *upGlueBarTr1 = new TGeoTranslation("upGlueBarTr1", 0,
2053 lowLayerYmin+(fgkHybGlueLowThick+fgkHybUpThick)/2,
2054 -(fgkHybridLength-sideWidth1)/2);
2055 TGeoTranslation *alBarTr1 = new TGeoTranslation("alBarTr1", 0,
2056 lowLayerYmin+fgkHybGlueLowThick+fgkHybUpThick+fgkHybAlThick/2,
2057 -(fgkHybridLength-sideWidth1)/2);
2058 upGlueBarTr1->RegisterYourself();
2059 alBarTr1->RegisterYourself();
2060
2061 TGeoCompositeShape *sLowUpGlueBar1 = new TGeoCompositeShape(
2062 "sUpGlueBar1:upGlueBarTr1-sRoundHole:hybHolePos1");
2063 TGeoCompositeShape *sLowAlBar1 = new TGeoCompositeShape(
2064 "sAlBar1:alBarTr1-sRoundHole:hybHolePos1");
2065 TGeoVolume *vLowUpGlueBar1 = new TGeoVolume("vLowUpGlueBar1",
2066 sLowUpGlueBar1, polyhamideSDD);
2067 TGeoVolume *vLowAlBar1 = new TGeoVolume("vLowAlBar1",
2068 sLowAlBar1, alSDD);
2069 vLowUpGlueBar1->SetLineColor(fColorPolyhamide);
2070 vLowAlBar1->SetLineColor(fColorAl);
2071 hybrid->AddNode(vLowUpGlueBar1,1,0);
2072 hybrid->AddNode(vLowAlBar1,1,0);
2073
2074 //---
2075 //here the upedex and glue layers are both assumed to be polyimide
2076 TGeoBBox *sUpGlueBar2 = new TGeoBBox("sUpGlueBar2", fgkHybridWidth/2,
2077 (fgkHybGlueLowThick+fgkHybUpThick)/2,
2078 sideWidth2/2);
2079 TGeoBBox *sAlBar2 = new TGeoBBox("sAlBar2", fgkHybridWidth/2,
2080 fgkHybAlThick/2, sideWidth2/2);
2081
2082 TGeoTranslation *upGlueBarTr2 = new TGeoTranslation("upGlueBarTr2", 0,
2083 lowLayerYmin+(fgkHybGlueLowThick+fgkHybUpThick)/2,
2084 (fgkHybridLength-sideWidth2)/2);
2085 TGeoTranslation *alBarTr2 = new TGeoTranslation("alBarTr2", 0,
2086 lowLayerYmin+fgkHybGlueLowThick+fgkHybUpThick+fgkHybAlThick/2,
2087 (fgkHybridLength-sideWidth2)/2);
2088 upGlueBarTr2->RegisterYourself();
2089 alBarTr2->RegisterYourself();
2090
2091 TGeoCompositeShape *sLowUpGlueBar2 = new TGeoCompositeShape(
2092 "sUpGlueBar2:upGlueBarTr2-sRoundHole:hybHolePos2");
2093 TGeoCompositeShape *sLowAlBar2 = new TGeoCompositeShape(
2094 "sAlBar2:alBarTr2-sRoundHole:hybHolePos2");
2095 TGeoVolume *vLowUpGlueBar2 = new TGeoVolume("vLowUpGlueBar2",sLowUpGlueBar2,
2096 polyhamideSDD);
2097 TGeoVolume *vLowAlBar2 = new TGeoVolume("vLowAlBar2",sLowAlBar2,
2098 alSDD);
2099 vLowUpGlueBar2->SetLineColor(fColorPolyhamide);
2100 vLowAlBar2->SetLineColor(fColorAl);
2101 hybrid->AddNode(vLowUpGlueBar2, 1, 0);
2102 hybrid->AddNode(vLowAlBar2, 1, 0);
2103
108bd0fe 2104 if(GetDebug(3)) { // Remove compiler warning.
b7943f00 2105 sAlScreenLayer->InspectShape();
2106 sUpGlueScreenLayer->InspectShape();
2107 sRoundHole->InspectShape();
2108 sUpGlueBar1->InspectShape();
2109 sUpGlueBar2->InspectShape();
2110 sAlBar1->InspectShape();
2111 sAlBar2->InspectShape();
2112 };
2113 //---
2114 //using class AliITSv11GeomCableFlat to add 2-layer segments ...
2115 Double_t piece1width = fgkHybFLlowPasX-fgkHybFLlowHolePasDX/2;
2116 AliITSv11GeomCableFlat lowFLpiece("lowFLpiece1",piece1width,
2117 lowFLTotalThick);
2118 lowFLpiece.SetNLayers(2);
2119 lowFLpiece.SetLayer(0, fgkHybGlueLowThick+fgkHybUpThick, polyhamideSDD,
2120 fColorPolyhamide);
2121 lowFLpiece.SetLayer(1, fgkHybAlThick, alSDD80p100, fColorAl);
2122 // alSDD at 80% : mostly to take into account strips of piece 3
2123
2124 Double_t x1[3] = { -fgkHybridWidth/2 + piece1width/2,
2125 lowLayerYmin + lowFLTotalThick/2,
2126 -fgkHybridLength/2 + sideWidth1 };
2127 Double_t x2[3] ={ x1[0], x1[1], fgkHybridLength/2 - sideWidth2 };
2128 Double_t vZ[3] = {0,0,1};
2129 lowFLpiece.AddCheckPoint( hybrid, 0, x2, vZ );
2130 lowFLpiece.AddCheckPoint( hybrid, 1, x1, vZ );
2131 lowFLpiece.SetInitialNode(hybrid);
108bd0fe 2132 lowFLpiece.CreateAndInsertBoxCableSegment(1);
b7943f00 2133 lowFLpiece.ResetPoints();
2134
2135 Double_t piece2width = fgkHybFLlowAmbX-fgkHybFLlowPasX
2136 -fgkHybFLlowHolePasDX/2-fgkHybFLlowHoleAmbDX/2;
2137
2138 lowFLpiece.SetWidth(piece2width);
2139 lowFLpiece.SetName("lowFLpiece2");
2140 x1[0] = piece2width/2+fgkHybFLlowPasX+fgkHybFLlowHolePasDX/2-fgkHybridWidth/2;
2141 x2[0] = x1[0];
2142 lowFLpiece.AddCheckPoint( hybrid, 0, x2, vZ );
2143 lowFLpiece.AddCheckPoint( hybrid, 1, x1, vZ );
108bd0fe 2144 lowFLpiece.CreateAndInsertBoxCableSegment(1);
b7943f00 2145 lowFLpiece.ResetPoints();
2146
2147 Double_t piece3width = fgkHybridWidth - fgkHybFLlowAmbX
2148 - fgkHybFLlowHoleAmbDX/2;
2149
2150 lowFLpiece.SetWidth(piece3width);
2151 lowFLpiece.SetName("lowFLpiece3");
2152 x1[0] = fgkHybridWidth/2-piece3width/2;
2153 x2[0] = x1[0];
2154 lowFLpiece.AddCheckPoint( hybrid, 0, x2, vZ );
2155 lowFLpiece.AddCheckPoint( hybrid, 1, x1, vZ );
108bd0fe 2156 lowFLpiece.CreateAndInsertBoxCableSegment(1);
b7943f00 2157
2158 Double_t zChips[4] = {fgkHybFLlowChipZ1,fgkHybFLlowChipZ2,
2159 fgkHybFLlowChipZ3,fgkHybFLlowChipZ4};
2160 Double_t vX[3] = {1,0,0};
2161 for (Int_t i=0; i<3; i++) {
2162 char ch[20];
2163 sprintf(ch, "lowFLpieceA%i", i+4);
2164 lowFLpiece.SetName(ch);
2165 lowFLpiece.SetWidth(zChips[i+1]-zChips[i]-fgkHybFLlowHoleDZ);
2166
2167 lowFLpiece.SetLayer(1, fgkHybAlThick, alSDD, fColorAl);
2168 x1[0] = -fgkHybridWidth/2 + piece1width;
2169 x2[0] = x1[0] + fgkHybFLlowHolePasDX;
2170 Double_t zPiece = (zChips[i+1]+zChips[i])/2 - fgkHybridLength/2;
2171 x1[2] = zPiece; x2[2] = zPiece;
2172 lowFLpiece.AddCheckPoint( hybrid, 0, x2, vX );
2173 lowFLpiece.AddCheckPoint( hybrid, 1, x1, vX );
108bd0fe 2174 lowFLpiece.CreateAndInsertBoxCableSegment(1,90);
b7943f00 2175 lowFLpiece.ResetPoints();
2176
2177 sprintf(ch, "lowFLpieceB%i", i+4);
2178 lowFLpiece.SetName(ch);
2179 x1[0] = fgkHybridWidth/2 - piece3width;
2180 x2[0] = x1[0] - fgkHybFLlowHoleAmbDX;
2181 lowFLpiece.AddCheckPoint( hybrid, 0, x1, vX );
2182 lowFLpiece.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2183 lowFLpiece.CreateAndInsertBoxCableSegment(1,90);
b7943f00 2184 };
2185
2186 //**************************************************** chips+CC:
2187 AliITSv11GeomCableFlat chip("", fgkHybChipsDZ, chipsCCTotThick);
2188 chip.SetInitialNode(hybrid);
2189 chip.SetNLayers(5);
2190 chip.SetLayer(0, fgkHybUnderNiThick, niSDD, 2);
2191 chip.SetLayer(1, fgkHybGlueAgThick, glueAG, 4);
2192 chip.SetLayer(2, fgkHybChipThick, siliconSDD, fColorSilicon);
2193 chip.SetLayer(3, fgkHybUpCCThick+fgkHybUpCCThick, polyhamideSDD,
2194 fColorPolyhamide);
2195 chip.SetLayer(4, fgkHybAlCCThick+fgkHybAlCCThick, alSDD80p100, fColorAl);
2196 // Here the tho CC (low+up) are merged
2197 // In fact, the last layer has a smaller surface of Al -> I put 80%
2198
2199 x1[1] = lowLayerYmin + chipsCCTotThick/2;
2200 x2[1] = x1[1];
2201 char ch[20];
2202
2203 for (Int_t i=0; i<4; i++) {
2204 sprintf(ch, "pascalCC%i", i);
2205 chip.SetName(ch);
2206 x1[0] = fgkHybFLlowPasX - fgkHybridWidth/2 - fgkHybPascalDX/2;
2207 x2[0] = x1[0] + fgkHybPascalDX;
2208 x1[2] = zChips[i] - fgkHybridLength/2;
2209 x2[2] = x1[2];
2210 chip.AddCheckPoint( hybrid, 0, x1, vX );
2211 chip.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2212 chip.CreateAndInsertBoxCableSegment(1,-90);
b7943f00 2213 chip.ResetPoints();
2214
2215 sprintf(ch, "ambraCC%i", i);
2216 chip.SetName(ch);
2217 x1[0] = fgkHybFLlowAmbX - fgkHybridWidth/2 - fgkHybAmbraDX/2;
2218 x2[0] = x1[0] + fgkHybAmbraDX;
2219 chip.AddCheckPoint( hybrid, 0, x1, vX );
2220 chip.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2221 chip.CreateAndInsertBoxCableSegment(1,-90);
b7943f00 2222 chip.ResetPoints();
2223 };
c789ee28 2224
b7943f00 2225 //**************************************************** CC outside chips:
73dfc864 2226 // I don't think there is a second aluminium layer here ...
b7943f00 2227 for (Int_t i = 0; i<4; i++) {
2228 char ch[20];
2229 sprintf(ch, "ccLayerA%i", i);
2230
2231 AliITSv11GeomCableFlat ccLayer1(ch, 6.6*fgkmm, ccUpLayerTotThick);
2232 ccLayer1.SetInitialNode(hybrid);
2233 ccLayer1.SetNLayers(2);
2234 ccLayer1.SetLayer(0, 2*fgkHybUpCCThick, polyhamideSDD, fColorPolyhamide);
2235 ccLayer1.SetLayer(1, fgkHybAlCCThick, alSDD50p100, fColorAl);
2236 // Al at ~50%
2237
2238 x1[0] = -fgkHybridWidth/2;
2239 x2[0] = fgkHybFLlowPasX - fgkHybridWidth/2 - fgkHybPascalDX/2;
2240 x1[1] = lowLayerYmin + fgkHybUnderNiThick + fgkHybGlueAgThick
2241 + fgkHybChipThick + ccUpLayerTotThick/2;
2242 x2[1] = x1[1];
2243 x1[2] = zChips[i] - fgkHybridLength/2;
2244 x2[2] = x1[2];
2245 ccLayer1.AddCheckPoint( hybrid, 0, x1, vX );
2246 ccLayer1.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2247 ccLayer1.CreateAndInsertBoxCableSegment(1,-90);
b7943f00 2248
2249 sprintf(ch, "ccLayerB%i", i);
2250 AliITSv11GeomCableFlat ccLayer2(ch, fgkHybChipsDZ, ccUpLayerTotThick);
2251 ccLayer2.SetInitialNode(hybrid);
2252 ccLayer2.SetNLayers(2);
2253 ccLayer2.SetLayer(0, 2*fgkHybUpCCThick, polyhamideSDD, fColorPolyhamide);
2254 ccLayer2.SetLayer(1, fgkHybAlCCThick, alSDD50p100, fColorAl);
2255 // Al at ~50%
2256
2257 x1[0] = -fgkHybridWidth/2 + fgkHybFLlowPasX + fgkHybPascalDX/2;
2258 x2[0] = -fgkHybridWidth/2 + fgkHybFLlowAmbX - fgkHybAmbraDX/2;
2259 ccLayer2.AddCheckPoint( hybrid, 0, x1, vX );
2260 ccLayer2.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2261 ccLayer2.CreateAndInsertBoxCableSegment(1,-90);
b7943f00 2262 ccLayer2.ResetPoints();
2263 sprintf(ch, "ccLayerC%i", i);
2264 ccLayer2.SetName(ch);
2265 x1[0] = -fgkHybridWidth/2 + fgkHybFLlowAmbX + fgkHybAmbraDX/2;
2266 x2[0] = fgkHybridWidth/2 - fgkHybFLUpperWidth + 3*fgkmm;
2267 x1[1] = lowLayerYmin + lowFLTotalThick + flUpThick + fgkHybAlThick
2268 + ccUpLayerTotThick/2;
2269 x2[1] = x1[1];
2270
2271 ccLayer2.AddCheckPoint( hybrid, 0, x1, vX );
2272 ccLayer2.AddCheckPoint( hybrid, 1, x2, vX );
108bd0fe 2273 ccLayer2.CreateAndInsertBoxCableSegment(1,-90);
b7943f00 2274 };
c789ee28 2275
b7943f00 2276 //**************************************************** FL UP:
2277 // (last Al layer will be a special triangular shape)
2278 TGeoBBox *sFLupPolyhamide = new TGeoBBox("sFLupPolyhamide",
2279 fgkHybFLUpperWidth/2, flUpThick/2,
2280 fgkHybFLUpperLength/2);
2281 TGeoVolume *vFLupPolyhamide = new TGeoVolume("vFLupPolyhamide",
2282 sFLupPolyhamide, polyhamideSDD);
2283 vFLupPolyhamide->SetLineColor(fColorPolyhamide);
2284 TGeoTranslation *trFLupPolyhamide =
2285 new TGeoTranslation(fgkHybridWidth/2-fgkHybFLUpperWidth/2,
2286 lowLayerYmin+lowFLTotalThick+flUpThick/2,0);
2287
2288 hybrid->AddNode(vFLupPolyhamide, 1, trFLupPolyhamide);
2289
2290 TGeoArb8 *aluStrip = new TGeoArb8(fgkHybAlThick/2);
2291 aluStrip->SetVertex( 0,-fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth);
2292 aluStrip->SetVertex( 1, fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth);
2293 aluStrip->SetVertex( 2, fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth-fgkHybFLUpperAldx);
2294 aluStrip->SetVertex( 3,-fgkHybFLUpperAlDZ/2, 0);
2295 aluStrip->SetVertex( 4,-fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth);
2296 aluStrip->SetVertex( 5, fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth);
2297 aluStrip->SetVertex( 6, fgkHybFLUpperAlDZ/2, fgkHybFLUpperWidth-fgkHybFLUpperAldx);
2298 aluStrip->SetVertex( 7,-fgkHybFLUpperAlDZ/2, 0);
2299 TGeoVolume *vAluStrip = new TGeoVolume("vAluStrip",aluStrip, alSDD50p100);
2300 // Al at ~50%
2301
2302 vAluStrip->SetLineColor(fColorAl);
531d6cdc 2303 //TGeoRotation rotAluStrip("rotAluStrip",0, -90, 90);
2304 TGeoRotation *rotAluStrip = new TGeoRotation("rotAluStrip",0, -90, 90);
2305
b7943f00 2306 Double_t yRotAluStrip = lowLayerYmin+lowFLTotalThick
2307 +flUpThick+fgkHybAlThick/2;
2308 TGeoCombiTrans *aluStripTr1 = new TGeoCombiTrans(
2309 fgkHybridWidth/2,yRotAluStrip,
531d6cdc 2310 fgkHybridLength/2-fgkHybFLlowChipZ1+1*fgkmm, rotAluStrip);
b7943f00 2311 TGeoCombiTrans *aluStripTr2 = new TGeoCombiTrans(*aluStripTr1);
2312 AddTranslationToCombiTrans(aluStripTr2,0,0,
2313 fgkHybFLlowChipZ1-fgkHybFLlowChipZ2);
2314 TGeoCombiTrans *aluStripTr3 = new TGeoCombiTrans(*aluStripTr2);
2315 AddTranslationToCombiTrans(aluStripTr3,0,0,
2316 fgkHybFLlowChipZ2-fgkHybFLlowChipZ3);
2317 TGeoCombiTrans *aluStripTr4 = new TGeoCombiTrans(*aluStripTr3);
2318 AddTranslationToCombiTrans(aluStripTr4,0,0,
2319 fgkHybFLlowChipZ3-fgkHybFLlowChipZ4);
2320
2321 hybrid->AddNode(vAluStrip, 1, aluStripTr1);
2322 hybrid->AddNode(vAluStrip, 2, aluStripTr2);
2323 hybrid->AddNode(vAluStrip, 3, aluStripTr3);
2324 hybrid->AddNode(vAluStrip, 4, aluStripTr4);
b7943f00 2325 //**************************************************** SMD:
2326 TGeoBBox *hybSMD = new TGeoBBox("ITSsddSMDshape",
2327 fgkHybSMDmiddleL/2+fgkHybSMDendL,
2328 fgkHybSMDheight/2,fgkHybSMDendW/2);
2329 TGeoVolume *vHybSMD = new TGeoVolume("ITSsddSMD",hybSMD,airSDD);
2330
2331 TGeoBBox *hybSMDmiddle = new TGeoBBox("ITSsddSMDmiddleShape",
2332 fgkHybSMDmiddleL/2,fgkHybSMDheight/2,
2333 fgkHybSMDmiddleW/2);
2334 TGeoVolume *vHybSMDmiddle = new TGeoVolume("ITSsddSMDmiddle",
2335 hybSMDmiddle,medSMD);
2336 vHybSMDmiddle->SetLineColor(fColorSMD);
2337 TGeoBBox *hybSMDend = new TGeoBBox("ITSsddSMDendShape",
2338 fgkHybSMDendL/2,fgkHybSMDheight/2,fgkHybSMDendW/2);
2339 TGeoVolume *vHybSMDend = new TGeoVolume("ITSsddSMDend",
2340 hybSMDend,medSMDweld);
2341 vHybSMDend->SetLineColor(fColorSMDweld);
2342 TGeoTranslation *vHybSMDendTr1 = new TGeoTranslation("",
2343 (fgkHybSMDmiddleL+fgkHybSMDendL)/2,0,0);
2344 TGeoTranslation *vHybSMDendTr2 = new TGeoTranslation("",
2345 -(fgkHybSMDmiddleL+fgkHybSMDendL)/2,0,0);
2346 vHybSMD->AddNode(vHybSMDmiddle,1,0);
2347 vHybSMD->AddNode(vHybSMDend,1,vHybSMDendTr1);
2348 vHybSMD->AddNode(vHybSMDend,2,vHybSMDendTr2);
2349 for (Int_t i=0; i<fgkNHybSMD; i++) {
2350 TGeoTranslation *vHybSMDtr = new TGeoTranslation("",
2351 -fgkHybridWidth/2+fgkHybSMDposX[i],
2352 lowLayerYmin+lowFLTotalThick+fgkHybSMDheight/2,
2353 -fgkHybridLength/2+fgkHybSMDposZ[i]);
2354 hybrid->AddNode(vHybSMD, i+1, vHybSMDtr);
2355 };
2356
b7943f00 2357 if (iLRSide == 0) {
2358 };
2359
2360 if(GetDebug(1)) hybrid->CheckOverlaps(0.01);
2361 hybrid->SetVisibility(kFALSE);
2362 return hybrid;
531d6cdc 2363}
c789ee28 2364
db486a6e 2365//________________________________________________________________________
73dfc864 2366TGeoVolume* AliITSv11GeometrySDD::CreateLadderSegment(Int_t iLay, Int_t iSeg) {
b7943f00 2367 //
73dfc864 2368 // Return a TGeoVolume* containing a segment of a ladder.
b7943f00 2369 //
2370
e118532f 2371 TGeoMedium *phynoxSDD = GetMedium("INOX$");
108bd0fe 2372 TGeoMedium *coolerMediumSDD = GetMedium("WATER$");
73dfc864 2373 TGeoMedium *airSDD = GetMedium("SDD AIR$");
b7943f00 2374
2375 Double_t tDY = fgkLadderSegBoxDH/2; //space left on top of the ladder
2376 Double_t segmentLength = fgkSegmentLength;
2377 Double_t spaceBetweenCables = 500*fgkmicron;
2378
2379 //*****************************************
2380 // Set parameters according to (iLay,iSeg):
2381 //*****************************************
2382 Int_t nDetectors = fgkLay3Ndet;
2383 Double_t coolPipeSuppH = fgkLay3CoolPipeSuppH;
2384 Double_t sensorCenterZPos = fLay3sensorZPos[iSeg]-
2385 (fgkSegmentLength*fgkLay3Ndet/2. -
2386 fgkSegmentLength/2-(iSeg)*fgkSegmentLength);
2387 // sensorCenterZPos = z in segment local coord syst.
2388
2389 AliITSv11GeomCableFlat *digitCableA = fDigitCableLay3A;
2390 AliITSv11GeomCableFlat *digitCableB = fDigitCableLay3B;
2391
2392 if (iLay==3) {
2393 } else if (iLay==4) {
2394 nDetectors = fgkLay4Ndet;
2395 coolPipeSuppH = fgkLay4CoolPipeSuppH;
2396 sensorCenterZPos = fLay4sensorZPos[iSeg]-
2397 (fgkSegmentLength*fgkLay4Ndet/2. -
2398 fgkSegmentLength/2-(iSeg)*fgkSegmentLength);
2399 digitCableA = fDigitCableLay4A;
2400 digitCableB = fDigitCableLay4B;
2401 } else
2402 printf("AliITSv11GeometrySDD::CreateLadderSegment Wrong layer index !");
2403
2404
2405 Double_t cableSideSign = -1;
2406 if (iSeg<nDetectors/2) cableSideSign = 1;
2407 Double_t spaceForCables = spaceBetweenCables*
2408 (nDetectors-TMath::Abs(nDetectors-2*iSeg-1)-1)/2
2409 +0.1*fgkmicron;
2410 // gives [0-1-2-2-1-0]*spaceBetweenCables
2411 // or [0-1-2-3-3-2-1-0]*spaceBetweenCables
2412 Int_t iUpdateCableMin;
2413 Int_t iUpdateCableMax;
2414 if (cableSideSign==-1) {
2415 iUpdateCableMin = nDetectors/2;
2416 iUpdateCableMax = iSeg-1;
2417 } else {
2418 iUpdateCableMin = iSeg+1;
2419 iUpdateCableMax = nDetectors/2-1;
2420 };
2421
2422 if(GetDebug(1)){
2423 cout << "Segment ("<< iLay <<',' << iSeg
2424 << ") : sensor z shift in local segment coord.="
2425 << sensorCenterZPos << endl;
2426 };
2427
2428 //****************************
2429 // The segment volume
2430 //****************************
108bd0fe 2431
73dfc864 2432 // Use of TGeoVolumeAssembly increases the calculation time of overlaps and very
2433 // likely slows down the transport of particles through the geometry
2434
2435 //TGeoVolumeAssembly *virtualSeg = new TGeoVolumeAssembly("ITSsddSegment");
2436
2437 TGeoBBox *segBox = new TGeoBBox("ITSsddSegBox",
2438 fgkLadderWidth/2+fgkPinSuppWidth+fgkLadderSegBoxDW,
2439 fgkLadderHeight/2+fgkLadderSegBoxDH/2,
2440 segmentLength/2);
2441
2442 TGeoVolume *virtualSeg = new TGeoVolume("ITSsddSegment",
2443 segBox, airSDD);
2444 virtualSeg->SetVisibility(kFALSE);
b7943f00 2445
2446 //******************************
2447 // Carbon fiber structure :
2448 //******************************
2449
2450 virtualSeg->AddNode(fLaddSegCommonVol[0], 1, fLaddSegCommonTr[0]);
2451 Int_t volumeIndex = 1;
2452 for (Int_t i = 1; i<fgkNladdSegCommonVol;i++ ) {
2453 if (fLaddSegCommonVol[i]==fLaddSegCommonVol[i-1])
2454 volumeIndex++;
2455 else
2456 volumeIndex = 1;
2457 virtualSeg->AddNode(fLaddSegCommonVol[i], volumeIndex,
2458 fLaddSegCommonTr[i]);
2459 };
2460
2461 //**********************************
2462 // Pine support of the sensors :
2463 //**********************************
531d6cdc 2464 TGeoRotation *rotPS1 = new TGeoRotation("",0,-90,90);
2465 TGeoRotation *rotPS2 = new TGeoRotation("",0,-90,-90);
2466
73dfc864 2467 // The use of the following constructor type allow to use rotPS1 and rotPS2
2468 // (and not copy them) therefore we gain some memory
b7943f00 2469 TGeoCombiTrans *transPS1 = new TGeoCombiTrans( fgkPinDYOnSensor,
2470 - fgkLadderHeight/2.-tDY
2471 + fgkPinSuppHeight/2.,
531d6cdc 2472 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
73dfc864 2473
2474 TGeoCombiTrans *transPS2 = new TGeoCombiTrans( fgkPinDYOnSensor,
2475 - fgkLadderHeight/2.-tDY
2476 + fgkPinSuppHeight/2.,
2477 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
b7943f00 2478 AddTranslationToCombiTrans(transPS2, 0, 0, fgkPinPinDDXOnSensor);
73dfc864 2479
2480 TGeoCombiTrans *transPS3 = new TGeoCombiTrans( fgkPinDYOnSensor,
2481 - fgkLadderHeight/2.-tDY
2482 + fgkPinSuppHeight/2.,
2483 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
b7943f00 2484 AddTranslationToCombiTrans(transPS3, 0, 0, -2*fgkPinDXminOnSensor);
73dfc864 2485
2486 TGeoCombiTrans *transPS4 = new TGeoCombiTrans( fgkPinDYOnSensor,
2487 - fgkLadderHeight/2.-tDY
2488 + fgkPinSuppHeight/2.,
2489 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
2490 AddTranslationToCombiTrans(transPS4, 0, 0, -2*fgkPinDXminOnSensor-fgkPinPinDDXOnSensor);
b7943f00 2491
2492 TGeoCombiTrans *transPS5 = new TGeoCombiTrans( -fgkPinDYOnSensor,
2493 - fgkLadderHeight/2. - tDY
2494 + fgkPinSuppHeight/2.,
531d6cdc 2495 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
73dfc864 2496
2497 TGeoCombiTrans *transPS6 = new TGeoCombiTrans( -fgkPinDYOnSensor,
2498 - fgkLadderHeight/2. - tDY
2499 + fgkPinSuppHeight/2.,
2500 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
b7943f00 2501 AddTranslationToCombiTrans(transPS6, 0, 0, fgkPinPinDDXOnSensor);
73dfc864 2502
2503 TGeoCombiTrans *transPS7 = new TGeoCombiTrans( -fgkPinDYOnSensor,
2504 - fgkLadderHeight/2. - tDY
2505 + fgkPinSuppHeight/2.,
2506 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
b7943f00 2507 AddTranslationToCombiTrans(transPS7, 0, 0, -2*fgkPinDXminOnSensor);
73dfc864 2508
2509 TGeoCombiTrans *transPS8 = new TGeoCombiTrans( -fgkPinDYOnSensor,
2510 - fgkLadderHeight/2. - tDY
2511 + fgkPinSuppHeight/2.,
2512 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
2513 AddTranslationToCombiTrans(transPS8, 0, 0, -2*fgkPinDXminOnSensor-fgkPinPinDDXOnSensor);
b7943f00 2514
2515 virtualSeg->AddNode(fPinSupport, 1, transPS1);
2516 virtualSeg->AddNode(fPinSupport, 2, transPS2);
2517 virtualSeg->AddNode(fPinSupport, 3, transPS3);
2518 virtualSeg->AddNode(fPinSupport, 4, transPS4);
2519 virtualSeg->AddNode(fPinSupport, 5, transPS5);
2520 virtualSeg->AddNode(fPinSupport, 6, transPS6);
2521 virtualSeg->AddNode(fPinSupport, 7, transPS7);
2522 virtualSeg->AddNode(fPinSupport, 8, transPS8);
e118532f 2523
2524 TGeoMedium *pinMed = GetMedium("SDDKAPTON (POLYCH2)$"); // medium ???
2525 Double_t fgkPinHeight = 4.5*fgkmm;
2526 TGeoTube *pineS = new TGeoTube("ITSsddPin",0,fgkPinR,
2527 fgkPinHeight/2.);
2528 TGeoVolume *pineV = new TGeoVolume("ITSsddPinVol", pineS, pinMed);
2529
2530 TGeoCombiTrans *transPS2b = new TGeoCombiTrans( fgkPinDYOnSensor,
2531 - fgkLadderHeight/2.-tDY
2532 + fgkPinHeight/2.,
2533 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
2534 AddTranslationToCombiTrans(transPS2b, 0, 0, fgkPinPinDDXOnSensor);
2535 virtualSeg->AddNode(pineV, 1, transPS2b);
2536
2537 TGeoCombiTrans *transPS6b = new TGeoCombiTrans( -fgkPinDYOnSensor,
2538 - fgkLadderHeight/2. - tDY
2539 + fgkPinHeight/2.,
2540 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
2541 AddTranslationToCombiTrans(transPS6b, 0, 0, fgkPinPinDDXOnSensor);
2542 virtualSeg->AddNode(pineV, 2, transPS6b);
2543
2544
2545 TGeoCombiTrans *transPS4b = new TGeoCombiTrans( fgkPinDYOnSensor,
2546 - fgkLadderHeight/2.-tDY
2547 + fgkPinHeight/2.,
2548 sensorCenterZPos+fgkPinDXminOnSensor,rotPS1);
2549 AddTranslationToCombiTrans(transPS4b, 0, 0, -2*fgkPinDXminOnSensor-fgkPinPinDDXOnSensor);
2550 virtualSeg->AddNode(pineV, 3, transPS4b);
2551
2552 TGeoCombiTrans *transPS8b = new TGeoCombiTrans( -fgkPinDYOnSensor,
2553 - fgkLadderHeight/2. - tDY
2554 + fgkPinHeight/2.,
2555 sensorCenterZPos+fgkPinDXminOnSensor,rotPS2);
2556 AddTranslationToCombiTrans(transPS8b, 0, 0, -2*fgkPinDXminOnSensor-fgkPinPinDDXOnSensor);
2557 virtualSeg->AddNode(pineV, 4, transPS8b);
2558
2559
b7943f00 2560 //******************************
2561 // Cooling pipe supports :
2562 //******************************
2563 Double_t triangleHeight = fgkLadderHeight - fgkLadderBeamRadius;
2564 Double_t halfTheta = TMath::ATan( 0.5*fgkLadderWidth/triangleHeight );
2565 Double_t triangleCPaxeDist = fgkCoolPipeSuppAxeDist-fgkCoolPipeSuppWidthExt-
2566 fgkCoolPipeSuppWidthIn+fgkLadderBeamRadius;
2567
2568 Double_t coolPipeSuppL = TMath::Tan(halfTheta)*
2569 (triangleHeight+triangleCPaxeDist/
2570 TMath::Sin(halfTheta)-coolPipeSuppH);
2571 if (fAddCoolingSyst) {
531d6cdc 2572 TGeoRotation *rotCPS2 = new TGeoRotation("", -halfTheta*TMath::RadToDeg(), -90, 90);
2573 TGeoRotation *rotCPS1 = new TGeoRotation("", halfTheta*TMath::RadToDeg(), -90, -90);
b7943f00 2574 TGeoCombiTrans *transCPS1 = new TGeoCombiTrans(coolPipeSuppL,
fa4639a3 2575 -fgkLadderHeight/2. - tDY
b7943f00 2576 +coolPipeSuppH+fgkLadderBeamRadius,
531d6cdc 2577 -segmentLength/2., rotCPS1);
73dfc864 2578
2579 TGeoCombiTrans *transCPS3 = new TGeoCombiTrans(coolPipeSuppL,
2580 -fgkLadderHeight/2. - tDY
2581 +coolPipeSuppH+fgkLadderBeamRadius,
2582 -segmentLength/2., rotCPS1);
b7943f00 2583 AddTranslationToCombiTrans(transCPS3, 0, 0, segmentLength);
2584
2585 TGeoCombiTrans *transCPS2 = new TGeoCombiTrans(-coolPipeSuppL,
fa4639a3 2586 -fgkLadderHeight/2.- tDY
b7943f00 2587 +coolPipeSuppH+fgkLadderBeamRadius,
531d6cdc 2588 segmentLength/2., rotCPS2);
73dfc864 2589
2590 TGeoCombiTrans *transCPS4 = new TGeoCombiTrans(-coolPipeSuppL,
2591 -fgkLadderHeight/2.- tDY
2592 +coolPipeSuppH+fgkLadderBeamRadius,
2593 segmentLength/2., rotCPS2);
b7943f00 2594 AddTranslationToCombiTrans(transCPS4, 0, 0, -segmentLength);
2595
2596 virtualSeg->AddNode(fCoolPipeSupportL, 1, transCPS1);
2597 virtualSeg->AddNode(fCoolPipeSupportL, 2, transCPS2);
2598 virtualSeg->AddNode(fCoolPipeSupportR, 1, transCPS3);
2599 virtualSeg->AddNode(fCoolPipeSupportR, 2, transCPS4);
2600 };
2601
2602 //************************
2603 // Cooling pipes :
2604 //************************
2605 TGeoTranslation *pipeTr1 = new TGeoTranslation(coolPipeSuppL,
2606 -fgkLadderHeight/2. - tDY +
2607 fgkLadderBeamRadius+coolPipeSuppH, 0);
2608 TGeoTranslation *pipeTr2 = new TGeoTranslation(-coolPipeSuppL,
2609 -fgkLadderHeight/2.- tDY +
2610 fgkLadderBeamRadius+coolPipeSuppH, 0);
2611
2612 if (fAddCoolingSyst) {
108bd0fe 2613 TGeoTube *coolingPipeShape = new TGeoTube( fgkCoolPipeInnerDiam/2,
2614 fgkCoolPipeOuterDiam/2,
2615 segmentLength/2);
2616 TGeoTube *coolerShape = new TGeoTube( 0, fgkCoolPipeInnerDiam/2,
2617 segmentLength/2);
2618
2619 TGeoVolume *coolingPipe = new TGeoVolume("ITSsddCoolingPipe",
2620 coolingPipeShape, phynoxSDD );
2621 coolingPipe->SetLineColor(fColorPhynox);
2622 TGeoVolume *cooler = new TGeoVolume("ITSsddCoolingLiquid",coolerShape,
2623 coolerMediumSDD );
2624
2625
2626 virtualSeg->AddNode(coolingPipe, 1, pipeTr1);
2627 virtualSeg->AddNode(coolingPipe, 2, pipeTr2);
2628 if (fCoolingOn) {
2629 virtualSeg->AddNode(cooler, 1, pipeTr1);
2630 virtualSeg->AddNode(cooler, 2, pipeTr2);
2631 };
b7943f00 2632 };
c789ee28 2633
b7943f00 2634 //**********************************
2635 // Bases of hybrid thermal bridges
2636 //**********************************
2637 Double_t shiftHyb = 1.05; // shift between thermal Bridge base and thermal bridge
2638 // approx !!! not clear on 0752/14-A
2639 if (fAddCoolingSyst) {
73dfc864 2640 TGeoRotation rotHybrid1("", 0, 0, -90 - fgkHybridAngle);
2641 TGeoRotation rotHybrid2("", 0 ,180, 90 - fgkHybridAngle);
2642 TGeoCombiTrans *baseTr1 = new TGeoCombiTrans(*pipeTr2, rotHybrid1);
2643 TGeoCombiTrans *baseTr2 = new TGeoCombiTrans(*pipeTr1, rotHybrid2);
b7943f00 2644
2645 virtualSeg->AddNode(fBaseThermalBridge, 1, baseTr1);
2646 virtualSeg->AddNode(fBaseThermalBridge, 2, baseTr2);
2647 };
2648
2649 //*************************
2650 // the 2 hybrids :
2651 //*************************
2652 Double_t hybDy = ((TGeoBBox*)fHybrid->GetShape())->GetDY();
2653 Double_t distAxeToHybridCenter = fgkBTBaxisAtoBase+hybDy;
2654
2655 Double_t hybrVolX = ( distAxeToHybridCenter*CosD(fgkHybridAngle)
2656 - shiftHyb*SinD(fgkHybridAngle) );
2657 Double_t hybrVolY = ( distAxeToHybridCenter*SinD(fgkHybridAngle)
2658 + shiftHyb*CosD(fgkHybridAngle) );
2659 if (fAddHybrids) {
2660 TGeoRotation rotHybrid3("", 0, 0, 90. - fgkHybridAngle);
2661 TGeoRotation rotHybrid4("", 0 ,180, -90. - fgkHybridAngle);
2662 TGeoCombiTrans *hybTr1 = new TGeoCombiTrans(*pipeTr2, rotHybrid3);
2663 TGeoCombiTrans *hybTr2 = new TGeoCombiTrans(*pipeTr1, rotHybrid4);
2664 AddTranslationToCombiTrans( hybTr1, -hybrVolX, hybrVolY, 0);
2665 AddTranslationToCombiTrans( hybTr2, hybrVolX, hybrVolY, 0);
2666
2667 virtualSeg->AddNode(fHybrid, 1, hybTr1);
2668 virtualSeg->AddNode(fHybrid, 2, hybTr2);
2669 };
2670
2671 //***********
2672 // cables
2673 //***********
2674 if (fAddCables) {
2675 // Starting from this segment
2676 Double_t hybDz = ((TGeoBBox*)fHybrid->GetShape())->GetDZ();
2677 Double_t hybDx = ((TGeoBBox*)fHybrid->GetShape())->GetDX();
2678 Double_t posDigitCableAlongHyb = shiftHyb+ hybDx
2679 - digitCableA->GetWidth()/2;
2680 Double_t distAxeToDigitCableCenter = distAxeToHybridCenter+hybDy
2681 - digitCableA->GetThickness()/2;
2682
2683 Double_t digitCableX = ( coolPipeSuppL
2684 + distAxeToDigitCableCenter*CosD(fgkHybridAngle)
2685 - posDigitCableAlongHyb*SinD(fgkHybridAngle) );
2686 Double_t digitCableY = ( - fgkLadderHeight/2.-TMath::Abs(tDY)
2687 + fgkLadderBeamRadius+coolPipeSuppH
2688 + distAxeToDigitCableCenter*SinD(fgkHybridAngle)
2689 + posDigitCableAlongHyb*CosD(fgkHybridAngle) );
2690
2691
2692 Double_t digitCableCenterA0[3]={ -cableSideSign*digitCableX,
2693 digitCableY, cableSideSign*hybDz };
2694 Double_t digitCableCenterA1[3] = {
2695 -cableSideSign*(digitCableX+spaceForCables*CosD(fgkHybridAngle)),
2696 digitCableY+spaceForCables*SinD(fgkHybridAngle),
2697 cableSideSign*segmentLength/2 };
2698
2699 Double_t digitCableCenterB0[3]={ cableSideSign*digitCableX,
2700 digitCableY,cableSideSign*hybDz};
2701 Double_t digitCableCenterB1[3]={
2702 cableSideSign*(digitCableX+spaceForCables*CosD(fgkHybridAngle)),
2703 digitCableY+spaceForCables*SinD(fgkHybridAngle),
2704 cableSideSign*segmentLength/2 };
2705
2706 Double_t vZ[3] = {0,0,1};
2707 digitCableA[iSeg].AddCheckPoint( virtualSeg, 0, digitCableCenterA0, vZ);
2708 digitCableA[iSeg].AddCheckPoint( virtualSeg, 1, digitCableCenterA1, vZ);
2709 digitCableB[iSeg].AddCheckPoint( virtualSeg, 0, digitCableCenterB0, vZ);
2710 digitCableB[iSeg].AddCheckPoint( virtualSeg, 1, digitCableCenterB1, vZ);
2711
2712 // Updating the other cables
2713 for (Int_t iCable=iUpdateCableMin; iCable<=iUpdateCableMax; iCable++) {
2714
2715 Int_t iPoint = TMath::Abs(iCable-iSeg)+1;
2716 Double_t coord[3];
2717 digitCableA[iCable].GetPoint( 1, coord);
2718 digitCableA[iCable].AddCheckPoint( virtualSeg, iPoint, coord, vZ);
2719 digitCableB[iCable].GetPoint( 1, coord);
2720 digitCableB[iCable].AddCheckPoint( virtualSeg, iPoint, coord, vZ);
2721 };
2722 };
2723
2724 //**********************************
2725 if(GetDebug(1)) virtualSeg->CheckOverlaps(0.01);
b7943f00 2726 return virtualSeg;
531d6cdc 2727}
db486a6e 2728
c789ee28 2729
2730//________________________________________________________________________
2731TGeoVolume* AliITSv11GeometrySDD::CreatePinSupport() {
2732//
e118532f 2733// Create a pine support and its pine
c789ee28 2734// axis of rotation is the cone axis, center in its middle
2735//
e118532f 2736 TGeoMedium *rytonSDD = GetMedium("SDD C AL (M55J)$"); //medium = ryton ?
2737
b7943f00 2738 TGeoCone *cone = new TGeoCone("ITSsddPinSuppCone",fgkPinSuppHeight/2.,
2739 0,fgkPinSuppRmax,0,fgkPinSuppRmax-
2740 fgkPinSuppHeight*TanD(fgkPinSuppConeAngle) );
2741 TGeoBBox *tong = new TGeoBBox("ITSsddPinSuppTong",fgkPinSuppRmax,
2742 fgkPinSuppLength/2.,fgkPinSuppThickness/2.);
2743 TGeoTube *hole = new TGeoTube("ITSsddPinSuppHole",0,fgkPinR,
e118532f 2744 fgkPinSuppHeight/2.+0.00001);
2745 // 0.00001 is for seing the actual hole (avoid viewer artefact)
2746
c789ee28 2747 if(GetDebug(3)){// Remove compiler warning.
db486a6e 2748 cone->InspectShape();
2749 tong->InspectShape();
2750 hole->InspectShape();
c789ee28 2751 };
db486a6e 2752
2753 TGeoTranslation *tongTrans = new TGeoTranslation("ITSsddPinSuppTongTr",0,
b7943f00 2754 fgkPinSuppLength/2.,-fgkPinSuppHeight/2.+fgkPinSuppThickness/2.);
db486a6e 2755 tongTrans->RegisterYourself();
2756 TGeoCompositeShape *pinSupportShape = new TGeoCompositeShape(
b7943f00 2757 "ITSsddPinSupportShape","(ITSsddPinSuppCone+"
e118532f 2758 "ITSsddPinSuppTong:ITSsddPinSuppTongTr)-ITSsddPinSuppHole");
db486a6e 2759
e118532f 2760 TGeoVolume *pinSupport = new TGeoVolume("ITSsddPinSupport", pinSupportShape,
db486a6e 2761 rytonSDD);
c789ee28 2762 pinSupport->SetLineColor(fColorRyton);
e118532f 2763
db486a6e 2764 return pinSupport;
531d6cdc 2765}
c789ee28 2766
b7943f00 2767
db486a6e 2768//________________________________________________________________________
c789ee28 2769TGeoVolume* AliITSv11GeometrySDD::CreateCoolPipeSupportL() {
2770//
2771// Create half of the cooling pipe support (ALR-0752/3)
2772//
2773
b7943f00 2774 Double_t diffX = fgkCoolPipeSuppHeight*TanD(fgkCoolPipeSuppAngle);
c789ee28 2775
b7943f00 2776 TGeoArb8 *side1 = new TGeoArb8(fgkCoolPipeSuppHeight/2.);
2777 side1->SetVertex( 0, 0, -fgkCoolPipeSuppWidthExt/2.);
2778 side1->SetVertex( 1, fgkCoolPipeSuppMaxLength/2.-diffX,
2779 -fgkCoolPipeSuppWidthExt/2.);
2780 side1->SetVertex( 2, fgkCoolPipeSuppMaxLength/2.-diffX,
2781 fgkCoolPipeSuppWidthExt/2.);
2782 side1->SetVertex( 3, 0, fgkCoolPipeSuppWidthExt/2.);
2783 side1->SetVertex( 4, 0, -fgkCoolPipeSuppWidthExt/2.);
2784 side1->SetVertex( 5, fgkCoolPipeSuppMaxLength/2.,
2785 -fgkCoolPipeSuppWidthExt/2.);
2786 side1->SetVertex( 6, fgkCoolPipeSuppMaxLength/2.,
2787 fgkCoolPipeSuppWidthExt/2.);
2788 side1->SetVertex( 7, 0, fgkCoolPipeSuppWidthExt/2.);
c789ee28 2789 side1->SetName("ITSsddCPSside1");
2790
2791 TGeoTranslation *side1Tr = new TGeoTranslation("ITSsddCPStr1",0,
b7943f00 2792 - fgkCoolPipeSuppAxeDist
2793 + fgkCoolPipeSuppWidthExt/2., 0);
c789ee28 2794 side1Tr->RegisterYourself();
2795 TGeoTranslation *side2Tr = new TGeoTranslation("ITSsddCPStr2",0,
b7943f00 2796 - fgkCoolPipeSuppAxeDist
2797 + fgkCoolPipeSuppWidthExt*3/2.
2798 + fgkCoolPipeSuppWidthIn,0);
c789ee28 2799 side2Tr->RegisterYourself();
2800
2801 TGeoBBox *middle = new TGeoBBox("ITSsddCPSmiddle",
b7943f00 2802 (fgkCoolPipeSuppMaxLength/2.-fgkCoolPipeSuppSlitL)/2.,
2803 fgkCoolPipeSuppWidthIn/2., fgkCoolPipeSuppHeight/2.);
c789ee28 2804 TGeoTranslation *middleTr =
2805 new TGeoTranslation("ITSsddCPStr3",
b7943f00 2806 (fgkCoolPipeSuppMaxLength/2.-fgkCoolPipeSuppSlitL)/2.,
2807 -fgkCoolPipeSuppAxeDist+fgkCoolPipeSuppWidthExt
2808 +fgkCoolPipeSuppWidthIn/2., 0);
c789ee28 2809 middleTr->RegisterYourself();
2810
2811 TGeoBBox *axeBox = new TGeoBBox("ITSsddCPSaxeBox",
b7943f00 2812 fgkCoolPipeSuppTongW/4.,
2813 (fgkCoolPipeSuppFulWidth
2814 - 2*fgkCoolPipeSuppWidthExt
2815 - fgkCoolPipeSuppWidthIn)/2,
2816 fgkCoolPipeSuppHeight/2.);
c789ee28 2817
2818 TGeoTranslation *axeBoxTr = new TGeoTranslation("ITSsddCPSAxBoxTr",
b7943f00 2819 fgkCoolPipeSuppTongW/4.,
2820 - fgkCoolPipeSuppAxeDist
2821 + fgkCoolPipeSuppFulWidth
c789ee28 2822 - axeBox->GetDY(), 0);
2823 axeBoxTr->RegisterYourself();
2824
b7943f00 2825 TGeoTube *axe = new TGeoTube("ITSsddCPSaxe",0,fgkCoolPipeSuppHoleDiam/2.,
2826 fgkCoolPipeSuppTongW/4.);
c789ee28 2827
531d6cdc 2828 TGeoRotation *axeRot = new TGeoRotation("ITSsddCPSaxeRot",90,90,0);
c789ee28 2829 TGeoCombiTrans *axeTrans = new TGeoCombiTrans("ITSsddCPSaxeTr",
531d6cdc 2830 fgkCoolPipeSuppTongW/4.,0,0,axeRot);
c789ee28 2831 axeTrans->RegisterYourself();
531d6cdc 2832 //delete axeRot; // make the code crash, no idea of why !!!
c789ee28 2833
2834 if(GetDebug(3)){
2835 middle->InspectShape();
2836 axe->InspectShape();
2837 };
2838
108bd0fe 2839 TGeoMedium *rytonSDD = GetMedium("SDD C AL (M55J)$"); //medium = ryton ? !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
c789ee28 2840
2841 TGeoCompositeShape *coolPipeSuppShape = new TGeoCompositeShape(
2842 "ITSsddCoolPipeSuppShapeL",
2843 "ITSsddCPSmiddle:ITSsddCPStr3"
2844 "+ITSsddCPSside1:ITSsddCPStr1"
2845 "+ITSsddCPSside1:ITSsddCPStr2"
2846 "+ITSsddCPSaxeBox:ITSsddCPSAxBoxTr"
2847 "-ITSsddCPSaxe:ITSsddCPSaxeTr");
2848 TGeoVolume *coolPipeSupp = new TGeoVolume("ITSsddCoolPipeSupportL",
2849 coolPipeSuppShape, rytonSDD);
2850
2851 coolPipeSupp->SetLineColor(fColorRyton);
531d6cdc 2852
c789ee28 2853 return coolPipeSupp;
531d6cdc 2854}
2855
c789ee28 2856
2857//________________________________________________________________________
2858TGeoVolume* AliITSv11GeometrySDD::CreateCoolPipeSupportR() {
2859//
2860//Create half of the cooling pipe support (ALR-0752/3)
2861//
2862
b7943f00 2863 Double_t diffX = fgkCoolPipeSuppHeight*TanD(fgkCoolPipeSuppAngle);
c789ee28 2864
b7943f00 2865 TGeoArb8 *side1 = new TGeoArb8(fgkCoolPipeSuppHeight/2.);
2866 side1->SetVertex( 0, 0, -fgkCoolPipeSuppWidthExt/2.);
2867 side1->SetVertex( 1, -(fgkCoolPipeSuppMaxLength/2.-diffX),
2868 -fgkCoolPipeSuppWidthExt/2.);
2869 side1->SetVertex( 2, -(fgkCoolPipeSuppMaxLength/2.-diffX),
2870 fgkCoolPipeSuppWidthExt/2.);
2871 side1->SetVertex( 3, 0, fgkCoolPipeSuppWidthExt/2.);
2872 side1->SetVertex( 4, 0, -fgkCoolPipeSuppWidthExt/2.);
2873 side1->SetVertex( 5, -fgkCoolPipeSuppMaxLength/2.,
2874 -fgkCoolPipeSuppWidthExt/2.);
2875 side1->SetVertex( 6, -fgkCoolPipeSuppMaxLength/2.,
2876 fgkCoolPipeSuppWidthExt/2.);
2877 side1->SetVertex( 7, 0, fgkCoolPipeSuppWidthExt/2.);
c789ee28 2878 side1->SetName("ITSsddCPSside1R");
2879
2880 TGeoTranslation *side1Tr = new TGeoTranslation("ITSsddCPStr1R",0,
b7943f00 2881 - fgkCoolPipeSuppAxeDist
2882 + fgkCoolPipeSuppWidthExt/2., 0);
c789ee28 2883 side1Tr->RegisterYourself();
2884 TGeoTranslation *side2Tr = new TGeoTranslation("ITSsddCPStr2R",0,
b7943f00 2885 - fgkCoolPipeSuppAxeDist
2886 + fgkCoolPipeSuppWidthExt*3/2.
2887 + fgkCoolPipeSuppWidthIn, 0);
c789ee28 2888 side2Tr->RegisterYourself();
2889
2890 TGeoBBox *middle = new TGeoBBox("ITSsddCPSmiddleR",
b7943f00 2891 (fgkCoolPipeSuppMaxLength/2.
2892 - fgkCoolPipeSuppSlitL)/2.,
2893 fgkCoolPipeSuppWidthIn/2.,
2894 fgkCoolPipeSuppHeight/2.);
c789ee28 2895 TGeoTranslation *middleTr =
2896 new TGeoTranslation("ITSsddCPStr3R",
b7943f00 2897 -( fgkCoolPipeSuppMaxLength/2.
2898 -fgkCoolPipeSuppSlitL)/2.,
2899 -fgkCoolPipeSuppAxeDist + fgkCoolPipeSuppWidthExt
2900 + fgkCoolPipeSuppWidthIn/2.,0);
c789ee28 2901 middleTr->RegisterYourself();
2902
2903 TGeoBBox *axeBox = new TGeoBBox("ITSsddCPSaxeBoxR",
b7943f00 2904 fgkCoolPipeSuppTongW/4.,
2905 (fgkCoolPipeSuppFulWidth
2906 - 2*fgkCoolPipeSuppWidthExt
2907 - fgkCoolPipeSuppWidthIn)/2,
2908 fgkCoolPipeSuppHeight/2.);
c789ee28 2909
2910 TGeoTranslation *axeBoxTr = new TGeoTranslation("ITSsddCPSAxBoxTrR",
b7943f00 2911 - fgkCoolPipeSuppTongW/4.,
2912 - fgkCoolPipeSuppAxeDist
2913 + fgkCoolPipeSuppFulWidth
c789ee28 2914 - axeBox->GetDY(),0);
2915 axeBoxTr->RegisterYourself();
2916
b7943f00 2917 TGeoTube *axe = new TGeoTube("ITSsddCPSaxeR",0,fgkCoolPipeSuppHoleDiam/2.,
2918 fgkCoolPipeSuppTongW/4.);
531d6cdc 2919
2920 TGeoRotation *axeRot = new TGeoRotation("ITSsddCPSaxeRotR",90,90,0);
c789ee28 2921 TGeoCombiTrans *axeTrans = new TGeoCombiTrans("ITSsddCPSaxeTrR",
531d6cdc 2922 -fgkCoolPipeSuppTongW/4.,0,0,axeRot);
c789ee28 2923 axeTrans->RegisterYourself();
531d6cdc 2924 //delete axeRot;
c789ee28 2925
2926 if(GetDebug(3)){
2927 middle->InspectShape();
2928 axe->InspectShape();
2929 };
2930
2931 TGeoCompositeShape *coolPipeSuppShape = new TGeoCompositeShape(
2932 "ITSsddCoolPipeSuppShapeR",
2933 "ITSsddCPSmiddleR:ITSsddCPStr3R"
2934 "+ITSsddCPSside1R:ITSsddCPStr1R"
2935 "+ITSsddCPSside1R:ITSsddCPStr2R"
2936 "+ITSsddCPSaxeBoxR:ITSsddCPSAxBoxTrR"
2937 "-ITSsddCPSaxeR:ITSsddCPSaxeTrR");
b7943f00 2938
108bd0fe 2939 TGeoMedium *rytonSDD = GetMedium("SDD C AL (M55J)$"); //medium = ryton ? To code !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
c789ee28 2940 TGeoVolume *coolPipeSupp = new TGeoVolume( "ITSsddCoolPipeSupportR",
2941 coolPipeSuppShape, rytonSDD);
2942 coolPipeSupp->SetLineColor(fColorRyton);
2943
2944 return coolPipeSupp;
531d6cdc 2945}
c789ee28 2946
2947//________________________________________________________________________
2948TGeoVolume* AliITSv11GeometrySDD::CreateBaseThermalBridge() {
108bd0fe 2949 //
2950 // based on ALR 0752/8
2951 //
c789ee28 2952
b7943f00 2953 Double_t dy = fgkBTBaxisAtoBase - fgkRadiusBminBTB - fgkBTBthick;
c789ee28 2954
b7943f00 2955 Double_t base1width = fgkBTBwidth - fgkBTBaxisAtoBottom - fgkRadiusBminBTB
2956 - (fgkRadiusAminBTB+fgkBTBthick);
c789ee28 2957 TGeoBBox *base1 = new TGeoBBox( "ITSsddBTBbase1", base1width/2.,
b7943f00 2958 fgkBTBthick/2., fgkBTBlength/2.);
c789ee28 2959 TGeoTranslation *base1Tr = new TGeoTranslation("ITSsddBTBtr1",
b7943f00 2960 fgkBTBaxisAtoBottom-fgkBTBwidth+base1width/2.,
2961 -(fgkBTBaxisAtoBase-fgkBTBthick/2.), 0);
c789ee28 2962 base1Tr->RegisterYourself();
2963
b7943f00 2964 Double_t base2width = fgkBTBaxisAtoBottom - fgkRadiusAminBTB - fgkBTBthick
2965 - fgkRadiusBminBTB;
c789ee28 2966 TGeoBBox *base2 = new TGeoBBox( "ITSsddBTBbase2", base2width/2.,
b7943f00 2967 fgkBTBthick/2., fgkBTBlength/2.);
c789ee28 2968 TGeoTranslation *base2Tr = new TGeoTranslation("ITSsddBTBtr2",
b7943f00 2969 fgkBTBaxisAtoBottom - base2width/2.,
2970 -(fgkBTBaxisAtoBase-fgkBTBthick/2.), 0);
c789ee28 2971 base2Tr->RegisterYourself();
2972
2973 TGeoBBox *side = new TGeoBBox( "ITSsddBTBside",
b7943f00 2974 fgkBTBthick/2., dy/2., fgkBTBlength/2.);
c789ee28 2975 TGeoTranslation *sideTr1 = new TGeoTranslation("ITSsddBTBsideTr1",
b7943f00 2976 -fgkRadiusAminBTB-fgkBTBthick/2., -dy/2., 0);
c789ee28 2977 TGeoTranslation *sideTr2 = new TGeoTranslation("ITSsddBTBsideTr2",
b7943f00 2978 fgkRadiusAminBTB+fgkBTBthick/2., -dy/2., 0);
c789ee28 2979 sideTr1->RegisterYourself();
2980 sideTr2->RegisterYourself();
2981
b7943f00 2982 TGeoBBox *hole = new TGeoBBox( "ITSsddBTBhole", fgkBTBHolewidth/2.,
2983 fgkBTBthick/2., fgkBTBHoleLength/2.);
c789ee28 2984 TGeoTranslation *holeTr1 = new TGeoTranslation("ITSsddBTBholeTr1",
b7943f00 2985 - fgkBTBHoleRefX + fgkBTBHolewidth/2.,
2986 - (fgkBTBaxisAtoBase-fgkBTBthick/2.),
2987 fgkBTBHoleRefY+(fgkBTBHoleLength-fgkBTBlength)/2.);
c789ee28 2988 TGeoTranslation *holeTr2 = new TGeoTranslation("ITSsddBTBholeTr2",
b7943f00 2989 - fgkBTBHoleRefX + fgkBTBHolewidth/2.,
2990 - (fgkBTBaxisAtoBase-fgkBTBthick/2.),
2991 - fgkBTBHoleRefY-(fgkBTBHoleLength-fgkBTBlength)/2.);
c789ee28 2992 holeTr1->RegisterYourself();
2993 holeTr2->RegisterYourself();
2994
b7943f00 2995 Double_t radiusAmaxBTB = fgkRadiusAminBTB + fgkBTBthick;
c789ee28 2996 TGeoTubeSeg *mainAxis = new TGeoTubeSeg( "ITSsddBTBmainAxis",
b7943f00 2997 fgkRadiusAminBTB, radiusAmaxBTB,
2998 fgkBTBlength/2., 0., 180.);
c789ee28 2999 TGeoTubeSeg *round1 = new TGeoTubeSeg( "ITSsddBTBround1",
b7943f00 3000 fgkRadiusBminBTB, fgkRadiusBminBTB+fgkBTBthick,
3001 fgkBTBlength/2., 270., 360.);
c789ee28 3002 TGeoTranslation *roundTr1 = new TGeoTranslation("ITSsddBTBround1Tr",
b7943f00 3003 -(fgkRadiusAminBTB+fgkBTBthick+fgkRadiusBminBTB),
c789ee28 3004 -dy, 0);
3005 roundTr1->RegisterYourself();
3006
3007 TGeoTubeSeg *round2 = new TGeoTubeSeg( "ITSsddBTBround2",
b7943f00 3008 fgkRadiusBminBTB, fgkRadiusBminBTB+fgkBTBthick,
3009 fgkBTBlength/2., 180., 270.);
c789ee28 3010 TGeoTranslation *roundTr2 = new TGeoTranslation("ITSsddBTBround2Tr",
b7943f00 3011 (fgkRadiusAminBTB+fgkBTBthick+fgkRadiusBminBTB),
c789ee28 3012 -dy, 0);
3013 roundTr2->RegisterYourself();
3014
3015 TGeoCompositeShape *sBaseThermalBridge = new TGeoCompositeShape(
3016 "ITSsddBaseThermalBridgeShape",
3017 "ITSsddBTBbase1:ITSsddBTBtr1"
3018 "+ ITSsddBTBbase2:ITSsddBTBtr2"
3019 "+ ITSsddBTBround1:ITSsddBTBround1Tr"
3020 "+ ITSsddBTBround2:ITSsddBTBround2Tr"
3021 "+ ITSsddBTBside:ITSsddBTBsideTr1"
3022 "+ ITSsddBTBside:ITSsddBTBsideTr2"
3023 "- ITSsddBTBhole:ITSsddBTBholeTr1"
3024 "- ITSsddBTBhole:ITSsddBTBholeTr2"
3025 "+ ITSsddBTBmainAxis");
3026
3027 if(GetDebug(3)){// Remove compiler warning.
3028 base1->InspectShape();
3029 base2->InspectShape();
3030 side->InspectShape();
3031 hole->InspectShape();
3032 mainAxis->InspectShape();
3033 round1->InspectShape();
3034 round2->InspectShape();
3035 };
3036
108bd0fe 3037 TGeoMedium *carbonFiberLadderStruct = GetMedium("SDD C AL (M55J)$");
c789ee28 3038 TGeoVolume *vBaseThermalBridge = new TGeoVolume( "ITSsddBaseThermalBridge",
3039 sBaseThermalBridge,
3040 carbonFiberLadderStruct);
3041
3042 vBaseThermalBridge->SetLineColor(fColorCarbonFiber);
3043 return vBaseThermalBridge;
531d6cdc 3044}
c789ee28 3045
3046
c789ee28 3047//________________________________________________________________________
108bd0fe 3048TGeoVolumeAssembly* AliITSv11GeometrySDD::CreateEndLadder(Int_t iLay) {
b7943f00 3049 //
108bd0fe 3050 // Return an assembly containing a end of a CF ladder.
b7943f00 3051 //
3052
108bd0fe 3053 TGeoMedium *carbonFiberLadderStruct = GetMedium("SDD C AL (M55J)$"); // ITSsddCarbonM55J
e118532f 3054 TGeoMedium *stesalite = GetMedium("G10FR4$");
3055 TGeoMedium *phynoxSDD = GetMedium("INOX$");
108bd0fe 3056 TGeoMedium *coolerMediumSDD = GetMedium("WATER$");
b7943f00 3057
3058 Double_t length = (fgkLay3LadderLength-fgkLay3Ndet*fgkSegmentLength)/2.;
3059 Double_t coolPipeSuppH = fgkLay3CoolPipeSuppH;
3060 Double_t underSegDH = fLay3LadderUnderSegDH;
108bd0fe 3061 Double_t footDZ = fgkRubyZladd3 - fgkLay3Ndet*fgkSegmentLength/2 - length/2;
3062 // footDZ is also where to place the ruby's center in local Z
3063 Double_t coolPipeEndLen = (fgkCoolPipeLay3Len-fgkSegmentLength*fgkLay3Ndet)/2;
3064
b7943f00 3065 if (iLay==3) {
3066 } else if (iLay==4) {
108bd0fe 3067 length = (fgkLay4LadderLength-fgkLay4Ndet*fgkSegmentLength)/2.;
3068 coolPipeSuppH = fgkLay4CoolPipeSuppH;
3069 underSegDH = fLay4LadderUnderSegDH;
3070 footDZ = fgkRubyZladd4 - fgkLay4Ndet*fgkSegmentLength/2 - length/2;
3071 coolPipeEndLen = (fgkCoolPipeLay4Len-fgkSegmentLength*fgkLay4Ndet)/2;
b7943f00 3072 } else {
3073 printf("error in AliITSv11GeometrySDD::CreateEndLadder: Wrong layer");
3074 return 0;
3075 };
c789ee28 3076
b7943f00 3077 Double_t tDY = (- fgkLadderSegBoxDH/2 //space left on top of the ladder
3078 + underSegDH/2); //space under ladder segment
3079 // here tDY is not the same as for the segment because the end ladder
3080 // does not have a space under it, inside the general ladder volume.
3081 Double_t segmentLength = fgkSegmentLength;
3082 Double_t topCornerLength = fgkSegmentLength/2.-fgkLay4LaddTopCornerEnd;
3083
108bd0fe 3084 TGeoVolumeAssembly *virtualEnd = new TGeoVolumeAssembly("ITSsddEnd");
b7943f00 3085
3086 //**********************************
3087 // coding real matter :
3088 //**********************************
3089 Double_t triangleHeight = fgkLadderHeight - fgkLadderBeamRadius;
3090 Double_t halfTheta = TMath::ATan( 0.5*fgkLadderWidth/triangleHeight );
3091 Double_t beta = (TMath::Pi()-2.*halfTheta)/4.;
3092 Double_t alpha = TMath::Pi()*3./4. - halfTheta/2.;
3093
3094 //--- The 3 V shape corners of the Carbon Fiber Ladder
3095 //--- the top V
3096 TGeoArb8 *cfLaddTop1 = CreateLadderSide(topCornerLength/2., halfTheta, -1,
3097 fgkLadderLa, fgkLadderHa, fgkLadderl);
3098 TGeoVolume *cfLaddTopVol1 = new TGeoVolume("ITSsddCFladdTopCornerVol1",
3099 cfLaddTop1,carbonFiberLadderStruct);
3100 cfLaddTopVol1->SetLineColor(fColorCarbonFiber);
3101 TGeoArb8 *cfLaddTop2 = CreateLadderSide( topCornerLength/2., halfTheta, 1,
3102 fgkLadderLa, fgkLadderHa, fgkLadderl);
3103 TGeoVolume *cfLaddTopVol2 = new TGeoVolume("ITSsddCFladdTopCornerV2",
3104 cfLaddTop2,carbonFiberLadderStruct);
3105 cfLaddTopVol2->SetLineColor(fColorCarbonFiber);
3106 TGeoTranslation *trTop1 = new TGeoTranslation(0, fgkLadderHeight/2+tDY,
3107 -(length-topCornerLength)/2.);
3108 virtualEnd->AddNode(cfLaddTopVol1, 1, trTop1);
3109 virtualEnd->AddNode(cfLaddTopVol2, 1, trTop1);
3110
3111 //--- the 2 side V
3112 TGeoArb8 *cfLaddSide1 = CreateLadderSide( length/2., beta, -1,
3113 fgkLadderLb, fgkLadderHb, fgkLadderl);
3114 TGeoVolume *cfLaddSideVol1 = new TGeoVolume("ITSsddCFladdSideCornerV1",
3115 cfLaddSide1,carbonFiberLadderStruct);
3116 cfLaddSideVol1->SetLineColor(fColorCarbonFiber);
3117 TGeoArb8 *cfLaddSide2 = CreateLadderSide( length/2., beta, 1,
3118 fgkLadderLb, fgkLadderHb, fgkLadderl);
3119 TGeoVolume *cfLaddSideVol2 = new TGeoVolume("ITSsddCFladdSideCornerV2",
3120 cfLaddSide2,carbonFiberLadderStruct);
3121 cfLaddSideVol2->SetLineColor(fColorCarbonFiber);
3122 Double_t dYTranslation = ( fgkLadderHeight/2. - 0.5*fgkLadderWidth*
3123 TMath::Tan(beta) - fgkLadderBeamRadius );
3124
3125 // because center of the triangle doesn't correspond to virtual vol. center
3126 Double_t distCenterSideDown = 0.5*fgkLadderWidth/TMath::Cos(beta);
3127 TGeoCombiTrans *ctSideR = CreateCombiTrans("", distCenterSideDown, 0,
3128 alpha*TMath::RadToDeg());
3129 AddTranslationToCombiTrans(ctSideR, 0, -dYTranslation+tDY, 0);
3130 TGeoCombiTrans *ctSideL = CreateCombiTrans("", distCenterSideDown, 0,
3131 -alpha*TMath::RadToDeg());
3132 AddTranslationToCombiTrans(ctSideL, 0, -dYTranslation+tDY, 0);
3133 virtualEnd->AddNode(cfLaddSideVol1, 1, ctSideR);
3134 virtualEnd->AddNode(cfLaddSideVol2, 1, ctSideR);
3135 virtualEnd->AddNode(cfLaddSideVol1, 2, ctSideL);
3136 virtualEnd->AddNode(cfLaddSideVol2, 2, ctSideL);
3137
3138 //--- The beams
3139 // Beams on the sides
3140 Double_t beamPhiPrime = TMath::ASin(1./TMath::Sqrt( (1+TMath::Sin(2*beta)*
3141 TMath::Sin(2*beta)/(TanD(fgkBeamSidePhi)*TanD(fgkBeamSidePhi))) ));
3142
3143 //Euler rotation : about Z, then new X, then new Z
531d6cdc 3144 TGeoRotation *beamRot1 = new TGeoRotation("", 90-2.*beta*TMath::RadToDeg(),
b7943f00 3145 -beamPhiPrime*TMath::RadToDeg(), -90);
531d6cdc 3146 TGeoRotation *beamRot2 = new TGeoRotation("", 90-2.*beta*TMath::RadToDeg(),
b7943f00 3147 beamPhiPrime*TMath::RadToDeg(), -90);
531d6cdc 3148 TGeoRotation *beamRot3 = new TGeoRotation("", 90+2.*beta*TMath::RadToDeg(),
b7943f00 3149 beamPhiPrime*TMath::RadToDeg(), -90);
531d6cdc 3150 TGeoRotation *beamRot4 = new TGeoRotation("", 90+2.*beta*TMath::RadToDeg(),
b7943f00 3151 -beamPhiPrime*TMath::RadToDeg(), -90);
3152 TGeoCombiTrans *beamTransf1 = new TGeoCombiTrans(0.5*triangleHeight*
3153 TMath::Tan(halfTheta),
3154 fgkLadderBeamRadius/2. + tDY,
531d6cdc 3155 -length/2 + segmentLength/8, beamRot1);
b7943f00 3156 TGeoCombiTrans *beamTransf3 = new TGeoCombiTrans( 0.5*triangleHeight*
3157 TMath::Tan(halfTheta),
3158 fgkLadderBeamRadius/2.+tDY,
531d6cdc 3159 -length/2 + 3*segmentLength/8, beamRot2);
b7943f00 3160 TGeoCombiTrans *beamTransf5 = new TGeoCombiTrans(-0.5*triangleHeight*
3161 TMath::Tan(halfTheta),
3162 fgkLadderBeamRadius/2.+tDY,
531d6cdc 3163 -length/2 + segmentLength/8, beamRot3);
b7943f00 3164 TGeoCombiTrans *beamTransf7 = new TGeoCombiTrans(-0.5*triangleHeight*
3165 TMath::Tan(halfTheta),
3166 fgkLadderBeamRadius/2. + tDY,
531d6cdc 3167 -length/2+3*segmentLength/8, beamRot4);
b7943f00 3168
3169 virtualEnd->AddNode(fLaddSegCommonVol[6], 1, beamTransf1);
3170 virtualEnd->AddNode(fLaddSegCommonVol[6], 2, beamTransf3);
3171 virtualEnd->AddNode(fLaddSegCommonVol[6], 3, beamTransf5);
3172 virtualEnd->AddNode(fLaddSegCommonVol[6], 4, beamTransf7);
3173
3174 //--- Beams of the bottom
108bd0fe 3175 TGeoRotation *bottomBeamRot1 = new TGeoRotation("",90, 90, 90);
3176
3177 /* Not there actually
b7943f00 3178 TGeoTubeSeg *bottomBeam1 = new TGeoTubeSeg(0, fgkLadderBeamRadius,
3179 fgkLadderWidth/2.-fgkLadderLb/3, 0, 180);
3180 TGeoVolume *bottomBeam1Vol = new TGeoVolume("ITSsddBottomBeam1Vol",
3181 bottomBeam1, carbonFiberLadderStruct);
3182 bottomBeam1Vol->SetLineColor(fColorCarbonFiber);
3183
b7943f00 3184 TGeoCombiTrans *bottomBeamTransf1 = new TGeoCombiTrans(0,
3185 -(fgkLadderHeight/2-fgkLadderBeamRadius)+tDY,
531d6cdc 3186 -length/2+fgkSegmentLength/2, bottomBeamRot1);
b7943f00 3187 virtualEnd->AddNode(bottomBeam1Vol, 1, bottomBeamTransf1);
108bd0fe 3188*/
b7943f00 3189 TGeoTubeSeg *bottomBeam2 = new TGeoTubeSeg(0, fgkLadderBeamRadius,
3190 fgkLadderWidth/2.-fgkLadderLb/3, 0, 90);
3191 TGeoVolume *bottomBeam2Vol = new TGeoVolume("ITSsddBottomBeam2Vol",
3192 bottomBeam2, carbonFiberLadderStruct);
3193 bottomBeam2Vol->SetLineColor(fColorCarbonFiber);
3194 TGeoCombiTrans *bottomBeamTransf2 = new TGeoCombiTrans(0,
531d6cdc 3195 -(fgkLadderHeight/2-fgkLadderBeamRadius)+tDY,-length/2,bottomBeamRot1);
b7943f00 3196 virtualEnd->AddNode(bottomBeam2Vol, 1, bottomBeamTransf2);
3197
3198 //**********************************
3199 //the cooling pipe supports
3200 Double_t triangleCPaxeDist = fgkCoolPipeSuppAxeDist-fgkCoolPipeSuppWidthExt-
fa4639a3 3201 fgkCoolPipeSuppWidthIn+fgkLadderBeamRadius;
b7943f00 3202
3203 Double_t coolPipeSuppL = TMath::Tan(halfTheta)*
fa4639a3 3204 (triangleHeight+triangleCPaxeDist/
3205 TMath::Sin(halfTheta)-coolPipeSuppH);
b7943f00 3206
3207 if (fAddCoolingSyst) {
108bd0fe 3208 TGeoRotation *rotCPS2 = new TGeoRotation("",-halfTheta*TMath::RadToDeg(),-90, 90);
3209 TGeoRotation *rotCPS1 = new TGeoRotation("", halfTheta*TMath::RadToDeg(),-90,-90);
3210 TGeoCombiTrans *transCPS1 = new TGeoCombiTrans(coolPipeSuppL,
3211 -fgkLadderHeight/2.+ tDY +
3212 coolPipeSuppH+fgkLadderBeamRadius,
3213 -length/2., rotCPS1);
3214 TGeoCombiTrans *transCPS4 = new TGeoCombiTrans(-coolPipeSuppL,
3215 -fgkLadderHeight/2.+ tDY +
3216 coolPipeSuppH+fgkLadderBeamRadius,
3217 -length/2., rotCPS2);
3218
3219 virtualEnd->AddNode(fCoolPipeSupportL, 1, transCPS1);
3220 virtualEnd->AddNode(fCoolPipeSupportR, 1, transCPS4);
b7943f00 3221 };
3222
3223 //**********************************
108bd0fe 3224 //--- The stesalite foot of the ladder
3225
73dfc864 3226 Double_t footDY = -(fgkLadderHeight/2-fgkLadderBeamRadius)+tDY
3227 - fgkLadFootY/2+fgkLadFingerPrintY;
3228
3229 TGeoTranslation *footTr = new TGeoTranslation("SDDfootTr",0,footDY,footDZ);
3230 virtualEnd->AddNode(fLadderFoot, 1, footTr);
3231
3232 //=====================================
3233 //--- cooling pipe
3234
3235 if (fAddCoolingSyst) {
3236
3237 TGeoTranslation *pipeTr1 = new TGeoTranslation(coolPipeSuppL,
3238 -fgkLadderHeight/2.+ tDY +
3239 coolPipeSuppH + fgkLadderBeamRadius,
3240 -length/2.+coolPipeEndLen/2.);
3241 TGeoTranslation *pipeTr2 = new TGeoTranslation(-coolPipeSuppL,
3242 -fgkLadderHeight/2. + tDY +
3243 fgkLadderBeamRadius + coolPipeSuppH,
3244 -length/2.+coolPipeEndLen/2.);
3245
3246 TGeoTube *coolingPipeShape = new TGeoTube( fgkCoolPipeInnerDiam/2,
3247 fgkCoolPipeOuterDiam/2,
3248 coolPipeEndLen/2);
3249 TGeoTube *coolerShape = new TGeoTube( 0, fgkCoolPipeInnerDiam/2,
3250 coolPipeEndLen/2);
3251
3252 TGeoVolume *coolingPipe = new TGeoVolume("ITSsddCoolingPipeEnd",
3253 coolingPipeShape, phynoxSDD );
3254 coolingPipe->SetLineColor(fColorPhynox);
3255 TGeoVolume *cooler = new TGeoVolume("ITSsddCoolingEndLiquid",coolerShape,
3256 coolerMediumSDD );
3257
3258 virtualEnd->AddNode(coolingPipe, 1, pipeTr1);
3259 virtualEnd->AddNode(coolingPipe, 2, pipeTr2);
3260 if (fCoolingOn) {
3261 virtualEnd->AddNode(cooler, 1, pipeTr1);
3262 virtualEnd->AddNode(cooler, 2, pipeTr2);
3263 };
3264 };
3265
3266 //=====================================
3267 //--- HV cable guide
3268
3269
3270 TGeoBBox* guideHVbox = new TGeoBBox("guideHVbox",fgkHVguideX1/2,
3271 fgkHVguideY1/2,fgkHVguideZ1/2);
e118532f 3272 TGeoVolume *guideHV = new TGeoVolume("guideHV",guideHVbox,stesalite);
73dfc864 3273