Adding the AliAnalysisGUI class which is the main class that controls the GUI.
[u/mrichter/AliRoot.git] / ITS / AliITSv11GeometrySPD.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. *
14 **************************************************************************/
15
16// This class Defines the Geometry for the ITS services and support cones
17// outside of the ceneteral volume (except for the Ceneteral support
18// cylinders. Other classes define the rest of the ITS. Specificaly the ITS
19// The SSD support cone,SSD Support centeral cylinder, SDD support cone,
20// The SDD cupport centeral cylinder, the SPD Thermal Sheald, The supports
21// and cable trays on both the RB26 (muon dump) and RB24 sides, and all of
22// the cabling from the ladders/stave ends out past the TPC.
23
24/* $Id$ */
25// General Root includes
26#include <Riostream.h>
27#include <TMath.h>
28#include <TLatex.h>
29#include <TCanvas.h>
30#include <TPolyLine.h>
31// Root Geometry includes
32#include <TGeoManager.h>
33#include <TGeoVolume.h>
34#include <TGeoPcon.h>
35#include <TGeoCone.h>
36#include <TGeoTube.h> // contaings TGeoTubeSeg
37#include <TGeoArb8.h>
38#include <TGeoEltu.h>
39#include <TGeoXtru.h>
40#include <TGeoCompositeShape.h>
41#include <TGeoMatrix.h>
bf86817c 42//#include <TGeoRotation.h>
43//#include <TGeoCombiTrans.h>
44//#include <TGeoTranslation.h>
db486a6e 45#include "AliITSv11GeometrySPD.h"
46
47ClassImp(AliITSv11GeometrySPD)
48
49#define SQ(A) (A)*(A)
50
51//______________________________________________________________________
bf86817c 52void AliITSv11GeometrySPD::CarbonFiberSector(TGeoVolume *moth){
db486a6e 53 // Define the detail SPD Carbon fiber support Sector geometry.
54 // Based on the drawings ALICE-Pixel "Construzione Profilo Modulo"
55 // March 25 2004 and ALICE-SUPPORTO "construzione Profilo Modulo"
56 // Define Outside radii as negitive, Outside in the sence that the
57 // center of the arc is outside of the object.
58 // February 16 2004.
59 // Inputs:
bf86817c 60 // none.
db486a6e 61 // Outputs:
62 // none.
63 // Return:
bf86817c 64 // none.
db486a6e 65 TGeoManager *mgr = gGeoManager;
66 TGeoMedium *medSPDcf = 0; // SPD support cone Carbon Fiber materal number.
67 //TGeoMedium *medSPDfs = 0; // SPD support cone inserto stesalite 4411w.
68 //TGeoMedium *medSPDfo = 0; // SPD support cone foam, Rohacell 50A.
69 TGeoMedium *medSPDss = 0; // SPD support cone screw material,Stainless
70 TGeoMedium *medSPDair = 0; // SPD support cone Air
71 //TGeoMedium *medSPDal = 0; // SPD support cone SDD mounting bracket Al
72 TGeoMedium *medSPDcoolfl = 0; // SPD cooling fluid, Freeon
73 medSPDcf = mgr->GetMedium("ITSspdCarbonFiber");
74 //medSPDfs = mgr->GetMedium("ITSspdStaselite4411w");
75 //medSPDfo = mgr->GetMedium("ITSspdRohacell50A");
76 medSPDss = mgr->GetMedium("ITSspdStainlessSteal");
77 medSPDair= mgr->GetMedium("ITSspdAir");
78 medSPDcoolfl= mgr->GetMedium("ITSspdCoolingFluid");
79 //
80 const Double_t ksecDz = 0.5*500.0*fgkmm;
81 const Double_t ksecLen = 30.0*fgkmm;
82 const Double_t ksecCthick = 0.20*fgkmm;
83 const Double_t ksecDipLength = 3.2*fgkmm;
84 const Double_t ksecDipRadii = 0.4*fgkmm;
85 //const Double_t ksecCoolingTubeExtraDepth = 0.86*fgkmm;
86 //
87 const Double_t ksecX0 = -10.725*fgkmm;
88 const Double_t ksecY0 = -14.853*fgkmm;
89 const Double_t ksecR0 = -0.8*fgkmm; // Outside
90 const Double_t ksecX1 = -13.187*fgkmm;
91 const Double_t ksecY1 = -19.964*fgkmm;
92 const Double_t ksecR1 = +0.6*fgkmm; // Inside
bf86817c 93 const Double_t ksecDip0 = 5.9*fgkmm;
db486a6e 94 //
95 const Double_t ksecX2 = -3.883*fgkmm;
96 const Double_t ksecY2 = -17.805*fgkmm;
97 const Double_t ksecR2 = +0.80*fgkmm; // Inside Guess.
98 const Double_t ksecX3 = -3.123*fgkmm;
99 const Double_t ksecY3 = -14.618*fgkmm;
100 const Double_t ksecR3 = -0.6*fgkmm; // Outside
bf86817c 101 const Double_t ksecDip1 = 8.035*fgkmm;
db486a6e 102 //
103 const Double_t ksecX4 = +11.280*fgkmm;
104 const Double_t ksecY4 = -14.473*fgkmm;
105 const Double_t ksecR4 = +0.8*fgkmm; // Inside
106 const Double_t ksecX5 = +19.544*fgkmm;
107 const Double_t ksecY5 = +10.961*fgkmm;
108 const Double_t ksecR5 = +0.8*fgkmm; // Inside
bf86817c 109 const Double_t ksecDip2 = 4.553*fgkmm;
db486a6e 110 //
111 const Double_t ksecX6 = +10.830*fgkmm;
112 const Double_t ksecY6 = +16.858*fgkmm;
113 const Double_t ksecR6 = +0.6*fgkmm; // Inside
114 const Double_t ksecX7 = +11.581*fgkmm;
115 const Double_t ksecY7 = +13.317*fgkmm;
116 const Double_t ksecR7 = -0.6*fgkmm; // Outside
bf86817c 117 const Double_t ksecDip3 = 6.978*fgkmm;
db486a6e 118 //
119 const Double_t ksecX8 = -0.733*fgkmm;
120 const Double_t ksecY8 = +17.486*fgkmm;
121 const Double_t ksecR8 = +0.6*fgkmm; // Inside
122 const Double_t ksecX9 = +0.562*fgkmm;
123 const Double_t ksecY9 = +14.486*fgkmm;
124 const Double_t ksecR9 = -0.6*fgkmm; // Outside
bf86817c 125 const Double_t ksecDip4 = 6.978*fgkmm;
db486a6e 126 //
127 const Double_t ksecX10 = -12.252*fgkmm;
128 const Double_t ksecY10 = +16.298*fgkmm;
129 const Double_t ksecR10 = +0.6*fgkmm; // Inside
130 const Double_t ksecX11 = -10.445*fgkmm;
131 const Double_t ksecY11 = +13.162*fgkmm;
132 const Double_t ksecR11 = -0.6*fgkmm; // Outside
bf86817c 133 const Double_t ksecDip5 = 6.978*fgkmm;
db486a6e 134 //
135 const Double_t ksecX12 = -22.276*fgkmm;
136 const Double_t ksecY12 = +12.948*fgkmm;
137 const Double_t ksecR12 = +0.85*fgkmm; // Inside
138 //const Double_t ksecX13 = *fgkmm;
139 //const Double_t ksecY13 = *fgkmm;
140 const Double_t ksecR13 = -0.8*fgkmm; // Outside
141 const Double_t ksecAngleSide13 = 36.0*fgkDegree;
142 //
bf86817c 143 const Int_t ksecNRadii = 14;
db486a6e 144 const Int_t ksecNPointsPerRadii = 4;
145 const Int_t ksecNCoolingTubeDips = 6;
146 // Since the Rounded parts are aproximated by a regular polygon and
147 // a cooling tube of the propper diameter must fit, a scaling factor
148 // increases the size of the polygon for the tube to fit.
149 //const Double_t ksecRCoolScale = 1./TMath::Cos(TMath::Pi()/
150 // (Double_t)ksecNPointsPerRadii);
151 const Double_t ksecZEndLen = 30.00*fgkmm;
152 //const Double_t ksecZFlangLen= 45.00*fgkmm;
153 const Double_t ksecTl = 0.860*fgkmm;
154 const Double_t ksecCthick2 = 0.600*fgkmm;
bf86817c 155 const Double_t ksecCthick3 = 1.800*fgkmm;
156 const Double_t ksecSidelen = 22.00*fgkmm;
157 const Double_t ksecSideD5 = 3.679*fgkmm;
158 const Double_t ksecSideD12 = 7.066*fgkmm;
db486a6e 159 const Double_t ksecRCoolOut = 2.400*fgkmm;
160 const Double_t ksecRCoolIn = 2.000*fgkmm;
161 const Double_t ksecDl1 = 5.900*fgkmm;
162 const Double_t ksecDl2 = 8.035*fgkmm;
163 const Double_t ksecDl3 = 4.553*fgkmm;
164 const Double_t ksecDl4 = 6.978*fgkmm;
165 const Double_t ksecDl5 = 6.978*fgkmm;
166 const Double_t ksecDl6 = 6.978*fgkmm;
bf86817c 167 const Double_t ksecCoolTubeThick = 10.0*fgkmicron;
db486a6e 168 //
bf86817c 169 const Int_t ksecNPoints = (ksecNPointsPerRadii+1)*(ksecNRadii+
170 ksecNCoolingTubeDips) + 8;
171 Double_t secX[ksecNRadii] = {ksecX0,ksecX1,ksecX2,ksecX3,ksecX4,ksecX5,
172 ksecX6,ksecX7,ksecX8,ksecX9,ksecX10,ksecX11,
db486a6e 173 ksecX12,-1000.0};
bf86817c 174 Double_t secY[ksecNRadii] = {ksecY0,ksecY1,ksecY2,ksecY3,ksecY4,ksecY5,
175 ksecY6,ksecY7,ksecY8,ksecY9,ksecY10,ksecY11,
db486a6e 176 ksecY12,-1000.0};
bf86817c 177 Double_t secR[ksecNRadii] = {ksecR0,ksecR1,ksecR2,ksecR3,ksecR4,ksecR5,
178 ksecR6,ksecR7,ksecR8,ksecR9,ksecR10,ksecR11,
179 ksecR12,ksecR13};
180 Double_t secDip[ksecNRadii]={0.0,ksecDip0,0.0,ksecDip1,0.0,ksecDip2,0.0,
181 ksecDip3,0.0,ksecDip4,0.0,ksecDip5,0.0,0.0};
182 Double_t secX2[ksecNRadii+ksecNCoolingTubeDips] = {
183 ksecX0,ksecX1,-1000.,ksecX2,ksecX3,-1000.,ksecX4,ksecX5,
184 -1000.,ksecX6,ksecX7,-1000.,ksecX8,ksecX9,-1000.,
185 ksecX10,ksecX11,-1000.,ksecX12,-1000.0};
186 Double_t secY2[ksecNRadii+ksecNCoolingTubeDips] = {
187 ksecY0,ksecY1,-1000.,ksecY2,ksecY3,-1000.,ksecY4,ksecY5,
188 -1000.,ksecY6,ksecY7,-1000.,ksecY8,ksecY9,-1000.,
189 ksecY10,ksecY11,-1000.,ksecY12,-1000.0};
190 Double_t secR2[ksecNRadii+ksecNCoolingTubeDips] = {
db486a6e 191 ksecR0,ksecR1,ksecRCoolOut,ksecR2,ksecR3,ksecRCoolOut,ksecR4,ksecR5,
192 ksecRCoolOut,ksecR6,ksecR7,ksecRCoolOut,ksecR8,ksecR9,ksecRCoolOut,
193 ksecR10,ksecR11,ksecRCoolOut,ksecR12,ksecR13};
bf86817c 194 Double_t secDip2[ksecNRadii]={0.0,ksecDl1,0.0,ksecDl2,0.0,ksecDl3,0.0,
195 ksecDl4,0.0,ksecDl5,0.0,ksecDl6,0.0,0.0};
db486a6e 196 const Int_t ksecDipIndex[ksecNCoolingTubeDips] = {2,5,8,11,14,17};
197 Double_t secAngleStart[ksecNRadii];
198 Double_t secAngleEnd[ksecNRadii];
bf86817c 199 Double_t secAngleStart2[ksecNRadii+ksecNCoolingTubeDips];
200 Double_t secAngleEnd2[ksecNRadii+ksecNCoolingTubeDips];
201 Double_t secAngleStart3[ksecNRadii+ksecNCoolingTubeDips];
202 Double_t secAngleEnd3[ksecNRadii+ksecNCoolingTubeDips];
203 Double_t xp[ksecNPoints],yp[ksecNPoints];
db486a6e 204 TGeoXtru *sA0,*sA1,*sB0,*sB1;
205 TGeoEltu *sTA0,*sTA1;
bf86817c 206 TGeoTube *sTB0,*sTB1;
db486a6e 207 TGeoRotation *rot;
208 TGeoTranslation *trans;
209 TGeoCombiTrans *rotrans;
210 Double_t t,t0,t1,a,b,x0,y0,x1,y1;
bf86817c 211 Int_t i,j,k;
db486a6e 212
213 if(moth==0){
214 Error("CarbonFiberSector","moth=%p",moth);
bf86817c 215 return;
db486a6e 216 } // end if moth==0
bf86817c 217 SetDebug(3);
db486a6e 218
db486a6e 219 secAngleStart[0] = 0.5*ksecAngleSide13;
220 for(i=0;i<ksecNRadii-2;i++){
db486a6e 221 AnglesForRoundedCorners(secX[i],secY[i],secR[i],
bf86817c 222 secX[i+1],secY[i+1],secR[i+1],t0,t1);
223 secAngleEnd[i] = t0;
224 if(secR[i]>0.0&&secR[i+1]>0.0)if(secAngleStart[i]>secAngleEnd[i])
db486a6e 225 secAngleEnd[i] += 360.0;
bf86817c 226 secAngleStart[i+1] = t1;
db486a6e 227 } // end for i
228 secAngleEnd[ksecNRadii-2] = secAngleStart[ksecNRadii-2] +
bf86817c 229 (secAngleEnd[10]-secAngleStart[10]);
db486a6e 230 if(secAngleEnd[ksecNRadii-2]<0.0) secAngleEnd[ksecNRadii-2] += 360.0;
231 secAngleStart[ksecNRadii-1] = secAngleEnd[ksecNRadii-2] - 180.0;
232 secAngleEnd[ksecNRadii-1] = secAngleStart[0];
bf86817c 233 //
db486a6e 234 i = 0;
235 j = ksecNRadii-2;
236 t0 = TanD(secAngleStart[i]-90.);
237 t1 = TanD(secAngleEnd[j]-90.);
238 t = secY[i] - secY[j];
bf86817c 239 // Note, secR[i=0] <0; secR[j=12]>0; and secR[j+1=13] <0
db486a6e 240 t += (-secR[i]+secR[j+1])*SinD(secAngleStart[i]);
241 t -= (secR[j]-secR[j+1])*SinD(secAngleEnd[j]);
242 t += t1*secX[j] - t0*secX[i];
243 t += t1*(secR[j]-secR[j+1])*CosD(secAngleEnd[j]);
244 t -= t0*(-secR[i]+secR[j+1])*CosD(secAngleStart[i]);
245 secX[ksecNRadii-1] = t/(t1-t0);
246 secY[ksecNRadii-1] = TanD(90.+0.5*ksecAngleSide13)*
247 (secX[ksecNRadii-1]-secX[0]) + secY[0];
db486a6e 248 //
f77f13c8 249 if(AliDebugLevel()>=2){
bf86817c 250 cout <<" X \t Y \t R \t S \t E"<<endl;
251 for(i=0;i<ksecNRadii;i++){
252 cout <<"{"<< secX[i] <<",";
253 cout << secY[i] <<",";
254 cout << secR[i] <<",";
255 cout << secAngleStart[i] <<",";
256 cout << secAngleEnd[i] <<"},"<< endl;
257 } // end for i
258 } // end if GetDebug
259 //
260 if(GetDebug(3)) cout <<"Double_t sA0[][";
261 if(GetDebug(4)) cout <<"3]{";
262 else if(GetDebug(3)) cout <<"2]{";
263 j = -1;
264 t0 = (Double_t)ksecNPointsPerRadii;
265 for(i=0;i<ksecNRadii;i++){
266 t1 = (secAngleEnd[i]-secAngleStart[i])/t0;
267 if(GetDebug(5)) cout<<"t1="<< t1<<endl;
268 for(k=0;k<=ksecNPointsPerRadii;k++){
269 t=secAngleStart[i]+((Double_t)k)*t1;
270 j++;
271 xp[j] = TMath::Abs(secR[i])*CosD(t)+secX[i];
272 yp[j] = TMath::Abs(secR[i])*SinD(t)+secY[i];
273 if(GetDebug(3)){
274 cout << "{"<<xp[j]<<","<<yp[j];
275 if(GetDebug(4)) cout <<","<<t;
276 cout <<"},";
277 } // end if GetDebug
db486a6e 278 } // end for k
bf86817c 279 if(GetDebug(3)) cout << endl;
280 t = secAngleEnd[i];
281 a = ksecDipLength+2.0*(ksecDipRadii);
282 b = secDip[i]-0.5*a;
283 switch (i){
284 case 1: case 5: // Dip0,2
285 j++;
286 xp[j] = xp[j-1]-b*CosD(t-90.);
287 yp[j] = yp[j-1]-b*SinD(t-90.);
288 j++;
289 xp[j] = xp[j-1]-(2.0*ksecDipRadii)*CosD(t);
290 yp[j] = yp[j-1]-(2.0*ksecDipRadii)*SinD(t);
291 j++;
292 xp[j] = xp[j-1]-a*CosD(t-90.);
293 yp[j] = yp[j-1]-a*SinD(t-90.);
294 j++;
295 xp[j] = xp[j-1]+(2.0*ksecDipRadii)*CosD(t);
296 yp[j] = yp[j-1]+(2.0*ksecDipRadii)*SinD(t);
297 if(GetDebug(3))for(k=-3;k<=0;k++){
298 cout << "{"<<xp[j+k]<<","<<yp[j+k];
299 if(GetDebug(4)) cout <<","<<0.0;
300 cout <<"},";
301 } // end if GetDebug
302 if(GetDebug(3)) cout << endl;
303 break;
304 case 3: case 7: case 9: case 11:// Dip 1,3,4,5
305 j++;
306 xp[j] = xp[j-1]+b*CosD(t-90.);
307 yp[j] = yp[j-1]+b*SinD(t-90.);
308 j++;
309 xp[j] = xp[j-1]+(2.0*ksecDipRadii)*CosD(t);
310 yp[j] = yp[j-1]+(2.0*ksecDipRadii)*SinD(t);
311 j++;
312 xp[j] = xp[j-1]+a*CosD(t-90.);
313 yp[j] = yp[j-1]+a*SinD(t-90.);
314 j++;
315 xp[j] = xp[j-1]-(2.0*ksecDipRadii)*CosD(t);
316 yp[j] = yp[j-1]-(2.0*ksecDipRadii)*SinD(t);
317 if(GetDebug(3))for(k=-3;k<=0;k++){
318 cout << "{"<<xp[j+k]<<","<<yp[j+k];
319 if(GetDebug(4)) cout <<","<<0.0;
320 cout <<"},";
321 } // end if GetDebug
322 if(GetDebug(3)) cout << endl;
323 break;
324 default:
325 break;
326 } // end switch
327 } // end of i
328 if(GetDebug(3)) cout<<"{"<<xp[0]<<","<<yp[0];
329 if(GetDebug(4)) cout<<","<< secAngleStart[0];
330 if(GetDebug(3)) cout<<"}} j="<<j<<endl;
db486a6e 331 sA0 = new TGeoXtru(2);
332 sA0->SetName("ITS SPD Carbon fiber support Sector A0");
bf86817c 333 sA0->DefinePolygon(j+1,xp,yp);
db486a6e 334 sA0->DefineSection(0,-ksecDz);
335 sA0->DefineSection(1,ksecDz);
336 //
bf86817c 337 if(GetDebug(3)) cout <<"Double_t sA1[][{";
338 if(GetDebug(4)) cout <<"3]{";
339 else if(GetDebug(3)) cout <<"2]{";
340 j = -1;
341 t0 = (Double_t)ksecNPointsPerRadii;
342 for(i=0;i<ksecNRadii;i++){
343 t1 = (secAngleEnd[i]-secAngleStart[i])/t0;
344 if(GetDebug(5)) cout<<"t1="<< t1<<endl;
345 for(k=0;k<=ksecNPointsPerRadii;k++){
346 t=secAngleStart[i]+((Double_t)k)*t1;
347 j++;
348 xp[j] = TMath::Abs(secR[i]-ksecCthick)*CosD(t)+secX[i];
349 yp[j] = TMath::Abs(secR[i]-ksecCthick)*SinD(t)+secY[i];
350 if(GetDebug(3)){
351 cout << "{"<<xp[j]<<","<<yp[j];
352 if(GetDebug(4)) cout <<","<<t;
353 cout <<"},";
354 } // end if GetDebug
355 } // end for t
356 if(GetDebug(3)) cout << endl;
357 t = secAngleEnd[i];
358 a = ksecDipLength+2.0*(ksecDipRadii+ksecCthick);
359 b = secDip[i]-0.5*a;
360 switch (i){
361 case 1: case 5: // Dip0,2
362 j++;
363 xp[j] = xp[j-1]-b*CosD(t-90.);
364 yp[j] = yp[j-1]-b*SinD(t-90.);
365 j++;
366 xp[j] = xp[j-1]-(2.0*ksecDipRadii)*CosD(t);
367 yp[j] = yp[j-1]-(2.0*ksecDipRadii)*SinD(t);
368 j++;
369 xp[j] = xp[j-1]-a*CosD(t-90.);
370 yp[j] = yp[j-1]-a*SinD(t-90.);
371 j++;
372 xp[j] = xp[j-1]+(2.0*ksecDipRadii)*CosD(t);
373 yp[j] = yp[j-1]+(2.0*ksecDipRadii)*SinD(t);
374 if(GetDebug(3))for(k=-3;k<=0;k++){
375 cout << "{"<<xp[j+k]<<","<<yp[j+k];
376 if(GetDebug(4)) cout <<",t="<<0.0;
377 cout <<"},";
378 } // end if GetDebug
379 if(GetDebug(3)) cout << endl;
380 break;
381 case 3: case 7: case 9: case 11:// Dip 1,3,4,5
382 j++;
383 xp[j] = xp[j-1]+b*CosD(t-90.);
384 yp[j] = yp[j-1]+b*SinD(t-90.);
385 j++;
386 xp[j] = xp[j-1]+(2.0*ksecDipRadii)*CosD(t);
387 yp[j] = yp[j-1]+(2.0*ksecDipRadii)*SinD(t);
388 j++;
389 xp[j] = xp[j-1]+a*CosD(t-90.);
390 yp[j] = yp[j-1]+a*SinD(t-90.);
391 j++;
392 xp[j] = xp[j-1]-(2.0*ksecDipRadii)*CosD(t);
393 yp[j] = yp[j-1]-(2.0*ksecDipRadii)*SinD(t);
394 if(GetDebug(3))for(k=-3;k<=0;k++){
395 cout << "{"<<xp[j+k]<<","<<yp[j+k];
396 if(GetDebug(4)) cout <<",t="<<0.0;
397 cout <<"},";
398 } // end if GetDebug
399 if(GetDebug(3)) cout << endl;
400 break;
401 default:
402 break;
403 } // end switch
404 } // end of i
405 if(GetDebug(3)) cout<<"{"<<xp[0]<<","<<yp[0];
406 if(GetDebug(4)) cout<<","<< secAngleStart[0];
407 if(GetDebug(3)) cout<<"}} j="<<j<<endl;
db486a6e 408 sA1 = new TGeoXtru(2);
409 sA1->SetName("ITS SPD Carbon fiber support Sector Air A1");
bf86817c 410 sA1->DefinePolygon(j+1,xp,yp);
db486a6e 411 sA1->DefineSection(0,-ksecDz);
412 sA1->DefineSection(1,ksecDz);
413 //
db486a6e 414 sTA0 = new TGeoEltu("ITS SPD Cooling Tube TA0",
bf86817c 415 ksecDipRadii,0.5*ksecDipLength,ksecDz);
db486a6e 416 sTA1 = new TGeoEltu("ITS SPD Cooling Tube coolant TA1",
417 sTA0->GetA()-ksecCoolTubeThick,
418 sTA0->GetB()-ksecCoolTubeThick,ksecDz);
419 //
bf86817c 420 j = 0;
421 for(i=0;i<ksecNRadii;i++){
422 secAngleStart2[j] = secAngleStart[i];
423 secAngleEnd2[j] = secAngleEnd[i];
424 secAngleStart3[j] = secAngleStart2[j];
425 secAngleEnd3[j] = secAngleEnd2[j];
426 secX2[j] = secX[i];
427 secY2[j] = secY[i];
428 secR2[j] = secR[i];
429 j++;
430 t = secAngleEnd[i];
431 switch (i){
432 case 1: case 5: // Tube 0,2
433 x0 = secX[i] + TMath::Abs(secR[i])*CosD(t); // last point of turn
434 y0 = secY[i] + TMath::Abs(secR[i])*SinD(t);
435 x1 = x0-secDip2[i]*CosD(t-90.); // center point of dip
436 y1 = y0-secDip2[i]*SinD(t-90.); // along line
437 secX2[j] = x1-ksecTl*CosD(t); // location of circle center.
438 secY2[j] = y1-ksecTl*SinD(t);
439 x1 = secX[i+1]+TMath::Abs(secR[i+1])*CosD(secAngleStart2[i+1]);
440 y1 = secY[i+1]+TMath::Abs(secR[i+1])*SinD(secAngleStart2[i+1]);
441 //Find starting and ending angles, break if error.
442 if(!AngleOfIntersectionWithLine(x0,y0,x1,y1,secX2[j],secY2[j],
443 secR2[j],secAngleStart2[j],secAngleEnd2[j]))break;
444 // thicknes of Carbon fiber over the cooling tubes.
445 a = ksecRCoolOut-ksecRCoolIn;
446 // last point of turn
447 x0 = secX[i]+(TMath::Abs(secR[i])-ksecCthick2)*CosD(t);
448 y0 = secY[i]+(TMath::Abs(secR[i])-ksecCthick2)*SinD(t);
449 x1 = secX[i+1]+(TMath::Abs(secR[i+1])-ksecCthick2)*CosD(secAngleStart3[i+1]);
450 y1 = secY[i+1]+(TMath::Abs(secR[i+1])-ksecCthick2)*SinD(secAngleStart3[i+1]);
451 //Find starting and ending angles, break if error.
452 if(!AngleOfIntersectionWithLine(x0,y0,x1,y1,secX2[j],secY2[j],
453 secR2[j]-a,secAngleStart3[j],secAngleEnd3[j]))break;
454 if(i==1) { // Fix odd case.
455 x0 = secAngleStart3[j];
456 secAngleStart3[j] = secAngleEnd3[j] - 360.0;
457 secAngleEnd3[j] = x0;
458 } // end if i==1
459 if(i==5) { // Fix odd case.
460 x0 = secAngleStart2[j];
461 secAngleStart2[j] = secAngleEnd2[j] - 360.0;
462 secAngleEnd2[j] = x0;
463 x0 = secAngleStart3[j];
464 secAngleStart3[j] = secAngleEnd3[j] - 360.0;
465 secAngleEnd3[j] = x0;
466 } // end if i==5
467 // Because a polygon is replacing the rounded surface, the
468 // radius of the polygon must be larger to make room for the
469 // cooling tube of the same size. The radio of the radii of
470 // a circle fitting the inside/outside of a regualr polygon
471 // is given by Cos(180/n) where n is the number of sides of the
472 // regurla polygon. In this case, it is scalled for the partical
473 // circles involved.
474 secR2[j] = secR2[j]/CosD(0.5*(secAngleEnd[j]-secAngleStart[j])/
475 ((Double_t)ksecNPointsPerRadii));
476 j++;
477 break;
478 case 3: case 7: case 9: case 11:// Tube 1,2,4,5,6
479 x0 = secX[i] + TMath::Abs(secR[i])*CosD(t); // last point of turn
480 y0 = secY[i] + TMath::Abs(secR[i])*SinD(t);
481 x1 = x0+secDip2[i]*CosD(t-90.); // center point of dip
482 y1 = y0+secDip2[i]*SinD(t-90.); // along line
483 secX2[j] = x1+ksecTl*CosD(t); // location of circle center.
484 secY2[j] = y1+ksecTl*SinD(t);
485 x1 = secX[i+1]+TMath::Abs(secR[i+1])*CosD(secAngleStart2[i+1]);
486 y1 = secY[i+1]+TMath::Abs(secR[i+1])*SinD(secAngleStart2[i+1]);
487 if(!AngleOfIntersectionWithLine(x0,y0,x1,y1,secX2[j],secY2[j],
488 secR2[j],secAngleStart2[j],secAngleEnd2[j]))break;//don't intersect
489 // thicknes of Carbon fiber over the cooling tubes.
490 a = ksecRCoolOut-ksecRCoolIn;
491 // last point of turn
492 x0 = secX[i] + (TMath::Abs(secR[i])+ksecCthick2)*CosD(t);
493 y0 = secY[i] + (TMath::Abs(secR[i])+ksecCthick2)*SinD(t);
494 x1 = secX[i+1]+(TMath::Abs(secR[i+1])-ksecCthick2)*CosD(secAngleStart3[i+1]);
495 y1 = secY[i+1]+(TMath::Abs(secR[i+1])-ksecCthick2)*SinD(secAngleStart3[i+1]);
496 //Find starting and ending angles, break if error.
497 if(!AngleOfIntersectionWithLine(x0,y0,x1,y1,secX2[j],secY2[j],
498 secR2[j]-a,secAngleStart3[j],secAngleEnd3[j]))break;
499 if(i==7) { // Fix odd case
500 x0 = secAngleStart2[j];
501 secAngleStart2[j] = secAngleEnd2[j] - 360.0;
502 secAngleEnd2[j] = x0;
503 x0 = secAngleStart3[j];
504 secAngleStart3[j] = secAngleEnd3[j] - 360.0;
505 secAngleEnd3[j] = x0;
506 } // end if i==7
507 if(i==9) { // Fix odd case
508 x0 = secAngleStart3[j];
509 secAngleStart3[j] = secAngleEnd3[j] - 360.0;
510 secAngleEnd3[j] = x0;
511 } // end if i==7
512 // Because a polygon is replacing the rounded surface, the
513 // radius of the polygon must be larger to make room for the
514 // cooling tube of the same size. The radio of the radii of
515 // a circle fitting the inside/outside of a regualr polygon
516 // is given by Cos(180/n) where n is the number of sides of the
517 // regurla polygon. In this case, it is scalled for the partical
518 // circles involved.
519 secR2[j] = secR2[j]/CosD(0.5*(secAngleEnd[j]-secAngleStart[j])/
520 ((Double_t)ksecNPointsPerRadii));
521 j++;
522 break;
523 }// end switch
524 } // end for i
db486a6e 525 //
bf86817c 526 if(GetDebug(2)){
527 cout <<" X2 \t Y2 \t R2 \t S2 \t E2"<<endl;
528 for(i=0;i<j;i++){
529 cout <<"{"<< secX2[i] <<",";
530 cout << secY2[i] <<",";
531 cout << secR2[i] <<",";
532 cout << secAngleStart2[i] <<",";
533 cout << secAngleEnd2[i] <<"}," << endl;
534 } // end for i
535 } // end if GetDebug
536 if(GetDebug(2)){
537 cout <<" X2 \t Y2 \t R2 \t S3 \t E3"<<endl;
538 for(i=0;i<j;i++){
539 cout <<"{"<< secX2[i] <<",";
540 cout << secY2[i] <<",";
541 cout << secR2[i] <<",";
542 cout << secAngleStart3[i] <<",";
543 cout << secAngleEnd3[i] <<"}," << endl;
544 } // end for i
545 } // end if GetDebug
546 if(GetDebug(3)) cout <<"Double_t sB0[][";
547 if(GetDebug(4)) cout <<"3]{";
548 else if(GetDebug(3)) cout <<"2]{";
549 j = -1;
550 t0 = (Double_t)ksecNPointsPerRadii;
551 for(i=0;i<ksecNRadii+ksecNCoolingTubeDips;i++){
552 t1 = (secAngleEnd2[i]-secAngleStart2[i])/t0;
553 if(GetDebug(5)) cout<<"t1="<< t1<<endl;
554 for(k=0;k<=ksecNPointsPerRadii;k++){
555 t=secAngleStart2[i]+((Double_t)k)*t1;
556 j++;
557 xp[j] = TMath::Abs(secR2[i])*CosD(t)+secX2[i];
558 yp[j] = TMath::Abs(secR2[i])*SinD(t)+secY2[i];
559 if(GetDebug(3)){
560 cout << "{"<<xp[j]<<","<<yp[j];
561 if(GetDebug(4)) cout <<","<<t;
562 cout <<"},";
563 } // end if GetDebug
564 } // end for k
565 if(GetDebug(3)) cout << endl;
566 if(i==6) { // add thicker side
567 b = CosD(0.5*ksecAngleSide13);
568 a = SinD(0.5*ksecAngleSide13);
569 x1 = xp[j];
570 y1 = yp[j];
571 x0 = a*a*ksecX5 + b*b*x1 - (y1-ksecY5)*a*b;
572 y0 = a*a*y1 + b*b*ksecY5 - (x1-ksecX5)*a*b;
573 j++;
574 xp[j+3] = x0 - ksecSideD5*a;
575 yp[j+3] = y0 - ksecSideD5*b;
576 xp[j+2] = xp[j+3] + (ksecCthick3-ksecCthick2)*b;
577 yp[j+2] = yp[j+3] - (ksecCthick3-ksecCthick2)*a;
578 xp[j+1] = xp[j+2] - ksecSidelen*a;
579 yp[j+1] = yp[j+2] - ksecSidelen*b;
580 xp[j] = xp[j+1] - (ksecCthick3-ksecCthick2)*b;
581 yp[j] = yp[j+1] + (ksecCthick3-ksecCthick2)*a;
582 j += 3;
583 if(GetDebug(3))for(k=-3;k<=0;k++){
584 cout << "{"<<xp[j+k]<<","<<yp[j+k];
585 if(GetDebug(4)) cout <<",t="<<0.0;
586 cout <<"},";
587 } // end if GetDebug
588 if(GetDebug(3)) cout << endl;
589 } // end if i==6
590 if(i==19) { // add thicker side
591 // first propogate referece point 12 to -18 degree edge
592 b = CosD(0.5*ksecAngleSide13);
593 a = SinD(0.5*ksecAngleSide13);
594 x1 = secX[0]+TMath::Abs(secR[0])*CosD(secAngleStart[0]);
595 y1 = secY[0]+TMath::Abs(secR[0])*SinD(secAngleStart[0]);
596 x0 = a*b*(y1-secY[ksecNRadii-2]) +
597 a*a*secX[ksecNRadii-2] + b*b*x1;
598 y0 = a*b*(x1-secX[ksecNRadii-2]) +
599 b*b*secY[ksecNRadii-2] + a*a*y1;
600 j++;
601 xp[j] = x0 + ksecSideD12*a;
602 yp[j] = y0 - ksecSideD12*b;
603 j++;
604 xp[j] = xp[j-1] - (ksecCthick3-ksecCthick2)*b;
605 yp[j] = yp[j-1] - (ksecCthick3-ksecCthick2)*a;
606 j++;
607 xp[j] = xp[j-1] + ksecSidelen*a;
608 yp[j] = yp[j-1] - ksecSidelen*b;
609 j++;
610 xp[j] = xp[j-1] + (ksecCthick3-ksecCthick2)*b;
611 yp[j] = yp[j-1] + (ksecCthick3-ksecCthick2)*a;
612 if(GetDebug(3))for(k=-3;k<=0;k++){
613 cout << "{"<<xp[j+k]<<","<<yp[j+k];
614 if(GetDebug(4)) cout <<",t="<<0.0;
615 cout <<"},";
616 } // end if GetDebug
617 if(GetDebug(3)) cout << endl;
618 } // end if i==19
619 } // end for i
620 if(GetDebug(3)) cout<<"{"<<xp[0]<<","<<yp[0];
621 if(GetDebug(4)) cout<<","<< secAngleStart2[0];
622 if(GetDebug(3)) cout<<"}} j="<<j<<endl;
db486a6e 623 sB0 = new TGeoXtru(2);
624 sB0->SetName("ITS SPD Carbon fiber support Sector End B0");
bf86817c 625 sB0->DefinePolygon(j+1,xp,yp);
db486a6e 626 sB0->DefineSection(0,ksecDz);
627 sB0->DefineSection(1,ksecDz+ksecZEndLen);
628 //
bf86817c 629 if(GetDebug(3)) cout <<"Double_t sB1[][{";
630 if(GetDebug(4)) cout <<"3]{";
631 else if(GetDebug(3)) cout <<"2]{";
632 j = -1;
633 t0 = (Double_t)ksecNPointsPerRadii;
634 for(i=0;i<ksecNRadii+ksecNCoolingTubeDips;i++){
635 t1 = (secAngleEnd3[i]-secAngleStart3[i])/t0;
636 if(GetDebug(5)) cout<<"t1="<< t1<<endl;
637 for(k=0;k<=ksecNPointsPerRadii;k++){
638 t=secAngleStart3[i]+((Double_t)k)*t1;
639 j++;
640 x0 = TMath::Abs(secR2[i]-ksecCthick2);
641 if(i==2||i==5||i==8||i==11||i==14||i==17){
642 x0 = TMath::Abs(secR2[i]-ksecRCoolOut+ksecRCoolIn);/*
643 if(k==0){// compute change in start and end angles to
644 // compensate for thickness of carbon fiber
645 y0 = (ksecCthick2-ksecRCoolOut*SinD(t))/
646 ksecRCoolIn; // sin th'
647 if(GetDebug(5))cout <<" k=0 t="<<t<<" y0="<<y0<<endl;
648 y1 = TMath::Sqrt(1-y0*y0); // cos th'
649 t -= 180.*TMath::ASin(SinD(t)*y1-CosD(t)*y0)/TMath::Pi();
650 }else if(k==ksecNPointsPerRadii) {
651 y0 = (ksecCthick2-ksecRCoolOut*SinD(t))/
652 ksecRCoolIn; // sin th'
653 if(GetDebug(5))cout <<" k="<<k<<" t="<<t<<" y0="<<y0<<endl;
654 y1 = TMath::Sqrt(1-y0*y0); // cos th'
655 t += 180.*TMath::ASin(SinD(t)*y1-CosD(t)*y0)/TMath::Pi();
656 } // end if
657 */} // end if
658 xp[j] = x0*CosD(t)+secX2[i];
659 yp[j] = x0*SinD(t)+secY2[i];
660 if(GetDebug(3)){
661 cout << "{"<<xp[j]<<","<<yp[j];
662 if(GetDebug(4)) cout <<","<<t;
663 cout <<"},";
664 } // end if GetDebug
665 } // end for k
666 if(GetDebug(3)) cout << endl;
db486a6e 667 } // end for i
bf86817c 668 if(GetDebug(3)) cout<<"{"<<xp[0]<<","<<yp[0];
669 if(GetDebug(4)) cout<<","<< secAngleStart2[0];
670 if(GetDebug(3)) cout<<"}} j="<<j<<endl;
db486a6e 671 sB1 = new TGeoXtru(2);
672 sB1->SetName("ITS SPD Carbon fiber support Sector Air End B1");
bf86817c 673 sB1->DefinePolygon(j+1,xp,yp);
db486a6e 674 sB1->DefineSection(0,ksecDz);
675 sB1->DefineSection(1,ksecDz+ksecLen);
676 sTB0 = new TGeoTube("ITS SPD Cooling Tube End TB0",0.0,
bf86817c 677 ksecRCoolIn,0.5*ksecLen);
db486a6e 678 sTB1 = new TGeoTube("ITS SPD Cooling Tube End coolant TB0",0.0,
679 sTB0->GetRmax()-ksecCoolTubeThick,0.5*ksecLen);
680 //
db486a6e 681 if(GetDebug()){
db486a6e 682 sA0->InspectShape();
683 sA1->InspectShape();
684 sB0->InspectShape();
685 sB1->InspectShape();
686 } // end if GetDebug
687 //
bf86817c 688 TGeoVolume *vM,*vA0,*vA1,*vTA0,*vTA1,*vB0,*vB1,*vTB0,*vTB1;
689 vM = moth;
db486a6e 690 vA0 = new TGeoVolume("ITSSPDCarbonFiberSupportSectorA0",sA0,medSPDcf);
691 vA0->SetVisibility(kTRUE);
692 vA0->SetLineColor(4); // Blue
693 vA0->SetLineWidth(1);
694 vA0->SetFillColor(vA0->GetLineColor());
695 vA0->SetFillStyle(4010); // 10% transparent
696 vA1 = new TGeoVolume("ITSSPDCarbonFiberSupportSectorAirA1",sA1,medSPDair);
697 vA1->SetVisibility(kTRUE);
698 vA1->SetLineColor(7); // light Blue
699 vA1->SetLineWidth(1);
700 vA1->SetFillColor(vA1->GetLineColor());
701 vA1->SetFillStyle(4090); // 90% transparent
702 vTA0 = new TGeoVolume("ITSSPDCoolingTubeTA0",sTA0,medSPDss);
703 vTA0->SetVisibility(kTRUE);
704 vTA0->SetLineColor(1); // Black
705 vTA0->SetLineWidth(1);
706 vTA0->SetFillColor(vTA0->GetLineColor());
707 vTA0->SetFillStyle(4000); // 0% transparent
708 vTA1 = new TGeoVolume("ITSSPDCoolingTubeFluidTA1",sTA1,medSPDcoolfl);
709 vTA1->SetVisibility(kTRUE);
710 vTA1->SetLineColor(6); // Purple
711 vTA1->SetLineWidth(1);
712 vTA1->SetFillColor(vTA1->GetLineColor());
713 vTA1->SetFillStyle(4000); // 0% transparent
714 vB0 = new TGeoVolume("ITSSPDCarbonFiberSupportSectorEndB0",sB0,medSPDcf);
715 vB0->SetVisibility(kTRUE);
716 vB0->SetLineColor(4); // Blue
717 vB0->SetLineWidth(1);
718 vB0->SetFillColor(vB0->GetLineColor());
719 vB0->SetFillStyle(4010); // 10% transparent
bf86817c 720 vB1 = new TGeoVolume("ITSSPDCarbonFiberSupportSectorEndAirB1",sB1,medSPDair);
db486a6e 721 vB1->SetVisibility(kTRUE);
722 vB1->SetLineColor(7); // light Blue
723 vB1->SetLineWidth(1);
724 vB1->SetFillColor(vB1->GetLineColor());
725 vB1->SetFillStyle(4090); // 90% transparent
726 vTB0 = new TGeoVolume("ITSSPDCoolingTubeEndTB0",sTB0,medSPDss);
727 vTB0->SetVisibility(kTRUE);
728 vTB0->SetLineColor(1); // Black
729 vTB0->SetLineWidth(1);
730 vTB0->SetFillColor(vTB0->GetLineColor());
731 vTB0->SetFillStyle(4000); // 0% transparent
732 vTB1 = new TGeoVolume("ITSSPDCoolingTubeEndFluidTB1",sTB1,medSPDcoolfl);
733 vTB1->SetVisibility(kTRUE);
734 vTB1->SetLineColor(6); // Purple
735 vTB1->SetLineWidth(1);
736 vTB1->SetFillColor(vTB1->GetLineColor());
737 vTB1->SetFillStyle(4000); // 0% transparent
738 //
db486a6e 739 vA0->AddNode(vA1,1,0); // Put air inside carbon fiber.
740 vB0->AddNode(vB1,1,0); // Put air inside carbon fiber.
741 vTA0->AddNode(vTA1,1,0); // Put air inside carbon fiber.
742 vTB0->AddNode(vTB1,1,0); // Put air inside carbon fiber.
743 for(i=0;i<ksecNCoolingTubeDips;i++){
bf86817c 744 x0 = secX2[ksecDipIndex[i]];
745 y0 = secY2[ksecDipIndex[i]];
746 trans = new TGeoTranslation("",x0,y0,0.0);
db486a6e 747 vB1->AddNode(vTB0,i+1,trans);
bf86817c 748 rot = new TGeoRotation("",0.0,0.0,
749 TMath::RadToDeg()*TMath::ATan2(y0,x0));
750 rotrans = new TGeoCombiTrans(*trans,*rot);
751 vM->AddNode(vTA0,i+1,rotrans);
752 delete rot;
db486a6e 753 } // end for i
bf86817c 754 vM->AddNode(vA0,1,0);
755 vM->AddNode(vB0,1,0);
756 vM->AddNode(vB0,2,new TGeoScale(1.0,1.0,-1.0)); // Reflection.
db486a6e 757 if(GetDebug()){
db486a6e 758 vA0->PrintNodes();
759 vA1->PrintNodes();
760 vB0->PrintNodes();
761 vB1->PrintNodes();
762 } // end if GetDebug
763 //
db486a6e 764}
765//______________________________________________________________________
bf86817c 766void AliITSv11GeometrySPD::HalfStave(TGeoVolume *moth){
db486a6e 767 // Define the detail SPD Half Stave geometry.
768 // Inputs:
769 // none.
770 // Outputs:
771 // none.
772 // Return:
773 // none.
774
bf86817c 775 if(moth==0){
776 Error("HalfStave","moth=%p",moth);
777 return;
778 } // end if moth==0
db486a6e 779}
780//----------------------------------------------------------------------
781void AliITSv11GeometrySPD::CreateFigure0(const Char_t *filepath,
782 const Char_t *type){
783 // Creates Figure 0 for the documentation of this class. In this
784 // specific case, it creates the X,Y cross section of the SPD suport
785 // section, center and ends. The output is written to a standard
786 // file name to the path specificed.
787 // Inputs:
788 // const Char_t *filepath Path where the figure is to be drawn
789 // const Char_t *type The type of file, default is gif.
790 // Output:
791 // none.
792 // Return:
793 // none.
794 TGeoXtru *sA0,*sA1,*sB0,*sB1;
795 //TPolyMarker *pmA,*pmB;
796 TPolyLine plA0,plA1,plB0,plB1;
797 TCanvas *canvas;
798 TLatex txt;
bf86817c 799 Double_t x,y;
db486a6e 800
bf86817c 801 sA0 = (TGeoXtru*) gGeomManager->GetVolume(
db486a6e 802 "ITSSPDCarbonFiberSupportSectorA0_1")->GetShape();
bf86817c 803 sA1 = (TGeoXtru*) gGeomManager->GetVolume(
db486a6e 804 "ITSSPDCarbonFiberSupportSectorAirA1_1")->GetShape();
bf86817c 805 sB0 = (TGeoXtru*) gGeomManager->GetVolume(
db486a6e 806 "ITSSPDCarbonFiberSupportSectorEndB0_1")->GetShape();
bf86817c 807 sB1 = (TGeoXtru*) gGeomManager->GetVolume(
db486a6e 808 "ITSSPDCarbonFiberSupportSectorEndAirB1_1")->GetShape();
809 //pmA = new TPolyMarker();
810 //pmA.SetMarkerStyle(2); // +
811 //pmA.SetMarkerColor(7); // light blue
812 //pmB = new TPolyMarker();
813 //pmB.SetMarkerStyle(5); // X
814 //pmB.SetMarkerColor(6); // purple
bf86817c 815 plA0.SetPolyline(sA0->GetNvert());
db486a6e 816 plA0.SetLineColor(1); // black
817 plA0.SetLineStyle(1);
bf86817c 818 plA1.SetPolyline(sA1->GetNvert());
db486a6e 819 plA1.SetLineColor(2); // red
820 plA1.SetLineStyle(1);
bf86817c 821 plB0.SetPolyLine(sB0.GetNvert());
db486a6e 822 plB0.SetLineColor(3); // Green
823 plB0.SetLineStyle(2);
824 plB1.SetPolyLine(sB1->GetNvert());
825 plB1.SetLineColor(4); // Blue
826 plB1.SetLineStyle(2);
827 //for(i=0;i<kNRadii;i++) pmA.SetPoint(i,xyB1p[i][0],xyB1p[i][1]);
828 //for(i=0;i<kNRadii;i++) pmB.SetPoint(i,xyB1p[i][0],xyB1p[i][1]);
829 for(i=0;i<sA0->GetNvert();i++) plA0.SetPoint(i,sA0->GetX(i),sA0->GetY(i));
830 for(i=0;i<sA1->GetNvert();i++) plA1.SetPoint(i,sA1->GetX(i),sA1->GetY(i));
831 for(i=0;i<sB0->GetNvert();i++) plB0.SetPoint(i,sB0->GetX(i),sB0->GetY(i));
832 for(i=0;i<sB1->GetNvert();i++) plB1.SetPoint(i,sB1->GetX(i),sB1->GetY(i));
833 canvas = new TCanvas("AliITSv11GeometrySPDFig0","",1000,1000);
bf86817c 834 canvas.Range(-3.,-3.,3.,3.);
835 txt.SetTextsize(0.05);
db486a6e 836 txt.SetTextAlign(33);
837 txt.SetTextColor(1);
bf86817c 838 txt.Draw(2.9,2.9,"Section A-A outer Carbon Fiber surface");
db486a6e 839 txt.SetTextColor(2);
bf86817c 840 txt.Draw(2.9,2.5,"Section A-A Inner Carbon Fiber surface");
db486a6e 841 txt.SetTextColor(3);
bf86817c 842 txt.Draw(2.9,2.1,"Section E-E outer Carbon Fiber surface");
db486a6e 843 txt.SetTextColor(4);
bf86817c 844 txt.Draw(2.9,1.7,"Section E-E Inner Carbon Fiber surface");
db486a6e 845 plA0.Draw();
846 plA1.Draw();
847 plB0.Draw();
848 plB1.Draw();
849 //pmA.Draw();
850 //pmB.Draw();
851 //
db486a6e 852 Char_t chr[3];
853 for(i=0;i<kNRadii;i++){
854 sprintf(chr,"%2d",i);txt.DrawLatex(x-0.1,y,chr);
bf86817c 855 sprintf(chr,"%8.4",);txt.DrawLatex(x,y,chr);
856 sprintf(chr,"%8.4",);txt.DrawLatex(x+0.5,y,chr);
857 sprintf(chr,"%8.4",);txt.DrawLatex(x+1.0,y,chr);
858 sprintf(chr,"%8.4",);txt.DrawLatex(x+1.5,y,chr);
859 sprintf(chr,"%8.4",);txt.DrawLatex(x+2.0,y,chr);
860 if() txt.DrawLatex(x+2.5,y,"A-A/E-E");
db486a6e 861 else txt.DrawLatex(x+2.5,y,"E-E");
862 } // end for i
863 txt.DrawLatex(x,y,"x_{c} mm");
864 txt.DrawLatex(x+0.5,y,"y_{c} mm");
865 txt.DrawLatex(x+1.0,y,"R mm");
866 txt.DrawLatex(x+1.5,y,"#theta_{start}^{#circle}");
867 txt.DrawLatex(x+2.0,y,"#theta_{end}^{#circle}");
868 txt.DrawLatex(x+2.5,y,"Section");
869 //
870}