ROOT logo
/**************************************************************************
 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 *                                                                        *
 * Author: The ALICE Off-line Project.                                    *
 * Contributors are mentioned in the code where appropriate.              *
 *                                                                        *
 * Permission to use, copy, modify and distribute this software and its   *
 * documentation strictly for non-commercial purposes is hereby granted   *
 * without fee, provided that the above copyright notice appears in all   *
 * copies and that both the copyright notice and this permission notice   *
 * appear in the supporting documentation. The authors make no claims     *
 * about the suitability of this software for any purpose. It is          *
 * provided "as is" without express or implied warranty.                  *
 **************************************************************************/

//*************************************************************************
// This class Defines the Geometry for the ITS Upgrade using TGeo
// This is a work class used to study different configurations
// during the development of the new ITS structure.
//
//  Mario Sitta <sitta@to.infn.it>
//  Chinorat Kobdaj (kobdaj@g.sut.ac.th)
//*************************************************************************


/* $Id: AliITSUv0Layer.cxx  */
// General Root includes
#include <TMath.h>
// Root Geometry includes
//#include <AliLog.h>
#include <TGeoManager.h>
#include <TGeoVolume.h>
#include <TGeoPcon.h>
#include <TGeoCone.h>
#include <TGeoTube.h> // contaings TGeoTubeSeg
#include <TGeoArb8.h>
#include <TGeoXtru.h>
#include <TGeoCompositeShape.h>
#include <TGeoMatrix.h>
#include "AliITSUv0Layer.h"
#include "AliITSUGeomTGeo.h"
#include <TGeoBBox.h>
#include <TGeoShape.h>
#include <TGeoTrd1.h>
using namespace TMath;

const Double_t AliITSUv0Layer::fgkDefaultSensorThick = 300*fgkmicron;
const Double_t AliITSUv0Layer::fgkDefaultStaveThick =   1*fgkcm;

ClassImp(AliITSUv0Layer)

#define SQ(A) (A)*(A)

//________________________________________________________________________
AliITSUv0Layer::AliITSUv0Layer(): 
  AliITSv11Geometry(),
  fLayerNumber(0),
  fPhi0(0),
  fLayRadius(0),
  fZLength(0),
  fSensorThick(0),
  fStaveThick(0),
  fStaveWidth(0),
  fStaveTilt(0),
  fNStaves(0),
  fNChips(0),
  fChipTypeID(0),
  fIsTurbo(0),
  fBuildLevel(0),
  fStaveModel(AliITSUv0::kModelDummy)
{
  //
  // Standard constructor
  //
}

//________________________________________________________________________
AliITSUv0Layer::AliITSUv0Layer(Int_t debug): 
  AliITSv11Geometry(debug),
  fLayerNumber(0),
  fPhi0(0),
  fLayRadius(0),
  fZLength(0),
  fSensorThick(0),
  fStaveThick(0),
  fStaveWidth(0),
  fStaveTilt(0),
  fNStaves(0),
  fNChips(0),
  fChipTypeID(0),
  fIsTurbo(0),
  fBuildLevel(0),
  fStaveModel(AliITSUv0::kModelDummy)
{
  //
  // Constructor setting debugging level
  //
}

//________________________________________________________________________
AliITSUv0Layer::AliITSUv0Layer(Int_t lay, Int_t debug): 
  AliITSv11Geometry(debug),
  fLayerNumber(lay),
  fPhi0(0),
  fLayRadius(0),
  fZLength(0),
  fSensorThick(0),
  fStaveThick(0),
  fStaveWidth(0),
  fStaveTilt(0),
  fNStaves(0),
  fNChips(0),
  fChipTypeID(0),
  fIsTurbo(0),
  fBuildLevel(0),
  fStaveModel(AliITSUv0::kModelDummy)
{
  //
  // Constructor setting layer number and debugging level
  //
}

//________________________________________________________________________
AliITSUv0Layer::AliITSUv0Layer(Int_t lay, Bool_t turbo, Int_t debug): 
  AliITSv11Geometry(debug),
  fLayerNumber(lay),
  fPhi0(0),
  fLayRadius(0),
  fZLength(0),
  fSensorThick(0),
  fStaveThick(0),
  fStaveWidth(0),
  fStaveTilt(0),
  fNStaves(0),
  fNChips(0),
  fChipTypeID(0),
  fIsTurbo(turbo),
  fBuildLevel(0),
  fStaveModel(AliITSUv0::kModelDummy)
{
  //
  // Constructor setting layer number and debugging level
  // for a "turbo" layer (i.e. where staves overlap in phi)
  //
}

//________________________________________________________________________
AliITSUv0Layer::AliITSUv0Layer(const AliITSUv0Layer &s):
  AliITSv11Geometry(s.GetDebug()),
  fLayerNumber(s.fLayerNumber),
  fPhi0(s.fPhi0),
  fLayRadius(s.fLayRadius),
  fZLength(s.fZLength),
  fSensorThick(s.fSensorThick),
  fStaveThick(s.fStaveThick),
  fStaveWidth(s.fStaveWidth),
  fStaveTilt(s.fStaveTilt),
  fNStaves(s.fNStaves),
  fNChips(s.fNChips),
  fChipTypeID(s.fChipTypeID),
  fIsTurbo(s.fIsTurbo),
  fBuildLevel(s.fBuildLevel),
  fStaveModel(s.fStaveModel)
{
  //
  // Copy constructor
  //
}

//________________________________________________________________________
AliITSUv0Layer& AliITSUv0Layer::operator=(const AliITSUv0Layer &s)
{
  //
  // Assignment operator 
  //
  if(&s == this) return *this;

  fLayerNumber = s.fLayerNumber;
  fPhi0        = s.fPhi0;
  fLayRadius   = s.fLayRadius;
  fZLength     = s.fZLength;
  fSensorThick = s.fSensorThick;
  fStaveThick = s.fStaveThick;
  fStaveWidth = s.fStaveWidth;
  fStaveTilt  = s.fStaveTilt;
  fNStaves    = s.fNStaves;
  fNChips    = s.fNChips;
  fIsTurbo     = s.fIsTurbo;
  fChipTypeID   = s.fChipTypeID;
  fBuildLevel  = s.fBuildLevel;
  fStaveModel  = s.fStaveModel;

  return *this;
}

//________________________________________________________________________
AliITSUv0Layer::~AliITSUv0Layer() {
  //
  // Destructor
  //
}

//________________________________________________________________________
void AliITSUv0Layer::CreateLayer(TGeoVolume *moth){
//
// Creates the actual Layer and places inside its mother volume
//
// Input:
//         moth : the TGeoVolume owing the volume structure
//
// Output:
//
// Return:
//
// Created:      17 Jun 2011  Mario Sitta
// Updated:      08 Jul 2011  Mario Sitta
// Updated:      20 May 2013  Mario Sitta  Layer is Assembly instead of Tube
//
  // Local variables
  char volname[30];
  Double_t xpos, ypos, zpos;
  Double_t alpha;


  // Check if the user set the proper parameters
  if (fLayRadius <= 0) AliFatal(Form("Wrong layer radius (%f)",fLayRadius));
  if (fZLength   <= 0) AliFatal(Form("Wrong layer length (%f)",fZLength));
  if (fNStaves  <= 0) AliFatal(Form("Wrong number of staves (%d)",fNStaves));
  if (fNChips  <= 0) AliFatal(Form("Wrong number of chips (%d)",fNChips));

  if (fStaveThick <= 0) {
    AliInfo(Form("Stave thickness wrong or not set (%f), using default (%f)",
		 fStaveThick,fgkDefaultStaveThick));
    fStaveThick = fgkDefaultStaveThick;
  }

  if (fSensorThick <= 0) {
    AliInfo(Form("Sensor thickness wrong or not set (%f), using default (%f)",
		 fSensorThick,fgkDefaultSensorThick));
    fSensorThick = fgkDefaultSensorThick;
  }

  if (fSensorThick > fStaveThick) {
    AliWarning(Form("Sensor thickness (%f) is greater than stave thickness (%f), fixing",
		 fSensorThick,fStaveThick));
    fSensorThick = fStaveThick;
  }


  // If a Turbo layer is requested, do it and exit
  if (fIsTurbo) {
    CreateLayerTurbo(moth);
    return;
  }


  // First create the stave container
  alpha = (360./(2*fNStaves))*DegToRad();

  //  fStaveWidth = fLayRadius*Tan(alpha);

  snprintf(volname, 30, "%s%d", AliITSUGeomTGeo::GetITSLayerPattern(),fLayerNumber);
  TGeoVolume *layVol = new TGeoVolumeAssembly(volname);
  layVol->SetUniqueID(fChipTypeID);

//  layVol->SetVisibility(kFALSE);
  layVol->SetVisibility(kTRUE);
  layVol->SetLineColor(1);

  TGeoVolume *stavVol = CreateStave();


  // Now build up the layer
  alpha = 360./fNStaves;
  Double_t r = fLayRadius + ((TGeoBBox*)stavVol->GetShape())->GetDY();
  for (Int_t j=0; j<fNStaves; j++) {
    Double_t phi = j*alpha + fPhi0;
    xpos = r*CosD(phi);// r*SinD(-phi);
    ypos = r*SinD(phi);// r*CosD(-phi);
    zpos = 0.;
    phi += 90;
    layVol->AddNode(stavVol, j, new TGeoCombiTrans( xpos, ypos, zpos,
						    new TGeoRotation("",phi,0,0)));
  }


  // Finally put everything in the mother volume
  moth->AddNode(layVol, 1, 0);


  // Upgrade geometry is served
  return;
}

//________________________________________________________________________
void AliITSUv0Layer::CreateLayerTurbo(TGeoVolume *moth){
//
// Creates the actual Layer and places inside its mother volume
// A so-called "turbo" layer is a layer where staves overlap in phi
// User can set width and tilt angle, no check is performed here
// to avoid volume overlaps
//
// Input:
//         moth : the TGeoVolume owing the volume structure
//
// Output:
//
// Return:
//
// Created:      08 Jul 2011  Mario Sitta
// Updated:      08 Mar 2012  Mario Sitta  Correct way to compute container R
// Updated:      20 May 2013  Mario Sitta  Layer is Assemgbly instead of Tube
//


  // Local variables
  char volname[30];
  Double_t xpos, ypos, zpos;
  Double_t alpha;


  // Check if the user set the proper (remaining) parameters
  if (fStaveWidth <= 0)
    AliFatal(Form("Wrong stave width (%f)",fStaveWidth));
  if (Abs(fStaveTilt) > 45)
    AliWarning(Form("Stave tilt angle (%f) greater than 45deg",fStaveTilt));


  snprintf(volname, 30, "%s%d", AliITSUGeomTGeo::GetITSLayerPattern(), fLayerNumber);
  TGeoVolume *layVol = new TGeoVolumeAssembly(volname);
  layVol->SetUniqueID(fChipTypeID);
  layVol->SetVisibility(kTRUE);
  layVol->SetLineColor(1);
  TGeoVolume *stavVol = CreateStave();


  // Now build up the layer
  alpha = 360./fNStaves;
  Double_t r = fLayRadius /* +chip thick ?! */;
  for (Int_t j=0; j<fNStaves; j++) {
    Double_t phi = j*alpha + fPhi0;
    xpos = r*CosD(phi);// r*SinD(-phi);
    ypos = r*SinD(phi);// r*CosD(-phi);
    zpos = 0.;
    phi += 90;
    layVol->AddNode(stavVol, j, new TGeoCombiTrans( xpos, ypos, zpos,
						    new TGeoRotation("", phi-fStaveTilt,0,0)));
  }


  // Finally put everything in the mother volume
  moth->AddNode(layVol, 1, 0);

  return;
}

//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStave(const TGeoManager * /*mgr*/){
//
// Creates the actual Stave
//
// Input:
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Jun 2011  Mario Sitta
//

  char volname[30];
  Double_t xlen, ylen, zlen;
  Double_t xpos, ypos, zpos, zmod;
  Double_t alpha;


  // First create all needed shapes
  alpha = (360./(2*fNStaves))*DegToRad();

  // The stave
  xlen = fLayRadius*Tan(alpha);
  if (fIsTurbo) xlen = 0.5*fStaveWidth;
  ylen = 0.5*fStaveThick;
  zlen = 0.5*fZLength;

  Double_t yplus = 0.46;
  //  Double_t origin[]={0,-yplus/2,0};
  //  TGeoBBox *stave = new TGeoBBox(xlen, ylen+yplus/2, zlen, origin);
  TGeoXtru *stave = new TGeoXtru(2); //z sections
  Double_t xv[5] = {xlen,xlen,0,-xlen,-xlen};
  Double_t yv[5] = {ylen+0.09,-0.15,-yplus-fSensorThick,-0.15,ylen+0.09};    
  stave->DefinePolygon(5,xv,yv);
  stave->DefineSection(0,-zlen,0,0,1.);
  stave->DefineSection(1,+zlen,0,0,1.);
  

  // We have all shapes: now create the real volumes
//  TGeoMedium *medAir = mgr->GetMedium("ITS_AIR$");

  snprintf(volname, 30, "%s%d", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);
//  TGeoVolume *stavVol = new TGeoVolume(volname, stave, medAir);
  TGeoVolume *stavVol = new TGeoVolumeAssembly(volname);

  //  stavVol->SetVisibility(kFALSE);
  stavVol->SetVisibility(kTRUE);
  stavVol->SetLineColor(2);
  TGeoVolume *modVol = CreateChip(xlen,ylen, zlen);


  // Now build up the stave
  zmod = ((TGeoBBox*)modVol->GetShape())->GetDZ();
  for (Int_t j=0; j<fNChips; j++) {
    xpos = 0.;
    ypos = 0.021;  // Remove small overlap - M.S: 21may13
    zpos = -stave->GetDZ() + j*2*zmod + zmod;
    stavVol->AddNode(modVol, j, new TGeoTranslation(xpos, ypos, zpos));
  }
 

  // put mechanical stave structure, only inner barrel up to now
  if (fLayerNumber<3) {
    TGeoVolume *mechStavVol = CreateStaveStruct(xlen,zlen); 
    if (mechStavVol)
      stavVol->AddNode(mechStavVol, fNChips, new TGeoCombiTrans(0, -0.15-ylen, 0, new TGeoRotation("",0, 0, 180)));
  }
  

  // Done, return the stave
  return stavVol;
}

//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveStruct(const Double_t xsta,
					      const Double_t zsta,
					      const TGeoManager *mgr){
//
// Create the mechanical stave structure
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
//

  TGeoVolume *mechStavVol = 0;

  switch (fStaveModel) {
    case AliITSUv0::kModelDummy:
      mechStavVol = CreateStaveModelDummy(xsta,zsta,mgr);
      break;
    case AliITSUv0::kModel0:
      mechStavVol = CreateStaveModel0(xsta,zsta,mgr);
      break;
    case AliITSUv0::kModel1:
      mechStavVol = CreateStaveModel1(xsta,zsta,mgr);
      break;
    case AliITSUv0::kModel21:
      mechStavVol = CreateStaveModel21(xsta,zsta,mgr);
      break;
    case AliITSUv0::kModel22:
      mechStavVol = CreateStaveModel22(xsta,zsta,mgr);
      break;
    case AliITSUv0::kModel3:
      mechStavVol = CreateStaveModel3(xsta,zsta,mgr);
      break;
    default:
      AliFatal(Form("Unknown stave model %d",fStaveModel));
      break;
  }

  return mechStavVol; 
}


//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModelDummy(const Double_t ,
					      const Double_t ,
					      const TGeoManager *) const {
//
// Create dummy stave
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
//

  // Done, return the stave structur
  return 0;
}

//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModel0(const Double_t xsta,
					      const Double_t zsta,
					      const TGeoManager *mgr){
//
// Create the mechanical stave structure for Model 0 of TDR
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
//
  
  // Materials defined in AliITSUv0
  TGeoMedium *medAir    = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medWater  = mgr->GetMedium("ITS_WATER$");

  TGeoMedium *medM60J3K    = mgr->GetMedium("ITS_M60J3K$"); 
  TGeoMedium *medKapton    = mgr->GetMedium("ITS_KAPTON(POLYCH2)$");
  TGeoMedium *medGlue      = mgr->GetMedium("ITS_GLUE$");
  TGeoMedium *medFlexCable = mgr->GetMedium("ITS_FLEXCABLE$");

  // Local parameters
  Double_t kConeOutRadius = 0.15/2;
  Double_t kConeInRadius = 0.1430/2;
  Double_t kStaveLength = zsta*2;
  Double_t kStaveWidth = xsta*2-kConeOutRadius*2;
  Double_t kWidth = kStaveWidth/4;//1/2 of kWidth
  Double_t kStaveHeight = 0.3;
  Double_t kHeight = kStaveHeight/2;
  Double_t kAlpha = 90-67;//90-33.69;
  Double_t kTheta = kAlpha*TMath::DegToRad();
  Double_t kS1 = kWidth/TMath::Sin(kTheta);
  Double_t kL1 = kWidth/TMath::Tan(kTheta);
  Double_t kS2 = TMath::Sqrt(kHeight*kHeight + kS1*kS1);//TMath::Sin(the2);
  Double_t kThe2 = TMath::ATan(kHeight/kS1);
  Double_t kBeta = kThe2*TMath::RadToDeg();
  // Int_t  loop = kStaveLength/(kL1);
  // Double_t s3 = kWidth/(2*TMath::Sin(kTheta));
  // Double_t s4 = 3*kWidth/(2*TMath::Sin(kTheta));

  AliDebug(1, Form("BuildLevel %d\n",fBuildLevel));

  char volname[30];
  snprintf(volname, 30, "%s%d_StaveStruct", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);

  Double_t z=0, y=-0.011+0.0150, x=0;

   TGeoVolume *mechStavVol = 0;

  if (fBuildLevel < 5) {

    // world (trapezoid)
    TGeoXtru *mechStruct = new TGeoXtru(2); //z sections
    Double_t xv[5] = {kStaveWidth/2+0.1,kStaveWidth/2+0.1,0,-kStaveWidth/2-0.1,-kStaveWidth/2-0.1};
    Double_t yv[5] = {-kConeOutRadius*2-0.07,0,kStaveHeight,0,-kConeOutRadius*2-0.07};    
    mechStruct->DefinePolygon(5,xv,yv);
    mechStruct->DefineSection(0,-kStaveLength-0.1,0,0,1.);
    mechStruct->DefineSection(1,kStaveLength+0.1,0,0,1.);

    mechStavVol = new TGeoVolume(volname, mechStruct, medAir);
    mechStavVol->SetLineColor(12);
    mechStavVol->SetFillColor(12); 
    mechStavVol->SetVisibility(kTRUE);
      
    // detailed structure ++++++++++++++
    //Pipe Kapton grey-35
    TGeoTube *coolTube = new TGeoTube(kConeInRadius,kConeOutRadius,kStaveLength/2);
    TGeoVolume *volCoolTube= new TGeoVolume("pipe", coolTube, medKapton);
    volCoolTube->SetFillColor(35);
    volCoolTube->SetLineColor(35);
    mechStavVol->AddNode(volCoolTube,0,new TGeoTranslation(x+(kStaveWidth/2),y-(kHeight-kConeOutRadius),0));
    mechStavVol->AddNode(volCoolTube,1,new TGeoTranslation(x-(kStaveWidth/2),y-(kHeight-kConeOutRadius),0));
  }

  if (fBuildLevel < 4) {
    TGeoTube *coolTubeW = new TGeoTube(0.,kConeInRadius,kStaveLength/2);
    TGeoVolume *volCoolTubeW= new TGeoVolume("pipeWater", coolTubeW, medWater);
    volCoolTubeW->SetFillColor(4);
    volCoolTubeW->SetLineColor(4);
    mechStavVol->AddNode(volCoolTubeW,0,new TGeoTranslation(x+(kStaveWidth/2),y-(kHeight-kConeOutRadius),0));
    mechStavVol->AddNode(volCoolTubeW,1,new TGeoTranslation(x-(kStaveWidth/2),y-(kHeight-kConeOutRadius),0));
  }

  //frequency of filament
  //n = 4 means very dense(4 filaments per interval)
  //n = 2 means dense(2 filaments per interval)
  Int_t n =4;
  Int_t loop = (Int_t)(kStaveLength/(4*kL1/n) + 2/n)-1;
  if (fBuildLevel < 3) {
    //Top CFRP Filament black-12 Carbon structure TGeoBBox (length,thickness,width)
    TGeoBBox *t2=new TGeoBBox(kS2,0.007/2,0.15/2);//(kS2,0.002,0.02);
    TGeoVolume *volT2=new TGeoVolume("TopFilament", t2, medM60J3K);
    volT2->SetLineColor(12);
    volT2->SetFillColor(12); 

    for(int i=1;i<loop;i++){  //i<60;i++){
      mechStavVol->AddNode(volT2,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y+(2*kConeOutRadius),z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2,//z-14.25+(i*2*kL1),
						     new TGeoRotation("volT2",90,90-kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y+(2*kConeOutRadius),z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2,//z-14.25+(i*2*kL1),
						     new TGeoRotation("volT2",90,-90+kAlpha,-90+kBeta)));
      mechStavVol->AddNode(volT2,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y+(2*kConeOutRadius),z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2,//z-14.25+(i*2*kL1),
						     new TGeoRotation("volT2",90,-90+kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y+(2*kConeOutRadius),z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2,//z-14.25+(i*2*kL1),  
						     new TGeoRotation("volT2",90,90-kAlpha,-90+kBeta)));
    }


    //Bottom CFRP Filament black-12 Carbon structure  TGeoBBox (thickness,width,length)
    TGeoBBox *t1=new TGeoBBox(0.007/2,0.15/2,kS1);//(0.002,0.02,kS1);
    TGeoVolume *volT1=new TGeoVolume("CFRPBottom", t1, medM60J3K);
    volT1->SetLineColor(12);
    volT1->SetFillColor(12); 

    for(int i=1;i<loop;i++){
      mechStavVol->AddNode(volT1,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y-kHeight,z-kStaveLength/2+((4/n)*kL1*i)+kS1/2, //z-14.25+(i*2*kL1),  
						     new TGeoRotation("volT1",-90,kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y-kHeight,z-kStaveLength/2+((4/n)*kL1*i)+kS1/2,  //z-14.25+(i*2*kL1), 
						     new TGeoRotation("volT1",90,kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y-kHeight,z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2, //z-14.25+(i*2*kL1), 
						     new TGeoRotation("volT1",-90,-kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y-kHeight,z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2, //z-14.25+(i*2*kL1), 
						     new TGeoRotation("volT1",-90,+kAlpha,0)));
    }
  }
   
  if (fBuildLevel < 2) {
    // Glue CFRP-Silicon layers TGeoBBox(thickness,width,kS1);
    TGeoBBox *tG=new TGeoBBox(0.0075/2,0.18/2,kS1);
    TGeoVolume *volTG=new TGeoVolume("Glue1", tG, medGlue);
    volTG->SetLineColor(5);
    volTG->SetFillColor(5); 

    for(int i=1;i<loop;i++){ //i<60;i++){
      mechStavVol->AddNode(volTG,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y-0.16,z-kStaveLength/2+((4/n)*kL1*i)+kS1/2, //z-14.25+(2*kL1*i), 
						     new TGeoRotation("volTG",-90,kAlpha,0)));
      mechStavVol->AddNode(volTG,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y-0.16,z-kStaveLength/2+((4/n)*kL1*i)+kS1/2, //z-14.25+(2*kL1*i), 
						     new TGeoRotation("volTG",90,kAlpha,0)));
      mechStavVol->AddNode(volTG,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y-0.16,z-kStaveLength/2+((4/n)*i*kL1)+kS1/2, //z-14.25+(i*2*kL1), 
						     new TGeoRotation("volTG",-90,-kAlpha,0)));
      mechStavVol->AddNode(volTG,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y-0.16,z-kStaveLength/2+(i*(4/n)*kL1)+kS1/2, //z-14.25+(i*2*kL1), 
						     new TGeoRotation("volTG",-90,+kAlpha,0)));
    }

    TGeoBBox *glue = new TGeoBBox(xsta, 0.005/2, zsta);
    TGeoVolume *volGlue=new TGeoVolume("Glue2", glue, medGlue);
    volGlue->SetLineColor(5);
    volGlue->SetFillColor(5); 
    //mechStavVol->AddNode(volGlue, 0, new TGeoCombiTrans(x, y-0.16, z, new TGeoRotation("",0, 0, 0)));
    mechStavVol->AddNode(volGlue, 1, new TGeoCombiTrans(x, y-0.165-fSensorThick-0.005, z, new TGeoRotation("",0, 0, 0)));
  }

  if (fBuildLevel < 1) {
    //Flex cable brown-28 TGeoBBox(width,thickness,length); 
    TGeoBBox *kapCable = new TGeoBBox(xsta, 0.01/2, zsta);
    TGeoVolume *volCable=new TGeoVolume("FlexCable", kapCable, medFlexCable);
    volCable->SetLineColor(28);
    volCable->SetFillColor(28); 
    mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-0.165-fSensorThick-0.005-0.01, z, new TGeoRotation("",0, 0, 0)));
 }

  // Done, return the stave structur
  return mechStavVol;
}


//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModel1(const Double_t xsta,
					      const Double_t zsta,
					      const TGeoManager *mgr){
//
// Create the mechanical stave structure for Model 1 of TDR
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
//
  
  // Materials defined in AliITSUv0
  TGeoMedium *medAir    = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medWater  = mgr->GetMedium("ITS_WATER$");

  TGeoMedium *medM60J3K    = mgr->GetMedium("ITS_M60J3K$"); 
  TGeoMedium *medKapton    = mgr->GetMedium("ITS_KAPTON(POLYCH2)$");
  TGeoMedium *medGlue      = mgr->GetMedium("ITS_GLUE$");
  TGeoMedium *medFlexCable = mgr->GetMedium("ITS_FLEXCABLE$");

  // Local parameters
  Double_t kConeOutRadius = 0.15/2;
  //    Double_t kConeInRadius = 0.1430/2;
  Double_t kStaveLength = zsta*2;
  //    Double_t kStaveWidth = xsta*2-kConeOutRadius*2;
  Double_t kStaveWidth = xsta*2;
  Double_t kWidth = kStaveWidth/4;//1/2 of kWidth
  Double_t kStaveHeight = 0.3;
  Double_t kHeight = kStaveHeight/2;
  Double_t kAlpha = 90-33.;//90-30;
  Double_t kTheta = kAlpha*TMath::DegToRad();
  Double_t kS1 = kWidth/TMath::Sin(kTheta);
  Double_t kL1 = kWidth/TMath::Tan(kTheta);
  Double_t kS2 = TMath::Sqrt(kHeight*kHeight + kS1*kS1);//TMath::Sin(the2);
  Double_t kThe2 = TMath::ATan(kHeight/kS1);
  Double_t kBeta = kThe2*TMath::RadToDeg();
  Int_t  loop = (Int_t)((kStaveLength/(2*kL1))/2);
  

  TGeoVolume *mechStavVol = 0;

  char volname[30];
  snprintf(volname, 30, "%s%d_StaveStruct", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);
    

  // detailed structure ++++++++++++++
  Double_t z=0, y=-0.011+0.0150, x=0;

  // Polimide micro channels numbers
  Double_t yMC = y-kHeight+0.01;
  Int_t nb = (Int_t)(kStaveWidth/0.1)+1;
  Double_t xstaMC = (nb*0.1-0.08)/2;


  if (fBuildLevel < 5) {
    // world (trapezoid)
    TGeoXtru *mechStruct = new TGeoXtru(2); //z sections
    Double_t xv[5] = {kStaveWidth/2+0.1,kStaveWidth/2+0.1,0,-kStaveWidth/2-0.1,-kStaveWidth/2-0.1};
    Double_t yv[5] = {-kConeOutRadius*2-0.07,0,kStaveHeight,0,-kConeOutRadius*2-0.07};    
    mechStruct->DefinePolygon(5,xv,yv);
    mechStruct->DefineSection(0,-kStaveLength-0.1,0,0,1.);
    mechStruct->DefineSection(1,kStaveLength+0.1,0,0,1.);

    mechStavVol = new TGeoVolume(volname, mechStruct, medAir);
    mechStavVol->SetLineColor(12);
    mechStavVol->SetFillColor(12); 
    mechStavVol->SetVisibility(kTRUE);
      
    // Polimide micro channels numbers
    TGeoBBox *tM0=new TGeoBBox(xstaMC, 0.005/2, zsta);
    TGeoVolume *volTM0=new TGeoVolume("MicroChanCover", tM0, medKapton);
    volTM0->SetLineColor(35);
    volTM0->SetFillColor(35); 
    mechStavVol->AddNode(volTM0, 0, new TGeoCombiTrans(x,-0.0125+yMC, z, new TGeoRotation("",0, 0, 0)));
    mechStavVol->AddNode(volTM0, 1, new TGeoCombiTrans(x,+0.0125+yMC, z, new TGeoRotation("",0, 0, 0)));
      
    TGeoBBox *tM0b=new TGeoBBox(0.02/2, 0.02/2, zsta);
    TGeoVolume *volTM0b=new TGeoVolume("MicroChanWalls", tM0b, medKapton);
    volTM0b->SetLineColor(35);
    volTM0b->SetFillColor(35); 
    for (Int_t ib=0;ib<nb;ib++) {
      mechStavVol->AddNode(volTM0b, ib, new TGeoCombiTrans(x+ib*0.1-xstaMC+0.01,yMC, z, new TGeoRotation("",0, 0, 0)));
    }
      
  }
    
  if (fBuildLevel < 4) {
    // Water in Polimide micro channels
    TGeoBBox *water=new TGeoBBox(0.08/2, 0.02/2, zsta+0.1);
    TGeoVolume *volWater=new TGeoVolume("Water", water, medWater);
    volWater->SetLineColor(4);
    volWater->SetFillColor(4); 
    for (Int_t ib=0;ib<(nb-1);ib++) {
      mechStavVol->AddNode(volWater, ib, new TGeoCombiTrans(x+ib*0.1-xstaMC+0.06,yMC, z, new TGeoRotation("",0, 0, 0)));
    }
  }
    
  if (fBuildLevel < 3) {
    //Bottom filament CFRP black-12 Carbon structure TGeoBBox (thickness,width,length)
    Double_t filWidth = 0.04;
    Double_t filHeight= 0.02;
    TGeoBBox *t1=new TGeoBBox(filHeight/2,filWidth/2,kS1);
    TGeoVolume *volT1=new TGeoVolume("CFRPBottom", t1, medM60J3K);
    volT1->SetLineColor(12);
    volT1->SetFillColor(12); 
    for(int i=0;i<loop;i++){//i<30;i++){
      mechStavVol->AddNode(volT1,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y-kHeight+0.04+filHeight/2,z-kStaveLength/2+(4*kL1)+kS1/2, 
						     new TGeoRotation("volT1",-90,kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y-kHeight+0.04+filHeight/2,z-kStaveLength/2+(4*kL1*i)+kS1/2, 
						     new TGeoRotation("volT1",90,kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y-kHeight+0.04+filHeight/2,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2, 
						     new TGeoRotation("volT1",-90,-kAlpha,0)));
      mechStavVol->AddNode(volT1,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y-kHeight+0.04+filHeight/2,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2, 
						     new TGeoRotation("volT1",-90,+kAlpha,0)));
    }

      // Top filament CFRP black-12 Carbon structure TGeoBBox (length,thickness,width)
    TGeoBBox *t2=new TGeoBBox(kS2,filHeight/2,filWidth/2);
    TGeoVolume *volT2=new TGeoVolume("CFRPTop", t2, medM60J3K);
    volT2->SetLineColor(12);
    volT2->SetFillColor(12); 
    for(int i=0;i<loop;i++){ //i<30;i++){
      mechStavVol->AddNode(volT2,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y+0.04+filHeight/2,z-kStaveLength/2+(i*4*kL1)+kS1/2,
						     new TGeoRotation("volT2",90,90-kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y+0.04+filHeight/2,z-kStaveLength/2+(i*4*kL1)+kS1/2,
						     new TGeoRotation("volT2",90,-90+kAlpha,-90+kBeta)));
      mechStavVol->AddNode(volT2,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y+0.04+filHeight/2,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2,
						     new TGeoRotation("volT2",90,-90+kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y+0.04+filHeight/2,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2, 
						     new TGeoRotation("volT2",90,90-kAlpha,-90+kBeta)));
    }
  }

  if (fBuildLevel < 2) {
    // Glue between filament and polimide micro channel
    TGeoBBox *t3=new TGeoBBox(0.01/2,0.04,kS1);
    TGeoVolume *volT3=new TGeoVolume("FilamentGlue", t3, medGlue);
    volT3->SetLineColor(5);
    volT3->SetFillColor(5); 
    for(int i=0;i<loop;i++){//i<30;i++){
      mechStavVol->AddNode(volT3,4*i+0,
				  new TGeoCombiTrans(x+kWidth,y-kHeight+0.0325,z-kStaveLength/2+(4*kL1*i)+kS1/2, 
						     new TGeoRotation("volT1",-90,kAlpha,0)));
      mechStavVol->AddNode(volT3,4*i+1,
				  new TGeoCombiTrans(x-kWidth,y-kHeight+0.0325,z-kStaveLength/2+(4*kL1*i)+kS1/2, 
						     new TGeoRotation("volT1",90,kAlpha,0)));
      mechStavVol->AddNode(volT3,4*i+2,
				  new TGeoCombiTrans(x+kWidth,y-kHeight+0.0325,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2, 
						     new TGeoRotation("volT1",-90,-kAlpha,0)));
      mechStavVol->AddNode(volT3,4*i+3,
				  new TGeoCombiTrans(x-kWidth,y-kHeight+0.0325,z-kStaveLength/2+2*kL1+(i*4*kL1)+kS1/2, 
						     new TGeoRotation("volT1",-90,+kAlpha,0)));
    }
      
    // Glue microchannel and sensor
    TGeoBBox *glueM = new TGeoBBox(xsta, 0.01/2, zsta);
    TGeoVolume *volGlueM=new TGeoVolume("MicroChanGlue", glueM, medGlue);
    volGlueM->SetLineColor(5);
    volGlueM->SetFillColor(5); 
    mechStavVol->AddNode(volGlueM, 0, new TGeoCombiTrans(x, y-0.16, z, new TGeoRotation("",0, 0, 0)));

    // Glue sensor and kapton
    TGeoBBox *glue = new TGeoBBox(xsta, 0.005/2, zsta);
    TGeoVolume *volGlue=new TGeoVolume("SensorGlue", glue, medGlue);
    volGlue->SetLineColor(5);
    volGlue->SetFillColor(5); 
    mechStavVol->AddNode(volGlue, 1, new TGeoCombiTrans(x, y-0.165-fSensorThick-0.005, z, new TGeoRotation("",0, 0, 0)));
  }

  if (fBuildLevel < 1) {
    TGeoBBox *kapCable = new TGeoBBox(xsta, 0.01/2, zsta);
    TGeoVolume *volCable=new TGeoVolume("FlexCable", kapCable, medFlexCable);
    volCable->SetLineColor(28);
    volCable->SetFillColor(28); 
    mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-0.165-fSensorThick-0.005-0.01, z, new TGeoRotation("",0, 0, 0)));
  }
    
  // Done, return the stave structur
  return mechStavVol;

}

//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModel21(const Double_t xsta,
					       const Double_t zsta,
					       const TGeoManager *mgr){
//
// Create the mechanical stave structure for Model 2.1 of TDR
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
//
  
  // Materials defined in AliITSUv0
  TGeoMedium *medAir    = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medWater  = mgr->GetMedium("ITS_WATER$");

  TGeoMedium *medM60J3K    = mgr->GetMedium("ITS_M60J3K$"); 
  TGeoMedium *medKapton    = mgr->GetMedium("ITS_KAPTON(POLYCH2)$");
  TGeoMedium *medGlue      = mgr->GetMedium("ITS_GLUE$");
  TGeoMedium *medFlexCable = mgr->GetMedium("ITS_FLEXCABLE$");
  TGeoMedium *medK13D2U2k  = mgr->GetMedium("ITS_K13D2U2k$");
  TGeoMedium *medFGS003    = mgr->GetMedium("ITS_FGS003$"); 
  TGeoMedium *medCarbonFleece = mgr->GetMedium("ITS_CarbonFleece$"); 

  // Local parameters
  Double_t kConeOutRadius =0.151384/2;
  Double_t kConeInRadius = 0.145034/2;
  Double_t kStaveLength = zsta;
  Double_t kStaveWidth = xsta*2;
  Double_t kWidth = (kStaveWidth+0.005)/4;
  Double_t kStaveHeigth = 0.33;//0.33;
  Double_t kHeight = (kStaveHeigth+0.025)/2;
  Double_t kAlpha = 57; //56.31;
  Double_t kTheta = kAlpha*TMath::DegToRad();
  Double_t kS1 = (kStaveWidth/4)/TMath::Sin(kTheta);
  Double_t kL1 = (kStaveWidth/4)/TMath::Tan(kTheta);
  Double_t kS2 = sqrt(kHeight*kHeight + kS1*kS1);//TMath::Sin(the2);
  Double_t kThe2 = TMath::ATan(kHeight/kS1);
  Double_t kBeta = kThe2*TMath::RadToDeg();
  // Double_t lay1 = 0.003157;
  Double_t kLay1 = 0.003;//Amec carbon
  // Double_t lay2 = 0.0043215;//C Fleece carbon
  Double_t kLay2 = 0.002;//C Fleece carbon
  Double_t kLay3 = 0.007;//K13D2U carbon
  Int_t  loop = (Int_t)(kStaveLength/(2*kL1));


  char volname[30];
  snprintf(volname, 30, "%s%d_StaveStruct", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);

  Double_t z=0, y=-(kConeOutRadius+0.03)+0.0385, x=0;

  TGeoVolume *mechStavVol = 0;

  if (fBuildLevel < 5) {
    // world (trapezoid)
    TGeoXtru *mechStruct = new TGeoXtru(2); //z sections
    Double_t xv[5] = {kStaveWidth/2+0.1,kStaveWidth/2+0.1,0,-kStaveWidth/2-0.1,-kStaveWidth/2-0.1};
    Double_t yv[5] = {-kConeOutRadius*2-0.07,0,kStaveHeigth,0,-kConeOutRadius*2-0.07};    
    mechStruct->DefinePolygon(5,xv,yv);
    mechStruct->DefineSection(0,-kStaveLength-0.1,0,0,1.);
    mechStruct->DefineSection(1,kStaveLength+0.1,0,0,1.);

    mechStavVol = new TGeoVolume(volname, mechStruct, medAir);
    mechStavVol->SetLineColor(12);
    mechStavVol->SetFillColor(12); 
    mechStavVol->SetVisibility(kTRUE);  
      
    //Pipe Kapton grey-35 
    TGeoCone *cone1 = new TGeoCone(kStaveLength,kConeInRadius,kConeOutRadius,kConeInRadius,kConeOutRadius);
    TGeoVolume *volCone1= new TGeoVolume("PolyimidePipe", cone1, medKapton);
    volCone1->SetFillColor(35);
    volCone1->SetLineColor(35);
    mechStavVol->AddNode(volCone1,1,new TGeoTranslation(x+0.25,y,z));
    mechStavVol->AddNode(volCone1,2,new TGeoTranslation(x-0.25,y,z));
  }

  if (fBuildLevel < 4) {
    
    TGeoTube *coolTubeW = new TGeoTube(0.,kConeInRadius,kStaveLength);
    TGeoVolume *volCoolTubeW= new TGeoVolume("Water", coolTubeW, medWater);
    volCoolTubeW->SetFillColor(4);
    volCoolTubeW->SetLineColor(4);
    mechStavVol->AddNode(volCoolTubeW,0,new TGeoTranslation(x-0.25,y,z));
    mechStavVol->AddNode(volCoolTubeW,1,new TGeoTranslation(x+0.25,y,z));
  }

  if (fBuildLevel < 3) {
    //top fillament
    // Top filament M60J black-12 Carbon structure TGeoBBox (length,thickness,width)
    TGeoBBox *t2=new TGeoBBox(kS2,0.02/2,0.04/2); //TGeoBBox *t2=new TGeoBBox(kS2,0.01,0.02);
    TGeoVolume *volT2=new TGeoVolume("TopFilament", t2, medM60J3K);
    volT2->SetLineColor(12);
    volT2->SetFillColor(12); 
    for(int i=0;i<loop;i++){// i<28;i++){
      mechStavVol->AddNode(volT2,i*4+1,new TGeoCombiTrans(x+kWidth,y+kHeight+(0.12/2)-0.014+0.007,z-kStaveLength+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,90-kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,i*4+2,new TGeoCombiTrans(x-kWidth,y+kHeight+(0.12/2)-0.014+0.007,z-kStaveLength+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,-90+kAlpha,-90+kBeta)));
      mechStavVol->AddNode(volT2,i*4+3,new TGeoCombiTrans(x+kWidth,y+kHeight+(0.12/2)-0.014+0.007,z-kStaveLength+2*kL1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,-90+kAlpha,90-kBeta)));
      mechStavVol->AddNode(volT2,i*4+4,new TGeoCombiTrans(x-kWidth,y+kHeight+(0.12/2)-0.014+0.007,z-kStaveLength+2*kL1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,90-kAlpha,-90+kBeta)));
//    mechStavVol->AddNode(volT2,i*4+1,new TGeoCombiTrans(x+kWidth+0.0036,y+kHeight-(0.12/2)+0.072,z+kStaveLength+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,90-kAlpha,90-kBeta)));

 }
 
    //wall side structure out
    TGeoBBox *box4 = new TGeoBBox(0.03/2,0.12/2,kStaveLength-0.50);
    TGeoVolume *plate4 = new TGeoVolume("WallOut",box4,medM60J3K);
    plate4->SetFillColor(35);
    plate4->SetLineColor(35);
    mechStavVol->AddNode(plate4,1,new TGeoCombiTrans(x+(2*kStaveWidth/4)-(0.03/2),y-0.0022-kConeOutRadius+0.12/2+0.007,z,new TGeoRotation("plate4",0,0,0)));
    mechStavVol->AddNode(plate4,2,new TGeoCombiTrans(x-(2*kStaveWidth/4)+(0.03/2),y-0.0022-kConeOutRadius+0.12/2+0.007,z,new TGeoRotation("plate4",0,0,0)));
    //wall side in
    TGeoBBox *box5 = new TGeoBBox(0.015/2,0.12/2,kStaveLength-0.50);
    TGeoVolume *plate5 = new TGeoVolume("WallIn",box5,medM60J3K);
    plate5->SetFillColor(12);
    plate5->SetLineColor(12);
    mechStavVol->AddNode(plate5,1,new TGeoCombiTrans(x+(2*kStaveWidth/4)-0.03-0.015/2,y-0.0022-kConeOutRadius+0.12/2+0.007,z,new TGeoRotation("plate5",0,0,0)));
    mechStavVol->AddNode(plate5,2,new TGeoCombiTrans(x-(2*kStaveWidth/4)+0.03+0.015/2,y-0.0022-kConeOutRadius+0.12/2+0.007,z,new TGeoRotation("plate5",0,0,0)));

     //Amec Thermasol red-2 cover tube FGS300
    TGeoConeSeg *cons1 = new TGeoConeSeg(kStaveLength-0.50,kConeOutRadius,kConeOutRadius+kLay1,kConeOutRadius,kConeOutRadius+kLay1,0,180);
    TGeoVolume *cone11 = new TGeoVolume("ThermasolPipeCover",cons1,medFGS003);
    cone11->SetFillColor(2);
    cone11->SetLineColor(2);
    mechStavVol->AddNode(cone11,1,new TGeoCombiTrans(x+0.25,y,z,new TGeoRotation("Cone11",0,0,0)));
    mechStavVol->AddNode(cone11,2,new TGeoCombiTrans(x-0.25,y,z,new TGeoRotation("Cone11",0,0,0)));

    TGeoBBox *box2 = new TGeoBBox((0.50-(2*kConeOutRadius))/2,kLay1/2,kStaveLength-0.50);
    TGeoVolume *plate2 = new TGeoVolume("ThermasolMiddle",box2,medFGS003);
    plate2->SetFillColor(2);
    plate2->SetLineColor(2);
    mechStavVol->AddNode(plate2,1,new TGeoCombiTrans(x,y-kConeOutRadius+(kLay1/2),z,new TGeoRotation("plate2",0,0,0)));

    TGeoBBox *box21 = new TGeoBBox((0.75-0.25-kConeOutRadius-kLay1)/2,kLay1/2,kStaveLength-0.50);
    TGeoVolume *plate21 = new TGeoVolume("ThermasolLeftRight",box21,medFGS003);
    plate21->SetFillColor(2);
    plate21->SetLineColor(2);
    mechStavVol->AddNode(plate21,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+(0.75-0.25-kConeOutRadius)/2-(kLay1/2),y-kConeOutRadius+(kLay1/2),z,new TGeoRotation("plate21",0,0,0)));
    mechStavVol->AddNode(plate21,2,new TGeoCombiTrans(x-0.25-kConeOutRadius-(0.75-0.25-kConeOutRadius)/2+(kLay1/2),y-kConeOutRadius+(kLay1/2),z,new TGeoRotation("plate21",0,0,0)));

    TGeoBBox *box22 = new TGeoBBox((kLay1/2),kConeOutRadius/2,kStaveLength-0.50);
    TGeoVolume *plate22 = new TGeoVolume("ThermasolVertical",box22,medFGS003);
    plate22->SetFillColor(2);
    plate22->SetLineColor(2);
    mechStavVol->AddNode(plate22,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+(kLay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
    mechStavVol->AddNode(plate22,2,new TGeoCombiTrans(x+0.25-kConeOutRadius-(kLay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
    mechStavVol->AddNode(plate22,3,new TGeoCombiTrans(x-0.25+kConeOutRadius+(kLay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
    mechStavVol->AddNode(plate22,4,new TGeoCombiTrans(x-0.25-kConeOutRadius-(kLay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));

    //C Fleece
    TGeoConeSeg *cons2 = new TGeoConeSeg(kStaveLength-0.50,kConeOutRadius+kLay1,kConeOutRadius+kLay1+kLay2,kConeOutRadius+kLay1,kConeOutRadius+kLay1+kLay2,0,180); 
    TGeoVolume *cone12 = new TGeoVolume("CFleecePipeCover",cons2,medCarbonFleece);
    cone12->SetFillColor(28);
    cone12->SetLineColor(28);
    mechStavVol->AddNode(cone12,1,new TGeoCombiTrans(x+0.25,y,z,new TGeoRotation("Cone12",0,0,0)));
    mechStavVol->AddNode(cone12,2,new TGeoCombiTrans(x-0.25,y,z,new TGeoRotation("Cone12",0,0,0)));

    TGeoBBox *box3 = new TGeoBBox((0.50-(2*(kConeOutRadius+kLay1)))/2,kLay2/2,kStaveLength-0.50);
    TGeoVolume *plate3 = new TGeoVolume("CFleeceMiddle",box3,medCarbonFleece);
    plate3->SetFillColor(28);
    plate3->SetLineColor(28);
    mechStavVol->AddNode(plate3,1,new TGeoCombiTrans(x,y-kConeOutRadius+kLay1+(kLay2/2),z,new TGeoRotation("plate3",0,0,0)));

    TGeoBBox *box31 = new TGeoBBox((0.75-0.25-kConeOutRadius-kLay1)/2,kLay2/2,kStaveLength-0.50);
    TGeoVolume *plate31 = new TGeoVolume("CFleeceLeftRight",box31,medCarbonFleece);
    plate31->SetFillColor(28);
    plate31->SetLineColor(28);
    mechStavVol->AddNode(plate31,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+kLay1+(0.75-0.25-kConeOutRadius-kLay1)/2,y-kConeOutRadius+kLay1+(kLay2/2),z,new TGeoRotation("plate31",0,0,0)));
    mechStavVol->AddNode(plate31,2,new TGeoCombiTrans(x-0.25-kConeOutRadius-kLay1-(0.75-0.25-kConeOutRadius-kLay1)/2,y-kConeOutRadius+kLay1+(kLay2/2),z,new TGeoRotation("plate31",0,0,0)));

    TGeoBBox *box32 = new TGeoBBox((kLay2/2),(kConeOutRadius-kLay1)/2,kStaveLength-0.50);
    TGeoVolume *plate32 = new TGeoVolume("CFleeceVertical",box32,medCarbonFleece);
    plate32->SetFillColor(28);
    plate32->SetLineColor(28);
    mechStavVol->AddNode(plate32,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+kLay1+(kLay2/2),y+(kLay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
    mechStavVol->AddNode(plate32,2,new TGeoCombiTrans(x+0.25-kConeOutRadius-kLay1-(kLay2/2),y+(kLay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
    mechStavVol->AddNode(plate32,3,new TGeoCombiTrans(x-0.25+kConeOutRadius+kLay1+(kLay2/2),y+(kLay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
    mechStavVol->AddNode(plate32,4,new TGeoCombiTrans(x-0.25-kConeOutRadius-kLay1-(kLay2/2),y+(kLay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));


    //K13D2U carbon plate
    TGeoBBox *box1 = new TGeoBBox(2*kWidth,kLay3/2,kStaveLength-0.50);
    TGeoVolume *plate1 = new TGeoVolume("CarbonPlate",box1,medK13D2U2k);
    plate1->SetFillColor(5);
    plate1->SetLineColor(5);
    mechStavVol->AddNode(plate1,1,new TGeoCombiTrans(x,y-(kConeOutRadius+(kLay3/2)),z,new TGeoRotation("plate1",0,0,0)));

    //C Fleece bottom plate 
    TGeoBBox *box6 = new TGeoBBox(2*kWidth,kLay2/2,kStaveLength-0.50);
    TGeoVolume *plate6 = new TGeoVolume("CFleeceBottom",box6,medCarbonFleece);
    plate6->SetFillColor(2);
    plate6->SetLineColor(2);
    mechStavVol->AddNode(plate6,1,new TGeoCombiTrans(x,y-(kConeOutRadius+kLay3+(kLay2/2)),z,new TGeoRotation("plate1",0,0,0)));
      
      
  }

  if (fBuildLevel < 2) {
    //Glue layers and kapton
    TGeoBBox *glue = new TGeoBBox(kStaveWidth/2, 0.005/2, zsta);
    TGeoVolume *volGlue=new TGeoVolume("Glue", glue, medGlue);
    volGlue->SetLineColor(5);
    volGlue->SetFillColor(5); 
    mechStavVol->AddNode(volGlue, 0, new TGeoCombiTrans(x,y-(kConeOutRadius+kLay3+(kLay2/2)+(0.01/2)), z, new TGeoRotation("",0, 0, 0)));
    mechStavVol->AddNode(volGlue, 1, new TGeoCombiTrans(x,y-(kConeOutRadius+kLay3+(kLay2/2)+0.01+fSensorThick+(0.01/2)), z, new TGeoRotation("",0, 0, 0)));
  }

  if (fBuildLevel < 1) {
    TGeoBBox *kapCable = new TGeoBBox(kStaveWidth/2, 0.01/2, zsta);
    TGeoVolume *volCable=new TGeoVolume("FlexCable", kapCable, medFlexCable);
    volCable->SetLineColor(28);
    volCable->SetFillColor(28); 
    mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-(kConeOutRadius+kLay3+(kLay2/2)+0.01+fSensorThick+0.01+(0.01/2)), z, new TGeoRotation("",0, 0, 0)));
  }
    

  // Done, return the stave structure
  return mechStavVol;
  
}
// new model22
//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModel22(const Double_t xsta,
					       const Double_t zsta,
					       const TGeoManager *mgr){
//
// Create the mechanical stave structure for Model 2.2 of TDR
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Mar 2013  Chinorat Kobdaj
// Updated:      26 Apr 2013  Mario Sitta
// Updated:      30 Apr 2013  Wanchaloem Poonsawat 
//
  
  // Materials defined in AliITSUv0
  TGeoMedium *medAir    = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medWater  = mgr->GetMedium("ITS_WATER$");

  TGeoMedium *medM60J3K    = mgr->GetMedium("ITS_M60J3K$"); 
  TGeoMedium *medKapton    = mgr->GetMedium("ITS_KAPTON(POLYCH2)$");
  TGeoMedium *medGlue      = mgr->GetMedium("ITS_GLUE$");
  TGeoMedium *medFlexCable = mgr->GetMedium("ITS_FLEXCABLE$");
  TGeoMedium *medK13D2U2k  = mgr->GetMedium("ITS_K13D2U2k$");
  TGeoMedium *medFGS003    = mgr->GetMedium("ITS_FGS003$"); 
  TGeoMedium *medCarbonFleece = mgr->GetMedium("ITS_CarbonFleece$"); 

  // Local parameters
  Double_t kConeOutRadius =0.107/2;//0.107/2;
  Double_t kConeInRadius = 0.1015/2;//0.10105/2
  Double_t kStaveLength = zsta;
  Double_t kStaveWidth = xsta*2;
  Double_t kWidth = (kStaveWidth)/4;
  Double_t kStaveHeight = 0.283;//0.33;
  Double_t kHeight = (kStaveHeight)/2;
  Double_t kAlpha = 57;//56.31;
  Double_t kTheta = kAlpha*TMath::DegToRad();
  Double_t kS1 = ((kStaveWidth)/4)/TMath::Sin(kTheta);
  Double_t kL1 = (kStaveWidth/4)/TMath::Tan(kTheta);
  Double_t kS2 = sqrt(kHeight*kHeight + kS1*kS1);//TMath::Sin(kThe2);
  Double_t kThe2 = TMath::ATan(kHeight/(0.375-0.036));
  Double_t kBeta = kThe2*TMath::RadToDeg();
  Double_t klay1 = 0.003;//Amec carbon
  Double_t klay2 = 0.002;//C Fleece carbon
  Double_t klay3 = 0.007;//CFplate K13D2U carbon
  Double_t klay4 = 0.007;//GluekStaveLength/2
  Double_t klay5 = 0.01;//Flex cable
  Double_t kTopVertexMaxWidth = 0.072;
  Double_t kTopVertexHeight = 0.04;
  Double_t kSideVertexMWidth = 0.052;
  Double_t kSideVertexHeight = 0.11; 

 
  Int_t  loop = (Int_t)(kStaveLength/(2*kL1));

  char volname[30];
  snprintf(volname, 30, "%s%d_StaveStruct", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);

  Double_t z=0, y=-(2*kConeOutRadius)+klay1+klay2+fSensorThick/2-0.0004, x=0;

  TGeoVolume *mechStavVol = 0;

  if (fBuildLevel < 5) {
    // world (trapezoid)
    TGeoXtru *mechStruct = new TGeoXtru(2); //z sections
    Double_t xv[6] = {kStaveWidth/2,kStaveWidth/2,0.012,-0.012,-kStaveWidth/2,-kStaveWidth/2}; 
    /* Double_t yv[6] = {-2*(kConeOutRadius+klay1+1.5*klay2+klay3+klay4+fSensorThick+klay5),
                        0-0.02,kStaveHeight+0.01,kStaveHeight+0.01,0-0.02,
			-2*(kConeOutRadius+klay1+1.5*klay2+klay3+klay4+fSensorThick+klay5)};  // (kConeOutRadius*2)-0.0635 */
    Double_t yv[6] = {-(kConeOutRadius*2)-0.06395,0-0.02,kStaveHeight+0.01,kStaveHeight+0.01,0-0.02,-(kConeOutRadius*2)-0.06395};  // (kConeOutRadius*2)-0.064
    mechStruct->DefinePolygon(6,xv,yv);
    mechStruct->DefineSection(0,-kStaveLength,0,0,1.);
    mechStruct->DefineSection(1,kStaveLength,0,0,1.);

    mechStavVol = new TGeoVolume(volname, mechStruct, medAir);
    mechStavVol->SetLineColor(12);
    mechStavVol->SetFillColor(12); 
    mechStavVol->SetVisibility(kTRUE);  
      
    //Polyimide Pipe Kapton grey-35 
    TGeoCone *cone1 = new TGeoCone(kStaveLength,kConeInRadius,kConeOutRadius-0.0001,kConeInRadius,kConeOutRadius-0.0001);
    TGeoVolume *volCone1= new TGeoVolume("PolyimidePipe", cone1, medKapton);
    volCone1->SetFillColor(35);
    volCone1->SetLineColor(35);
    mechStavVol->AddNode(volCone1,1,new TGeoTranslation(x+0.25,y,z));
    mechStavVol->AddNode(volCone1,2,new TGeoTranslation(x-0.25,y,z));
    }

  if (fBuildLevel < 4) {
    TGeoTube *coolTubeW = new TGeoTube(0.,kConeInRadius-0.0001,kStaveLength);
    TGeoVolume *volCoolTubeW= new TGeoVolume("Water", coolTubeW, medWater);
    volCoolTubeW->SetFillColor(4);
    volCoolTubeW->SetLineColor(4);
    mechStavVol->AddNode(volCoolTubeW,0,new TGeoTranslation(x-0.25,y,z));
    mechStavVol->AddNode(volCoolTubeW,1,new TGeoTranslation(x+0.25,y,z));
  }

  if (fBuildLevel < 3) {
    //top fillament
    // Top filament M60J black-12 Carbon structure TGeoBBox (length,thickness,width)
    TGeoBBox *t2=new TGeoBBox(kS2-0.028,0.02/2,0.02/2); //0.04/2//TGeoBBox *t2=new TGeoBBox(kS2,0.01,0.02);//kS2-0.03 old Config.C
    TGeoVolume *volT2=new TGeoVolume("TopFilament", t2, medM60J3K);
    volT2->SetLineColor(12);
    volT2->SetFillColor(12); 
    for(int i=0;i<loop;i++){// i<28;i++){
      // 1) Front Left Top Filament
       mechStavVol->AddNode(volT2,i*4+1,new TGeoCombiTrans(x+kWidth+0.0036,y+kHeight+0.01,z-kStaveLength+0.1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,90-kAlpha,90-kBeta)));
      // 2) Front Right Top Filament
      mechStavVol->AddNode(volT2,i*4+2,new TGeoCombiTrans(x-kWidth-0.0036,y+kHeight+0.01,z-kStaveLength+0.1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,-90+kAlpha,-90+kBeta)));
      // 3) Back Left  Top Filament
      mechStavVol->AddNode(volT2,i*4+3,new TGeoCombiTrans(x+kWidth+0.0036,y+kHeight+0.01,z-kStaveLength+0.1+2*kL1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,-90+kAlpha,90-kBeta)));
      // 4) Back Right Top Filament
      mechStavVol->AddNode(volT2,i*4+4,new TGeoCombiTrans(x-kWidth-0.0036,y+kHeight+0.01,z-kStaveLength+0.1+2*kL1+(i*4*kL1)+kS1/2, new TGeoRotation("volT2",90,90-kAlpha,-90+kBeta)));
   }
 
     //Vertex  structure 

      //top ver trd1
      TGeoTrd1 *trd1 = new TGeoTrd1(0,kTopVertexMaxWidth/2,kStaveLength,kTopVertexHeight/2);
      TGeoVolume *ibdv = new TGeoVolume("TopVertex",trd1,medM60J3K);
      ibdv->SetFillColor(12);
      ibdv->SetLineColor(12);
      mechStavVol->AddNode(ibdv,1,new TGeoCombiTrans(x,y+kStaveHeight+0.03,z,new TGeoRotation("ibdv",0.,-90,0)));//y+kStaveHeight+0.056

      //left trd2
      TGeoTrd1 *trd2 = new TGeoTrd1(0,kSideVertexMWidth/2,kStaveLength, kSideVertexHeight/2);
      TGeoVolume *ibdv2 = new TGeoVolume("LeftVertex",trd2,medM60J3K);
      ibdv2->SetFillColor(12);
      ibdv2->SetLineColor(12);
      mechStavVol->AddNode(ibdv2,1,new TGeoCombiTrans(x+kStaveWidth/2-0.06,y-0.0355,z,new TGeoRotation("ibdv2",-103.3,90,0))); //x-kStaveWidth/2-0.09 old Config.C y-0.0355,

      //right trd3
      TGeoTrd1 *trd3 = new TGeoTrd1(0,kSideVertexMWidth/2,kStaveLength, kSideVertexHeight/2);
      TGeoVolume *ibdv3 = new TGeoVolume("RightVertex",trd3,medM60J3K);
      ibdv3->SetFillColor(12);
      ibdv3->SetLineColor(12);
      mechStavVol->AddNode(ibdv3,1,new TGeoCombiTrans(x-kStaveWidth/2+0.06,y-0.0355,z,new TGeoRotation("ibdv3",103.3,90,0))); //x-kStaveWidth/2+0.09 old Config.C
      
     //Carbon Fleece
      TGeoConeSeg *cons2 = new TGeoConeSeg(zsta,kConeOutRadius+klay1,kConeOutRadius+klay1+klay2,kConeOutRadius+klay1,kConeOutRadius+klay1+klay2,0,180); 
      TGeoVolume *cone12 = new TGeoVolume("CarbonFleecePipeCover",cons2,medCarbonFleece);
      cone12->SetFillColor(28);
      cone12->SetLineColor(28);
      mechStavVol->AddNode(cone12,1,new TGeoCombiTrans(x+0.25,y,z,new TGeoRotation("cone12",0,0,0)));
      mechStavVol->AddNode(cone12,2,new TGeoCombiTrans(x-0.25,y,z,new TGeoRotation("cone12",0,0,0)));

      TGeoBBox *box3 = new TGeoBBox((0.50-(2*(kConeOutRadius+klay1)))/2,klay2/2,zsta);//kStaveLength-0.50);
      TGeoVolume *plate3 = new TGeoVolume("CarbonFleeceMiddle",box3,medCarbonFleece);
      plate3->SetFillColor(28);
      plate3->SetLineColor(28);
      mechStavVol->AddNode(plate3,1,new TGeoCombiTrans(x,y-kConeOutRadius+klay1+(klay2/2),z,new TGeoRotation("plate3",0,0,0)));

      TGeoBBox *box31 = new TGeoBBox((0.75-0.25-kConeOutRadius-klay1)/2+0.0025,klay2/2,zsta);
      TGeoVolume *plate31 = new TGeoVolume("CarbonFleeceLeftRight",box31,medCarbonFleece);
      plate31->SetFillColor(28);
      plate31->SetLineColor(28);
      mechStavVol->AddNode(plate31,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+klay1+(0.75-0.25-kConeOutRadius-klay1)/2,y-kConeOutRadius+klay1+(klay2/2),z,new TGeoRotation("plate31",0,0,0)));
      mechStavVol->AddNode(plate31,2,new TGeoCombiTrans(x-0.25-kConeOutRadius-klay1-(0.75-0.25-kConeOutRadius-klay1)/2,y-kConeOutRadius+klay1+(klay2/2),z,new TGeoRotation("plate31",0,0,0)));

      TGeoBBox *box32 = new TGeoBBox((klay2/2),(kConeOutRadius-klay1)/2,zsta);
      TGeoVolume *plate32 = new TGeoVolume("CarbonFleeceVertical",box32,medCarbonFleece);
      plate32->SetFillColor(28);
      plate32->SetLineColor(28);
      mechStavVol->AddNode(plate32,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+klay1+(klay2/2),y+(klay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
      mechStavVol->AddNode(plate32,2,new TGeoCombiTrans(x+0.25-kConeOutRadius-klay1-(klay2/2),y+(klay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
      mechStavVol->AddNode(plate32,3,new TGeoCombiTrans(x-0.25+kConeOutRadius+klay1+(klay2/2),y+(klay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));
      mechStavVol->AddNode(plate32,4,new TGeoCombiTrans(x-0.25-kConeOutRadius-klay1-(klay2/2),y+(klay1-kConeOutRadius)/2,z,new TGeoRotation("plate32",0,0,0)));

     //Amec Thermasol red-2 cover tube FGS300 or Carbon Paper
      TGeoConeSeg *cons1 = new TGeoConeSeg(zsta,kConeOutRadius,kConeOutRadius+klay1-0.0001,kConeOutRadius,kConeOutRadius+klay1-0.0001,0,180);//kConeOutRadius+klay1-0.0001
      TGeoVolume *cone11 = new TGeoVolume("ThermasolPipeCover",cons1,medFGS003);
      cone11->SetFillColor(2);
      cone11->SetLineColor(2);
      mechStavVol->AddNode(cone11,1,new TGeoCombiTrans(x+0.25,y,z,new TGeoRotation("cone11",0,0,0)));
      mechStavVol->AddNode(cone11,2,new TGeoCombiTrans(x-0.25,y,z,new TGeoRotation("cone11",0,0,0)));

      TGeoBBox *box2 = new TGeoBBox((0.50-(2*kConeOutRadius))/2,(klay1/2),zsta);//kStaveLength-0.50);
      TGeoVolume *plate2 = new TGeoVolume("ThermasolMiddle",box2,medFGS003);
      plate2->SetFillColor(2);
      plate2->SetLineColor(2);
      mechStavVol->AddNode(plate2,1,new TGeoCombiTrans(x,y-kConeOutRadius+(klay1/2),z,new TGeoRotation("plate2",0,0,0)));

      TGeoBBox *box21 = new TGeoBBox((0.75-0.25-kConeOutRadius-klay1)/2+0.0025,(klay1/2),zsta);
      TGeoVolume *plate21 = new TGeoVolume("ThermasolLeftRight",box21,medFGS003);
      plate21->SetFillColor(2);
      plate21->SetLineColor(2);
      mechStavVol->AddNode(plate21,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+(0.75-0.25-kConeOutRadius)/2-(klay1/2)+0.0025,y-kConeOutRadius+(klay1/2),z,new TGeoRotation("plate21",0,0,0)));
      mechStavVol->AddNode(plate21,2,new TGeoCombiTrans(x-0.25-kConeOutRadius-(0.75-0.25-kConeOutRadius)/2+(klay1/2)-0.0025,y-kConeOutRadius+(klay1/2),z,new TGeoRotation("plate21",0,0,0)));

      TGeoBBox *box22 = new TGeoBBox((klay1/2),kConeOutRadius/2,zsta);
      TGeoVolume *plate22 = new TGeoVolume("ThermasolVertical",box22,medFGS003);
      plate22->SetFillColor(2);
      plate22->SetLineColor(2);
      mechStavVol->AddNode(plate22,1,new TGeoCombiTrans(x+0.25+kConeOutRadius+(klay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
      mechStavVol->AddNode(plate22,2,new TGeoCombiTrans(x+0.25-kConeOutRadius-(klay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
      mechStavVol->AddNode(plate22,3,new TGeoCombiTrans(x-0.25+kConeOutRadius+(klay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));
      mechStavVol->AddNode(plate22,4,new TGeoCombiTrans(x-0.25-kConeOutRadius-(klay1/2),y-kConeOutRadius/2,z,new TGeoRotation("plate22",0,0,0)));

     //K13D2U CF plate
      TGeoBBox *box1 = new TGeoBBox(2*kWidth,(klay3)/2,zsta);
      TGeoVolume *plate1 = new TGeoVolume("CFPlate",box1,medK13D2U2k);
      plate1->SetFillColor(5);
      plate1->SetLineColor(5);
      mechStavVol->AddNode(plate1,1,new TGeoCombiTrans(x,y-(kConeOutRadius+(klay3/2)),z,new TGeoRotation("plate1",0,0,0)));

     //C Fleece bottom plate 
      TGeoBBox *box6 = new TGeoBBox(2*kWidth,(klay2)/2,zsta);
      TGeoVolume *plate6 = new TGeoVolume("CarbonFleeceBottom",box6,medCarbonFleece);
      plate6->SetFillColor(2);
      plate6->SetLineColor(2);
      mechStavVol->AddNode(plate6,1,new TGeoCombiTrans(x,y-(kConeOutRadius+klay3+(klay2/2)),z,new TGeoRotation("plate6",0,0,0)));

    }
   if (fBuildLevel < 2) {
      //Glue klayers and kapton
     TGeoBBox *glue = new TGeoBBox(kStaveWidth/2, (klay4)/2, zsta);
      TGeoVolume *volGlue=new TGeoVolume("Glue", glue, medGlue);
      volGlue->SetLineColor(5);
      volGlue->SetFillColor(5); 
      // mechStavVol->AddNode(volGlue, 0, new TGeoCombiTrans(x,y-(kConeOutRadius+klay3+klay2+(klay4/2)), z, new TGeoRotation("",0, 0, 0)));
      mechStavVol->AddNode(volGlue, 0, new TGeoCombiTrans(x,y-(kConeOutRadius+klay3+klay2+(klay4)/2)+0.00005, z, new TGeoRotation("",0, 0, 0)));
    }

     if (fBuildLevel < 1) {
     //Flex Cable or Bus
      TGeoBBox *kapCable = new TGeoBBox(kStaveWidth/2, klay5/2, zsta);//klay5/2
      TGeoVolume *volCable=new TGeoVolume("FlexCable", kapCable, medFlexCable);
      volCable->SetLineColor(28);
      volCable->SetFillColor(28); 
      //      mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-(kConeOutRadius+klay3+klay2+klay4+fSensorThick+(klay5)/2)+0.0002, z, new TGeoRotation("",0, 0, 0)));
      mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-(kConeOutRadius+klay3+klay2+klay4+fSensorThick+(klay5)/2)+0.01185, z, new TGeoRotation("",0, 0, 0)));
      }
    // Done, return the stave structe
    return mechStavVol;
}

// model3
//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateStaveModel3(const Double_t xsta,
					       const Double_t zsta,
					       const TGeoManager *mgr){
//
// Create the mechanical stave structure for Model 3 of TDR
//
// Input:
//         xsta : X length
//         zsta : Z length
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      28 May 2013  Chinorat Kobdaj
// Updated:                   Mario Sitta
// Updated:                   Wanchaloem Poonsawat 
//
  
  // Materials defined in AliITSUv0
  TGeoMedium *medAir    = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medWater  = mgr->GetMedium("ITS_WATER$");

  TGeoMedium *medM60J3K    = mgr->GetMedium("ITS_M60J3K$"); 
  TGeoMedium *medKapton    = mgr->GetMedium("ITS_KAPTON(POLYCH2)$");
  TGeoMedium *medGlue      = mgr->GetMedium("ITS_GLUE$");
  TGeoMedium *medFlexCable = mgr->GetMedium("ITS_FLEXCABLE$");
  //TGeoMedium *medK13D2U2k  = mgr->GetMedium("ITS_K13D2U2k$");
  //TGeoMedium *medFGS003    = mgr->GetMedium("ITS_FGS003$"); 
  //TGeoMedium *medCarbonFleece = mgr->GetMedium("ITS_CarbonFleece$"); 

  // Local parameters
    Double_t kConeOutRadius = 0.15/2;
    Double_t kStaveLength = zsta*2;
    Double_t kStaveWidth = xsta*2;
    Double_t w = kStaveWidth/4;//1/2 of W
    Double_t staveHeight = 0.3;
    Double_t h = staveHeight/2;
    Double_t alpha = 90-33.;//90-30;
    Double_t the1 = alpha*TMath::DegToRad();
    Double_t s1 = w/TMath::Sin(the1);
    Double_t l = w/TMath::Tan(the1);
    Double_t s2 = TMath::Sqrt(h*h + s1*s1);//TMath::Sin(the2);
    Double_t the2 = TMath::ATan(h/s1);
    Double_t beta = the2*TMath::RadToDeg();
    Double_t klay4 = 0.007; //Glue
    Double_t klay5 = 0.01; //Flexcable
    Int_t  loop = (kStaveLength/(2*l))/2;
    Double_t hh = 0.01;
       Double_t ang1 = 0*TMath::DegToRad();
       Double_t ang2 = 0*TMath::DegToRad();
       Double_t ang3 = 0*TMath::DegToRad();
       Int_t chips = 4;
       Double_t headWidth=0.25;
       Double_t smcLength=kStaveLength/chips-2*headWidth;//6.25;
       Double_t smcWidth=kStaveWidth;
       Double_t smcSide1Thick=0.03;
       Double_t vaporThick=0.032;
       Double_t liquidThick=0.028;
       Double_t smcSide2Thick=0.01;
       Double_t smcSide3Thick=0.0055;
       Double_t smcSide4Thick=0.0095;
       Double_t smcSide5Thick=0.0075;
       Double_t smcSpace=0.01;


    char volname[30];
    snprintf(volname, 30, "%s%d_StaveStruct", AliITSUGeomTGeo::GetITSStavePattern(), fLayerNumber);
    
    // detailed structure ++++++++++++++
    Double_t z=0, y=0-0.007, x=0;

    // Polimide micro channels numbers
    Double_t yMC = y-h+0.01;
    Int_t nb = (Int_t)(kStaveWidth/0.1)+1;
    Double_t xstaMC = (nb*0.1-0.08)/2;


    TGeoVolume *mechStavVol = 0;
    if (fBuildLevel < 5) {
      // world (trapezoid)
      TGeoXtru *mechStruct = new TGeoXtru(2); //z sections
      Double_t xv[5] = {kStaveWidth/2+0.1,kStaveWidth/2+0.1,0,-kStaveWidth/2-0.1,-kStaveWidth/2-0.1};
      Double_t yv[5] = {-kConeOutRadius*2-0.07,0,staveHeight,0,-kConeOutRadius*2-0.07};    
      mechStruct->DefinePolygon(5,xv,yv);
      mechStruct->DefineSection(0,-kStaveLength-0.1,0,0,1.);
      mechStruct->DefineSection(1,kStaveLength+0.1,0,0,1.);
      mechStavVol = new TGeoVolume(volname, mechStruct, medAir);
      mechStavVol->SetLineColor(12);
      mechStavVol->SetFillColor(12); 
      mechStavVol->SetVisibility(kTRUE);

       // Silicon micro channels numbers
      
      TGeoBBox *tM0a=new TGeoBBox(smcWidth/2, 0.003/2, headWidth/2);
      TGeoVolume *volTM0a=new TGeoVolume("microChanTop1", tM0a, medKapton);
      volTM0a->SetLineColor(35);
      volTM0a->SetFillColor(35); 

      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0a, 0, new TGeoCombiTrans(x,yMC+0.03, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth+smcLength/2+(headWidth/2), new TGeoRotation("",ang1, ang2, ang3)));
      mechStavVol->AddNode(volTM0a, 1, new TGeoCombiTrans(x,yMC+0.03, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth-smcLength/2-(headWidth/2), new TGeoRotation("",ang1, ang2, ang3)));
      }
      TGeoBBox *tM0c=new TGeoBBox(0.3/2, 0.003/2,smcLength/2);
      TGeoVolume *volTM0c=new TGeoVolume("microChanTop2", tM0c, medKapton);
      volTM0c->SetLineColor(35);
      volTM0c->SetFillColor(35); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0c, 0, new TGeoCombiTrans(x+(smcWidth/2)-(0.3/2),yMC+0.03, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));
      mechStavVol->AddNode(volTM0c, 1, new TGeoCombiTrans(x-(smcWidth/2)+(0.3/2),yMC+0.03, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0c1=new TGeoBBox(0.2225/2, 0.003/2,smcLength/2);
      TGeoVolume *volTM0c1=new TGeoVolume("microChanBot1", tM0c1, medKapton);
      volTM0c1->SetLineColor(6);
      volTM0c1->SetFillColor(6); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0c1, 0, new TGeoCombiTrans(x+smcWidth/2-(smcSide1Thick)-(vaporThick)-(smcSide2Thick)-(smcSide3Thick)-(0.2225/2),yMC+0.03-hh-(0.003), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      mechStavVol->AddNode(volTM0c1, 1, new TGeoCombiTrans(x-smcWidth/2+(smcSide1Thick)+(liquidThick)+(smcSide2Thick)+(smcSide4Thick)+(0.2225/2),yMC+0.03-hh-(0.003), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0c2=new TGeoBBox(0.072/2, 0.003/2,smcLength/2);
      TGeoVolume *volTM0c2=new TGeoVolume("microChanBot2", tM0c2, medKapton);
      volTM0c2->SetLineColor(35);
      volTM0c2->SetFillColor(35); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0c2, 0, new TGeoCombiTrans(x+smcWidth/2-(0.072/2),yMC+0.03-(0.035+0.0015)-(0.003)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0c2r=new TGeoBBox(0.068/2, 0.003/2,smcLength/2);
      TGeoVolume *volTM0c2r=new TGeoVolume("microChanBot3", tM0c2r, medKapton);
      volTM0c2r->SetLineColor(35);
      volTM0c2r->SetFillColor(35); 
      for(Int_t  mo=1; mo<=chips; mo++) {      
      mechStavVol->AddNode(volTM0c2r, 0, new TGeoCombiTrans(x-smcWidth/2+(0.068/2),yMC+0.03-(0.035+0.0015)-(0.003)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0d=new TGeoBBox(smcSide1Thick/2, 0.035/2,smcLength/2);
      TGeoVolume *volTM0d=new TGeoVolume("microChanSide1", tM0d, medKapton);
      volTM0d->SetLineColor(12);
      volTM0d->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0d, 0, new TGeoCombiTrans(x+smcWidth/2-(smcSide1Thick/2),yMC+0.03-0.0015-(0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      mechStavVol->AddNode(volTM0d, 1, new TGeoCombiTrans(x-smcWidth/2+(smcSide1Thick/2),yMC+0.03-0.0015-(0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }

      TGeoBBox *tM0d1=new TGeoBBox(smcSide2Thick/2, 0.035/2,smcLength/2);
      TGeoVolume *volTM0d1=new TGeoVolume("microChanSide2", tM0d1, medKapton);
      volTM0d1->SetLineColor(12);
      volTM0d1->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0d1, 0, new TGeoCombiTrans(x+smcWidth/2-(smcSide1Thick)-(vaporThick)-(smcSide2Thick/2),yMC+0.03-(0.003+0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      mechStavVol->AddNode(volTM0d1, 1, new TGeoCombiTrans(x-smcWidth/2+(smcSide1Thick)+(liquidThick)+(smcSide2Thick/2),yMC+0.03-(0.003+0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0d2=new TGeoBBox(smcSide3Thick/2, (hh+0.003)/2, smcLength/2);
      TGeoVolume *volTM0d2=new TGeoVolume("microChanSide3", tM0d2, medKapton);
      volTM0d2->SetLineColor(12);
      volTM0d2->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0d2, 0, new TGeoCombiTrans(x+smcWidth/2-(smcSide1Thick)-(vaporThick)-(smcSide2Thick)-(smcSide3Thick/2),yMC+0.03-(0.003+hh+0.003)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0d2r=new TGeoBBox(smcSide4Thick/2, (hh+0.003)/2, smcLength/2);
      TGeoVolume *volTM0d2r=new TGeoVolume("microChanSide4", tM0d2r, medKapton);
      volTM0d2r->SetLineColor(12);
      volTM0d2r->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0d2r, 0, new TGeoCombiTrans(x-smcWidth/2+(smcSide1Thick)+(liquidThick)+(smcSide2Thick)+(smcSide4Thick/2),yMC+0.03-(0.003+hh+0.003)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0e=new TGeoBBox(smcSide5Thick/2, hh/2,smcLength/2);
      TGeoVolume *volTM0e=new TGeoVolume("microChanSide5", tM0e, medKapton);    
      volTM0e->SetLineColor(12);
      volTM0e->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      for (Int_t ie=0;ie<11;ie++) {
	mechStavVol->AddNode(volTM0e, 0, new TGeoCombiTrans(x-(ie*(smcSpace+smcSide5Thick))+smcWidth/2-(smcSide1Thick)-(vaporThick)-(smcSide2Thick)-(smcSide3Thick)-smcSpace-(smcSide5Thick/2),yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
	mechStavVol->AddNode(volTM0e, 1, new TGeoCombiTrans(x+(ie*(smcSpace+smcSide5Thick))-smcWidth/2+(smcSide1Thick)+(liquidThick)+(smcSide2Thick)+(smcSide4Thick)+smcSpace+(smcSide5Thick/2),yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
         }
      }
      
      TGeoBBox *tM0f=new TGeoBBox(0.02/2, hh/2, smcLength/2);
      TGeoVolume *volTM0f=new TGeoVolume("microChanTop3", tM0f, medKapton);
      //Double_t smcChannels=12;
      Double_t smcCloseWallvapor=smcWidth/2-smcSide1Thick-vaporThick-smcSide2Thick-smcSide3Thick-12*smcSpace-11*smcSide5Thick;
      Double_t smcCloseWallliquid=smcWidth/2-smcSide1Thick-liquidThick-smcSide2Thick-smcSide4Thick-12*smcSpace-11*smcSide5Thick;
      volTM0f->SetLineColor(12);
      volTM0f->SetFillColor(12); 
      for(Int_t  mo=1; mo<=chips; mo++) {
       mechStavVol->AddNode(volTM0f, 0, new TGeoCombiTrans(x+smcCloseWallvapor-(0.02)/2,yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
       mechStavVol->AddNode(volTM0f, 1, new TGeoCombiTrans(x-smcCloseWallliquid+(0.02)/2,yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      //Head(back) microchannel

      TGeoBBox *tM0hb=new TGeoBBox(smcWidth/2, 0.025/2, headWidth/2);
      TGeoVolume *volTM0hb=new TGeoVolume("microChanHeadBackBottom1", tM0hb, medKapton);
      volTM0hb->SetLineColor(4);
      volTM0hb->SetFillColor(4); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0hb, 0, new TGeoCombiTrans(x,yMC+0.03-0.0145-(0.025/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth+smcLength/2+(headWidth/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      mechStavVol->AddNode(volTM0hb, 1, new TGeoCombiTrans(x,yMC+0.03-0.0145-(0.025)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth-smcLength/2-(headWidth/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0h1=new TGeoBBox(smcWidth/2, 0.013/2, 0.05/2);
      TGeoVolume *volTM0h1=new TGeoVolume("microChanHeadBackBottom2", tM0h1, medKapton);
      volTM0h1->SetLineColor(5);
      volTM0h1->SetFillColor(5); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0h1, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-(0.013/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth-smcLength/2-headWidth+(0.05/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0h2=new TGeoBBox(smcWidth/2, 0.003/2, 0.18/2);
      TGeoVolume *volTM0h2=new TGeoVolume("microChanHeadBackBottom7", tM0h2, medKapton);
      volTM0h2->SetLineColor(6);
      volTM0h2->SetFillColor(6);
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0h2, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-0.01-(0.003/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth-smcLength/2-0.02-(0.18/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0h3=new TGeoBBox(smcWidth/2, 0.013/2, 0.02/2);
      TGeoVolume *volTM0h3=new TGeoVolume("microChanHeadBackBottom3", tM0h3, medKapton);
      volTM0h3->SetLineColor(5);
      volTM0h3->SetFillColor(5); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0h3, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-(0.013/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth-smcLength/2-(0.02/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0b1=new TGeoBBox(smcWidth/2, 0.013/2, 0.03/2);
      TGeoVolume *volTM0b1=new TGeoVolume("microChanHeadBackBottom4", tM0b1, medKapton);
      volTM0b1->SetLineColor(5);
      volTM0b1->SetFillColor(5); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0b1, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-(0.013/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth+smcLength/2+headWidth-(0.03/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0b2=new TGeoBBox(smcWidth/2, 0.003/2, 0.2/2);
      TGeoVolume *volTM0b2=new TGeoVolume("microChanHeadBackBottom5", tM0b2, medKapton);
      volTM0b2->SetLineColor(6);
      volTM0b2->SetFillColor(6); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0b2, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-0.01-(0.003/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth+smcLength/2+0.02+(0.2/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0b3=new TGeoBBox(smcWidth/2, 0.013/2, 0.02/2);
      TGeoVolume *volTM0b3=new TGeoVolume("microChanHeadBackBottom6", tM0b3, medKapton);
      volTM0b3->SetLineColor(5);
      volTM0b3->SetFillColor(5); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0b3, 0, new TGeoCombiTrans(x,yMC+0.03-0.0015-(0.013/2), z+(mo-3)*kStaveLength/4+smcLength/2+headWidth+smcLength/2+(0.02/2), new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
     
      TGeoBBox *tM0b=new TGeoBBox(0.02/2, 0.02/2, zsta);
      TGeoVolume *volTM0b=new TGeoVolume("microChanWalls", tM0b, medKapton);
      volTM0b->SetLineColor(35);
      volTM0b->SetFillColor(35); 
      for (Int_t ib=0;ib<nb;ib++) {
	//mechStavVol->AddNode(volTM0b, ib, new TGeoCombiTrans(x+ib*0.1-xstaMC+0.01,yMC, z, new TGeoRotation("",0, 0, 0)));
      }
      
      } 
    
    if (fBuildLevel < 4) {

      //**********cooling  inlet outlet

      TGeoBBox *tM0dv=new TGeoBBox(vaporThick/2, 0.035/2,smcLength/2);
      TGeoVolume *volTM0dv=new TGeoVolume("microChanVapor", tM0dv, medWater);
      volTM0dv->SetLineColor(2);
      volTM0dv->SetFillColor(2);
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0dv, 0, new TGeoCombiTrans(x+smcWidth/2-(smcSide1Thick)-(vaporThick/2),yMC+0.03-0.0015-(0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      TGeoBBox *tM0dl=new TGeoBBox(liquidThick/2, 0.035/2,smcLength/2);
      TGeoVolume *volTM0dl=new TGeoVolume("microChanLiquid", tM0dl, medWater);
      volTM0dl->SetLineColor(3);
      volTM0dl->SetFillColor(3); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      mechStavVol->AddNode(volTM0dl, 0, new TGeoCombiTrans(x-smcWidth/2+(smcSide1Thick)+(liquidThick/2),yMC+0.03-0.0015-(0.035)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      // small cooling fluid now using water wait for freeon value  
      TGeoBBox *tM0dlq=new TGeoBBox(smcSpace/2, hh/2,smcLength/2);
      TGeoVolume *volTM0dlq=new TGeoVolume("smallLiquid", tM0dlq, medWater);
      volTM0dlq->SetLineColor(3);
      volTM0dlq->SetFillColor(3); 
      TGeoBBox *tM0dvp=new TGeoBBox(smcSpace/2, hh/2,smcLength/2);
      TGeoVolume *volTM0dvp=new TGeoVolume("microChanVapor", tM0dvp, medWater);
      volTM0dvp->SetLineColor(2);
      volTM0dvp->SetFillColor(2); 
      for(Int_t  mo=1; mo<=chips; mo++) {
      for (Int_t is=0;is<12;is++) {
	mechStavVol->AddNode(volTM0dlq, 0, new TGeoCombiTrans(x+(is*(smcSpace+smcSide5Thick))-smcWidth/2+(smcSide1Thick)+(vaporThick)+(smcSide2Thick)+(smcSide3Thick)+smcSpace/2,yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
	mechStavVol->AddNode(volTM0dvp, 1, new TGeoCombiTrans(x-(is*(smcSpace+smcSide5Thick))+smcWidth/2-(smcSide1Thick)-(vaporThick)-(smcSide2Thick)-(smcSide3Thick)-smcSpace/2,yMC+0.03-(0.003+hh)/2, z+(mo-3)*kStaveLength/4+smcLength/2+headWidth, new TGeoRotation("",ang1, ang2, ang3)));//("",0, 0, 0)));
      }
      }

      //*************

    }
    
    if (fBuildLevel < 3) {

      //Bottom filament CFRP black-12 Carbon structure TGeoBBox (thickness,width,length)
 
      Double_t filWidth = 0.04;
      Double_t filHeight= 0.02;
      TGeoBBox *t1=new TGeoBBox(filHeight/2,filWidth/2,s1);
      TGeoVolume *volT1=new TGeoVolume("bottomFilament", t1, medM60J3K);
      volT1->SetLineColor(12);
      volT1->SetFillColor(12); 
      for(int i=0;i<loop;i++){//i<30;i++){
       	mechStavVol->AddNode(volT1,4*i+0,
				    new TGeoCombiTrans(x+w,y-h+0.04+filHeight/2,z-kStaveLength/2+(4*l*i)+s1/2, 
						       new TGeoRotation("volT1",-90,alpha,0)));
	mechStavVol->AddNode(volT1,4*i+1,
				    new TGeoCombiTrans(x-w,y-h+0.04+filHeight/2,z-kStaveLength/2+(4*l*i)+s1/2, 
						       new TGeoRotation("volT1",90,alpha,0)));
	mechStavVol->AddNode(volT1,4*i+2,
				    new TGeoCombiTrans(x+w,y-h+0.04+filHeight/2,z-kStaveLength/2+2*l+(i*4*l)+s1/2, 
						       new TGeoRotation("volT1",-90,-alpha,0)));
	mechStavVol->AddNode(volT1,4*i+3,
				    new TGeoCombiTrans(x-w,y-h+0.04+filHeight/2,z-kStaveLength/2+2*l+(i*4*l)+s1/2, 
						       new TGeoRotation("volT1",-90,+alpha,0)));
	}
 
     // Top filament CERP black-12 Carbon structure TGeoBBox (length,thickness,width)

      TGeoBBox *t2=new TGeoBBox(s2,filHeight/2,filWidth/2);
      TGeoVolume *volT2=new TGeoVolume("topFilament", t2, medM60J3K);
      volT2->SetLineColor(12);
      volT2->SetFillColor(12); 
      for(int i=0;i<loop;i++){ //i<30;i++){
       	mechStavVol->AddNode(volT2,4*i+0,
				    new TGeoCombiTrans(x+w,y+0.04+filHeight/2,z-kStaveLength/2+(i*4*l)+s1/2,
						       new TGeoRotation("volT2",90,90-alpha,90-beta)));
	mechStavVol->AddNode(volT2,4*i+1,
				    new TGeoCombiTrans(x-w,y+0.04+filHeight/2,z-kStaveLength/2+(i*4*l)+s1/2,
						       new TGeoRotation("volT2",90,-90+alpha,-90+beta)));
	mechStavVol->AddNode(volT2,4*i+2,
				    new TGeoCombiTrans(x+w,y+0.04+filHeight/2,z-kStaveLength/2+2*l+(i*4*l)+s1/2,
						       new TGeoRotation("volT2",90,-90+alpha,90-beta)));
	mechStavVol->AddNode(volT2,4*i+3,
				    new TGeoCombiTrans(x-w,y+0.04+filHeight/2,z-kStaveLength/2+2*l+(i*4*l)+s1/2, 
						       new TGeoRotation("volT2",90,90-alpha,-90+beta)));
	}
    }

    if (fBuildLevel < 2) {

      // Glue Filament and Silicon MicroChannel
      TGeoBBox *tM0=new TGeoBBox(xstaMC/5, klay4/2, zsta);
      TGeoVolume *volTM0=new TGeoVolume("glueFM", tM0,medGlue );
      volTM0->SetLineColor(5);
      volTM0->SetFillColor(5); 
      mechStavVol->AddNode(volTM0, 0, new TGeoCombiTrans(x-xsta/2-0.25,0.03+yMC, z, new TGeoRotation("",0, 0, 0)));
      mechStavVol->AddNode(volTM0, 1, new TGeoCombiTrans(x+xsta/2+0.25,0.03+yMC, z, new TGeoRotation("",0, 0, 0)));

            
      // Glue microchannel and sensor
      TGeoBBox *glueM = new TGeoBBox(xstaMC/5, klay4/2, zsta);
      TGeoVolume *volGlueM=new TGeoVolume("glueMS", glueM, medGlue);
      volGlueM->SetLineColor(5);
      volGlueM->SetFillColor(5); 
      mechStavVol->AddNode(volGlueM, 0, new TGeoCombiTrans(x-xsta/2-0.25,yMC-0.01, z, new TGeoRotation("",0, 0, 0)));
      mechStavVol->AddNode(volGlueM, 1, new TGeoCombiTrans(x+xsta/2+0.25,yMC-0.01, z, new TGeoRotation("",0, 0, 0)));
     
       // Glue sensor and kapton
      TGeoBBox *glue = new TGeoBBox(xsta, klay4/2, zsta);
      TGeoVolume *volGlue=new TGeoVolume("glueSensorBus", glue, medGlue);
      volGlue->SetLineColor(5);
      volGlue->SetFillColor(5); 
       mechStavVol->AddNode(volGlue, 1, new TGeoCombiTrans(x, y-0.154-fSensorThick-klay4/2, z, new TGeoRotation("",0, 0, 0)));
    }      

    if (fBuildLevel < 1) {
      TGeoBBox *kapCable = new TGeoBBox(xsta, klay5/2, zsta);
      TGeoVolume *volCable=new TGeoVolume("Flexcable", kapCable, medFlexCable);
      volCable->SetLineColor(28);
      volCable->SetFillColor(28); 
      mechStavVol->AddNode(volCable, 0, new TGeoCombiTrans(x, y-0.154-fSensorThick-klay4-klay5/2, z, new TGeoRotation("",0, 0, 0)));
    }

  // Done, return the stave structur
    return mechStavVol;
 }

//________________________________________________________________________
TGeoVolume* AliITSUv0Layer::CreateChip(const Double_t xsta,
                                         const Double_t ysta,   
					 const Double_t zsta,
					 const TGeoManager *mgr){
//
// Creates the actual Chip
//
// Input:
//         xsta,zsta : the stave dimensions
//         mgr  : the GeoManager (used only to get the proper material)
//
// Output:
//
// Return:
//
// Created:      22 Jun 2011  Mario Sitta
//

  char volname[30];
  Double_t xlen, ylen, zlen;
  Double_t xpos, ypos, zpos;


  // First create all needed shapes

  // The chip
  TGeoBBox *chip = new TGeoBBox(xsta,  ysta, zsta/fNChips);

  // The sensor
  xlen = chip->GetDX();
  ylen = 0.5*fSensorThick;
  zlen = chip->GetDZ();
  TGeoBBox *sensor = new TGeoBBox(xlen, ylen, zlen);


  // We have all shapes: now create the real volumes
  //TGeoMedium *medAir = mgr->GetMedium("ITS_AIR$");
  TGeoMedium *medSi  = mgr->GetMedium("ITS_SI$");

  snprintf(volname, 30, "%s%d", AliITSUGeomTGeo::GetITSChipPattern(), fLayerNumber);
  // TGeoVolume *modVol = new TGeoVolume(volname, chip, medAir);
  TGeoVolume *modVol = new TGeoVolume(volname, chip, medSi);
  modVol->SetVisibility(kTRUE);
  modVol->SetLineColor(1);

  snprintf(volname, 30, "%s%d", AliITSUGeomTGeo::GetITSSensorPattern(), fLayerNumber);
  TGeoVolume *sensVol = new TGeoVolume(volname, sensor, medSi);
  sensVol->SetVisibility(kTRUE);
  sensVol->SetLineColor(8);
  sensVol->SetLineWidth(1);
  sensVol->SetFillColor(sensVol->GetLineColor());
  sensVol->SetFillStyle(4000); // 0% transparent


  // Now build up the chip
  xpos = 0.;
  ypos = -chip->GetDY() + sensor->GetDY();
  zpos = 0.;

  modVol->AddNode(sensVol, 1, new TGeoTranslation(xpos, ypos, zpos));

  // Done, return the chip
  return modVol;
}

//________________________________________________________________________
Double_t AliITSUv0Layer::RadiusOfTurboContainer(){
//
// Computes the inner radius of the air container for the Turbo configuration
// as the radius of either the circle tangent to the stave or the circle
// passing for the stave's lower vertex
//
// Input:
//         none (all needed parameters are class members)
//
// Output:
//
// Return:
//        the radius of the container if >0, else flag to use the lower vertex
//
// Created:      08 Mar 2012  Mario Sitta
//

  Double_t rr, delta, z, lstav, rstav;

  if (fStaveThick > 89.) // Very big angle: avoid overflows since surely
    return -1;            // the radius from lower vertex is the right value

  rstav = fLayRadius + 0.5*fStaveThick;
  delta = (0.5*fStaveThick)/CosD(fStaveTilt);
  z     = (0.5*fStaveThick)*TanD(fStaveTilt);

  rr = rstav - delta;
  lstav = (0.5*fStaveWidth) - z;

  if ( (rr*SinD(fStaveTilt) < lstav) )
    return (rr*CosD(fStaveTilt));
  else
    return -1;
}

//________________________________________________________________________
void AliITSUv0Layer::SetStaveTilt(const Double_t t)
{
//
// Sets the Stave tilt angle (for turbo layers only)
//
// Input:
//         t :  the stave tilt angle
//
// Output:
//
// Return:
//
// Created:      08 Jul 2011  Mario Sitta
//

  if (fIsTurbo)
    fStaveTilt = t;
  else
    AliError("Not a Turbo layer");

}

//________________________________________________________________________
void AliITSUv0Layer::SetStaveWidth(const Double_t w){
//
// Sets the Stave width (for turbo layers only)
//
// Input:
//         w :  the stave width
//
// Output:
//
// Return:
//
// Created:      08 Jul 2011  Mario Sitta
//

  if (fIsTurbo)
    fStaveWidth = w;
  else
    AliError("Not a Turbo layer");

}
 AliITSUv0Layer.cxx:1
 AliITSUv0Layer.cxx:2
 AliITSUv0Layer.cxx:3
 AliITSUv0Layer.cxx:4
 AliITSUv0Layer.cxx:5
 AliITSUv0Layer.cxx:6
 AliITSUv0Layer.cxx:7
 AliITSUv0Layer.cxx:8
 AliITSUv0Layer.cxx:9
 AliITSUv0Layer.cxx:10
 AliITSUv0Layer.cxx:11
 AliITSUv0Layer.cxx:12
 AliITSUv0Layer.cxx:13
 AliITSUv0Layer.cxx:14
 AliITSUv0Layer.cxx:15
 AliITSUv0Layer.cxx:16
 AliITSUv0Layer.cxx:17
 AliITSUv0Layer.cxx:18
 AliITSUv0Layer.cxx:19
 AliITSUv0Layer.cxx:20
 AliITSUv0Layer.cxx:21
 AliITSUv0Layer.cxx:22
 AliITSUv0Layer.cxx:23
 AliITSUv0Layer.cxx:24
 AliITSUv0Layer.cxx:25
 AliITSUv0Layer.cxx:26
 AliITSUv0Layer.cxx:27
 AliITSUv0Layer.cxx:28
 AliITSUv0Layer.cxx:29
 AliITSUv0Layer.cxx:30
 AliITSUv0Layer.cxx:31
 AliITSUv0Layer.cxx:32
 AliITSUv0Layer.cxx:33
 AliITSUv0Layer.cxx:34
 AliITSUv0Layer.cxx:35
 AliITSUv0Layer.cxx:36
 AliITSUv0Layer.cxx:37
 AliITSUv0Layer.cxx:38
 AliITSUv0Layer.cxx:39
 AliITSUv0Layer.cxx:40
 AliITSUv0Layer.cxx:41
 AliITSUv0Layer.cxx:42
 AliITSUv0Layer.cxx:43
 AliITSUv0Layer.cxx:44
 AliITSUv0Layer.cxx:45
 AliITSUv0Layer.cxx:46
 AliITSUv0Layer.cxx:47
 AliITSUv0Layer.cxx:48
 AliITSUv0Layer.cxx:49
 AliITSUv0Layer.cxx:50
 AliITSUv0Layer.cxx:51
 AliITSUv0Layer.cxx:52
 AliITSUv0Layer.cxx:53
 AliITSUv0Layer.cxx:54
 AliITSUv0Layer.cxx:55
 AliITSUv0Layer.cxx:56
 AliITSUv0Layer.cxx:57
 AliITSUv0Layer.cxx:58
 AliITSUv0Layer.cxx:59
 AliITSUv0Layer.cxx:60
 AliITSUv0Layer.cxx:61
 AliITSUv0Layer.cxx:62
 AliITSUv0Layer.cxx:63
 AliITSUv0Layer.cxx:64
 AliITSUv0Layer.cxx:65
 AliITSUv0Layer.cxx:66
 AliITSUv0Layer.cxx:67
 AliITSUv0Layer.cxx:68
 AliITSUv0Layer.cxx:69
 AliITSUv0Layer.cxx:70
 AliITSUv0Layer.cxx:71
 AliITSUv0Layer.cxx:72
 AliITSUv0Layer.cxx:73
 AliITSUv0Layer.cxx:74
 AliITSUv0Layer.cxx:75
 AliITSUv0Layer.cxx:76
 AliITSUv0Layer.cxx:77
 AliITSUv0Layer.cxx:78
 AliITSUv0Layer.cxx:79
 AliITSUv0Layer.cxx:80
 AliITSUv0Layer.cxx:81
 AliITSUv0Layer.cxx:82
 AliITSUv0Layer.cxx:83
 AliITSUv0Layer.cxx:84
 AliITSUv0Layer.cxx:85
 AliITSUv0Layer.cxx:86
 AliITSUv0Layer.cxx:87
 AliITSUv0Layer.cxx:88
 AliITSUv0Layer.cxx:89
 AliITSUv0Layer.cxx:90
 AliITSUv0Layer.cxx:91
 AliITSUv0Layer.cxx:92
 AliITSUv0Layer.cxx:93
 AliITSUv0Layer.cxx:94
 AliITSUv0Layer.cxx:95
 AliITSUv0Layer.cxx:96
 AliITSUv0Layer.cxx:97
 AliITSUv0Layer.cxx:98
 AliITSUv0Layer.cxx:99
 AliITSUv0Layer.cxx:100
 AliITSUv0Layer.cxx:101
 AliITSUv0Layer.cxx:102
 AliITSUv0Layer.cxx:103
 AliITSUv0Layer.cxx:104
 AliITSUv0Layer.cxx:105
 AliITSUv0Layer.cxx:106
 AliITSUv0Layer.cxx:107
 AliITSUv0Layer.cxx:108
 AliITSUv0Layer.cxx:109
 AliITSUv0Layer.cxx:110
 AliITSUv0Layer.cxx:111
 AliITSUv0Layer.cxx:112
 AliITSUv0Layer.cxx:113
 AliITSUv0Layer.cxx:114
 AliITSUv0Layer.cxx:115
 AliITSUv0Layer.cxx:116
 AliITSUv0Layer.cxx:117
 AliITSUv0Layer.cxx:118
 AliITSUv0Layer.cxx:119
 AliITSUv0Layer.cxx:120
 AliITSUv0Layer.cxx:121
 AliITSUv0Layer.cxx:122
 AliITSUv0Layer.cxx:123
 AliITSUv0Layer.cxx:124
 AliITSUv0Layer.cxx:125
 AliITSUv0Layer.cxx:126
 AliITSUv0Layer.cxx:127
 AliITSUv0Layer.cxx:128
 AliITSUv0Layer.cxx:129
 AliITSUv0Layer.cxx:130
 AliITSUv0Layer.cxx:131
 AliITSUv0Layer.cxx:132
 AliITSUv0Layer.cxx:133
 AliITSUv0Layer.cxx:134
 AliITSUv0Layer.cxx:135
 AliITSUv0Layer.cxx:136
 AliITSUv0Layer.cxx:137
 AliITSUv0Layer.cxx:138
 AliITSUv0Layer.cxx:139
 AliITSUv0Layer.cxx:140
 AliITSUv0Layer.cxx:141
 AliITSUv0Layer.cxx:142
 AliITSUv0Layer.cxx:143
 AliITSUv0Layer.cxx:144
 AliITSUv0Layer.cxx:145
 AliITSUv0Layer.cxx:146
 AliITSUv0Layer.cxx:147
 AliITSUv0Layer.cxx:148
 AliITSUv0Layer.cxx:149
 AliITSUv0Layer.cxx:150
 AliITSUv0Layer.cxx:151
 AliITSUv0Layer.cxx:152
 AliITSUv0Layer.cxx:153
 AliITSUv0Layer.cxx:154
 AliITSUv0Layer.cxx:155
 AliITSUv0Layer.cxx:156
 AliITSUv0Layer.cxx:157
 AliITSUv0Layer.cxx:158
 AliITSUv0Layer.cxx:159
 AliITSUv0Layer.cxx:160
 AliITSUv0Layer.cxx:161
 AliITSUv0Layer.cxx:162
 AliITSUv0Layer.cxx:163
 AliITSUv0Layer.cxx:164
 AliITSUv0Layer.cxx:165
 AliITSUv0Layer.cxx:166
 AliITSUv0Layer.cxx:167
 AliITSUv0Layer.cxx:168
 AliITSUv0Layer.cxx:169
 AliITSUv0Layer.cxx:170
 AliITSUv0Layer.cxx:171
 AliITSUv0Layer.cxx:172
 AliITSUv0Layer.cxx:173
 AliITSUv0Layer.cxx:174
 AliITSUv0Layer.cxx:175
 AliITSUv0Layer.cxx:176
 AliITSUv0Layer.cxx:177
 AliITSUv0Layer.cxx:178
 AliITSUv0Layer.cxx:179
 AliITSUv0Layer.cxx:180
 AliITSUv0Layer.cxx:181
 AliITSUv0Layer.cxx:182
 AliITSUv0Layer.cxx:183
 AliITSUv0Layer.cxx:184
 AliITSUv0Layer.cxx:185
 AliITSUv0Layer.cxx:186
 AliITSUv0Layer.cxx:187
 AliITSUv0Layer.cxx:188
 AliITSUv0Layer.cxx:189
 AliITSUv0Layer.cxx:190
 AliITSUv0Layer.cxx:191
 AliITSUv0Layer.cxx:192
 AliITSUv0Layer.cxx:193
 AliITSUv0Layer.cxx:194
 AliITSUv0Layer.cxx:195
 AliITSUv0Layer.cxx:196
 AliITSUv0Layer.cxx:197
 AliITSUv0Layer.cxx:198
 AliITSUv0Layer.cxx:199
 AliITSUv0Layer.cxx:200
 AliITSUv0Layer.cxx:201
 AliITSUv0Layer.cxx:202
 AliITSUv0Layer.cxx:203
 AliITSUv0Layer.cxx:204
 AliITSUv0Layer.cxx:205
 AliITSUv0Layer.cxx:206
 AliITSUv0Layer.cxx:207
 AliITSUv0Layer.cxx:208
 AliITSUv0Layer.cxx:209
 AliITSUv0Layer.cxx:210
 AliITSUv0Layer.cxx:211
 AliITSUv0Layer.cxx:212
 AliITSUv0Layer.cxx:213
 AliITSUv0Layer.cxx:214
 AliITSUv0Layer.cxx:215
 AliITSUv0Layer.cxx:216
 AliITSUv0Layer.cxx:217
 AliITSUv0Layer.cxx:218
 AliITSUv0Layer.cxx:219
 AliITSUv0Layer.cxx:220
 AliITSUv0Layer.cxx:221
 AliITSUv0Layer.cxx:222
 AliITSUv0Layer.cxx:223
 AliITSUv0Layer.cxx:224
 AliITSUv0Layer.cxx:225
 AliITSUv0Layer.cxx:226
 AliITSUv0Layer.cxx:227
 AliITSUv0Layer.cxx:228
 AliITSUv0Layer.cxx:229
 AliITSUv0Layer.cxx:230
 AliITSUv0Layer.cxx:231
 AliITSUv0Layer.cxx:232
 AliITSUv0Layer.cxx:233
 AliITSUv0Layer.cxx:234
 AliITSUv0Layer.cxx:235
 AliITSUv0Layer.cxx:236
 AliITSUv0Layer.cxx:237
 AliITSUv0Layer.cxx:238
 AliITSUv0Layer.cxx:239
 AliITSUv0Layer.cxx:240
 AliITSUv0Layer.cxx:241
 AliITSUv0Layer.cxx:242
 AliITSUv0Layer.cxx:243
 AliITSUv0Layer.cxx:244
 AliITSUv0Layer.cxx:245
 AliITSUv0Layer.cxx:246
 AliITSUv0Layer.cxx:247
 AliITSUv0Layer.cxx:248
 AliITSUv0Layer.cxx:249
 AliITSUv0Layer.cxx:250
 AliITSUv0Layer.cxx:251
 AliITSUv0Layer.cxx:252
 AliITSUv0Layer.cxx:253
 AliITSUv0Layer.cxx:254
 AliITSUv0Layer.cxx:255
 AliITSUv0Layer.cxx:256
 AliITSUv0Layer.cxx:257
 AliITSUv0Layer.cxx:258
 AliITSUv0Layer.cxx:259
 AliITSUv0Layer.cxx:260
 AliITSUv0Layer.cxx:261
 AliITSUv0Layer.cxx:262
 AliITSUv0Layer.cxx:263
 AliITSUv0Layer.cxx:264
 AliITSUv0Layer.cxx:265
 AliITSUv0Layer.cxx:266
 AliITSUv0Layer.cxx:267
 AliITSUv0Layer.cxx:268
 AliITSUv0Layer.cxx:269
 AliITSUv0Layer.cxx:270
 AliITSUv0Layer.cxx:271
 AliITSUv0Layer.cxx:272
 AliITSUv0Layer.cxx:273
 AliITSUv0Layer.cxx:274
 AliITSUv0Layer.cxx:275
 AliITSUv0Layer.cxx:276
 AliITSUv0Layer.cxx:277
 AliITSUv0Layer.cxx:278
 AliITSUv0Layer.cxx:279
 AliITSUv0Layer.cxx:280
 AliITSUv0Layer.cxx:281
 AliITSUv0Layer.cxx:282
 AliITSUv0Layer.cxx:283
 AliITSUv0Layer.cxx:284
 AliITSUv0Layer.cxx:285
 AliITSUv0Layer.cxx:286
 AliITSUv0Layer.cxx:287
 AliITSUv0Layer.cxx:288
 AliITSUv0Layer.cxx:289
 AliITSUv0Layer.cxx:290
 AliITSUv0Layer.cxx:291
 AliITSUv0Layer.cxx:292
 AliITSUv0Layer.cxx:293
 AliITSUv0Layer.cxx:294
 AliITSUv0Layer.cxx:295
 AliITSUv0Layer.cxx:296
 AliITSUv0Layer.cxx:297
 AliITSUv0Layer.cxx:298
 AliITSUv0Layer.cxx:299
 AliITSUv0Layer.cxx:300
 AliITSUv0Layer.cxx:301
 AliITSUv0Layer.cxx:302
 AliITSUv0Layer.cxx:303
 AliITSUv0Layer.cxx:304
 AliITSUv0Layer.cxx:305
 AliITSUv0Layer.cxx:306
 AliITSUv0Layer.cxx:307
 AliITSUv0Layer.cxx:308
 AliITSUv0Layer.cxx:309
 AliITSUv0Layer.cxx:310
 AliITSUv0Layer.cxx:311
 AliITSUv0Layer.cxx:312
 AliITSUv0Layer.cxx:313
 AliITSUv0Layer.cxx:314
 AliITSUv0Layer.cxx:315
 AliITSUv0Layer.cxx:316
 AliITSUv0Layer.cxx:317
 AliITSUv0Layer.cxx:318
 AliITSUv0Layer.cxx:319
 AliITSUv0Layer.cxx:320
 AliITSUv0Layer.cxx:321
 AliITSUv0Layer.cxx:322
 AliITSUv0Layer.cxx:323
 AliITSUv0Layer.cxx:324
 AliITSUv0Layer.cxx:325
 AliITSUv0Layer.cxx:326
 AliITSUv0Layer.cxx:327
 AliITSUv0Layer.cxx:328
 AliITSUv0Layer.cxx:329
 AliITSUv0Layer.cxx:330
 AliITSUv0Layer.cxx:331
 AliITSUv0Layer.cxx:332
 AliITSUv0Layer.cxx:333
 AliITSUv0Layer.cxx:334
 AliITSUv0Layer.cxx:335
 AliITSUv0Layer.cxx:336
 AliITSUv0Layer.cxx:337
 AliITSUv0Layer.cxx:338
 AliITSUv0Layer.cxx:339
 AliITSUv0Layer.cxx:340
 AliITSUv0Layer.cxx:341
 AliITSUv0Layer.cxx:342
 AliITSUv0Layer.cxx:343
 AliITSUv0Layer.cxx:344
 AliITSUv0Layer.cxx:345
 AliITSUv0Layer.cxx:346
 AliITSUv0Layer.cxx:347
 AliITSUv0Layer.cxx:348
 AliITSUv0Layer.cxx:349
 AliITSUv0Layer.cxx:350
 AliITSUv0Layer.cxx:351
 AliITSUv0Layer.cxx:352
 AliITSUv0Layer.cxx:353
 AliITSUv0Layer.cxx:354
 AliITSUv0Layer.cxx:355
 AliITSUv0Layer.cxx:356
 AliITSUv0Layer.cxx:357
 AliITSUv0Layer.cxx:358
 AliITSUv0Layer.cxx:359
 AliITSUv0Layer.cxx:360
 AliITSUv0Layer.cxx:361
 AliITSUv0Layer.cxx:362
 AliITSUv0Layer.cxx:363
 AliITSUv0Layer.cxx:364
 AliITSUv0Layer.cxx:365
 AliITSUv0Layer.cxx:366
 AliITSUv0Layer.cxx:367
 AliITSUv0Layer.cxx:368
 AliITSUv0Layer.cxx:369
 AliITSUv0Layer.cxx:370
 AliITSUv0Layer.cxx:371
 AliITSUv0Layer.cxx:372
 AliITSUv0Layer.cxx:373
 AliITSUv0Layer.cxx:374
 AliITSUv0Layer.cxx:375
 AliITSUv0Layer.cxx:376
 AliITSUv0Layer.cxx:377
 AliITSUv0Layer.cxx:378
 AliITSUv0Layer.cxx:379
 AliITSUv0Layer.cxx:380
 AliITSUv0Layer.cxx:381
 AliITSUv0Layer.cxx:382
 AliITSUv0Layer.cxx:383
 AliITSUv0Layer.cxx:384
 AliITSUv0Layer.cxx:385
 AliITSUv0Layer.cxx:386
 AliITSUv0Layer.cxx:387
 AliITSUv0Layer.cxx:388
 AliITSUv0Layer.cxx:389
 AliITSUv0Layer.cxx:390
 AliITSUv0Layer.cxx:391
 AliITSUv0Layer.cxx:392
 AliITSUv0Layer.cxx:393
 AliITSUv0Layer.cxx:394
 AliITSUv0Layer.cxx:395
 AliITSUv0Layer.cxx:396
 AliITSUv0Layer.cxx:397
 AliITSUv0Layer.cxx:398
 AliITSUv0Layer.cxx:399
 AliITSUv0Layer.cxx:400
 AliITSUv0Layer.cxx:401
 AliITSUv0Layer.cxx:402
 AliITSUv0Layer.cxx:403
 AliITSUv0Layer.cxx:404
 AliITSUv0Layer.cxx:405
 AliITSUv0Layer.cxx:406
 AliITSUv0Layer.cxx:407
 AliITSUv0Layer.cxx:408
 AliITSUv0Layer.cxx:409
 AliITSUv0Layer.cxx:410
 AliITSUv0Layer.cxx:411
 AliITSUv0Layer.cxx:412
 AliITSUv0Layer.cxx:413
 AliITSUv0Layer.cxx:414
 AliITSUv0Layer.cxx:415
 AliITSUv0Layer.cxx:416
 AliITSUv0Layer.cxx:417
 AliITSUv0Layer.cxx:418
 AliITSUv0Layer.cxx:419
 AliITSUv0Layer.cxx:420
 AliITSUv0Layer.cxx:421
 AliITSUv0Layer.cxx:422
 AliITSUv0Layer.cxx:423
 AliITSUv0Layer.cxx:424
 AliITSUv0Layer.cxx:425
 AliITSUv0Layer.cxx:426
 AliITSUv0Layer.cxx:427
 AliITSUv0Layer.cxx:428
 AliITSUv0Layer.cxx:429
 AliITSUv0Layer.cxx:430
 AliITSUv0Layer.cxx:431
 AliITSUv0Layer.cxx:432
 AliITSUv0Layer.cxx:433
 AliITSUv0Layer.cxx:434
 AliITSUv0Layer.cxx:435
 AliITSUv0Layer.cxx:436
 AliITSUv0Layer.cxx:437
 AliITSUv0Layer.cxx:438
 AliITSUv0Layer.cxx:439
 AliITSUv0Layer.cxx:440
 AliITSUv0Layer.cxx:441
 AliITSUv0Layer.cxx:442
 AliITSUv0Layer.cxx:443
 AliITSUv0Layer.cxx:444
 AliITSUv0Layer.cxx:445
 AliITSUv0Layer.cxx:446
 AliITSUv0Layer.cxx:447
 AliITSUv0Layer.cxx:448
 AliITSUv0Layer.cxx:449
 AliITSUv0Layer.cxx:450
 AliITSUv0Layer.cxx:451
 AliITSUv0Layer.cxx:452
 AliITSUv0Layer.cxx:453
 AliITSUv0Layer.cxx:454
 AliITSUv0Layer.cxx:455
 AliITSUv0Layer.cxx:456
 AliITSUv0Layer.cxx:457
 AliITSUv0Layer.cxx:458
 AliITSUv0Layer.cxx:459
 AliITSUv0Layer.cxx:460
 AliITSUv0Layer.cxx:461
 AliITSUv0Layer.cxx:462
 AliITSUv0Layer.cxx:463
 AliITSUv0Layer.cxx:464
 AliITSUv0Layer.cxx:465
 AliITSUv0Layer.cxx:466
 AliITSUv0Layer.cxx:467
 AliITSUv0Layer.cxx:468
 AliITSUv0Layer.cxx:469
 AliITSUv0Layer.cxx:470
 AliITSUv0Layer.cxx:471
 AliITSUv0Layer.cxx:472
 AliITSUv0Layer.cxx:473
 AliITSUv0Layer.cxx:474
 AliITSUv0Layer.cxx:475
 AliITSUv0Layer.cxx:476
 AliITSUv0Layer.cxx:477
 AliITSUv0Layer.cxx:478
 AliITSUv0Layer.cxx:479
 AliITSUv0Layer.cxx:480
 AliITSUv0Layer.cxx:481
 AliITSUv0Layer.cxx:482
 AliITSUv0Layer.cxx:483
 AliITSUv0Layer.cxx:484
 AliITSUv0Layer.cxx:485
 AliITSUv0Layer.cxx:486
 AliITSUv0Layer.cxx:487
 AliITSUv0Layer.cxx:488
 AliITSUv0Layer.cxx:489
 AliITSUv0Layer.cxx:490
 AliITSUv0Layer.cxx:491
 AliITSUv0Layer.cxx:492
 AliITSUv0Layer.cxx:493
 AliITSUv0Layer.cxx:494
 AliITSUv0Layer.cxx:495
 AliITSUv0Layer.cxx:496
 AliITSUv0Layer.cxx:497
 AliITSUv0Layer.cxx:498
 AliITSUv0Layer.cxx:499
 AliITSUv0Layer.cxx:500
 AliITSUv0Layer.cxx:501
 AliITSUv0Layer.cxx:502
 AliITSUv0Layer.cxx:503
 AliITSUv0Layer.cxx:504
 AliITSUv0Layer.cxx:505
 AliITSUv0Layer.cxx:506
 AliITSUv0Layer.cxx:507
 AliITSUv0Layer.cxx:508
 AliITSUv0Layer.cxx:509
 AliITSUv0Layer.cxx:510
 AliITSUv0Layer.cxx:511
 AliITSUv0Layer.cxx:512
 AliITSUv0Layer.cxx:513
 AliITSUv0Layer.cxx:514
 AliITSUv0Layer.cxx:515
 AliITSUv0Layer.cxx:516
 AliITSUv0Layer.cxx:517
 AliITSUv0Layer.cxx:518
 AliITSUv0Layer.cxx:519
 AliITSUv0Layer.cxx:520
 AliITSUv0Layer.cxx:521
 AliITSUv0Layer.cxx:522
 AliITSUv0Layer.cxx:523
 AliITSUv0Layer.cxx:524
 AliITSUv0Layer.cxx:525
 AliITSUv0Layer.cxx:526
 AliITSUv0Layer.cxx:527
 AliITSUv0Layer.cxx:528
 AliITSUv0Layer.cxx:529
 AliITSUv0Layer.cxx:530
 AliITSUv0Layer.cxx:531
 AliITSUv0Layer.cxx:532
 AliITSUv0Layer.cxx:533
 AliITSUv0Layer.cxx:534
 AliITSUv0Layer.cxx:535
 AliITSUv0Layer.cxx:536
 AliITSUv0Layer.cxx:537
 AliITSUv0Layer.cxx:538
 AliITSUv0Layer.cxx:539
 AliITSUv0Layer.cxx:540
 AliITSUv0Layer.cxx:541
 AliITSUv0Layer.cxx:542
 AliITSUv0Layer.cxx:543
 AliITSUv0Layer.cxx:544
 AliITSUv0Layer.cxx:545
 AliITSUv0Layer.cxx:546
 AliITSUv0Layer.cxx:547
 AliITSUv0Layer.cxx:548
 AliITSUv0Layer.cxx:549
 AliITSUv0Layer.cxx:550
 AliITSUv0Layer.cxx:551
 AliITSUv0Layer.cxx:552
 AliITSUv0Layer.cxx:553
 AliITSUv0Layer.cxx:554
 AliITSUv0Layer.cxx:555
 AliITSUv0Layer.cxx:556
 AliITSUv0Layer.cxx:557
 AliITSUv0Layer.cxx:558
 AliITSUv0Layer.cxx:559
 AliITSUv0Layer.cxx:560
 AliITSUv0Layer.cxx:561
 AliITSUv0Layer.cxx:562
 AliITSUv0Layer.cxx:563
 AliITSUv0Layer.cxx:564
 AliITSUv0Layer.cxx:565
 AliITSUv0Layer.cxx:566
 AliITSUv0Layer.cxx:567
 AliITSUv0Layer.cxx:568
 AliITSUv0Layer.cxx:569
 AliITSUv0Layer.cxx:570
 AliITSUv0Layer.cxx:571
 AliITSUv0Layer.cxx:572
 AliITSUv0Layer.cxx:573
 AliITSUv0Layer.cxx:574
 AliITSUv0Layer.cxx:575
 AliITSUv0Layer.cxx:576
 AliITSUv0Layer.cxx:577
 AliITSUv0Layer.cxx:578
 AliITSUv0Layer.cxx:579
 AliITSUv0Layer.cxx:580
 AliITSUv0Layer.cxx:581
 AliITSUv0Layer.cxx:582
 AliITSUv0Layer.cxx:583
 AliITSUv0Layer.cxx:584
 AliITSUv0Layer.cxx:585
 AliITSUv0Layer.cxx:586
 AliITSUv0Layer.cxx:587
 AliITSUv0Layer.cxx:588
 AliITSUv0Layer.cxx:589
 AliITSUv0Layer.cxx:590
 AliITSUv0Layer.cxx:591
 AliITSUv0Layer.cxx:592
 AliITSUv0Layer.cxx:593
 AliITSUv0Layer.cxx:594
 AliITSUv0Layer.cxx:595
 AliITSUv0Layer.cxx:596
 AliITSUv0Layer.cxx:597
 AliITSUv0Layer.cxx:598
 AliITSUv0Layer.cxx:599
 AliITSUv0Layer.cxx:600
 AliITSUv0Layer.cxx:601
 AliITSUv0Layer.cxx:602
 AliITSUv0Layer.cxx:603
 AliITSUv0Layer.cxx:604
 AliITSUv0Layer.cxx:605
 AliITSUv0Layer.cxx:606
 AliITSUv0Layer.cxx:607
 AliITSUv0Layer.cxx:608
 AliITSUv0Layer.cxx:609
 AliITSUv0Layer.cxx:610
 AliITSUv0Layer.cxx:611
 AliITSUv0Layer.cxx:612
 AliITSUv0Layer.cxx:613
 AliITSUv0Layer.cxx:614
 AliITSUv0Layer.cxx:615
 AliITSUv0Layer.cxx:616
 AliITSUv0Layer.cxx:617
 AliITSUv0Layer.cxx:618
 AliITSUv0Layer.cxx:619
 AliITSUv0Layer.cxx:620
 AliITSUv0Layer.cxx:621
 AliITSUv0Layer.cxx:622
 AliITSUv0Layer.cxx:623
 AliITSUv0Layer.cxx:624
 AliITSUv0Layer.cxx:625
 AliITSUv0Layer.cxx:626
 AliITSUv0Layer.cxx:627
 AliITSUv0Layer.cxx:628
 AliITSUv0Layer.cxx:629
 AliITSUv0Layer.cxx:630
 AliITSUv0Layer.cxx:631
 AliITSUv0Layer.cxx:632
 AliITSUv0Layer.cxx:633
 AliITSUv0Layer.cxx:634
 AliITSUv0Layer.cxx:635
 AliITSUv0Layer.cxx:636
 AliITSUv0Layer.cxx:637
 AliITSUv0Layer.cxx:638
 AliITSUv0Layer.cxx:639
 AliITSUv0Layer.cxx:640
 AliITSUv0Layer.cxx:641
 AliITSUv0Layer.cxx:642
 AliITSUv0Layer.cxx:643
 AliITSUv0Layer.cxx:644
 AliITSUv0Layer.cxx:645
 AliITSUv0Layer.cxx:646
 AliITSUv0Layer.cxx:647
 AliITSUv0Layer.cxx:648
 AliITSUv0Layer.cxx:649
 AliITSUv0Layer.cxx:650
 AliITSUv0Layer.cxx:651
 AliITSUv0Layer.cxx:652
 AliITSUv0Layer.cxx:653
 AliITSUv0Layer.cxx:654
 AliITSUv0Layer.cxx:655
 AliITSUv0Layer.cxx:656
 AliITSUv0Layer.cxx:657
 AliITSUv0Layer.cxx:658
 AliITSUv0Layer.cxx:659
 AliITSUv0Layer.cxx:660
 AliITSUv0Layer.cxx:661
 AliITSUv0Layer.cxx:662
 AliITSUv0Layer.cxx:663
 AliITSUv0Layer.cxx:664
 AliITSUv0Layer.cxx:665
 AliITSUv0Layer.cxx:666
 AliITSUv0Layer.cxx:667
 AliITSUv0Layer.cxx:668
 AliITSUv0Layer.cxx:669
 AliITSUv0Layer.cxx:670
 AliITSUv0Layer.cxx:671
 AliITSUv0Layer.cxx:672
 AliITSUv0Layer.cxx:673
 AliITSUv0Layer.cxx:674
 AliITSUv0Layer.cxx:675
 AliITSUv0Layer.cxx:676
 AliITSUv0Layer.cxx:677
 AliITSUv0Layer.cxx:678
 AliITSUv0Layer.cxx:679
 AliITSUv0Layer.cxx:680
 AliITSUv0Layer.cxx:681
 AliITSUv0Layer.cxx:682
 AliITSUv0Layer.cxx:683
 AliITSUv0Layer.cxx:684
 AliITSUv0Layer.cxx:685
 AliITSUv0Layer.cxx:686
 AliITSUv0Layer.cxx:687
 AliITSUv0Layer.cxx:688
 AliITSUv0Layer.cxx:689
 AliITSUv0Layer.cxx:690
 AliITSUv0Layer.cxx:691
 AliITSUv0Layer.cxx:692
 AliITSUv0Layer.cxx:693
 AliITSUv0Layer.cxx:694
 AliITSUv0Layer.cxx:695
 AliITSUv0Layer.cxx:696
 AliITSUv0Layer.cxx:697
 AliITSUv0Layer.cxx:698
 AliITSUv0Layer.cxx:699
 AliITSUv0Layer.cxx:700
 AliITSUv0Layer.cxx:701
 AliITSUv0Layer.cxx:702
 AliITSUv0Layer.cxx:703
 AliITSUv0Layer.cxx:704
 AliITSUv0Layer.cxx:705
 AliITSUv0Layer.cxx:706
 AliITSUv0Layer.cxx:707
 AliITSUv0Layer.cxx:708
 AliITSUv0Layer.cxx:709
 AliITSUv0Layer.cxx:710
 AliITSUv0Layer.cxx:711
 AliITSUv0Layer.cxx:712
 AliITSUv0Layer.cxx:713
 AliITSUv0Layer.cxx:714
 AliITSUv0Layer.cxx:715
 AliITSUv0Layer.cxx:716
 AliITSUv0Layer.cxx:717
 AliITSUv0Layer.cxx:718
 AliITSUv0Layer.cxx:719
 AliITSUv0Layer.cxx:720
 AliITSUv0Layer.cxx:721
 AliITSUv0Layer.cxx:722
 AliITSUv0Layer.cxx:723
 AliITSUv0Layer.cxx:724
 AliITSUv0Layer.cxx:725
 AliITSUv0Layer.cxx:726
 AliITSUv0Layer.cxx:727
 AliITSUv0Layer.cxx:728
 AliITSUv0Layer.cxx:729
 AliITSUv0Layer.cxx:730
 AliITSUv0Layer.cxx:731
 AliITSUv0Layer.cxx:732
 AliITSUv0Layer.cxx:733
 AliITSUv0Layer.cxx:734
 AliITSUv0Layer.cxx:735
 AliITSUv0Layer.cxx:736
 AliITSUv0Layer.cxx:737
 AliITSUv0Layer.cxx:738
 AliITSUv0Layer.cxx:739
 AliITSUv0Layer.cxx:740
 AliITSUv0Layer.cxx:741
 AliITSUv0Layer.cxx:742
 AliITSUv0Layer.cxx:743
 AliITSUv0Layer.cxx:744
 AliITSUv0Layer.cxx:745
 AliITSUv0Layer.cxx:746
 AliITSUv0Layer.cxx:747
 AliITSUv0Layer.cxx:748
 AliITSUv0Layer.cxx:749
 AliITSUv0Layer.cxx:750
 AliITSUv0Layer.cxx:751
 AliITSUv0Layer.cxx:752
 AliITSUv0Layer.cxx:753
 AliITSUv0Layer.cxx:754
 AliITSUv0Layer.cxx:755
 AliITSUv0Layer.cxx:756
 AliITSUv0Layer.cxx:757
 AliITSUv0Layer.cxx:758
 AliITSUv0Layer.cxx:759
 AliITSUv0Layer.cxx:760
 AliITSUv0Layer.cxx:761
 AliITSUv0Layer.cxx:762
 AliITSUv0Layer.cxx:763
 AliITSUv0Layer.cxx:764
 AliITSUv0Layer.cxx:765
 AliITSUv0Layer.cxx:766
 AliITSUv0Layer.cxx:767
 AliITSUv0Layer.cxx:768
 AliITSUv0Layer.cxx:769
 AliITSUv0Layer.cxx:770
 AliITSUv0Layer.cxx:771
 AliITSUv0Layer.cxx:772
 AliITSUv0Layer.cxx:773
 AliITSUv0Layer.cxx:774
 AliITSUv0Layer.cxx:775
 AliITSUv0Layer.cxx:776
 AliITSUv0Layer.cxx:777
 AliITSUv0Layer.cxx:778
 AliITSUv0Layer.cxx:779
 AliITSUv0Layer.cxx:780
 AliITSUv0Layer.cxx:781
 AliITSUv0Layer.cxx:782
 AliITSUv0Layer.cxx:783
 AliITSUv0Layer.cxx:784
 AliITSUv0Layer.cxx:785
 AliITSUv0Layer.cxx:786
 AliITSUv0Layer.cxx:787
 AliITSUv0Layer.cxx:788
 AliITSUv0Layer.cxx:789
 AliITSUv0Layer.cxx:790
 AliITSUv0Layer.cxx:791
 AliITSUv0Layer.cxx:792
 AliITSUv0Layer.cxx:793
 AliITSUv0Layer.cxx:794
 AliITSUv0Layer.cxx:795
 AliITSUv0Layer.cxx:796
 AliITSUv0Layer.cxx:797
 AliITSUv0Layer.cxx:798
 AliITSUv0Layer.cxx:799
 AliITSUv0Layer.cxx:800
 AliITSUv0Layer.cxx:801
 AliITSUv0Layer.cxx:802
 AliITSUv0Layer.cxx:803
 AliITSUv0Layer.cxx:804
 AliITSUv0Layer.cxx:805
 AliITSUv0Layer.cxx:806
 AliITSUv0Layer.cxx:807
 AliITSUv0Layer.cxx:808
 AliITSUv0Layer.cxx:809
 AliITSUv0Layer.cxx:810
 AliITSUv0Layer.cxx:811
 AliITSUv0Layer.cxx:812
 AliITSUv0Layer.cxx:813
 AliITSUv0Layer.cxx:814
 AliITSUv0Layer.cxx:815
 AliITSUv0Layer.cxx:816
 AliITSUv0Layer.cxx:817
 AliITSUv0Layer.cxx:818
 AliITSUv0Layer.cxx:819
 AliITSUv0Layer.cxx:820
 AliITSUv0Layer.cxx:821
 AliITSUv0Layer.cxx:822
 AliITSUv0Layer.cxx:823
 AliITSUv0Layer.cxx:824
 AliITSUv0Layer.cxx:825
 AliITSUv0Layer.cxx:826
 AliITSUv0Layer.cxx:827
 AliITSUv0Layer.cxx:828
 AliITSUv0Layer.cxx:829
 AliITSUv0Layer.cxx:830
 AliITSUv0Layer.cxx:831
 AliITSUv0Layer.cxx:832
 AliITSUv0Layer.cxx:833
 AliITSUv0Layer.cxx:834
 AliITSUv0Layer.cxx:835
 AliITSUv0Layer.cxx:836
 AliITSUv0Layer.cxx:837
 AliITSUv0Layer.cxx:838
 AliITSUv0Layer.cxx:839
 AliITSUv0Layer.cxx:840
 AliITSUv0Layer.cxx:841
 AliITSUv0Layer.cxx:842
 AliITSUv0Layer.cxx:843
 AliITSUv0Layer.cxx:844
 AliITSUv0Layer.cxx:845
 AliITSUv0Layer.cxx:846
 AliITSUv0Layer.cxx:847
 AliITSUv0Layer.cxx:848
 AliITSUv0Layer.cxx:849
 AliITSUv0Layer.cxx:850
 AliITSUv0Layer.cxx:851
 AliITSUv0Layer.cxx:852
 AliITSUv0Layer.cxx:853
 AliITSUv0Layer.cxx:854
 AliITSUv0Layer.cxx:855
 AliITSUv0Layer.cxx:856
 AliITSUv0Layer.cxx:857
 AliITSUv0Layer.cxx:858
 AliITSUv0Layer.cxx:859
 AliITSUv0Layer.cxx:860
 AliITSUv0Layer.cxx:861
 AliITSUv0Layer.cxx:862
 AliITSUv0Layer.cxx:863
 AliITSUv0Layer.cxx:864
 AliITSUv0Layer.cxx:865
 AliITSUv0Layer.cxx:866
 AliITSUv0Layer.cxx:867
 AliITSUv0Layer.cxx:868
 AliITSUv0Layer.cxx:869
 AliITSUv0Layer.cxx:870
 AliITSUv0Layer.cxx:871
 AliITSUv0Layer.cxx:872
 AliITSUv0Layer.cxx:873
 AliITSUv0Layer.cxx:874
 AliITSUv0Layer.cxx:875
 AliITSUv0Layer.cxx:876
 AliITSUv0Layer.cxx:877
 AliITSUv0Layer.cxx:878
 AliITSUv0Layer.cxx:879
 AliITSUv0Layer.cxx:880
 AliITSUv0Layer.cxx:881
 AliITSUv0Layer.cxx:882
 AliITSUv0Layer.cxx:883
 AliITSUv0Layer.cxx:884
 AliITSUv0Layer.cxx:885
 AliITSUv0Layer.cxx:886
 AliITSUv0Layer.cxx:887
 AliITSUv0Layer.cxx:888
 AliITSUv0Layer.cxx:889
 AliITSUv0Layer.cxx:890
 AliITSUv0Layer.cxx:891
 AliITSUv0Layer.cxx:892
 AliITSUv0Layer.cxx:893
 AliITSUv0Layer.cxx:894
 AliITSUv0Layer.cxx:895
 AliITSUv0Layer.cxx:896
 AliITSUv0Layer.cxx:897
 AliITSUv0Layer.cxx:898
 AliITSUv0Layer.cxx:899
 AliITSUv0Layer.cxx:900
 AliITSUv0Layer.cxx:901
 AliITSUv0Layer.cxx:902
 AliITSUv0Layer.cxx:903
 AliITSUv0Layer.cxx:904
 AliITSUv0Layer.cxx:905
 AliITSUv0Layer.cxx:906
 AliITSUv0Layer.cxx:907
 AliITSUv0Layer.cxx:908
 AliITSUv0Layer.cxx:909
 AliITSUv0Layer.cxx:910
 AliITSUv0Layer.cxx:911
 AliITSUv0Layer.cxx:912
 AliITSUv0Layer.cxx:913
 AliITSUv0Layer.cxx:914
 AliITSUv0Layer.cxx:915
 AliITSUv0Layer.cxx:916
 AliITSUv0Layer.cxx:917
 AliITSUv0Layer.cxx:918
 AliITSUv0Layer.cxx:919
 AliITSUv0Layer.cxx:920
 AliITSUv0Layer.cxx:921
 AliITSUv0Layer.cxx:922
 AliITSUv0Layer.cxx:923
 AliITSUv0Layer.cxx:924
 AliITSUv0Layer.cxx:925
 AliITSUv0Layer.cxx:926
 AliITSUv0Layer.cxx:927
 AliITSUv0Layer.cxx:928
 AliITSUv0Layer.cxx:929
 AliITSUv0Layer.cxx:930
 AliITSUv0Layer.cxx:931
 AliITSUv0Layer.cxx:932
 AliITSUv0Layer.cxx:933
 AliITSUv0Layer.cxx:934
 AliITSUv0Layer.cxx:935
 AliITSUv0Layer.cxx:936
 AliITSUv0Layer.cxx:937
 AliITSUv0Layer.cxx:938
 AliITSUv0Layer.cxx:939
 AliITSUv0Layer.cxx:940
 AliITSUv0Layer.cxx:941
 AliITSUv0Layer.cxx:942
 AliITSUv0Layer.cxx:943
 AliITSUv0Layer.cxx:944
 AliITSUv0Layer.cxx:945
 AliITSUv0Layer.cxx:946
 AliITSUv0Layer.cxx:947
 AliITSUv0Layer.cxx:948
 AliITSUv0Layer.cxx:949
 AliITSUv0Layer.cxx:950
 AliITSUv0Layer.cxx:951
 AliITSUv0Layer.cxx:952
 AliITSUv0Layer.cxx:953
 AliITSUv0Layer.cxx:954
 AliITSUv0Layer.cxx:955
 AliITSUv0Layer.cxx:956
 AliITSUv0Layer.cxx:957
 AliITSUv0Layer.cxx:958
 AliITSUv0Layer.cxx:959
 AliITSUv0Layer.cxx:960
 AliITSUv0Layer.cxx:961
 AliITSUv0Layer.cxx:962
 AliITSUv0Layer.cxx:963
 AliITSUv0Layer.cxx:964
 AliITSUv0Layer.cxx:965
 AliITSUv0Layer.cxx:966
 AliITSUv0Layer.cxx:967
 AliITSUv0Layer.cxx:968
 AliITSUv0Layer.cxx:969
 AliITSUv0Layer.cxx:970
 AliITSUv0Layer.cxx:971
 AliITSUv0Layer.cxx:972
 AliITSUv0Layer.cxx:973
 AliITSUv0Layer.cxx:974
 AliITSUv0Layer.cxx:975
 AliITSUv0Layer.cxx:976
 AliITSUv0Layer.cxx:977
 AliITSUv0Layer.cxx:978
 AliITSUv0Layer.cxx:979
 AliITSUv0Layer.cxx:980
 AliITSUv0Layer.cxx:981
 AliITSUv0Layer.cxx:982
 AliITSUv0Layer.cxx:983
 AliITSUv0Layer.cxx:984
 AliITSUv0Layer.cxx:985
 AliITSUv0Layer.cxx:986
 AliITSUv0Layer.cxx:987
 AliITSUv0Layer.cxx:988
 AliITSUv0Layer.cxx:989
 AliITSUv0Layer.cxx:990
 AliITSUv0Layer.cxx:991
 AliITSUv0Layer.cxx:992
 AliITSUv0Layer.cxx:993
 AliITSUv0Layer.cxx:994
 AliITSUv0Layer.cxx:995
 AliITSUv0Layer.cxx:996
 AliITSUv0Layer.cxx:997
 AliITSUv0Layer.cxx:998
 AliITSUv0Layer.cxx:999
 AliITSUv0Layer.cxx:1000
 AliITSUv0Layer.cxx:1001
 AliITSUv0Layer.cxx:1002
 AliITSUv0Layer.cxx:1003
 AliITSUv0Layer.cxx:1004
 AliITSUv0Layer.cxx:1005
 AliITSUv0Layer.cxx:1006
 AliITSUv0Layer.cxx:1007
 AliITSUv0Layer.cxx:1008
 AliITSUv0Layer.cxx:1009
 AliITSUv0Layer.cxx:1010
 AliITSUv0Layer.cxx:1011
 AliITSUv0Layer.cxx:1012
 AliITSUv0Layer.cxx:1013
 AliITSUv0Layer.cxx:1014
 AliITSUv0Layer.cxx:1015
 AliITSUv0Layer.cxx:1016
 AliITSUv0Layer.cxx:1017
 AliITSUv0Layer.cxx:1018
 AliITSUv0Layer.cxx:1019
 AliITSUv0Layer.cxx:1020
 AliITSUv0Layer.cxx:1021
 AliITSUv0Layer.cxx:1022
 AliITSUv0Layer.cxx:1023
 AliITSUv0Layer.cxx:1024
 AliITSUv0Layer.cxx:1025
 AliITSUv0Layer.cxx:1026
 AliITSUv0Layer.cxx:1027
 AliITSUv0Layer.cxx:1028
 AliITSUv0Layer.cxx:1029
 AliITSUv0Layer.cxx:1030
 AliITSUv0Layer.cxx:1031
 AliITSUv0Layer.cxx:1032
 AliITSUv0Layer.cxx:1033
 AliITSUv0Layer.cxx:1034
 AliITSUv0Layer.cxx:1035
 AliITSUv0Layer.cxx:1036
 AliITSUv0Layer.cxx:1037
 AliITSUv0Layer.cxx:1038
 AliITSUv0Layer.cxx:1039
 AliITSUv0Layer.cxx:1040
 AliITSUv0Layer.cxx:1041
 AliITSUv0Layer.cxx:1042
 AliITSUv0Layer.cxx:1043
 AliITSUv0Layer.cxx:1044
 AliITSUv0Layer.cxx:1045
 AliITSUv0Layer.cxx:1046
 AliITSUv0Layer.cxx:1047
 AliITSUv0Layer.cxx:1048
 AliITSUv0Layer.cxx:1049
 AliITSUv0Layer.cxx:1050
 AliITSUv0Layer.cxx:1051
 AliITSUv0Layer.cxx:1052
 AliITSUv0Layer.cxx:1053
 AliITSUv0Layer.cxx:1054
 AliITSUv0Layer.cxx:1055
 AliITSUv0Layer.cxx:1056
 AliITSUv0Layer.cxx:1057
 AliITSUv0Layer.cxx:1058
 AliITSUv0Layer.cxx:1059
 AliITSUv0Layer.cxx:1060
 AliITSUv0Layer.cxx:1061
 AliITSUv0Layer.cxx:1062
 AliITSUv0Layer.cxx:1063
 AliITSUv0Layer.cxx:1064
 AliITSUv0Layer.cxx:1065
 AliITSUv0Layer.cxx:1066
 AliITSUv0Layer.cxx:1067
 AliITSUv0Layer.cxx:1068
 AliITSUv0Layer.cxx:1069
 AliITSUv0Layer.cxx:1070
 AliITSUv0Layer.cxx:1071
 AliITSUv0Layer.cxx:1072
 AliITSUv0Layer.cxx:1073
 AliITSUv0Layer.cxx:1074
 AliITSUv0Layer.cxx:1075
 AliITSUv0Layer.cxx:1076
 AliITSUv0Layer.cxx:1077
 AliITSUv0Layer.cxx:1078
 AliITSUv0Layer.cxx:1079
 AliITSUv0Layer.cxx:1080
 AliITSUv0Layer.cxx:1081
 AliITSUv0Layer.cxx:1082
 AliITSUv0Layer.cxx:1083
 AliITSUv0Layer.cxx:1084
 AliITSUv0Layer.cxx:1085
 AliITSUv0Layer.cxx:1086
 AliITSUv0Layer.cxx:1087
 AliITSUv0Layer.cxx:1088
 AliITSUv0Layer.cxx:1089
 AliITSUv0Layer.cxx:1090
 AliITSUv0Layer.cxx:1091
 AliITSUv0Layer.cxx:1092
 AliITSUv0Layer.cxx:1093
 AliITSUv0Layer.cxx:1094
 AliITSUv0Layer.cxx:1095
 AliITSUv0Layer.cxx:1096
 AliITSUv0Layer.cxx:1097
 AliITSUv0Layer.cxx:1098
 AliITSUv0Layer.cxx:1099
 AliITSUv0Layer.cxx:1100
 AliITSUv0Layer.cxx:1101
 AliITSUv0Layer.cxx:1102
 AliITSUv0Layer.cxx:1103
 AliITSUv0Layer.cxx:1104
 AliITSUv0Layer.cxx:1105
 AliITSUv0Layer.cxx:1106
 AliITSUv0Layer.cxx:1107
 AliITSUv0Layer.cxx:1108
 AliITSUv0Layer.cxx:1109
 AliITSUv0Layer.cxx:1110
 AliITSUv0Layer.cxx:1111
 AliITSUv0Layer.cxx:1112
 AliITSUv0Layer.cxx:1113
 AliITSUv0Layer.cxx:1114
 AliITSUv0Layer.cxx:1115
 AliITSUv0Layer.cxx:1116
 AliITSUv0Layer.cxx:1117
 AliITSUv0Layer.cxx:1118
 AliITSUv0Layer.cxx:1119
 AliITSUv0Layer.cxx:1120
 AliITSUv0Layer.cxx:1121
 AliITSUv0Layer.cxx:1122
 AliITSUv0Layer.cxx:1123
 AliITSUv0Layer.cxx:1124
 AliITSUv0Layer.cxx:1125
 AliITSUv0Layer.cxx:1126
 AliITSUv0Layer.cxx:1127
 AliITSUv0Layer.cxx:1128
 AliITSUv0Layer.cxx:1129
 AliITSUv0Layer.cxx:1130
 AliITSUv0Layer.cxx:1131
 AliITSUv0Layer.cxx:1132
 AliITSUv0Layer.cxx:1133
 AliITSUv0Layer.cxx:1134
 AliITSUv0Layer.cxx:1135
 AliITSUv0Layer.cxx:1136
 AliITSUv0Layer.cxx:1137
 AliITSUv0Layer.cxx:1138
 AliITSUv0Layer.cxx:1139
 AliITSUv0Layer.cxx:1140
 AliITSUv0Layer.cxx:1141
 AliITSUv0Layer.cxx:1142
 AliITSUv0Layer.cxx:1143
 AliITSUv0Layer.cxx:1144
 AliITSUv0Layer.cxx:1145
 AliITSUv0Layer.cxx:1146
 AliITSUv0Layer.cxx:1147
 AliITSUv0Layer.cxx:1148
 AliITSUv0Layer.cxx:1149
 AliITSUv0Layer.cxx:1150
 AliITSUv0Layer.cxx:1151
 AliITSUv0Layer.cxx:1152
 AliITSUv0Layer.cxx:1153
 AliITSUv0Layer.cxx:1154
 AliITSUv0Layer.cxx:1155
 AliITSUv0Layer.cxx:1156
 AliITSUv0Layer.cxx:1157
 AliITSUv0Layer.cxx:1158
 AliITSUv0Layer.cxx:1159
 AliITSUv0Layer.cxx:1160
 AliITSUv0Layer.cxx:1161
 AliITSUv0Layer.cxx:1162
 AliITSUv0Layer.cxx:1163
 AliITSUv0Layer.cxx:1164
 AliITSUv0Layer.cxx:1165
 AliITSUv0Layer.cxx:1166
 AliITSUv0Layer.cxx:1167
 AliITSUv0Layer.cxx:1168
 AliITSUv0Layer.cxx:1169
 AliITSUv0Layer.cxx:1170
 AliITSUv0Layer.cxx:1171
 AliITSUv0Layer.cxx:1172
 AliITSUv0Layer.cxx:1173
 AliITSUv0Layer.cxx:1174
 AliITSUv0Layer.cxx:1175
 AliITSUv0Layer.cxx:1176
 AliITSUv0Layer.cxx:1177
 AliITSUv0Layer.cxx:1178
 AliITSUv0Layer.cxx:1179
 AliITSUv0Layer.cxx:1180
 AliITSUv0Layer.cxx:1181
 AliITSUv0Layer.cxx:1182
 AliITSUv0Layer.cxx:1183
 AliITSUv0Layer.cxx:1184
 AliITSUv0Layer.cxx:1185
 AliITSUv0Layer.cxx:1186
 AliITSUv0Layer.cxx:1187
 AliITSUv0Layer.cxx:1188
 AliITSUv0Layer.cxx:1189
 AliITSUv0Layer.cxx:1190
 AliITSUv0Layer.cxx:1191
 AliITSUv0Layer.cxx:1192
 AliITSUv0Layer.cxx:1193
 AliITSUv0Layer.cxx:1194
 AliITSUv0Layer.cxx:1195
 AliITSUv0Layer.cxx:1196
 AliITSUv0Layer.cxx:1197
 AliITSUv0Layer.cxx:1198
 AliITSUv0Layer.cxx:1199
 AliITSUv0Layer.cxx:1200
 AliITSUv0Layer.cxx:1201
 AliITSUv0Layer.cxx:1202
 AliITSUv0Layer.cxx:1203
 AliITSUv0Layer.cxx:1204
 AliITSUv0Layer.cxx:1205
 AliITSUv0Layer.cxx:1206
 AliITSUv0Layer.cxx:1207
 AliITSUv0Layer.cxx:1208
 AliITSUv0Layer.cxx:1209
 AliITSUv0Layer.cxx:1210
 AliITSUv0Layer.cxx:1211
 AliITSUv0Layer.cxx:1212
 AliITSUv0Layer.cxx:1213
 AliITSUv0Layer.cxx:1214
 AliITSUv0Layer.cxx:1215
 AliITSUv0Layer.cxx:1216
 AliITSUv0Layer.cxx:1217
 AliITSUv0Layer.cxx:1218
 AliITSUv0Layer.cxx:1219
 AliITSUv0Layer.cxx:1220
 AliITSUv0Layer.cxx:1221
 AliITSUv0Layer.cxx:1222
 AliITSUv0Layer.cxx:1223
 AliITSUv0Layer.cxx:1224
 AliITSUv0Layer.cxx:1225
 AliITSUv0Layer.cxx:1226
 AliITSUv0Layer.cxx:1227
 AliITSUv0Layer.cxx:1228
 AliITSUv0Layer.cxx:1229
 AliITSUv0Layer.cxx:1230
 AliITSUv0Layer.cxx:1231
 AliITSUv0Layer.cxx:1232
 AliITSUv0Layer.cxx:1233
 AliITSUv0Layer.cxx:1234
 AliITSUv0Layer.cxx:1235
 AliITSUv0Layer.cxx:1236
 AliITSUv0Layer.cxx:1237
 AliITSUv0Layer.cxx:1238
 AliITSUv0Layer.cxx:1239
 AliITSUv0Layer.cxx:1240
 AliITSUv0Layer.cxx:1241
 AliITSUv0Layer.cxx:1242
 AliITSUv0Layer.cxx:1243
 AliITSUv0Layer.cxx:1244
 AliITSUv0Layer.cxx:1245
 AliITSUv0Layer.cxx:1246
 AliITSUv0Layer.cxx:1247
 AliITSUv0Layer.cxx:1248
 AliITSUv0Layer.cxx:1249
 AliITSUv0Layer.cxx:1250
 AliITSUv0Layer.cxx:1251
 AliITSUv0Layer.cxx:1252
 AliITSUv0Layer.cxx:1253
 AliITSUv0Layer.cxx:1254
 AliITSUv0Layer.cxx:1255
 AliITSUv0Layer.cxx:1256
 AliITSUv0Layer.cxx:1257
 AliITSUv0Layer.cxx:1258
 AliITSUv0Layer.cxx:1259
 AliITSUv0Layer.cxx:1260
 AliITSUv0Layer.cxx:1261
 AliITSUv0Layer.cxx:1262
 AliITSUv0Layer.cxx:1263
 AliITSUv0Layer.cxx:1264
 AliITSUv0Layer.cxx:1265
 AliITSUv0Layer.cxx:1266
 AliITSUv0Layer.cxx:1267
 AliITSUv0Layer.cxx:1268
 AliITSUv0Layer.cxx:1269
 AliITSUv0Layer.cxx:1270
 AliITSUv0Layer.cxx:1271
 AliITSUv0Layer.cxx:1272
 AliITSUv0Layer.cxx:1273
 AliITSUv0Layer.cxx:1274
 AliITSUv0Layer.cxx:1275
 AliITSUv0Layer.cxx:1276
 AliITSUv0Layer.cxx:1277
 AliITSUv0Layer.cxx:1278
 AliITSUv0Layer.cxx:1279
 AliITSUv0Layer.cxx:1280
 AliITSUv0Layer.cxx:1281
 AliITSUv0Layer.cxx:1282
 AliITSUv0Layer.cxx:1283
 AliITSUv0Layer.cxx:1284
 AliITSUv0Layer.cxx:1285
 AliITSUv0Layer.cxx:1286
 AliITSUv0Layer.cxx:1287
 AliITSUv0Layer.cxx:1288
 AliITSUv0Layer.cxx:1289
 AliITSUv0Layer.cxx:1290
 AliITSUv0Layer.cxx:1291
 AliITSUv0Layer.cxx:1292
 AliITSUv0Layer.cxx:1293
 AliITSUv0Layer.cxx:1294
 AliITSUv0Layer.cxx:1295
 AliITSUv0Layer.cxx:1296
 AliITSUv0Layer.cxx:1297
 AliITSUv0Layer.cxx:1298
 AliITSUv0Layer.cxx:1299
 AliITSUv0Layer.cxx:1300
 AliITSUv0Layer.cxx:1301
 AliITSUv0Layer.cxx:1302
 AliITSUv0Layer.cxx:1303
 AliITSUv0Layer.cxx:1304
 AliITSUv0Layer.cxx:1305
 AliITSUv0Layer.cxx:1306
 AliITSUv0Layer.cxx:1307
 AliITSUv0Layer.cxx:1308
 AliITSUv0Layer.cxx:1309
 AliITSUv0Layer.cxx:1310
 AliITSUv0Layer.cxx:1311
 AliITSUv0Layer.cxx:1312
 AliITSUv0Layer.cxx:1313
 AliITSUv0Layer.cxx:1314
 AliITSUv0Layer.cxx:1315
 AliITSUv0Layer.cxx:1316
 AliITSUv0Layer.cxx:1317
 AliITSUv0Layer.cxx:1318
 AliITSUv0Layer.cxx:1319
 AliITSUv0Layer.cxx:1320
 AliITSUv0Layer.cxx:1321
 AliITSUv0Layer.cxx:1322
 AliITSUv0Layer.cxx:1323
 AliITSUv0Layer.cxx:1324
 AliITSUv0Layer.cxx:1325
 AliITSUv0Layer.cxx:1326
 AliITSUv0Layer.cxx:1327
 AliITSUv0Layer.cxx:1328
 AliITSUv0Layer.cxx:1329
 AliITSUv0Layer.cxx:1330
 AliITSUv0Layer.cxx:1331
 AliITSUv0Layer.cxx:1332
 AliITSUv0Layer.cxx:1333
 AliITSUv0Layer.cxx:1334
 AliITSUv0Layer.cxx:1335
 AliITSUv0Layer.cxx:1336
 AliITSUv0Layer.cxx:1337
 AliITSUv0Layer.cxx:1338
 AliITSUv0Layer.cxx:1339
 AliITSUv0Layer.cxx:1340
 AliITSUv0Layer.cxx:1341
 AliITSUv0Layer.cxx:1342
 AliITSUv0Layer.cxx:1343
 AliITSUv0Layer.cxx:1344
 AliITSUv0Layer.cxx:1345
 AliITSUv0Layer.cxx:1346
 AliITSUv0Layer.cxx:1347
 AliITSUv0Layer.cxx:1348
 AliITSUv0Layer.cxx:1349
 AliITSUv0Layer.cxx:1350
 AliITSUv0Layer.cxx:1351
 AliITSUv0Layer.cxx:1352
 AliITSUv0Layer.cxx:1353
 AliITSUv0Layer.cxx:1354
 AliITSUv0Layer.cxx:1355
 AliITSUv0Layer.cxx:1356
 AliITSUv0Layer.cxx:1357
 AliITSUv0Layer.cxx:1358
 AliITSUv0Layer.cxx:1359
 AliITSUv0Layer.cxx:1360
 AliITSUv0Layer.cxx:1361
 AliITSUv0Layer.cxx:1362
 AliITSUv0Layer.cxx:1363
 AliITSUv0Layer.cxx:1364
 AliITSUv0Layer.cxx:1365
 AliITSUv0Layer.cxx:1366
 AliITSUv0Layer.cxx:1367
 AliITSUv0Layer.cxx:1368
 AliITSUv0Layer.cxx:1369
 AliITSUv0Layer.cxx:1370
 AliITSUv0Layer.cxx:1371
 AliITSUv0Layer.cxx:1372
 AliITSUv0Layer.cxx:1373
 AliITSUv0Layer.cxx:1374
 AliITSUv0Layer.cxx:1375
 AliITSUv0Layer.cxx:1376
 AliITSUv0Layer.cxx:1377
 AliITSUv0Layer.cxx:1378
 AliITSUv0Layer.cxx:1379
 AliITSUv0Layer.cxx:1380
 AliITSUv0Layer.cxx:1381
 AliITSUv0Layer.cxx:1382
 AliITSUv0Layer.cxx:1383
 AliITSUv0Layer.cxx:1384
 AliITSUv0Layer.cxx:1385
 AliITSUv0Layer.cxx:1386
 AliITSUv0Layer.cxx:1387
 AliITSUv0Layer.cxx:1388
 AliITSUv0Layer.cxx:1389
 AliITSUv0Layer.cxx:1390
 AliITSUv0Layer.cxx:1391
 AliITSUv0Layer.cxx:1392
 AliITSUv0Layer.cxx:1393
 AliITSUv0Layer.cxx:1394
 AliITSUv0Layer.cxx:1395
 AliITSUv0Layer.cxx:1396
 AliITSUv0Layer.cxx:1397
 AliITSUv0Layer.cxx:1398
 AliITSUv0Layer.cxx:1399
 AliITSUv0Layer.cxx:1400
 AliITSUv0Layer.cxx:1401
 AliITSUv0Layer.cxx:1402
 AliITSUv0Layer.cxx:1403
 AliITSUv0Layer.cxx:1404
 AliITSUv0Layer.cxx:1405
 AliITSUv0Layer.cxx:1406
 AliITSUv0Layer.cxx:1407
 AliITSUv0Layer.cxx:1408
 AliITSUv0Layer.cxx:1409
 AliITSUv0Layer.cxx:1410
 AliITSUv0Layer.cxx:1411
 AliITSUv0Layer.cxx:1412
 AliITSUv0Layer.cxx:1413
 AliITSUv0Layer.cxx:1414
 AliITSUv0Layer.cxx:1415
 AliITSUv0Layer.cxx:1416
 AliITSUv0Layer.cxx:1417
 AliITSUv0Layer.cxx:1418
 AliITSUv0Layer.cxx:1419
 AliITSUv0Layer.cxx:1420
 AliITSUv0Layer.cxx:1421
 AliITSUv0Layer.cxx:1422
 AliITSUv0Layer.cxx:1423
 AliITSUv0Layer.cxx:1424
 AliITSUv0Layer.cxx:1425
 AliITSUv0Layer.cxx:1426
 AliITSUv0Layer.cxx:1427
 AliITSUv0Layer.cxx:1428
 AliITSUv0Layer.cxx:1429
 AliITSUv0Layer.cxx:1430
 AliITSUv0Layer.cxx:1431
 AliITSUv0Layer.cxx:1432
 AliITSUv0Layer.cxx:1433
 AliITSUv0Layer.cxx:1434
 AliITSUv0Layer.cxx:1435
 AliITSUv0Layer.cxx:1436
 AliITSUv0Layer.cxx:1437
 AliITSUv0Layer.cxx:1438
 AliITSUv0Layer.cxx:1439
 AliITSUv0Layer.cxx:1440
 AliITSUv0Layer.cxx:1441
 AliITSUv0Layer.cxx:1442
 AliITSUv0Layer.cxx:1443
 AliITSUv0Layer.cxx:1444
 AliITSUv0Layer.cxx:1445
 AliITSUv0Layer.cxx:1446
 AliITSUv0Layer.cxx:1447
 AliITSUv0Layer.cxx:1448
 AliITSUv0Layer.cxx:1449
 AliITSUv0Layer.cxx:1450
 AliITSUv0Layer.cxx:1451
 AliITSUv0Layer.cxx:1452
 AliITSUv0Layer.cxx:1453
 AliITSUv0Layer.cxx:1454
 AliITSUv0Layer.cxx:1455
 AliITSUv0Layer.cxx:1456
 AliITSUv0Layer.cxx:1457
 AliITSUv0Layer.cxx:1458
 AliITSUv0Layer.cxx:1459
 AliITSUv0Layer.cxx:1460
 AliITSUv0Layer.cxx:1461
 AliITSUv0Layer.cxx:1462
 AliITSUv0Layer.cxx:1463
 AliITSUv0Layer.cxx:1464
 AliITSUv0Layer.cxx:1465
 AliITSUv0Layer.cxx:1466
 AliITSUv0Layer.cxx:1467
 AliITSUv0Layer.cxx:1468
 AliITSUv0Layer.cxx:1469
 AliITSUv0Layer.cxx:1470
 AliITSUv0Layer.cxx:1471
 AliITSUv0Layer.cxx:1472
 AliITSUv0Layer.cxx:1473
 AliITSUv0Layer.cxx:1474
 AliITSUv0Layer.cxx:1475
 AliITSUv0Layer.cxx:1476
 AliITSUv0Layer.cxx:1477
 AliITSUv0Layer.cxx:1478
 AliITSUv0Layer.cxx:1479
 AliITSUv0Layer.cxx:1480
 AliITSUv0Layer.cxx:1481
 AliITSUv0Layer.cxx:1482
 AliITSUv0Layer.cxx:1483
 AliITSUv0Layer.cxx:1484
 AliITSUv0Layer.cxx:1485
 AliITSUv0Layer.cxx:1486
 AliITSUv0Layer.cxx:1487
 AliITSUv0Layer.cxx:1488
 AliITSUv0Layer.cxx:1489
 AliITSUv0Layer.cxx:1490
 AliITSUv0Layer.cxx:1491
 AliITSUv0Layer.cxx:1492
 AliITSUv0Layer.cxx:1493
 AliITSUv0Layer.cxx:1494
 AliITSUv0Layer.cxx:1495
 AliITSUv0Layer.cxx:1496
 AliITSUv0Layer.cxx:1497
 AliITSUv0Layer.cxx:1498
 AliITSUv0Layer.cxx:1499
 AliITSUv0Layer.cxx:1500
 AliITSUv0Layer.cxx:1501
 AliITSUv0Layer.cxx:1502
 AliITSUv0Layer.cxx:1503
 AliITSUv0Layer.cxx:1504
 AliITSUv0Layer.cxx:1505
 AliITSUv0Layer.cxx:1506
 AliITSUv0Layer.cxx:1507
 AliITSUv0Layer.cxx:1508
 AliITSUv0Layer.cxx:1509
 AliITSUv0Layer.cxx:1510
 AliITSUv0Layer.cxx:1511
 AliITSUv0Layer.cxx:1512
 AliITSUv0Layer.cxx:1513
 AliITSUv0Layer.cxx:1514
 AliITSUv0Layer.cxx:1515
 AliITSUv0Layer.cxx:1516
 AliITSUv0Layer.cxx:1517
 AliITSUv0Layer.cxx:1518
 AliITSUv0Layer.cxx:1519
 AliITSUv0Layer.cxx:1520
 AliITSUv0Layer.cxx:1521
 AliITSUv0Layer.cxx:1522
 AliITSUv0Layer.cxx:1523
 AliITSUv0Layer.cxx:1524
 AliITSUv0Layer.cxx:1525
 AliITSUv0Layer.cxx:1526
 AliITSUv0Layer.cxx:1527
 AliITSUv0Layer.cxx:1528
 AliITSUv0Layer.cxx:1529
 AliITSUv0Layer.cxx:1530
 AliITSUv0Layer.cxx:1531
 AliITSUv0Layer.cxx:1532
 AliITSUv0Layer.cxx:1533
 AliITSUv0Layer.cxx:1534
 AliITSUv0Layer.cxx:1535
 AliITSUv0Layer.cxx:1536
 AliITSUv0Layer.cxx:1537
 AliITSUv0Layer.cxx:1538
 AliITSUv0Layer.cxx:1539
 AliITSUv0Layer.cxx:1540
 AliITSUv0Layer.cxx:1541
 AliITSUv0Layer.cxx:1542
 AliITSUv0Layer.cxx:1543
 AliITSUv0Layer.cxx:1544
 AliITSUv0Layer.cxx:1545
 AliITSUv0Layer.cxx:1546
 AliITSUv0Layer.cxx:1547
 AliITSUv0Layer.cxx:1548
 AliITSUv0Layer.cxx:1549
 AliITSUv0Layer.cxx:1550
 AliITSUv0Layer.cxx:1551
 AliITSUv0Layer.cxx:1552
 AliITSUv0Layer.cxx:1553
 AliITSUv0Layer.cxx:1554
 AliITSUv0Layer.cxx:1555
 AliITSUv0Layer.cxx:1556
 AliITSUv0Layer.cxx:1557
 AliITSUv0Layer.cxx:1558
 AliITSUv0Layer.cxx:1559
 AliITSUv0Layer.cxx:1560
 AliITSUv0Layer.cxx:1561
 AliITSUv0Layer.cxx:1562
 AliITSUv0Layer.cxx:1563
 AliITSUv0Layer.cxx:1564
 AliITSUv0Layer.cxx:1565
 AliITSUv0Layer.cxx:1566
 AliITSUv0Layer.cxx:1567
 AliITSUv0Layer.cxx:1568
 AliITSUv0Layer.cxx:1569
 AliITSUv0Layer.cxx:1570
 AliITSUv0Layer.cxx:1571
 AliITSUv0Layer.cxx:1572
 AliITSUv0Layer.cxx:1573
 AliITSUv0Layer.cxx:1574
 AliITSUv0Layer.cxx:1575
 AliITSUv0Layer.cxx:1576
 AliITSUv0Layer.cxx:1577
 AliITSUv0Layer.cxx:1578
 AliITSUv0Layer.cxx:1579
 AliITSUv0Layer.cxx:1580
 AliITSUv0Layer.cxx:1581
 AliITSUv0Layer.cxx:1582
 AliITSUv0Layer.cxx:1583
 AliITSUv0Layer.cxx:1584
 AliITSUv0Layer.cxx:1585
 AliITSUv0Layer.cxx:1586
 AliITSUv0Layer.cxx:1587
 AliITSUv0Layer.cxx:1588
 AliITSUv0Layer.cxx:1589
 AliITSUv0Layer.cxx:1590
 AliITSUv0Layer.cxx:1591
 AliITSUv0Layer.cxx:1592
 AliITSUv0Layer.cxx:1593
 AliITSUv0Layer.cxx:1594
 AliITSUv0Layer.cxx:1595
 AliITSUv0Layer.cxx:1596
 AliITSUv0Layer.cxx:1597
 AliITSUv0Layer.cxx:1598
 AliITSUv0Layer.cxx:1599
 AliITSUv0Layer.cxx:1600
 AliITSUv0Layer.cxx:1601
 AliITSUv0Layer.cxx:1602
 AliITSUv0Layer.cxx:1603
 AliITSUv0Layer.cxx:1604
 AliITSUv0Layer.cxx:1605
 AliITSUv0Layer.cxx:1606
 AliITSUv0Layer.cxx:1607
 AliITSUv0Layer.cxx:1608
 AliITSUv0Layer.cxx:1609
 AliITSUv0Layer.cxx:1610
 AliITSUv0Layer.cxx:1611
 AliITSUv0Layer.cxx:1612
 AliITSUv0Layer.cxx:1613
 AliITSUv0Layer.cxx:1614
 AliITSUv0Layer.cxx:1615
 AliITSUv0Layer.cxx:1616
 AliITSUv0Layer.cxx:1617
 AliITSUv0Layer.cxx:1618
 AliITSUv0Layer.cxx:1619
 AliITSUv0Layer.cxx:1620
 AliITSUv0Layer.cxx:1621
 AliITSUv0Layer.cxx:1622
 AliITSUv0Layer.cxx:1623
 AliITSUv0Layer.cxx:1624
 AliITSUv0Layer.cxx:1625
 AliITSUv0Layer.cxx:1626
 AliITSUv0Layer.cxx:1627
 AliITSUv0Layer.cxx:1628
 AliITSUv0Layer.cxx:1629
 AliITSUv0Layer.cxx:1630
 AliITSUv0Layer.cxx:1631
 AliITSUv0Layer.cxx:1632
 AliITSUv0Layer.cxx:1633
 AliITSUv0Layer.cxx:1634
 AliITSUv0Layer.cxx:1635
 AliITSUv0Layer.cxx:1636
 AliITSUv0Layer.cxx:1637
 AliITSUv0Layer.cxx:1638
 AliITSUv0Layer.cxx:1639
 AliITSUv0Layer.cxx:1640
 AliITSUv0Layer.cxx:1641
 AliITSUv0Layer.cxx:1642
 AliITSUv0Layer.cxx:1643
 AliITSUv0Layer.cxx:1644
 AliITSUv0Layer.cxx:1645
 AliITSUv0Layer.cxx:1646
 AliITSUv0Layer.cxx:1647
 AliITSUv0Layer.cxx:1648
 AliITSUv0Layer.cxx:1649
 AliITSUv0Layer.cxx:1650
 AliITSUv0Layer.cxx:1651
 AliITSUv0Layer.cxx:1652
 AliITSUv0Layer.cxx:1653
 AliITSUv0Layer.cxx:1654
 AliITSUv0Layer.cxx:1655
 AliITSUv0Layer.cxx:1656
 AliITSUv0Layer.cxx:1657
 AliITSUv0Layer.cxx:1658
 AliITSUv0Layer.cxx:1659
 AliITSUv0Layer.cxx:1660
 AliITSUv0Layer.cxx:1661
 AliITSUv0Layer.cxx:1662
 AliITSUv0Layer.cxx:1663
 AliITSUv0Layer.cxx:1664
 AliITSUv0Layer.cxx:1665
 AliITSUv0Layer.cxx:1666
 AliITSUv0Layer.cxx:1667
 AliITSUv0Layer.cxx:1668
 AliITSUv0Layer.cxx:1669
 AliITSUv0Layer.cxx:1670
 AliITSUv0Layer.cxx:1671
 AliITSUv0Layer.cxx:1672
 AliITSUv0Layer.cxx:1673
 AliITSUv0Layer.cxx:1674
 AliITSUv0Layer.cxx:1675
 AliITSUv0Layer.cxx:1676
 AliITSUv0Layer.cxx:1677
 AliITSUv0Layer.cxx:1678
 AliITSUv0Layer.cxx:1679
 AliITSUv0Layer.cxx:1680
 AliITSUv0Layer.cxx:1681
 AliITSUv0Layer.cxx:1682
 AliITSUv0Layer.cxx:1683
 AliITSUv0Layer.cxx:1684
 AliITSUv0Layer.cxx:1685
 AliITSUv0Layer.cxx:1686
 AliITSUv0Layer.cxx:1687
 AliITSUv0Layer.cxx:1688
 AliITSUv0Layer.cxx:1689
 AliITSUv0Layer.cxx:1690
 AliITSUv0Layer.cxx:1691
 AliITSUv0Layer.cxx:1692
 AliITSUv0Layer.cxx:1693
 AliITSUv0Layer.cxx:1694
 AliITSUv0Layer.cxx:1695
 AliITSUv0Layer.cxx:1696
 AliITSUv0Layer.cxx:1697
 AliITSUv0Layer.cxx:1698
 AliITSUv0Layer.cxx:1699
 AliITSUv0Layer.cxx:1700
 AliITSUv0Layer.cxx:1701
 AliITSUv0Layer.cxx:1702
 AliITSUv0Layer.cxx:1703
 AliITSUv0Layer.cxx:1704
 AliITSUv0Layer.cxx:1705
 AliITSUv0Layer.cxx:1706
 AliITSUv0Layer.cxx:1707
 AliITSUv0Layer.cxx:1708
 AliITSUv0Layer.cxx:1709
 AliITSUv0Layer.cxx:1710
 AliITSUv0Layer.cxx:1711
 AliITSUv0Layer.cxx:1712
 AliITSUv0Layer.cxx:1713
 AliITSUv0Layer.cxx:1714
 AliITSUv0Layer.cxx:1715
 AliITSUv0Layer.cxx:1716
 AliITSUv0Layer.cxx:1717
 AliITSUv0Layer.cxx:1718
 AliITSUv0Layer.cxx:1719
 AliITSUv0Layer.cxx:1720
 AliITSUv0Layer.cxx:1721
 AliITSUv0Layer.cxx:1722
 AliITSUv0Layer.cxx:1723
 AliITSUv0Layer.cxx:1724
 AliITSUv0Layer.cxx:1725
 AliITSUv0Layer.cxx:1726
 AliITSUv0Layer.cxx:1727
 AliITSUv0Layer.cxx:1728
 AliITSUv0Layer.cxx:1729
 AliITSUv0Layer.cxx:1730
 AliITSUv0Layer.cxx:1731
 AliITSUv0Layer.cxx:1732
 AliITSUv0Layer.cxx:1733
 AliITSUv0Layer.cxx:1734
 AliITSUv0Layer.cxx:1735
 AliITSUv0Layer.cxx:1736
 AliITSUv0Layer.cxx:1737
 AliITSUv0Layer.cxx:1738
 AliITSUv0Layer.cxx:1739
 AliITSUv0Layer.cxx:1740
 AliITSUv0Layer.cxx:1741
 AliITSUv0Layer.cxx:1742
 AliITSUv0Layer.cxx:1743
 AliITSUv0Layer.cxx:1744
 AliITSUv0Layer.cxx:1745
 AliITSUv0Layer.cxx:1746
 AliITSUv0Layer.cxx:1747
 AliITSUv0Layer.cxx:1748
 AliITSUv0Layer.cxx:1749
 AliITSUv0Layer.cxx:1750
 AliITSUv0Layer.cxx:1751
 AliITSUv0Layer.cxx:1752
 AliITSUv0Layer.cxx:1753
 AliITSUv0Layer.cxx:1754
 AliITSUv0Layer.cxx:1755
 AliITSUv0Layer.cxx:1756
 AliITSUv0Layer.cxx:1757
 AliITSUv0Layer.cxx:1758
 AliITSUv0Layer.cxx:1759
 AliITSUv0Layer.cxx:1760
 AliITSUv0Layer.cxx:1761
 AliITSUv0Layer.cxx:1762
 AliITSUv0Layer.cxx:1763
 AliITSUv0Layer.cxx:1764
 AliITSUv0Layer.cxx:1765
 AliITSUv0Layer.cxx:1766
 AliITSUv0Layer.cxx:1767
 AliITSUv0Layer.cxx:1768
 AliITSUv0Layer.cxx:1769
 AliITSUv0Layer.cxx:1770
 AliITSUv0Layer.cxx:1771
 AliITSUv0Layer.cxx:1772
 AliITSUv0Layer.cxx:1773
 AliITSUv0Layer.cxx:1774
 AliITSUv0Layer.cxx:1775
 AliITSUv0Layer.cxx:1776
 AliITSUv0Layer.cxx:1777
 AliITSUv0Layer.cxx:1778
 AliITSUv0Layer.cxx:1779
 AliITSUv0Layer.cxx:1780
 AliITSUv0Layer.cxx:1781
 AliITSUv0Layer.cxx:1782
 AliITSUv0Layer.cxx:1783
 AliITSUv0Layer.cxx:1784
 AliITSUv0Layer.cxx:1785
 AliITSUv0Layer.cxx:1786
 AliITSUv0Layer.cxx:1787
 AliITSUv0Layer.cxx:1788
 AliITSUv0Layer.cxx:1789
 AliITSUv0Layer.cxx:1790
 AliITSUv0Layer.cxx:1791
 AliITSUv0Layer.cxx:1792
 AliITSUv0Layer.cxx:1793
 AliITSUv0Layer.cxx:1794
 AliITSUv0Layer.cxx:1795
 AliITSUv0Layer.cxx:1796
 AliITSUv0Layer.cxx:1797
 AliITSUv0Layer.cxx:1798
 AliITSUv0Layer.cxx:1799
 AliITSUv0Layer.cxx:1800
 AliITSUv0Layer.cxx:1801
 AliITSUv0Layer.cxx:1802
 AliITSUv0Layer.cxx:1803
 AliITSUv0Layer.cxx:1804
 AliITSUv0Layer.cxx:1805
 AliITSUv0Layer.cxx:1806
 AliITSUv0Layer.cxx:1807
 AliITSUv0Layer.cxx:1808
 AliITSUv0Layer.cxx:1809
 AliITSUv0Layer.cxx:1810
 AliITSUv0Layer.cxx:1811
 AliITSUv0Layer.cxx:1812
 AliITSUv0Layer.cxx:1813
 AliITSUv0Layer.cxx:1814
 AliITSUv0Layer.cxx:1815
 AliITSUv0Layer.cxx:1816
 AliITSUv0Layer.cxx:1817
 AliITSUv0Layer.cxx:1818
 AliITSUv0Layer.cxx:1819
 AliITSUv0Layer.cxx:1820
 AliITSUv0Layer.cxx:1821
 AliITSUv0Layer.cxx:1822
 AliITSUv0Layer.cxx:1823
 AliITSUv0Layer.cxx:1824
 AliITSUv0Layer.cxx:1825
 AliITSUv0Layer.cxx:1826
 AliITSUv0Layer.cxx:1827
 AliITSUv0Layer.cxx:1828
 AliITSUv0Layer.cxx:1829
 AliITSUv0Layer.cxx:1830
 AliITSUv0Layer.cxx:1831
 AliITSUv0Layer.cxx:1832
 AliITSUv0Layer.cxx:1833
 AliITSUv0Layer.cxx:1834
 AliITSUv0Layer.cxx:1835
 AliITSUv0Layer.cxx:1836
 AliITSUv0Layer.cxx:1837
 AliITSUv0Layer.cxx:1838
 AliITSUv0Layer.cxx:1839
 AliITSUv0Layer.cxx:1840
 AliITSUv0Layer.cxx:1841
 AliITSUv0Layer.cxx:1842
 AliITSUv0Layer.cxx:1843
 AliITSUv0Layer.cxx:1844
 AliITSUv0Layer.cxx:1845
 AliITSUv0Layer.cxx:1846
 AliITSUv0Layer.cxx:1847
 AliITSUv0Layer.cxx:1848
 AliITSUv0Layer.cxx:1849
 AliITSUv0Layer.cxx:1850
 AliITSUv0Layer.cxx:1851
 AliITSUv0Layer.cxx:1852
 AliITSUv0Layer.cxx:1853
 AliITSUv0Layer.cxx:1854
 AliITSUv0Layer.cxx:1855
 AliITSUv0Layer.cxx:1856
 AliITSUv0Layer.cxx:1857
 AliITSUv0Layer.cxx:1858
 AliITSUv0Layer.cxx:1859
 AliITSUv0Layer.cxx:1860
 AliITSUv0Layer.cxx:1861
 AliITSUv0Layer.cxx:1862
 AliITSUv0Layer.cxx:1863
 AliITSUv0Layer.cxx:1864
 AliITSUv0Layer.cxx:1865
 AliITSUv0Layer.cxx:1866
 AliITSUv0Layer.cxx:1867
 AliITSUv0Layer.cxx:1868
 AliITSUv0Layer.cxx:1869
 AliITSUv0Layer.cxx:1870
 AliITSUv0Layer.cxx:1871
 AliITSUv0Layer.cxx:1872
 AliITSUv0Layer.cxx:1873
 AliITSUv0Layer.cxx:1874
 AliITSUv0Layer.cxx:1875
 AliITSUv0Layer.cxx:1876
 AliITSUv0Layer.cxx:1877
 AliITSUv0Layer.cxx:1878
 AliITSUv0Layer.cxx:1879
 AliITSUv0Layer.cxx:1880
 AliITSUv0Layer.cxx:1881
 AliITSUv0Layer.cxx:1882