From 1cda0f77376654353d2d579e5244cf5bcd411879 Mon Sep 17 00:00:00 2001 From: belikov Date: Tue, 18 Mar 2014 16:10:41 +0100 Subject: [PATCH] Updating the TDR7 layout --- ITS/UPGRADE/testITSUv1/CreateITSUv1_tdr7.C | 116 ++++++--------------- 1 file changed, 31 insertions(+), 85 deletions(-) diff --git a/ITS/UPGRADE/testITSUv1/CreateITSUv1_tdr7.C b/ITS/UPGRADE/testITSUv1/CreateITSUv1_tdr7.C index e2271459daf..bdc89e4254a 100644 --- a/ITS/UPGRADE/testITSUv1/CreateITSUv1_tdr7.C +++ b/ITS/UPGRADE/testITSUv1/CreateITSUv1_tdr7.C @@ -20,28 +20,27 @@ double radii2Phi(double rMin,double rMid,double rMax, double sensW) void CreateITSUv1_tdr7() { - // ---------------------------------------------------------------------------------------------------- + //--------------------------------------------------------------------------- // This is the TDR7 layout. - // With this layout, the two middle layers are shifted in radius closer to the outer layers. - // ---------------------------------------------------------------------------------------------------- + // With this layout, the two middle layers are shifted in radius + // closer to the outer layers. + //--------------------------------------------------------------------------- - const Double_t dltR =4.94; // radial shift wrt the TDR6 - const Double_t dltZ =21.1; // increment in the lenght (for the corresponding wrapper volume) + const Double_t dltR =4.94; // wrapper volume: radial shift wrt the TDR6 + const Double_t dltZ =21.1; // wrapper volume: increment in the lenght const Int_t dltNsta=6; // increment in the number of staves const Int_t dltNmod=1; // increment in the number of modules in Z - + // gSystem->Load("libITSUpgradeBase.so"); gSystem->Load("libITSUpgradeSim.so"); - - + // // build ITS upgrade detector // sensitive area 13x15mm (X,Z) with 20x20 micron pitch, 2mm dead zone on readout side and 50 micron guardring const double kSensThick = 18e-4; const double kPitchX = 20e-4; const double kPitchZ = 20e-4; const int kNRow = 650; - const int kNCol = 750; - const int kNChips = 2; + const int kNCol = 1500; const double kLrThick03 = 120e-4; // -> effective thickness for ~0.3%X layers const double kLrThick08 = 600e-4; // -> effective thickness for ~0.8%X layers // @@ -51,24 +50,23 @@ void CreateITSUv1_tdr7() const int kNLr = 7; const int kNLrInner = 3; const int kBuildLevel = 3; - enum {kRmn,kRmd,kRmx,kNModPerStave,kPhi0,kNStave,kNPar}; // Radii are from last TDR (ALICE-TDR-017.pdf Tab. 1.1, rMid is mean value) const double tdr5dat[kNLr][kNPar] = { - {2.24, 2.34, 2.67, 9., 16.37, 12}, // for each inner layer: rMin,rMid,rMax,NMod/Stave,phi0, nStave + {2.24, 2.34, 2.67, 9., 16.37, 12}, // for each inner layer: rMin,rMid,rMax,NChip/Stave, phi0, nStaves {3.01, 3.15, 3.46, 9., 12.03, 16}, {3.78, 3.93, 4.21, 9., 10.02, 20}, - {-1, 19.6 +dltR, -1, 4.+dltNmod, 0., 24+dltNsta}, // for others: -, rMid, -, NMod/Stave, phi0, nStave // 24 was 49 - {-1, 24.55+dltR, -1, 4.+dltNmod, 0., 30+dltNsta}, // 30 was 61 + {-1, 19.6+dltR, -1, 4.+dltNmod, 0. , 24+dltNsta}, // for others: -, rMid, -, NMod/HStave, phi0, nStaves // 24 was 49 + {-1, 24.55+dltR, -1, 4.+dltNmod, 0. , 30+dltNsta}, // 30 was 61 {-1, 34.39, -1, 7., 0. , 42}, // 42 was 88 {-1, 39.34, -1, 7., 0. , 48} // 48 was 100 }; - const int nChipsPerModule = 7; // For OB we have to specify how many chips + const int nChipsPerModule = 7; // For OB: how many chips in a row // create segmentations: AliITSUSegmentationPix* seg0 = new AliITSUSegmentationPix(0, // segID (0:9) - kNChips, // chips per module - kNChips*kNCol, // ncols (total for module) + 1, // chips per module + kNCol, // ncols (total for module) kNRow, // nrows kPitchX, // default row pitch in cm kPitchZ, // default col pitch in cm @@ -82,97 +80,45 @@ void CreateITSUv1_tdr7() ); // see AliITSUSegmentationPix.h for extra options seg0->Store(AliITSUGeomTGeo::GetITSsegmentationFileName()); // - AliITSUSegmentationPix* seg1 = new AliITSUSegmentationPix(1, // segID (0:9) - kNChips, // chips per module - kNChips*kNCol, // ncols (total for module) - 2*kNRow, // nrows for oute layers - kPitchX, // default row pitch in cm - kPitchZ, // default col pitch in cm - kSensThick, // sensor thickness in cm - -1, // no special left col between chips - -1, // no special right col between chips - kGuardRing, // left - kGuardRing, // right - kReadOutEdge, // top !!! readout from both sides - kReadOutEdge // bottom - ); // see AliITSUSegmentationPix.h for extra options - seg1->Store(AliITSUGeomTGeo::GetITSsegmentationFileName()); - // seg0->Print(); - seg1->Print(); // - const double kMinOvl = 0.005; // require active zones overlap - const double kTilt = -10.; // tilt in degrees for outer layers - double dzLr,rLr,phi0,turbo,thick; - AliITSUSegmentationPix* seg=0; + double dzLr,rLr,phi0,turbo; int nStaveLr,nModPerStaveLr,idLr; - // virtual void DefineLayerTurbo(const Int_t nlay, const Double_t r, const Double_t zlen, const Int_t nstav, const Int_t nmod, const Double_t width, - // const Double_t tilt, const Double_t lthick = 0., const Double_t dthick = 0., const UInt_t detType=0); - AliITSUv1 *ITS = new AliITSUv1("ITS Upgrade",7); + // + AliITSUv1 *ITS = new AliITSUv1("ITS Upgrade",kNLr); ITS->SetStaveModelIB(AliITSUv1::kIBModel22); ITS->SetStaveModelOB(AliITSUv1::kOBModel1); // const int kNWrapVol = 3; const double wrpRMin[kNWrapVol] = { 2.1, 15.0+dltR, 32.0}; const double wrpRMax[kNWrapVol] = { 7.0, 27.0+dltR+2.3, 43.0+1.5}; - const double wrpZSpan[kNWrapVol] = {28.0, 96.0+dltZ, 158.0}; + const double wrpZSpan[kNWrapVol] = {28.0, 86.0+dltZ, 150.0}; + // ITS->SetNWrapVolumes(kNWrapVol); // define wrapper volumes for layers for (int iw=0;iwDefineWrapVolume(iw,wrpRMin[iw],wrpRMax[iw],wrpZSpan[iw]); // for (int idLr=0;idLrDx()); - thick = kLrThick03; - } - else { - seg = seg1; - turbo = kTilt; - thick = kLrThick08; - } + // nStaveLr = TMath::Nint(tdr5dat[idLr][kNStave]); - if (nStaveLr<0) nStaveLr = getNStaves(seg,kTilt,rLr,kMinOvl); // calculate automatically nModPerStaveLr = TMath::Nint(tdr5dat[idLr][kNModPerStave]); int nChipsPerStaveLr = nModPerStaveLr; + // if (idLr>=kNLrInner) { nChipsPerStaveLr *= nChipsPerModule; - ITS->DefineLayer(idLr, phi0, rLr, nChipsPerStaveLr*seg->Dz(), nStaveLr, nModPerStaveLr, - thick, seg->Dy(), seg->GetChipTypeID(),kBuildLevel); - printf("Add Lr%d: R=%6.2f DZ:%6.2f Staves:%3d NMod/Stave:%3d\n",idLr,rLr,nChipsPerStaveLr*seg->Dz(),nStaveLr,nModPerStaveLr); + ITS->DefineLayer(idLr, phi0, rLr, nChipsPerStaveLr*seg0->Dz(), nStaveLr, nModPerStaveLr, + kLrThick03, seg0->Dy(), seg0->GetChipTypeID(),kBuildLevel); + // printf("Add Lr%d: R=%6.2f DZ:%6.2f Staves:%3d NMod/Stave:%3d\n", + // idLr,rLr,nChipsPerStaveLr*seg0->Dz(),nStaveLr,nModPerStaveLr); } else { - ITS->DefineLayerTurbo(idLr, phi0, rLr, nChipsPerStaveLr*seg->Dz(), nStaveLr, nModPerStaveLr, - seg->Dx(), turbo, thick, seg->Dy(), seg->GetChipTypeID()); - printf("Add Lr%d: R=%6.2f DZ:%6.2f Turbo:%+6.2f Staves:%3d NMod/Stave:%3d\n",idLr,rLr,nChipsPerStaveLr*seg->Dz(),turbo,nStaveLr,nModPerStaveLr); + turbo = -radii2Turbo(tdr5dat[idLr][kRmn],rLr,tdr5dat[idLr][kRmx],seg0->Dx()); + ITS->DefineLayerTurbo(idLr, phi0, rLr, nChipsPerStaveLr*seg0->Dz(), nStaveLr, nChipsPerStaveLr, + seg0->Dx(), turbo, kLrThick08, seg0->Dy(), seg0->GetChipTypeID()); + // printf("Add Lr%d: R=%6.2f DZ:%6.2f Turbo:%+6.2f Staves:%3d NMod/Stave:%3d\n", + // idLr,rLr,nChipsPerStaveLr*seg0->Dz(),turbo,nStaveLr,nModPerStaveLr); } // } // } - -Int_t getNStaves(AliITSUSegmentationPix* seg, double tilt, double r0, double minOvl) -{ - double dphi = (90.-tilt)*TMath::DegToRad(); - double cs = TMath::Cos(dphi); - double sn = TMath::Sin(dphi); - double dx = seg->Dx(); - double tL = -dx/2 + seg->GetGuardBot(); - double tU = dx/2 - seg->GetGuardTop(); - // - double xL = r0 + cs*tL; - double yL = sn*tL; - double xU = r0 + cs*tU; - double yU = sn*tU; - double phiL = TMath::ATan2(yL,xL); - double phiU = TMath::ATan2(yU,xU); - double dphi = TMath::Abs(phiL-phiU); - if (dphi>TMath::Pi()) dphi = TMath::Abs(dphi-TMath::Pi()*2); - double span = dphi*r0; - // - double ov = -1; - int nStaveLr = 1 + r0*TMath::Pi()*2/span; - do { ov = 1.-r0*TMath::Pi()*2/nStaveLr/span; } while ( minOvl>=0 && ov