1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 Revision 1.21 2000/11/14 10:48:57 kowal2
19 Correct material used for TSA4. Thanks to J. Barbosa.
21 Revision 1.20 2000/11/06 17:24:10 kowal2
22 Corrected bug in the outer containment vessel and
23 the outer field cage geometry.
26 Revision 1.19 2000/11/02 16:55:24 kowal2
27 Corrected bug in the inner containment vessel geometry.
30 Revision 1.18 2000/11/02 07:24:11 kowal2
31 Correction in the TPC geometry.
32 Changes due to the new hit structure.
34 Revision 1.17 2000/07/10 20:57:39 hristov
35 Update of TPC code and macros by M.Kowalski
37 Revision 1.16 2000/06/30 12:07:50 kowal2
38 Updated from the TPC-PreRelease branch
40 Revision 1.15.2.4 2000/06/26 07:39:42 kowal2
41 Changes to obey the coding rules
43 Revision 1.15.2.3 2000/06/25 08:38:41 kowal2
44 Splitted from AliTPCtracking
46 Revision 1.15.2.2 2000/06/16 12:58:13 kowal2
47 Changed parameter settings
49 Revision 1.15.2.1 2000/06/09 07:15:07 kowal2
51 Defaults loaded automatically (hard-wired)
52 Optional parameters can be set via macro called in the constructor
54 Revision 1.15 2000/05/15 10:00:30 kowal2
55 Corrected bug in the TPC geometry, thanks to Ivana Hrivnacova
57 Revision 1.14 2000/04/17 09:37:33 kowal2
58 removed obsolete AliTPCDigitsDisplay.C
60 Revision 1.13.8.2 2000/04/10 08:33:44 kowal2
62 Updated readout chambers
64 Revision 1.13.8.1 2000/04/10 07:56:53 kowal2
65 Not used anymore - removed
67 Revision 1.13 1999/11/04 17:28:06 fca
68 Correct barrel part of HV Degrader
70 Revision 1.12 1999/10/08 06:27:23 fca
71 Corrected bug in the HV degrader geometry, thanks to G.Tabary
73 Revision 1.11 1999/10/04 13:39:54 fca
74 Correct array index problem
76 Revision 1.10 1999/09/29 09:24:34 fca
77 Introduction of the Copyright and cvs Log
82 ///////////////////////////////////////////////////////////////////////////////
84 // Time Projection Chamber version 0 -- "coarse" TPC //
88 <img src="picts/AliTPCv0Class.gif">
93 ///////////////////////////////////////////////////////////////////////////////
96 #include <TGeometry.h>
101 #include <iostream.h>
104 #include "AliConst.h"
106 #include "AliTPCParamSR.h"
107 #include "AliTPCDigitsArray.h"
111 //_____________________________________________________________________________
112 AliTPCv0::AliTPCv0(const char *name, const char *title)
116 // Standard creator for TPC version 0
119 SetGasMixt(2,20,10,-1,0.9,0.1,0.);
122 fTPCParam->Write(fTPCParam->GetTitle());
125 //_____________________________________________________________________________
126 void AliTPCv0::CreateGeometry()
129 // Creation of the TPC version 0, i.e. no sensitive volumes,
130 // only the material distribution
134 <img src="picts/AliTPC.gif">
139 <img src="picts/AliTPCv0Tree.gif">
143 //---------------------------------------------------------------
146 // Origin: Marek Kowalski, INP Cracow
147 // Marek.Kowalski@ifj.edu.pl
148 //---------------------------------------------------------------
152 Int_t *idtmed = fIdtmed->GetArray(); // TPC media
154 Int_t idrotm[120]; // rotation matrices
156 Int_t nRotMat = 0; // actual number of rotation matrices
160 // Mother volume (Air) - all volumes will be positioned in it
240 gMC->Gsvolu("TPC ","PCON",idtmed[0],dm,39);
243 //-------------------------------------------------------------------
244 // Tpc Outer INsulator (CO2)
245 //-------------------------------------------------------------------
284 gMC->Gsvolu("TOIN","PCON",idtmed[3],dm,21);
286 //---------------------------------------------------------------
287 // shreds (G10) - TPC Rings
288 //---------------------------------------------------------------
290 gMC->Gsvolu("TPCR","TUBE",idtmed[12],dm,0);
296 gMC->Gsposp("TPCR",1,"TOIN",0.,0.,-253.3,0,"ONLY",dm,3); // left bottom
304 gMC->Gsposp("TPCR",2,"TOIN",0.,0.,253.3,0,"ONLY",dm,3); // right
312 gMC->Gsposp("TPCR",3,"TOIN",0.,0.,-250.7,0,"ONLY",dm,3); // left top
314 //----------------------------------------------------------------
315 // Tpc Outer Contaiment Vessel
316 // mother volume - Al, daughters - composite (sandwich)
317 //----------------------------------------------------------------
359 gMC->Gsvolu("TOCV","PCON",idtmed[4],dm,21);
363 // Tpc SAndwich 1 - Al
369 gMC->Gsvolu("TSA1","TUBE",idtmed[4],dm,3);
371 // Tpc SAndwich 2 - Tedlar
376 gMC->Gsvolu("TSA2","TUBE",idtmed[9],dm,3);
378 // Tpc SAndwich 3 - Kevlar
383 gMC->Gsvolu("TSA3","TUBE",idtmed[5],dm,3);
385 // Tpc SAndwich 4 - NOMEX honeycomb
390 gMC->Gsvolu("TSA4","TUBE",idtmed[6],dm,3);
394 gMC->Gspos("TSA4",1,"TSA3",0.,0.,0.,0,"ONLY");
395 gMC->Gspos("TSA3",1,"TSA2",0.,0.,0.,0,"ONLY");
396 gMC->Gspos("TSA2",1,"TSA1",0.,0.,0.,0,"ONLY");
398 gMC->Gspos("TSA1",1,"TOCV",0.,0.,2.6,0,"ONLY");
402 gMC->Gspos("TOCV",1,"TOIN",0.,0.,0.,0,"ONLY");
404 //-------------------------------------------------------
405 // Tpc Outer Field Cage
406 // mother volume - Al, daughters - composite (sandwich)
407 //-------------------------------------------------------
447 gMC->Gsvolu("TOFC","PCON",idtmed[4],dm,21);
451 // Tpc SAndwich 5 - Tedlar
457 gMC->Gsvolu("TSA5","TUBE",idtmed[9],dm,3);
459 // Tpc SAndwich 6 - Kevlar
464 gMC->Gsvolu("TSA6","TUBE",idtmed[5],dm,3);
467 // Tpc SAndwich 7 - NOMEX
472 gMC->Gsvolu("TSA7","TUBE",idtmed[6],dm,3);
476 gMC->Gspos("TSA7",1,"TSA6",0.,0.,0.,0,"ONLY");
477 gMC->Gspos("TSA6",1,"TSA5",0.,0.,0.,0,"ONLY");
479 gMC->Gspos("TSA5",1,"TOFC",0.,0.,0.,0,"ONLY");
483 gMC->Gspos("TOFC",1,"TOIN",0.,0.,0.,0,"ONLY");
487 gMC->Gspos("TOIN",1,"TPC ",0.,0.,0.,0,"ONLY");
489 //--------------------------------------------------------------------
490 // Tpc Inner INsulator (CO2)
491 //--------------------------------------------------------------------
506 Float_t tanL = (66.2-59.0)/(255.6-73.3); // tangent of the left cone part
509 dm[7]= 59.0+ (253.6-73.3)*tanL;
590 gMC->Gsvolu("TIIN","PCON",idtmed[3],dm,48);
593 //--------------------------------------------------------------------
594 // Tpc Inner Containment vessel, Left part
595 // mother volume - Al, daughter - composite (sandwich)
596 //--------------------------------------------------------------------
610 Float_t cosL = 1./TMath::Sqrt(1.+tanL*tanL);
611 Float_t sandThick = 2.14; // cone composite thickness
617 dm[7]= 59.0 + (253.6-73.3)*tanL;
624 dm[11]= dm[7]+sandThick/cosL;
629 dm[13]= 59.0+(75.6-73.3)*tanL;
630 dm[14]= dm[13]+sandThick/cosL;
656 gMC->Gsvolu("TICL","PCON",idtmed[4],dm,27);
660 // Tpc SAndwich 9 - Al
669 dm[4]= 59.0+(254.3-73.3)*tanL;
670 dm[5]= dm[4]+sandThick/cosL;
675 dm[7]= 59.0+(78.3-73.3)*tanL;
676 dm[8]= dm[7]+sandThick/cosL;
680 gMC->Gsvolu("TSA9","PCON",idtmed[4],dm,9);
682 // Tpc SAndwich 10 - Tedlar
692 gMC->Gsvolu("TS10","PCON",idtmed[9],dm,9);
694 // Tpc SAndwich 11 - Kevlar
704 gMC->Gsvolu("TS11","PCON",idtmed[5],dm,9);
706 // Tpc SAndwich 12 - NOMEX
716 gMC->Gsvolu("TS12","PCON",idtmed[6],dm,9);
720 gMC->Gspos("TS12",1,"TS11",0.,0.,0.,0,"ONLY");
721 gMC->Gspos("TS11",1,"TS10",0.,0.,0.,0,"ONLY");
722 gMC->Gspos("TS10",1,"TSA9",0.,0.,0.,0,"ONLY");
726 gMC->Gspos("TSA9",1,"TICL",0.,0.,0.,0,"ONLY");
728 //--------------------------------------------------------------------
729 // Tpc Inner Containment vessel, Right part
730 // mother volume - Al, daughter - composite (sandwich)
731 //--------------------------------------------------------------------
757 Float_t tanR = (66.0-59.0)/(250.5-73.3); // to avoid accuracy problems
758 Float_t cosR = 1./TMath::Sqrt(1.+tanR*tanR); //as above
763 dm[13]= 59.0+(75.6-73.3)*tanR;
770 dm[17]= dm[16]+sandThick/cosR;
775 dm[19]= 59.0+(248.4-73.3)*tanR;
776 dm[20]= dm[19]+sandThick/cosR;
790 gMC->Gsvolu("TICR","PCON",idtmed[4],dm,27);
796 // Tpc SAndwich 13 - Al
805 dm[4]= 59.0+(78.3-73.3)*tanR;
806 dm[5]= dm[4]+sandThick/cosR;
811 dm[7]= 59.0+(249.1-73.3)*tanR;
812 dm[8]= dm[7]+sandThick/cosR;
816 gMC->Gsvolu("TS13","PCON",idtmed[4],dm,9);
818 // Tpc SAndwich 14 - Tedlar
828 gMC->Gsvolu("TS14","PCON",idtmed[9],dm,9);
830 // Tpc SAndwich 15 - Kevlar
840 gMC->Gsvolu("TS15","PCON",idtmed[5],dm,9);
842 // Tpc SAndwich 16 - NOMEX
852 gMC->Gsvolu("TS16","PCON",idtmed[6],dm,9);
856 gMC->Gspos("TS16",1,"TS15",0.,0.,0.,0,"ONLY");
857 gMC->Gspos("TS15",1,"TS14",0.,0.,0.,0,"ONLY");
858 gMC->Gspos("TS14",1,"TS13",0.,0.,0.,0,"ONLY");
862 gMC->Gspos("TS13",1,"TICR",0.,0.,0.,0,"ONLY");
864 //------------------------------------------------------
865 // Tpc Inner Field Cage
866 // mother volume - Al, daughters - composite (sandwich)
867 //------------------------------------------------------
909 gMC->Gsvolu("TIFC","PCON",idtmed[4],dm,21);
913 // Tpc Sandwich 17 - Tedlar
919 gMC->Gsvolu("TS17","TUBE",idtmed[9],dm,3);
921 // Tpc Sandwich 18 - Kevlar
926 gMC->Gsvolu("TS18","TUBE",idtmed[5],dm,3);
929 // Tpc Sandwich 19 - NOMEX
934 gMC->Gsvolu("TS19","TUBE",idtmed[6],dm,3);
938 gMC->Gspos("TS19",1,"TS18",0.,0.,0.,0,"ONLY");
939 gMC->Gspos("TS18",1,"TS17",0.,0.,0.,0,"ONLY");
943 gMC->Gspos("TS17",1,"TIFC",0.,0.,0.,0,"ONLY");
951 gMC->Gsposp("TPCR",4,"TIIN",0.,0.,-253.3,0,"ONLY",dm,3);
956 gMC->Gsposp("TPCR",5,"TIIN",0.,0.,250.7,0,"ONLY",dm,3);
961 gMC->Gsposp("TPCR",6,"TIIN",0.,0.,253.3,0,"ONLY",dm,3);
965 gMC->Gspos("TICL",1,"TIIN",0.,0.,0.,0,"ONLY");
969 gMC->Gspos("TICR",1,"TIIN",0.,0.,0.,0,"ONLY");
973 gMC->Gspos("TIFC",1,"TIIN",0.,0.,0.,0,"ONLY");
975 // Tpc Sandwich 21 - Al (central barrel)
981 gMC->Gsvolu("TS21","TUBE",idtmed[4],dm,3);
983 // Tpc Sandwich 22 - Tedlar (central barrel)
988 gMC->Gsvolu("TS22","TUBE",idtmed[9],dm,3);
990 // Tpc Sandwich 23 - Kevlar (central barrel)
995 gMC->Gsvolu("TS23","TUBE",idtmed[5],dm,3);
997 // Tpc Sandwich 24 - NOMEX (central barrel)
1002 gMC->Gsvolu("TS24","TUBE",idtmed[6],dm,3);
1006 gMC->Gspos("TS24",1,"TS23",0.,0.,0.,0,"ONLY");
1007 gMC->Gspos("TS23",1,"TS22",0.,0.,0.,0,"ONLY");
1008 gMC->Gspos("TS22",1,"TS21",0.,0.,0.,0,"ONLY");
1010 gMC->Gspos("TS21",1,"TIIN",0.,0.,0.,0,"ONLY");
1012 // put everything into the TPC
1014 gMC->Gspos("TIIN",1,"TPC ",0.,0.,0.,0,"ONLY");
1017 //---------------------------------------------------------
1018 // Tpc Dift Gas volume Nonsensitive (Ne-CO2 90/10)
1019 // and its daughters (HV membrane, rods, readout chambers)
1020 //---------------------------------------------------------
1026 gMC->Gsvolu("TDGN","TUBE",idtmed[1],dm,3);
1028 // sector opening angles
1030 Float_t innerOpenAngle = fTPCParam->GetInnerAngle();
1032 // sector angle shift
1034 Float_t innerAngleShift = fTPCParam->GetInnerAngleShift();
1036 // number of sectors
1038 Int_t nInnerSector = fTPCParam->GetNInnerSector()/2;
1039 Int_t nOuterSector = fTPCParam->GetNOuterSector()/2;
1041 // All above parameters are identical for inner and outer
1042 // sectors. The distinction is kept for the historical reasons
1043 // and eventually will disappear.
1045 Float_t tanAlpha = TMath::Tan(0.5*innerOpenAngle);
1046 Float_t cosAlpha = TMath::Sqrt(1.+tanAlpha*tanAlpha);
1049 //-------------------------------------------------------------------------
1050 // Tpc Inner Readout Chambers
1051 //-------------------------------------------------------------------------
1055 dm[2]= 1.6; // thickness
1058 gMC->Gsvolu("TIRC","TRD1",idtmed[4],dm,4);
1060 // this volume will be positioned in the empty space
1061 // of the end-cap to avoid overlaps
1068 gMC->Gsvolu("TIC1","TRD1",idtmed[4],dm,4);
1071 //------------------------------------------------
1072 // Tpc Inner readout chamber Pad Plane
1073 //------------------------------------------------
1080 gMC->Gsvolu("TIPP","TRD1",idtmed[12],dm,4);
1084 dm[0] -= 1.218511934;
1085 dm[1] -= 1.218511934;
1088 gMC->Gsvolu("TIC3","TRD1",idtmed[1],dm,4);
1090 gMC->Gspos("TIC3",1,"TIPP",0.,0.15,0.,0,"ONLY");
1092 gMC->Gspos("TIPP",1,"TIRC",0.,1.1,0.,0,"ONLY");
1095 //----------------------------------------------
1096 // Tpc Readout Chambers Empty spaces - for both
1097 // inner and outer sectors
1098 //----------------------------------------------
1100 gMC->Gsvolu("TRCE","TRD1",idtmed[0],dm,0);
1102 // Inner sector - 4 spaces
1113 space = rr*tanAlpha-dm[0];
1115 for(Int_t nsLow=0;nsLow<4;nsLow++){
1118 dm[1]= rr*tanAlpha - space;
1122 gMC->Gsposp("TRCE",nsLow+1,"TIRC",0.,-0.8,zz,0,"ONLY",dm,4);
1128 gMC->Gsposp("TRCE",nsLow+5,"TIC1",0.,1.05,zz-2.1,0,"ONLY",dm,4);
1131 dm[0] = rr*tanAlpha - space;
1137 // dm[1] - this is the dm[1] from the previous TRCE
1141 gMC->Gsposp("TRCE",9,"TIC1",0.,-1.2,0.,0,"ONLY",dm,4);
1144 // TPc Space for Connectors
1151 gMC->Gsvolu("TPSC","BOX ",idtmed[0],dm,3);
1159 gMC->Gsvolu("TPCC","BOX ",idtmed[13],dm,3);
1161 gMC->Gspos("TPCC",1,"TPSC",0.,0.15,0.,0,"ONLY");
1169 Float_t phi1,phi2,phi3,theta1,theta2,theta3; // rotation angles
1171 // inner part of the inner sector - 2 x 20 holes
1173 astep = 20.00096874/19.;
1175 alpha = 10.00048437-astep;
1187 for(ncon=0;ncon<20;ncon++){
1193 phi3 = (alpha>0) ? 0. : 180.;
1194 theta3 = TMath::Abs(alpha);
1196 AliMatrix(idrotm[nRotMat], theta1, phi1, theta2, phi2, theta3, phi3);
1200 gMC->Gspos("TPSC",ncon+1,"TIRC",x1,0.3,-12.7875,idrotm[nRotMat],"ONLY");
1201 gMC->Gspos("TPSC",ncon+21,"TIRC",x2,0.3,-2.8625,idrotm[nRotMat],"ONLY");
1212 // outer part of the inner sector - 2 x 25 holes
1214 astep = 20.00096874/24.;
1215 alpha = 10.00048437-astep;
1223 for(ncon=0;ncon<25;ncon++){
1229 phi3 = (alpha>0) ? 0. : 180.;
1230 theta3 = TMath::Abs(alpha);
1232 AliMatrix(idrotm[nRotMat], theta1, phi1, theta2, phi2, theta3, phi3);
1236 gMC->Gspos("TPSC",ncon+41,"TIRC",x1,0.3,7.0625,idrotm[nRotMat],"ONLY");
1237 gMC->Gspos("TPSC",ncon+66,"TIRC",x2,0.3,16.9875,idrotm[nRotMat],"ONLY");
1248 //--------------------------------------------------------------------------
1249 // TPC Outer Readout Chambers
1250 // this is NOT a final design
1251 //--------------------------------------------------------------------------
1255 dm[2]= 1.5; //thickness
1258 gMC->Gsvolu("TORC","TRD1",idtmed[4],dm,4);
1260 //------------------------------------------------
1261 // Tpc Outer readout chamber Pad Plane
1262 //------------------------------------------------
1266 gMC->Gsvolu("TOPP","TRD1",idtmed[12],dm,4);
1268 dm[0] -= 1.218511934;
1269 dm[1] -= 1.218511934;
1272 gMC->Gsvolu("TOC3","TRD1",idtmed[1],dm,4);
1274 gMC->Gspos("TOC3",1,"TOPP",0.,0.15,0.,0,"ONLY");
1276 gMC->Gspos("TOPP",1,"TORC",0.,1.0,0.,0,"ONLY");
1285 gMC->Gsposp("TRCE",10,"TORC",0.,-0.8,-2.15,0,"ONLY",dm,4);
1292 gMC->Gsvolu("TOC1","TRD1",idtmed[4],dm,4);
1299 gMC->Gsposp("TRCE",11,"TOC1",0.,0.,0.,0,"ONLY",dm,4);
1301 //-----------------------------------------------
1302 // Tpc Services Support Wheel
1303 //-----------------------------------------------
1318 gMC->Gsvolu("TSSW","PGON",idtmed[4],dm,10);
1320 // Tpc Services Wheel Cover
1325 gMC->Gsvolu("TSWC","PGON",idtmed[4],dm,10);
1327 // Tpc Service wheel Cover Empty space
1334 gMC->Gsvolu("TSCE","TRD1",idtmed[0],dm,4);
1336 // Tpc services Wheel Empty Spaces
1343 gMC->Gsvolu("TWES","TRD1",idtmed[0],dm,4);
1345 // Tpc Services Wheel Bars
1347 gMC->Gsvolu("TSWB","TRD1",idtmed[4],dm,0);
1357 gMC->Gsposp("TSWB",1,"TWES",0.,0.,-85.125,0,"ONLY",dm,4);
1362 gMC->Gsposp("TSWB",2,"TWES",0.,0.,85.125,0,"ONLY",dm,4);
1364 // TPc ELectronics - right now 30% X0 Si
1371 gMC->Gsvolu("TPEL","TRD1",idtmed[11],dm,4);
1372 gMC->Gspos("TPEL",1,"TWES",0.,0.,0.,0,"ONLY");
1374 //--------------------------------------------------------------------------
1376 //--------------------------------------------------------------------------
1378 // TPc Main Wheel - Al
1384 gMC->Gsvolu("TPMW","TUBE",idtmed[4],dm,3);
1386 // TPc Extra Wheel (to avoid overlapping) - Al
1392 gMC->Gsvolu("TPEW","TUBE",idtmed[4],dm,3);
1394 //--------------------------------------------------------------------------
1395 // Tpc Empty Space for the Readout chambers
1396 //--------------------------------------------------------------------------
1400 Float_t dR = 0.5*(rUp-rLow);
1402 space= 1.4/cosAlpha; // wheel ribs are 2.8 cm wide
1404 dm[0]= rLow*tanAlpha-space;
1405 dm[1]= rUp*tanAlpha-space;
1409 gMC->Gsvolu("TESR","TRD1",idtmed[0],dm,4);
1413 gMC->Gspos("TIC1",1,"TESR",0.,0.75,-dR+23.97,0,"ONLY");
1417 gMC->Gspos("TOC1",1,"TESR",0.,0.75,dR-55.02,0,"ONLY");
1419 // Tpc Empty Space Bars - Al (daughters of TESR)
1423 gMC->Gsvolu("TESB","TRD1",idtmed[4],dm,0);
1427 dm[0]= rLow*tanAlpha-space;
1428 dm[1]= 88.7*tanAlpha-space;
1434 gMC->Gsposp("TESB",1,"TESR",0.,2.05,zBar,0,"ONLY",dm,4);
1438 dm[0]= 131.65*tanAlpha-space;
1439 dm[1]= 136.5*tanAlpha-space;
1442 zBar = -dR +131.65+dm[3]-rLow;
1444 gMC->Gsposp("TESB",2,"TESR",0.,2.05,zBar,0,"ONLY",dm,4);
1448 dm[0]= 240.4*tanAlpha-space;
1449 dm[1]= rUp*tanAlpha-space;
1454 gMC->Gsposp("TESB",3,"TESR",0.,2.05,zBar,0,"ONLY",dm,4);
1456 // positioning of the empty spaces into the main wheel
1460 Float_t rCenter,xc,yc;
1461 Float_t rInner,rOuter; // center of the inner and outer chamber
1469 for(Int_t ns=0; ns<nInnerSector;ns++){
1471 phi1 = ns * innerOpenAngle + innerAngleShift;
1472 phi1 *= kRaddeg; // in degrees
1474 phi1 = (Float_t)TMath::Nint(phi1) + 270.;
1476 if (phi1 > 360.) phi1 -= 360.;
1481 phi3 = ns * innerOpenAngle + innerAngleShift;
1482 phi3 *= kRaddeg; // in degrees
1484 phi3 = (Float_t)TMath::Nint(phi3);
1486 if(phi3 > 360.) phi3 -= 360.;
1490 // "holes"->End plate
1492 xc = rCenter*TMath::Cos(phi3*kDegrad);
1493 yc = rCenter*TMath::Sin(phi3*kDegrad);
1495 AliMatrix(idrotm[nRotMat], theta1, phi1, theta2, phi2, theta3, phi3);
1497 gMC->Gspos("TESR",ns+1,"TPMW",xc,yc,0.,idrotm[nRotMat],"ONLY");
1499 // TSCE->TSWC (services wheel volumes)
1501 xc = 166.142*TMath::Cos(phi3*kDegrad);
1502 yc = 166.142*TMath::Sin(phi3*kDegrad);
1504 gMC->Gspos("TSCE",ns+1,"TSWC",xc,yc,0.,idrotm[nRotMat],"ONLY");
1505 gMC->Gspos("TWES",ns+1,"TSSW",xc,yc,0.,idrotm[nRotMat],"ONLY");
1508 // readout chambers->TDGN (drift gas)
1510 xc = rInner*TMath::Cos(phi3*kDegrad);
1511 yc = rInner*TMath::Sin(phi3*kDegrad);
1513 gMC->Gspos("TIRC",ns+1,"TDGN",xc,yc,252.,idrotm[nRotMat],"ONLY");
1515 xc = rOuter*TMath::Cos(phi3*kDegrad);
1516 yc = rOuter*TMath::Sin(phi3*kDegrad);
1518 gMC->Gspos("TORC",ns+1,"TDGN",xc,yc,252.1,idrotm[nRotMat],"ONLY");
1522 theta2 = 0.; // reflection
1524 AliMatrix(idrotm[nRotMat], theta1, phi1, theta2, phi2, theta3, phi3);
1526 xc = rInner*TMath::Cos(phi3*kDegrad);
1527 yc = rInner*TMath::Sin(phi3*kDegrad);
1529 gMC->Gspos("TIRC",ns+nInnerSector+1,"TDGN",xc,yc,-252.,idrotm[nRotMat],"ONLY");
1531 xc = rOuter*TMath::Cos(phi3*kDegrad);
1532 yc = rOuter*TMath::Sin(phi3*kDegrad);
1534 gMC->Gspos("TORC",ns+nOuterSector+1,"TDGN",xc,yc,-252.1,idrotm[nRotMat],"ONLY");
1540 // reflection matrix
1549 AliMatrix(idrotm[nRotMat], theta1, phi1, theta2, phi2, theta3, phi3);
1554 gMC->Gspos("TPMW",1,"TPC ",0.,0.,256.6,0,"ONLY");
1555 gMC->Gspos("TPMW",2,"TPC ",0.,0.,-256.6,idrotm[nRotMat],"ONLY");
1556 gMC->Gspos("TPEW",1,"TPC ",0.,0.,257.65,0,"ONLY");
1557 gMC->Gspos("TPEW",2,"TPC ",0.,0.,-257.65,0,"ONLY");
1561 //-------------------------------------------------------
1562 // Tpc High Voltage Membrane - NOMEX honeycomb
1563 //-------------------------------------------------------
1582 gMC->Gsvolu("THVM","PGON",idtmed[6],dm,10);
1584 gMC->Gspos("THVM",1,"TDGN",0.,0.,0.,0,"ONLY");
1586 //----------------------------------------------------------
1587 // TPc Support Rods - MAKROLON
1588 //----------------------------------------------------------
1594 gMC->Gsvolu("TPSR","TUBE",idtmed[7],dm,3);
1596 for(Int_t nrod=1;nrod<18;nrod++){
1597 Float_t angle=innerOpenAngle*(Float_t)nrod;
1599 xc=82.4*TMath::Cos(angle);
1600 yc=82.4*TMath::Sin(angle);
1602 gMC->Gspos("TPSR",nrod,"TDGN",xc,yc,126.95,0,"ONLY");
1603 gMC->Gspos("TPSR",nrod+17,"TDGN",xc,yc,-126.95,0,"ONLY");
1605 xc=254.2*TMath::Cos(angle);
1606 yc=254.2*TMath::Sin(angle);
1608 gMC->Gspos("TPSR",nrod+34,"TDGN",xc,yc,126.95,0,"ONLY");
1609 gMC->Gspos("TPSR",nrod+51,"TDGN",xc,yc,-126.95,0,"ONLY");
1613 //----------------------------------------------------------
1614 // Tpc High Voltage rod - MAKROLON + Copper cable
1615 //----------------------------------------------------------
1617 // rod with cable (Left)
1623 gMC->Gsvolu("THVL","TUBE",idtmed[7],dm,3);
1631 gMC->Gsvolu("THVC","TUBE",idtmed[10],dm,3);
1639 gMC->Gsvolu("THVE","TUBE",idtmed[1],dm,3);
1641 gMC->Gspos("THVC",1,"THVL",0.,0.,0.,0,"ONLY");
1642 gMC->Gspos("THVE",1,"THVL",0.,0.,0.,0,"ONLY");
1644 // rod without cable
1650 gMC->Gsvolu("THVR","TUBE",idtmed[7],dm,3);
1654 gMC->Gspos("THVL",1,"TDGN",82.4,0.,-126.95,0,"ONLY");
1655 gMC->Gspos("THVL",2,"TDGN",254.2,0.,-126.95,0,"ONLY");
1657 gMC->Gspos("THVR",1,"TDGN",82.4,0.,126.95,0,"ONLY");
1658 gMC->Gspos("THVR",2,"TDGN",254.2,0.,126.95,0,"ONLY");
1662 gMC->Gspos("TDGN",1,"TPC ",0.,0.,0.,0,"ONLY");
1665 // services wheel cover -> wheel
1668 gMC->Gspos("TSWC",1,"TSSW",0.,0.,4.5,0,"ONLY");
1669 gMC->Gspos("TSWC",2,"TSSW",0.,0.,-4.5,0,"ONLY");
1672 // put the wheel into the TPC
1674 gMC->Gspos("TSSW",1,"TPC ",0.,0.,278.7,0,"ONLY");
1675 gMC->Gspos("TSSW",2,"TPC ",0.,0.,-278.7,0,"ONLY");
1679 gMC->Gsord("TPMW",6);
1680 gMC->Gsord("TSSW",6);
1681 gMC->Gsord("TSWC",6);
1683 // put the TPC into ALIC (main mother volume)
1685 gMC->Gspos("TPC ",1,"ALIC",0.,0.,0.,0,"ONLY");
1687 } // end of function
1690 //_____________________________________________________________________________
1691 void AliTPCv0::CreateMaterials()
1694 // Define materials for the TPC
1696 AliTPC::CreateMaterials();
1699 //_____________________________________________________________________________
1700 void AliTPCv0::DrawDetector()
1703 // Draw a shaded view of the Time Projection Chamber version 0
1706 // Set everything unseen
1707 gMC->Gsatt("*", "seen", -1);
1709 // Set ALIC mother transparent
1710 gMC->Gsatt("ALIC","SEEN",0);
1712 // Set the volumes visible
1713 gMC->Gsatt("TPC ","SEEN",0);
1714 gMC->Gsatt("TOIN","SEEN",1);
1715 gMC->Gsatt("TOIN","COLO",7);
1716 gMC->Gsatt("TPCR","SEEN",0);
1717 gMC->Gsatt("TOCV","SEEN",1);
1718 gMC->Gsatt("TOCV","COLO",4);
1719 gMC->Gsatt("TSA1","SEEN",0);
1720 gMC->Gsatt("TSA2","SEEN",0);
1721 gMC->Gsatt("TSA3","SEEN",0);
1722 gMC->Gsatt("TSA4","SEEN",0);
1723 gMC->Gsatt("TOFC","SEEN",1);
1724 gMC->Gsatt("TOFC","COLO",4);
1725 gMC->Gsatt("TSA5","SEEN",0);
1726 gMC->Gsatt("TSA6","SEEN",0);
1727 gMC->Gsatt("TSA7","SEEN",0);
1728 gMC->Gsatt("TIIN","COLO",7);
1729 gMC->Gsatt("TIIN","SEEN",1);
1730 gMC->Gsatt("TICL","SEEN",0);
1731 gMC->Gsatt("TSA9","SEEN",0);
1732 gMC->Gsatt("TS10","SEEN",0);
1733 gMC->Gsatt("TS11","SEEN",0);
1734 gMC->Gsatt("TS12","SEEN",0);
1735 gMC->Gsatt("TICR","SEEN",0);
1736 gMC->Gsatt("TS13","SEEN",0);
1737 gMC->Gsatt("TS14","SEEN",0);
1738 gMC->Gsatt("TS15","SEEN",0);
1739 gMC->Gsatt("TS16","SEEN",0);
1740 gMC->Gsatt("TIFC","SEEN",1);
1741 gMC->Gsatt("TIFC","COLO",4);
1742 gMC->Gsatt("TS17","SEEN",0);
1743 gMC->Gsatt("TS18","SEEN",0);
1744 gMC->Gsatt("TS19","SEEN",0);
1745 gMC->Gsatt("TS21","SEEN",0);
1746 gMC->Gsatt("TS22","SEEN",0);
1747 gMC->Gsatt("TS23","SEEN",0);
1748 gMC->Gsatt("TS24","SEEN",0);
1749 gMC->Gsatt("TDGN","SEEN",0);
1750 gMC->Gsatt("TIRC","SEEN",0);
1751 gMC->Gsatt("TIC1","SEEN",1);
1752 gMC->Gsatt("TIPP","SEEN",0);
1753 gMC->Gsatt("TIC3","SEEN",0);
1754 gMC->Gsatt("TRCE","SEEN",0);
1755 gMC->Gsatt("TPSC","SEEN",0);
1756 gMC->Gsatt("TPCC","SEEN",0);
1757 gMC->Gsatt("TORC","SEEN",0);
1758 gMC->Gsatt("TOPP","SEEN",0);
1759 gMC->Gsatt("TOC3","SEEN",0);
1760 gMC->Gsatt("TOC1","SEEN",1);
1761 gMC->Gsatt("TSSW","SEEN",1);
1762 gMC->Gsatt("TSWC","SEEN",1);
1763 gMC->Gsatt("TSCE","SEEN",1);
1764 gMC->Gsatt("TSSW","COLO",3);
1765 gMC->Gsatt("TSWC","COLO",3);
1766 gMC->Gsatt("TSCE","COLO",6);
1767 gMC->Gsatt("TWES","SEEN",0);
1768 gMC->Gsatt("TSWB","SEEN",0);
1769 gMC->Gsatt("TPEL","SEEN",0);
1770 gMC->Gsatt("TPMW","SEEN",1);
1771 gMC->Gsatt("TPEW","SEEN",1);
1772 gMC->Gsatt("TESR","SEEN",1);
1773 gMC->Gsatt("TPMW","COLO",12);
1774 gMC->Gsatt("TPEW","COLO",12);
1775 gMC->Gsatt("TWES","COLO",5);
1776 gMC->Gsatt("TIC1","COLO",5);
1777 gMC->Gsatt("TOC1","COLO",5);
1778 gMC->Gsatt("TESB","SEEN",0);
1779 gMC->Gsatt("THVM","SEEN",1);
1780 gMC->Gsatt("THVM","COLO",11);
1781 gMC->Gsatt("TPSR","SEEN",0);
1782 gMC->Gsatt("THVL","SEEN",0);
1783 gMC->Gsatt("THVC","SEEN",0);
1784 gMC->Gsatt("THVE","SEEN",0);
1785 gMC->Gsatt("THVR","SEEN",0);
1787 gMC->Gdopt("hide", "on");
1788 gMC->Gdopt("shad", "on");
1789 gMC->Gsatt("*", "fill", 7);
1790 gMC->SetClipBox(".");
1791 gMC->SetClipBox("TPMW",-300,300,-300,300,254.,270.);
1792 gMC->SetClipBox("TESR",-300,300,-300,300,254.,270.);
1793 gMC->SetClipBox("TSSW",-300,300,-300,300,283.,284.);
1794 gMC->SetClipBox("TSWC",-300,300,-300,300,283.,284.);
1795 gMC->SetClipBox("*", 0, 300, -300, 300, -290, 290);
1796 gMC->DefaultRange();
1797 gMC->Gdraw("alic", 40, 30, 0, 12, 9.5, .025, .025);
1798 gMC->Gdhead(1111, "Time Projection Chamber");
1799 gMC->Gdman(18, 4, "MAN");
1800 gMC->Gdopt("hide","off");
1803 //_____________________________________________________________________________
1804 void AliTPCv0::Init()
1807 // Initialise Time Projection Chamber version 0
1809 printf("TPC version 0 initialized\n");
1812 //_____________________________________________________________________________
1813 void AliTPCv0::StepManager()
1816 // Procedure called at each step in the TPC