#include <TGeoManager.h>
#include <TGeoPhysicalNode.h>
-#include <TGeoMatrix.h>
+#include <TVirtualMC.h>
-#include "AliLog.h"
-#include "AliRunLoader.h"
-#include "AliAlignObj.h"
#include "AliAlignObjParams.h"
-#include "AliRun.h"
-#include "AliTRD.h"
#include "AliTRDcalibDB.h"
#include "AliTRDgeometry.h"
#include "AliTRDpadPlane.h"
-#include "AliTRDSimParam.h"
ClassImp(AliTRDgeometry)
fRotB21[isector] = TMath::Sin(phi);
fRotB22[isector] = TMath::Cos(phi);
}
-
- // Initialize the SM status
- for (isector = 0; isector < fgkNsector; isector++) {
- SetSMstatus(isector,1);
- }
+ // SM status
+ for (Int_t i = 0; i < kNsector; i++) {
+ fSMstatus[i] = 1;
+ }
+
}
//_____________________________________________________________________________
Float_t parTrd[kNparTrd];
Float_t parCha[kNparCha];
- Char_t cTagV[6];
- Char_t cTagM[5];
-
- AliTRDSimParam *simParam = AliTRDSimParam::Instance();
+ Char_t cTagV[100];
+ Char_t cTagM[100];
// There are three TRD volumes for the supermodules in order to accomodate
// the different arrangements in front of PHOS
ypos = 0.0;
zpos = 0.0;
for (Int_t isector = 0; isector < kNsector; isector++) {
- if (fSMstatus[isector]) {
+ if (GetSMstatus(isector)) {
sprintf(cTagV,"BTRD%d",isector);
switch (isector) {
case 13:
ypos = 0.5*fgkSlength + 0.5*fgkFlength;
zpos = 0.0;
for (Int_t isector = 0; isector < kNsector; isector++) {
- if (fSMstatus[isector]) {
+ if (GetSMstatus(isector)) {
sprintf(cTagV,"BTRD%d",isector);
gMC->Gspos("UTF1",1,cTagV,xpos, ypos,zpos,0,"ONLY");
gMC->Gspos("UTF2",1,cTagV,xpos,-ypos,zpos,0,"ONLY");
Float_t ypos = 0.0;
Float_t zpos = 0.0;
- Char_t cTagV[5];
- Char_t cTagM[5];
+ Char_t cTagV[100];
+ Char_t cTagM[100];
const Int_t kNparTRD = 4;
Float_t parTRD[kNparTRD];
//
// The envelope volume (aluminum)
- parTRD[0] = 90.00/2.0;
- parTRD[1] = 114.00/2.0;
+ parTRD[0] = 90.00/2.0 - 0.1;
+ parTRD[1] = 114.00/2.0 - 0.1;
parTRD[2] = 1.50/2.0;
parTRD[3] = 70.30/2.0;
gMC->Gsvolu("USCB","TRD1",idtmed[1301-1],parTRD,kNparTRD);
Float_t ypos = 0.0;
Float_t zpos = 0.0;
- Char_t cTagV[5];
+ Char_t cTagV[100];
const Int_t kNparBox = 3;
Float_t parBox[kNparBox];
Float_t xyzOrig[3];
Float_t xyzBoxd[3];
- Char_t cTagV[5];
- Char_t cTagM[5];
+ Char_t cTagV[100];
+ Char_t cTagM[100];
for (Int_t i = 0; i < 3; i++) {
xyzMin[i] = +9999.0;
xyzBoxd[i] = 0.5*(xyzMax[i]-xyzMin[i]);
}
-
+
sprintf(cTagM,"UT%02d",iDet);
gMC->Gsvolu(cTagM,"BOX ",idtmed[1302-1],xyzBoxd,kNparCha);
}
//_____________________________________________________________________________
-Int_t AliTRDgeometry::GetStack(Int_t det) const
+Int_t AliTRDgeometry::GetStack(Int_t det)
{
//
// Reconstruct the stack number from the detector number
}
//_____________________________________________________________________________
-Int_t AliTRDgeometry::GetSector(Int_t det) const
+Int_t AliTRDgeometry::GetSector(Int_t det)
{
//
// Reconstruct the sector number from the detector number
return kFALSE;
}
+ TString volPath;
+ TString vpStr = "ALIC_1/B077_1/BSEGMO";
+ TString vpApp1 = "_1/BTRD";
+ TString vpApp2 = "_1";
+ TString vpApp3a = "/UTR1_1/UTS1_1/UTI1_1";
+ TString vpApp3b = "/UTR2_1/UTS2_1/UTI2_1";
+ TString vpApp3c = "/UTR3_1/UTS3_1/UTI3_1";
+
fClusterMatrixArray = new TObjArray(kNdet);
AliAlignObjParams o;
Int_t iLayerTRD = iLayer - AliGeomManager::kTRD1;
Int_t lid = GetDetector(iLayerTRD,istack,isector);
- // Taking holes into account
+ // Check for disabled supermodules
+ volPath = vpStr;
+ volPath += isector;
+ volPath += vpApp1;
+ volPath += isector;
+ volPath += vpApp2;
+ switch (isector) {
+ case 13:
+ case 14:
+ case 15:
+ if (istack == 2) {
+ continue;
+ }
+ volPath += vpApp3c;
+ break;
+ case 11:
+ case 12:
+ volPath += vpApp3b;
+ break;
+ default:
+ volPath += vpApp3a;
+ };
+ if (!gGeoManager->CheckPath(volPath)) {
+ continue;
+ }
+
+ // Check for holes in from of PHOS
if (((isector == 13) || (isector == 14) || (isector == 15)) &&
- (istack == 2)) continue;
+ (istack == 2)) {
+ continue;
+ }
UShort_t volid = AliGeomManager::LayerToVolUID(iLayer,iModule);
const char *symname = AliGeomManager::SymName(volid);
}
}
+
+//_____________________________________________________________________________
+Bool_t AliTRDgeometry::IsHole(Int_t /*la*/, Int_t st, Int_t se) const
+{
+ //
+ // Checks for holes in front of PHOS
+ //
+
+ if (((se == 13) || (se == 14) || (se == 15)) &&
+ (st == 2)) {
+ return kTRUE;
+ }
+ return kFALSE;
+
+}