]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITSv1.cxx
MevSim interfaced through AliGenerator, first commit (Sylwester Radomski et al.)
[u/mrichter/AliRoot.git] / ITS / AliITSv1.cxx
CommitLineData
4c039060 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/*
17$Log$
a8a6107b 18Revision 1.22 2000/10/05 20:49:59 nilsen
19Now using root generated streamers.
20
f7f0c278 21Revision 1.14.2.9 2000/10/05 07:49:27 nilsen
22Removed hit generation from step manager.
23
24Revision 1.14.2.8 2000/07/31 13:50:37 barbera
25Updated from the release
d8331d3f 26
94de3818 27Revision 1.19 2000/07/10 16:07:19 fca
28Release version of ITS code
29
b6668dd3 30Revision 1.14.2.2 2000/05/19 10:09:21 nilsen
31fix for bug with HP and Sun unix + fix for event display in ITS-working branch
c9a71be1 32
56d6a1ef 33Revision 1.14.2.1 2000/03/04 23:45:19 nilsen
34Fixed up the comments/documentation.
35
36Revision 1.14 1999/11/25 06:52:56 fca
37Correct value of drca
38
c4a5a168 39Revision 1.13.2.1 1999/11/25 06:52:21 fca
40Correct value of drca
41
42Revision 1.13 1999/10/27 11:16:26 fca
43Correction of problem in geometry
44
7963222e 45Revision 1.12 1999/10/22 08:25:25 fca
46remove double definition of destructors
47
1e3deba7 48Revision 1.11 1999/10/22 08:16:49 fca
49Correct destructors, thanks to I.Hrivnacova
50
5b8cc8df 51Revision 1.10 1999/10/06 19:56:50 fca
52Add destructor
53
1c1b73f8 54Revision 1.9 1999/10/05 08:05:09 fca
55Minor corrections for uninitialised variables.
56
593d2ea1 57Revision 1.8 1999/09/29 09:24:20 fca
58Introduction of the Copyright and cvs Log
59
4c039060 60*/
61
fe4da5cc 62///////////////////////////////////////////////////////////////////////////////
63// //
64// Inner Traking System version 1 //
58005f18 65// This class contains the base procedures for the Inner Tracking System //
fe4da5cc 66// //
58005f18 67// Authors: R. Barbera, A. Morsch.
68// version 1.
69// Created 1998.
70//
71// NOTE: THIS IS THE COARSE pre.TDR geometry of the ITS. THIS WILL NOT WORK
72// with the geometry or module classes or any analysis classes. You are
73// strongly encouraged to uses AliITSv5.
fe4da5cc 74// //
75///////////////////////////////////////////////////////////////////////////////
76
77#include <TMath.h>
78#include <TRandom.h>
79#include <TVector.h>
c9a71be1 80#include <TGeometry.h>
81#include <TNode.h>
82#include <TTUBE.h>
b6668dd3 83#include <TFile.h> // only required for Tracking function?
84#include <TCanvas.h>
85#include <TObjArray.h>
f7f0c278 86#include <TObjString.h>
b6668dd3 87#include <TClonesArray.h>
88
c9a71be1 89
90#include "AliMC.h"
91#include "AliConst.h"
f7f0c278 92#include "AliRun.h"
93#include "AliMagF.h"
c9a71be1 94
58005f18 95#include "AliITShit.h"
fe4da5cc 96#include "AliITSv1.h"
fe4da5cc 97
fe4da5cc 98
99ClassImp(AliITSv1)
100
101//_____________________________________________________________________________
e8189707 102AliITSv1::AliITSv1() {
56d6a1ef 103////////////////////////////////////////////////////////////////////////
104// Standard default constructor for the ITS version 1.
105////////////////////////////////////////////////////////////////////////
e8189707 106
f7f0c278 107 fIdN = 0;
108 fIdName = 0;
109 fIdSens = 0;
110 fMajorVersion = 1;
111 fMinorVersion = -1;
fe4da5cc 112}
fe4da5cc 113//_____________________________________________________________________________
56d6a1ef 114AliITSv1::AliITSv1(const char *name, const char *title) : AliITS(name, title){
115////////////////////////////////////////////////////////////////////////
116// Standard constructor for the ITS version 1.
117////////////////////////////////////////////////////////////////////////
e8189707 118
f7f0c278 119 fIdN = 6;
120/*
121// TObjArray of TObjStrings
122 fIdName = new TObjArray(fIdN);
123 fIdName->AddAt(new TObjString("ITS1"),0);
124 fIdName->AddAt(new TObjString("ITS2"),1);
125 fIdName->AddAt(new TObjString("ITS3"),2);
126 fIdName->AddAt(new TObjString("ITS4"),3);
127 fIdName->AddAt(new TObjString("ITS5"),4);
128 fIdName->AddAt(new TObjString("ITS6"),5);
129*/
130// Array of TStrings.
131 fIdName = new TString[fIdN];
132 fIdName[0] = "ITS1";
133 fIdName[1] = "ITS2";
134 fIdName[2] = "ITS3";
135 fIdName[3] = "ITS4";
136 fIdName[4] = "ITS5";
137 fIdName[5] = "ITS6";
138 fIdSens = new Int_t[fIdN];
139 for (Int_t i=0;i<fIdN;i++) fIdSens[i] = 0;
140 fMajorVersion = 1;
141 fMinorVersion = 1;
e8189707 142
fe4da5cc 143}
b6668dd3 144//____________________________________________________________________________
145AliITSv1::AliITSv1(const AliITSv1 &source){
146////////////////////////////////////////////////////////////////////////
147// Copy Constructor for ITS version 1.
148////////////////////////////////////////////////////////////////////////
149 if(&source == this) return;
e8189707 150 printf("Not allowed to copy AliITSv1\n");
481937a6 151 return;
b6668dd3 152}
153//_____________________________________________________________________________
154AliITSv1& AliITSv1::operator=(const AliITSv1 &source){
155////////////////////////////////////////////////////////////////////////
156// Assignment operator for the ITS version 1.
157////////////////////////////////////////////////////////////////////////
481937a6 158 if(&source == this) return *this;
e8189707 159 printf("Not allowed to copy AliITSv1\n");
481937a6 160 return *this;
b6668dd3 161}
1c1b73f8 162//_____________________________________________________________________________
163AliITSv1::~AliITSv1() {
56d6a1ef 164////////////////////////////////////////////////////////////////////////
165// Standard destructor for the ITS version 1.
166////////////////////////////////////////////////////////////////////////
e8189707 167}
168
169//__________________________________________________________________________
c9a71be1 170void AliITSv1::BuildGeometry(){
b6668dd3 171////////////////////////////////////////////////////////////////////////
172// Geometry builder for the ITS version 1.
173////////////////////////////////////////////////////////////////////////
174 TNode *node, *top;
e8189707 175 const int kColorITS=kYellow;
c9a71be1 176 //
b6668dd3 177 top = gAlice->GetGeometry()->GetNode("alice");
c9a71be1 178
179 new TTUBE("S_layer1","Layer1 of ITS","void",3.9,3.9+0.05475,12.25);
b6668dd3 180 top->cd();
181 node = new TNode("Layer1","Layer1","S_layer1",0,0,0,"");
182 node->SetLineColor(kColorITS);
183 fNodes->Add(node);
c9a71be1 184
185 new TTUBE("S_layer2","Layer2 of ITS","void",7.6,7.6+0.05475,16.3);
b6668dd3 186 top->cd();
187 node = new TNode("Layer2","Layer2","S_layer2",0,0,0,"");
188 node->SetLineColor(kColorITS);
189 fNodes->Add(node);
c9a71be1 190
191 new TTUBE("S_layer3","Layer3 of ITS","void",14,14+0.05288,21.1);
b6668dd3 192 top->cd();
193 node = new TNode("Layer3","Layer3","S_layer3",0,0,0,"");
194 node->SetLineColor(kColorITS);
195 fNodes->Add(node);
c9a71be1 196
197 new TTUBE("S_layer4","Layer4 of ITS","void",24,24+0.05288,29.6);
b6668dd3 198 top->cd();
199 node = new TNode("Layer4","Layer4","S_layer4",0,0,0,"");
200 node->SetLineColor(kColorITS);
201 fNodes->Add(node);
c9a71be1 202
203 new TTUBE("S_layer5","Layer5 of ITS","void",40,40+0.05382,45.1);
b6668dd3 204 top->cd();
205 node = new TNode("Layer5","Layer5","S_layer5",0,0,0,"");
206 node->SetLineColor(kColorITS);
207 fNodes->Add(node);
c9a71be1 208
209 new TTUBE("S_layer6","Layer6 of ITS","void",45,45+0.05382,50.4);
b6668dd3 210 top->cd();
211 node = new TNode("Layer6","Layer6","S_layer6",0,0,0,"");
212 node->SetLineColor(kColorITS);
213 fNodes->Add(node);
c9a71be1 214}
fe4da5cc 215//_____________________________________________________________________________
56d6a1ef 216void AliITSv1::CreateGeometry(){
217////////////////////////////////////////////////////////////////////////
218// This routine defines and Creates the geometry for version 1 of the ITS.
219////////////////////////////////////////////////////////////////////////
fe4da5cc 220
221 Float_t drcer[6] = { 0.,0.,.08,.08,0.,0. }; //CERAMICS THICKNESS
222 Float_t drepx[6] = { 0.,0.,0.,0.,.5357,.5357 }; //EPOXY THICKNESS
223 Float_t drpla[6] = { 0.,0.,0.,0.,.1786,.1786 }; //PLASTIC THICKNESS
224 Float_t dzb[6] = { 0.,0.,15.,15.,4.,4. }; //LENGTH OF BOXES
225 Float_t dphi[6] = { 72.,72.,72.,72.,50.6,45. }; //COVERED PHI-RANGE FOR LAYERS 1-6
226 Float_t rl[6] = { 3.9,7.6,14.,24.,40.,45. }; //SILICON LAYERS INNER RADIUS
227 Float_t drl[6] = { .755,.755,.809,.809,.7,.7 }; //THICKNESS OF LAYERS (in % radiation length)
228 Float_t dzl[6] = { 12.67,16.91,20.85,29.15,45.11,50.975 };//HALF LENGTH OF LAYERS
229 Float_t drpcb[6] = { 0.,0.,.06,.06,0.,0. }; //PCB THICKNESS
230 Float_t drcu[6] = { 0.,0.,.0504,.0504,.0357,.0357 }; //COPPER THICKNESS
231 Float_t drsi[6] = { 0.,0.,.006,.006,.3571,.3571 }; //SILICON THICKNESS
232
c4a5a168 233 Float_t drca, dzfc;
fe4da5cc 234 Int_t i, nsec;
b6668dd3 235 Float_t rend, drcatpc, dzco, zend, dits[3], rlim, drsu, zmax;
fe4da5cc 236 Float_t zpos, dzco1, dzco2;
237 Float_t drcac[6], acone, dphii;
238 Float_t pcits[15], xltpc;
239 Float_t rzcone, rstep, r0, z0, acable, fp, dz, zi, ri;
240 Int_t idrotm[399];
241 Float_t dgh[15];
242
ad51aeb0 243 Int_t *idtmed = fIdtmed->GetArray()-199;
fe4da5cc 244
245 // CONVERT INTO CM (RL(SI)=9.36 CM)
e8189707 246 for (i = 0; i < 6; ++i) {
fe4da5cc 247 drl[i] = drl[i] / 100. * 9.36;
248 }
249
250 // SUPPORT ENDPLANE THICKNESS
251 drsu = 2.*0.06+1./20; // 1./20. is 1 cm of honeycomb (1/20 carbon density);
252
253 // CONE BELOW TPC
254
b6668dd3 255 drcatpc = 1.2/4.;
fe4da5cc 256
257 // CABLE THICKNESS (CONICAL CABLES CONNECTING THE LAYERS)
258
c4a5a168 259 drca = 0.2;
fe4da5cc 260
261 // ITS CONE ANGLE
262
263 acone = 45.;
264 acone *= kDegrad;
265
266 // CONE RADIUS AT 1ST LAYER
267
268 rzcone = 30.;
269
270 // FIELD CAGE HALF LENGTH
271
272 dzfc = 64.5;
273 rlim = 48.;
274 zmax = 80.;
275 xltpc = 275.;
276
277
278 // PARAMETERS FOR SMALL (1/2) ITS
f7f0c278 279/*
e8189707 280 for (i = 0; i < 6; ++i) {
fe4da5cc 281 dzl[i] /= 2.;
282 dzb[i] /= 2.;
283 }
284 drca /= 2.;
285 acone /= 2.;
b6668dd3 286 drcatpc /= 2.;
fe4da5cc 287 rzcone /= 2.;
288 dzfc /= 2.;
289 zmax /= 2.;
290 xltpc /= 2.;
f7f0c278 291*/
292 acable = 15.;
fe4da5cc 293
294
295 // EQUAL DISTRIBUTION INTO THE 6 LAYERS
b6668dd3 296 rstep = drcatpc / 6.;
e8189707 297 for (i = 0; i < 6; ++i) {
fe4da5cc 298 drcac[i] = (i+1) * rstep;
299 }
300
301 // NUMBER OF PHI SECTORS
302
303 nsec = 5;
304
305 // PACK IN PHI AS MUCH AS POSSIBLE
306 // NOW PACK USING THICKNESS
307
e8189707 308 for (i = 0; i < 6; ++i) {
fe4da5cc 309
310// PACKING FACTOR
311 fp = rl[5] / rl[i];
312
313 // PHI-PACKING NOT SUFFICIENT ?
314
315 if (dphi[i]/45 < fp) {
316 drcac[i] = drcac[i] * fp * 45/dphi[i];
317 }
318 }
319
320
321 // --- Define ghost volume containing the six layers and fill it with air
322
323 dgh[0] = 3.5;
324 dgh[1] = 50.;
325 dgh[2] = zmax;
cfce8870 326 gMC->Gsvolu("ITSV", "TUBE", idtmed[275], dgh, 3);
fe4da5cc 327
328 // --- Place the ghost volume in its mother volume (ALIC) and make it
329 // invisible
330
cfce8870 331 gMC->Gspos("ITSV", 1, "ALIC", 0., 0., 0., 0, "ONLY");
332 gMC->Gsatt("ITSV", "SEEN", 0);
fe4da5cc 333
334 // ITS LAYERS (SILICON)
335
336 dits[0] = rl[0];
337 dits[1] = rl[0] + drl[0];
338 dits[2] = dzl[0];
cfce8870 339 gMC->Gsvolu("ITS1", "TUBE", idtmed[199], dits, 3);
340 gMC->Gspos("ITS1", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 341
342 dits[0] = rl[1];
343 dits[1] = rl[1] + drl[1];
344 dits[2] = dzl[1];
cfce8870 345 gMC->Gsvolu("ITS2", "TUBE", idtmed[199], dits, 3);
346 gMC->Gspos("ITS2", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 347
348 dits[0] = rl[2];
349 dits[1] = rl[2] + drl[2];
350 dits[2] = dzl[2];
cfce8870 351 gMC->Gsvolu("ITS3", "TUBE", idtmed[224], dits, 3);
352 gMC->Gspos("ITS3", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 353
354 dits[0] = rl[3];
355 dits[1] = rl[3] + drl[3];
356 dits[2] = dzl[3];
cfce8870 357 gMC->Gsvolu("ITS4", "TUBE", idtmed[224], dits, 3);
358 gMC->Gspos("ITS4", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 359
360 dits[0] = rl[4];
361 dits[1] = rl[4] + drl[4];
362 dits[2] = dzl[4];
cfce8870 363 gMC->Gsvolu("ITS5", "TUBE", idtmed[249], dits, 3);
364 gMC->Gspos("ITS5", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 365
366 dits[0] = rl[5];
367 dits[1] = rl[5] + drl[5];
368 dits[2] = dzl[5];
cfce8870 369 gMC->Gsvolu("ITS6", "TUBE", idtmed[249], dits, 3);
370 gMC->Gspos("ITS6", 1, "ITSV", 0., 0., 0., 0, "ONLY");
fe4da5cc 371
372 // ELECTRONICS BOXES
373
374 // PCB (layer #3 and #4)
375
cfce8870 376 gMC->Gsvolu("IPCB", "TUBE", idtmed[233], dits, 0);
e8189707 377 for (i = 2; i < 4; ++i) {
fe4da5cc 378 dits[0] = rl[i];
379 dits[1] = dits[0] + drpcb[i];
380 dits[2] = dzb[i] / 2.;
381 zpos = dzl[i] + dits[2];
cfce8870 382 gMC->Gsposp("IPCB", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
383 gMC->Gsposp("IPCB", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 384 }
385
386 // COPPER (layer #3 and #4)
387
cfce8870 388 gMC->Gsvolu("ICO2", "TUBE", idtmed[234], dits, 0);
e8189707 389 for (i = 2; i < 4; ++i) {
fe4da5cc 390 dits[0] = rl[i] + drpcb[i];
391 dits[1] = dits[0] + drcu[i];
392 dits[2] = dzb[i] / 2.;
393 zpos = dzl[i] + dits[2];
cfce8870 394 gMC->Gsposp("ICO2", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
395 gMC->Gsposp("ICO2", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 396 }
397
398 // CERAMICS (layer #3 and #4)
399
cfce8870 400 gMC->Gsvolu("ICER", "TUBE", idtmed[235], dits, 0);
e8189707 401 for (i = 2; i < 4; ++i) {
fe4da5cc 402 dits[0] = rl[i] + drpcb[i] + drcu[i];
403 dits[1] = dits[0] + drcer[i];
404 dits[2] = dzb[i] / 2.;
405 zpos = dzl[i] + dits[2];
cfce8870 406 gMC->Gsposp("ICER", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
407 gMC->Gsposp("ICER", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 408 }
409
410 // SILICON (layer #3 and #4)
411
cfce8870 412 gMC->Gsvolu("ISI2", "TUBE", idtmed[226], dits, 0);
e8189707 413 for (i = 2; i < 4; ++i) {
fe4da5cc 414 dits[0] = rl[i] + drpcb[i] + drcu[i] + drcer[i];
415 dits[1] = dits[0] + drsi[i];
416 dits[2] = dzb[i] / 2.;
417 zpos = dzl[i] + dits[2];
cfce8870 418 gMC->Gsposp("ISI2", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
419 gMC->Gsposp("ISI2", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 420 }
421
422 // PLASTIC (G10FR4) (layer #5 and #6)
423
cfce8870 424 gMC->Gsvolu("IPLA", "TUBE", idtmed[262], dits, 0);
e8189707 425 for (i = 4; i < 6; ++i) {
fe4da5cc 426 dits[0] = rl[i];
427 dits[1] = dits[0] + drpla[i];
428 dits[2] = dzb[i] / 2.;
429 zpos = dzl[i] + dits[2];
cfce8870 430 gMC->Gsposp("IPLA", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
431 gMC->Gsposp("IPLA", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 432 }
433
434 // COPPER (layer #5 and #6)
435
cfce8870 436 gMC->Gsvolu("ICO3", "TUBE", idtmed[259], dits, 0);
e8189707 437 for (i = 4; i < 6; ++i) {
fe4da5cc 438 dits[0] = rl[i] + drpla[i];
439 dits[1] = dits[0] + drcu[i];
440 dits[2] = dzb[i] / 2.;
441 zpos = dzl[i] + dits[2];
cfce8870 442 gMC->Gsposp("ICO3", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
443 gMC->Gsposp("ICO3", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 444 }
445
446 // EPOXY (layer #5 and #6)
447
cfce8870 448 gMC->Gsvolu("IEPX", "TUBE", idtmed[262], dits, 0);
e8189707 449 for (i = 4; i < 6; ++i) {
fe4da5cc 450 dits[0] = rl[i] + drpla[i] + drcu[i];
451 dits[1] = dits[0] + drepx[i];
452 dits[2] = dzb[i] / 2.;
453 zpos = dzl[i] + dits[2];
cfce8870 454 gMC->Gsposp("IEPX", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
455 gMC->Gsposp("IEPX", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 456 }
457
458 // SILICON (layer #5 and #6)
459
cfce8870 460 gMC->Gsvolu("ISI3", "TUBE", idtmed[251], dits, 0);
e8189707 461 for (i = 4; i < 6; ++i) {
fe4da5cc 462 dits[0] = rl[i] + drpla[i] + drcu[i] + drepx[i];
463 dits[1] = dits[0] + drsi[i];
464 dits[2] = dzb[i] / 2.;
465 zpos = dzl[i] + dits[2];
cfce8870 466 gMC->Gsposp("ISI3", i-1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
467 gMC->Gsposp("ISI3", i+1, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 468 }
469
470 // SUPPORT
471
cfce8870 472 gMC->Gsvolu("ISUP", "TUBE", idtmed[274], dits, 0);
e8189707 473 for (i = 0; i < 6; ++i) {
fe4da5cc 474 dits[0] = rl[i];
7963222e 475 if (i < 5) dits[1] = rl[i+1];
fe4da5cc 476 else dits[1] = rlim;
477 dits[2] = drsu / 2.;
478 zpos = dzl[i] + dzb[i] + dits[2];
cfce8870 479 gMC->Gsposp("ISUP", i+1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
480 gMC->Gsposp("ISUP", i+7, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 481 }
482
483 // CABLES (HORIZONTAL)
484
cfce8870 485 gMC->Gsvolu("ICHO", "TUBE", idtmed[278], dits, 0);
e8189707 486 for (i = 0; i < 6; ++i) {
fe4da5cc 487 dits[0] = rl[i];
488 dits[1] = dits[0] + drca;
489 dits[2] = (rzcone + TMath::Tan(acone) * (rl[i] - rl[0]) - (dzl[i]+ dzb[i] + drsu)) / 2.;
490 zpos = dzl[i - 1] + dzb[i] + drsu + dits[2];
cfce8870 491 gMC->Gsposp("ICHO", i+1, "ITSV", 0., 0., zpos, 0, "ONLY", dits, 3);
492 gMC->Gsposp("ICHO", i+7, "ITSV", 0., 0.,-zpos, 0, "ONLY", dits, 3);
fe4da5cc 493 }
494 // DEFINE A CONICAL GHOST VOLUME FOR THE PHI SEGMENTATION
495 pcits[0] = 0.;
496 pcits[1] = 360.;
497 pcits[2] = 2.;
498 pcits[3] = rzcone;
499 pcits[4] = 3.5;
500 pcits[5] = rl[0];
501 pcits[6] = pcits[3] + TMath::Tan(acone) * (rlim - rl[0]);
502 pcits[7] = rlim - rl[0] + 3.5;
503 pcits[8] = rlim;
cfce8870 504 gMC->Gsvolu("ICMO", "PCON", idtmed[275], pcits, 9);
fe4da5cc 505 AliMatrix(idrotm[200], 90., 0., 90., 90., 180., 0.);
cfce8870 506 gMC->Gspos("ICMO", 1, "ITSV", 0., 0., 0., 0, "ONLY");
507 gMC->Gspos("ICMO", 2, "ITSV", 0., 0., 0., idrotm[200], "ONLY");
fe4da5cc 508
509 // DIVIDE INTO NSEC PHI-SECTIONS
510
cfce8870 511 gMC->Gsdvn("ICMD", "ICMO", nsec, 2);
512 gMC->Gsatt("ICMO", "SEEN", 0);
513 gMC->Gsatt("ICMD", "SEEN", 0);
fe4da5cc 514
515 // CONICAL CABLES
516
517 pcits[2] = 2.;
cfce8870 518 gMC->Gsvolu("ICCO", "PCON", idtmed[278], pcits, 0);
e8189707 519 for (i = 1; i < 6; ++i) {
fe4da5cc 520 pcits[0] = -dphi[i] / 2.;
521 pcits[1] = dphi[i];
522 if (i < 5) {
523 dzco = TMath::Tan(acone) * (rl[i+1] - rl[i]);
524 } else {
525 dzco1 = zmax - (rzcone + TMath::Tan(acone) * (rl[5] - rl[0])) -2.;
526 dzco2 = (rlim - rl[5]) * TMath::Tan(acone);
527 if (rl[5] + dzco1 / TMath::Tan(acone) < rlim) {
528 dzco = dzco1;
529 } else {
530 dzco = dzco2;
531 }
532 }
533 pcits[3] = rzcone + TMath::Tan(acone) * (rl[i] - rl[0]);
534 pcits[4] = rl[i] - drcac[i] / TMath::Sin(acone);
535 pcits[5] = rl[i];
536 pcits[6] = pcits[3] + dzco;
537 pcits[7] = rl[i] + dzco / TMath::Tan(acone) - drcac[i] / TMath::Sin(acone);
538 pcits[8] = rl[i] + dzco / TMath::Tan(acone);
539
cfce8870 540 gMC->Gsposp("ICCO", i, "ICMD", 0., 0., 0., 0, "ONLY", pcits, 9);
fe4da5cc 541
542 }
543 zend = pcits[6];
544 rend = pcits[8];
545
546 // CONICAL CABLES BELOW TPC
547
548 // DEFINE A CONICAL GHOST VOLUME FOR THE PHI SEGMENTATION
549 pcits[0] = 0.;
550 pcits[1] = 360.;
551 pcits[2] = 2.;
552 pcits[3] = zend;
553 pcits[5] = rend;
b6668dd3 554 pcits[4] = pcits[5] - drcatpc;
fe4da5cc 555 pcits[6] = xltpc;
556 pcits[8] = pcits[4] + (pcits[6] - pcits[3]) * TMath::Tan(acable * kDegrad);
b6668dd3 557 pcits[7] = pcits[8] - drcatpc;
fe4da5cc 558 AliMatrix(idrotm[200], 90., 0., 90., 90., 180., 0.);
cfce8870 559 gMC->Gsvolu("ICCM", "PCON", idtmed[275], pcits, 9);
560 gMC->Gspos("ICCM", 1, "ALIC", 0., 0., 0., 0, "ONLY");
561 gMC->Gspos("ICCM", 2, "ALIC", 0., 0., 0., idrotm[200], "ONLY");
562 gMC->Gsdvn("ITMD", "ICCM", nsec, 2);
563 gMC->Gsatt("ITMD", "SEEN", 0);
564 gMC->Gsatt("ICCM", "SEEN", 0);
fe4da5cc 565
566 // NOW PLACE SEGMENTS WITH DECREASING PHI SEGMENTS INTO THE
567 // GHOST-VOLUME
568
569 pcits[2] = 2.;
cfce8870 570 gMC->Gsvolu("ITTT", "PCON", idtmed[278], pcits, 0);
fe4da5cc 571 r0 = rend;
572 z0 = zend;
573 dz = (xltpc - zend) / 9.;
e8189707 574 for (i = 0; i < 9; ++i) {
fe4da5cc 575 zi = z0 + i*dz + dz / 2.;
576 ri = r0 + (zi - z0) * TMath::Tan(acable * kDegrad);
577 dphii = dphi[5] * r0 / ri;
578 pcits[0] = -dphii / 2.;
579 pcits[1] = dphii;
580 pcits[3] = zi - dz / 2.;
581 pcits[5] = r0 + (pcits[3] - z0) * TMath::Tan(acable * kDegrad);
b6668dd3 582 pcits[4] = pcits[5] - drcatpc;
fe4da5cc 583 pcits[6] = zi + dz / 2.;
584 pcits[8] = r0 + (pcits[6] - z0) * TMath::Tan(acable * kDegrad);
b6668dd3 585 pcits[7] = pcits[8] - drcatpc;
fe4da5cc 586
cfce8870 587 gMC->Gsposp("ITTT", i+1, "ITMD", 0., 0., 0., 0, "ONLY", pcits, 9);
fe4da5cc 588 }
589
590 // --- Outputs the geometry tree in the EUCLID/CAD format
591
592 if (fEuclidOut) {
cfce8870 593 gMC->WriteEuclid("ITSgeometry", "ITSV", 1, 5);
fe4da5cc 594 }
595}
fe4da5cc 596//_____________________________________________________________________________
56d6a1ef 597void AliITSv1::CreateMaterials(){
598////////////////////////////////////////////////////////////////////////
c9a71be1 599 //
600 // Create ITS materials
601 // This function defines the default materials used in the Geant
b6668dd3 602 // Monte Carlo simulations for the geometries AliITSv1 and AliITSv3.
603 // In general it is automatically replaced by
c9a71be1 604 // the CreatMaterials routine defined in AliITSv?. Should the function
605 // CreateMaterials not exist for the geometry version you are using this
606 // one is used. See the definition found in AliITSv5 or the other routine
607 // for a complete definition.
608 //
609 // Water H2O
610 Float_t awat[2] = { 1.00794,15.9994 };
611 Float_t zwat[2] = { 1.,8. };
612 Float_t wwat[2] = { 2.,1. };
613 Float_t denswat = 1.;
614 // Freon
615 Float_t afre[2] = { 12.011,18.9984032 };
616 Float_t zfre[2] = { 6.,9. };
617 Float_t wfre[2] = { 5.,12. };
618 Float_t densfre = 1.5;
619 // Ceramics
620 // 94.4% Al2O3 , 2.8% SiO2 , 2.3% MnO , 0.5% Cr2O3
621 Float_t acer[5] = { 26.981539,15.9994,28.0855,54.93805,51.9961 };
622 Float_t zcer[5] = { 13.,8.,14.,25., 24. };
623 Float_t wcer[5] = { .49976,1.01233,.01307, .01782,.00342 };
624 Float_t denscer = 3.6;
625 //
626 // 60% SiO2 , 40% G10FR4
627 // PC board
628 Float_t apcb[3] = { 28.0855,15.9994,17.749 };
629 Float_t zpcb[3] = { 14.,8.,8.875 };
630 Float_t wpcb[3] = { .28,.32,.4 };
631 Float_t denspcb = 1.8;
632 // POLYETHYL
633 Float_t apoly[2] = { 12.01,1. };
634 Float_t zpoly[2] = { 6.,1. };
635 Float_t wpoly[2] = { .33,.67 };
636 // SERVICES
637 Float_t zserv[4] = { 1.,6.,26.,29. };
638 Float_t aserv[4] = { 1.,12.,55.8,63.5 };
639 Float_t wserv[4] = { .014,.086,.42,.48 };
640
b6668dd3 641 Int_t isxfld = gAlice->Field()->Integ();
642 Float_t sxmgmx = gAlice->Field()->Max();
c9a71be1 643
644
645 // --- Define the various materials for GEANT ---
646
647 // 200-224 --> Silicon Pixel Detectors (detectors, chips, buses, cooling,..)
648
649 AliMaterial(0, "SPD Si$", 28.0855, 14., 2.33, 9.36, 999);
650 AliMaterial(1, "SPD Si chip$", 28.0855, 14., 2.33, 9.36, 999);
651 AliMaterial(2, "SPD Si bus$", 28.0855, 14., 2.33, 9.36, 999);
652 AliMaterial(3, "SPD C$", 12.011, 6., 2.265,18.8, 999);
653 // v. dens
654 AliMaterial(4, "SPD Air$", 14.61, 7.3, .001205, 30423., 999);
655 AliMaterial(5, "SPD Vacuum$", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
656 AliMaterial(6, "SPD Al$", 26.981539, 13., 2.6989, 8.9, 999);
657 AliMixture( 7, "SPD Water $", awat, zwat, denswat, -2, wwat);
658 AliMixture( 8, "SPD Freon$", afre, zfre, densfre, -2, wfre);
659 // **
b6668dd3 660 AliMedium(0, "SPD Si$", 0, 1,isxfld,sxmgmx, 10., .01, .1, .003, .003);
661 AliMedium(1, "SPD Si chip$", 1, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
662 AliMedium(2, "SPD Si bus$", 2, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
663 AliMedium(3, "SPD C$", 3, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
664 AliMedium(4, "SPD Air$", 4, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
665 AliMedium(5, "SPD Vacuum$", 5, 0,isxfld,sxmgmx, 10.,1.00, .1, .100,10.00);
666 AliMedium(6, "SPD Al$", 6, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
667 AliMedium(7, "SPD Water $", 7, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
668 AliMedium(8, "SPD Freon$", 8, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
c9a71be1 669
670 // 225-249 --> Silicon Drift Detectors (detectors, chips, buses, cooling,..)
671
672 AliMaterial(25, "SDD Si$", 28.0855, 14., 2.33, 9.36, 999);
673 AliMaterial(26, "SDD Si chip$", 28.0855, 14., 2.33, 9.36, 999);
674 AliMaterial(27, "SDD Si bus$", 28.0855, 14., 2.33, 9.36, 999);
675 AliMaterial(28, "SDD C$", 12.011, 6., 2.265,18.8, 999);
676 // v. dens
677 AliMaterial(29, "SDD Air$", 14.61, 7.3, .001205, 30423., 999);
678 AliMaterial(30, "SDD Vacuum$", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
679 AliMaterial(31, "SDD Al$", 26.981539, 13., 2.6989, 8.9, 999);
680 // After a call with ratios by number (negative number of elements),
681 // the ratio array is changed to the ratio by weight, so all successive
682 // calls with the same array must specify the number of elements as
683 // positive
684 AliMixture(32, "SDD Water $", awat, zwat, denswat, 2, wwat);
685 // After a call with ratios by number (negative number of elements),
686 // the ratio array is changed to the ratio by weight, so all successive
687 // calls with the same array must specify the number of elements as
688 // positive
689 AliMixture( 33, "SDD Freon$", afre, zfre, densfre, 2, wfre);
690 AliMixture( 34, "SDD PCB$", apcb, zpcb, denspcb, 3, wpcb);
691 AliMaterial(35, "SDD Copper$", 63.546, 29., 8.96, 1.43, 999);
692 AliMixture( 36, "SDD Ceramics$", acer, zcer, denscer, -5, wcer);
693 AliMaterial(37, "SDD Kapton$", 12.011, 6., 1.3, 31.27, 999);
694 // **
695 // check A and Z
b6668dd3 696 AliMedium(25, "SDD Si$", 25, 1,isxfld,sxmgmx, 10., .01, .1, .003, .003);
697 AliMedium(26, "SDD Si chip$", 26, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
698 AliMedium(27, "SDD Si bus$", 27, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
699 AliMedium(28, "SDD C$", 28, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
700 AliMedium(29, "SDD Air$", 29, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
701 AliMedium(30, "SDD Vacuum$", 30, 0,isxfld,sxmgmx, 10.,1.00, .1, .100,10.00);
702 AliMedium(31, "SDD Al$", 31, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
703 AliMedium(32, "SDD Water $", 32, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
704 AliMedium(33, "SDD Freon$", 33, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
705 AliMedium(34, "SDD PCB$", 34, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
706 AliMedium(35, "SDD Copper$", 35, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
707 AliMedium(36, "SDD Ceramics$",36, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
708 AliMedium(37, "SDD Kapton$", 37, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
c9a71be1 709
710 // 250-274 --> Silicon Strip Detectors (detectors, chips, buses, cooling,..)
711
712 AliMaterial(50, "SSD Si$", 28.0855, 14., 2.33, 9.36, 999.);
713 AliMaterial(51, "SSD Si chip$", 28.0855, 14., 2.33, 9.36, 999.);
714 AliMaterial(52, "SSD Si bus$", 28.0855, 14., 2.33, 9.36, 999.);
715 AliMaterial(53, "SSD C$", 12.011, 6., 2.265,18.8, 999.);
716 // v. dens
717 AliMaterial(54, "SSD Air$", 14.61, 7.3, .001205, 30423., 999);
718 AliMaterial(55, "SSD Vacuum$", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
719 AliMaterial(56, "SSD Al$", 26.981539, 13., 2.6989, 8.9, 999);
720 // After a call with ratios by number (negative number of elements),
721 // the ratio array is changed to the ratio by weight, so all successive
722 // calls with the same array must specify the number of elements as
723 // positive
724 AliMixture(57, "SSD Water $", awat, zwat, denswat, 2, wwat);
725 // After a call with ratios by number (negative number of elements),
726 // the ratio array is changed to the ratio by weight, so all successive
727 // calls with the same array must specify the number of elements as
728 // positive
729 AliMixture(58, "SSD Freon$", afre, zfre, densfre, 2, wfre);
730 AliMixture(59, "SSD PCB$", apcb, zpcb, denspcb, 3, wpcb);
731 AliMaterial(60, "SSD Copper$", 63.546, 29., 8.96, 1.43, 999.);
732 // After a call with ratios by number (negative number of elements),
733 // the ratio array is changed to the ratio by weight, so all successive
734 // calls with the same array must specify the number of elements as
735 // positive
736 AliMixture( 61, "SSD Ceramics$", acer, zcer, denscer, 5, wcer);
737 AliMaterial(62, "SSD Kapton$", 12.011, 6., 1.3, 31.27, 999.);
738 // check A and Z
739 AliMaterial(63, "SDD G10FR4$", 17.749, 8.875, 1.8, 21.822, 999.);
740 // **
b6668dd3 741 AliMedium(50, "SSD Si$", 50, 1,isxfld,sxmgmx, 10., .01, .1, .003, .003);
742 AliMedium(51, "SSD Si chip$", 51, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
743 AliMedium(52, "SSD Si bus$", 52, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
744 AliMedium(53, "SSD C$", 53, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
745 AliMedium(54, "SSD Air$", 54, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
746 AliMedium(55, "SSD Vacuum$", 55, 0,isxfld,sxmgmx, 10.,1.00, .1, .100,10.00);
747 AliMedium(56, "SSD Al$", 56, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
748 AliMedium(57, "SSD Water $", 57, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
749 AliMedium(58, "SSD Freon$", 58, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
750 AliMedium(59, "SSD PCB$", 59, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
751 AliMedium(60, "SSD Copper$", 60, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
752 AliMedium(61, "SSD Ceramics$",61, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
753 AliMedium(62, "SSD Kapton$", 62, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
754 AliMedium(63, "SSD G10FR4$", 63, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
c9a71be1 755
756 // 275-299 --> General (end-caps, frames, cooling, cables, etc.)
757
758 AliMaterial(75, "GEN C$", 12.011, 6., 2.265, 18.8, 999.);
759 // verify density
760 AliMaterial(76, "GEN Air$", 14.61, 7.3, .001205, 30423., 999);
761 AliMaterial(77, "GEN Vacuum$", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
762 AliMixture( 78, "GEN POLYETHYL$", apoly, zpoly, .95, -2, wpoly);
763 AliMixture( 79, "GEN SERVICES$", aserv, zserv, 4.68, 4, wserv);
764 AliMaterial(80, "GEN Copper$", 63.546, 29., 8.96, 1.43, 999.);
765 // After a call with ratios by number (negative number of elements),
766 // the ratio array is changed to the ratio by weight, so all successive
767 // calls with the same array must specify the number of elements as
768 // positive
769 AliMixture(81, "GEN Water $", awat, zwat, denswat, 2, wwat);
770 // **
b6668dd3 771 AliMedium(75,"GEN C$", 75, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
772 AliMedium(76,"GEN Air$", 76, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
773 AliMedium(77,"GEN Vacuum$", 77, 0,isxfld,sxmgmx, 10., .10, .1, .100,10.00);
774 AliMedium(78,"GEN POLYETHYL$",78, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
775 AliMedium(79,"GEN SERVICES$", 79, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
776 AliMedium(80,"GEN Copper$", 80, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
777 AliMedium(81,"GEN Water $", 81, 0,isxfld,sxmgmx, 10., .01, .1, .003, .003);
fe4da5cc 778}
fe4da5cc 779//_____________________________________________________________________________
593d2ea1 780void AliITSv1::Init(){
56d6a1ef 781////////////////////////////////////////////////////////////////////////
782// Initialise the ITS after it has been created.
783////////////////////////////////////////////////////////////////////////
e8189707 784
593d2ea1 785 //
786 AliITS::Init();
787 fMajorVersion = 1;
788 fMinorVersion = 0;
fe4da5cc 789}
790
791//_____________________________________________________________________________
56d6a1ef 792void AliITSv1::DrawModule(){
793////////////////////////////////////////////////////////////////////////
794// Draw a shaded view of the FMD version 1.
795////////////////////////////////////////////////////////////////////////
fe4da5cc 796
797 // Set everything unseen
cfce8870 798 gMC->Gsatt("*", "seen", -1);
fe4da5cc 799 //
800 // Set ALIC mother visible
cfce8870 801 gMC->Gsatt("ALIC","SEEN",0);
fe4da5cc 802 //
803 // Set the volumes visible
cfce8870 804 gMC->Gsatt("ITSV","SEEN",0);
805 gMC->Gsatt("ITS1","SEEN",1);
806 gMC->Gsatt("ITS2","SEEN",1);
807 gMC->Gsatt("ITS3","SEEN",1);
808 gMC->Gsatt("ITS4","SEEN",1);
809 gMC->Gsatt("ITS5","SEEN",1);
810 gMC->Gsatt("ITS6","SEEN",1);
fe4da5cc 811
cfce8870 812 gMC->Gsatt("IPCB","SEEN",1);
813 gMC->Gsatt("ICO2","SEEN",1);
814 gMC->Gsatt("ICER","SEEN",0);
815 gMC->Gsatt("ISI2","SEEN",0);
816 gMC->Gsatt("IPLA","SEEN",0);
817 gMC->Gsatt("ICO3","SEEN",0);
818 gMC->Gsatt("IEPX","SEEN",0);
819 gMC->Gsatt("ISI3","SEEN",1);
820 gMC->Gsatt("ISUP","SEEN",0);
821 gMC->Gsatt("ICHO","SEEN",0);
822 gMC->Gsatt("ICMO","SEEN",0);
823 gMC->Gsatt("ICMD","SEEN",0);
824 gMC->Gsatt("ICCO","SEEN",1);
825 gMC->Gsatt("ICCM","SEEN",0);
826 gMC->Gsatt("ITMD","SEEN",0);
827 gMC->Gsatt("ITTT","SEEN",1);
fe4da5cc 828
829 //
cfce8870 830 gMC->Gdopt("hide", "on");
831 gMC->Gdopt("shad", "on");
832 gMC->Gsatt("*", "fill", 7);
833 gMC->SetClipBox(".");
834 gMC->SetClipBox("*", 0, 300, -300, 300, -300, 300);
835 gMC->DefaultRange();
836 gMC->Gdraw("alic", 40, 30, 0, 11, 10, .07, .07);
837 gMC->Gdhead(1111, "Inner Tracking System Version 1");
838 gMC->Gdman(17, 6, "MAN");
fe4da5cc 839}
fe4da5cc 840//_____________________________________________________________________________
56d6a1ef 841void AliITSv1::StepManager(){
842////////////////////////////////////////////////////////////////////////
843// Called for every step in the ITS, then calles the AliITShit class
844// creator with the information to be recoreded about that hit.
845////////////////////////////////////////////////////////////////////////
d8331d3f 846/*
fe4da5cc 847 Int_t copy, id;
58005f18 848 Float_t hits[8];
849 Int_t vol[4];
0a6d8768 850 TLorentzVector position, momentum;
fe4da5cc 851 TClonesArray &lhits = *fHits;
fe4da5cc 852 //
58005f18 853 // Track status
854 vol[3] = 0;
855 if(gMC->IsTrackInside()) vol[3] += 1;
856 if(gMC->IsTrackEntering()) vol[3] += 2;
857 if(gMC->IsTrackExiting()) vol[3] += 4;
858 if(gMC->IsTrackOut()) vol[3] += 8;
859 if(gMC->IsTrackDisappeared()) vol[3] += 16;
860 if(gMC->IsTrackStop()) vol[3] += 32;
861 if(gMC->IsTrackAlive()) vol[3] += 64;
862 //
863 // Fill hit structure.
56d6a1ef 864 if( !(gMC->TrackCharge()) ) return;
fe4da5cc 865 //
866 // Only entering charged tracks
58005f18 867 if((id=gMC->CurrentVolID(copy))==fIdSens[0]) {
fe4da5cc 868 vol[0]=1;
0a6d8768 869 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 870 vol[1]=copy;
0a6d8768 871 id=gMC->CurrentVolOffID(2,copy);
fe4da5cc 872 vol[2]=copy;
58005f18 873 } else if(id==fIdSens[1]) {
fe4da5cc 874 vol[0]=2;
0a6d8768 875 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 876 vol[1]=copy;
0a6d8768 877 id=gMC->CurrentVolOffID(2,copy);
fe4da5cc 878 vol[2]=copy;
58005f18 879 } else if(id==fIdSens[2]) {
fe4da5cc 880 vol[0]=3;
881 vol[1]=copy;
0a6d8768 882 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 883 vol[2]=copy;
58005f18 884 } else if(id==fIdSens[3]) {
fe4da5cc 885 vol[0]=4;
886 vol[1]=copy;
0a6d8768 887 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 888 vol[2]=copy;
58005f18 889 } else if(id==fIdSens[4]) {
fe4da5cc 890 vol[0]=5;
891 vol[1]=copy;
0a6d8768 892 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 893 vol[2]=copy;
58005f18 894 } else if(id==fIdSens[5]) {
fe4da5cc 895 vol[0]=6;
896 vol[1]=copy;
0a6d8768 897 id=gMC->CurrentVolOffID(1,copy);
fe4da5cc 898 vol[2]=copy;
899 } else return;
cfce8870 900 gMC->TrackPosition(position);
901 gMC->TrackMomentum(momentum);
fe4da5cc 902 hits[0]=position[0];
903 hits[1]=position[1];
904 hits[2]=position[2];
0a6d8768 905 hits[3]=momentum[0];
906 hits[4]=momentum[1];
58005f18 907 hits[5]=momentum[2];
cfce8870 908 hits[6]=gMC->Edep();
58005f18 909 hits[7]=gMC->TrackTime();
fe4da5cc 910 new(lhits[fNhits++]) AliITShit(fIshunt,gAlice->CurrentTrack(),vol,hits);
d8331d3f 911*/
fe4da5cc 912}