// //
///////////////////////////////////////////////////////////////////////////////
-#include "TBRIK.h"
-#include "TGeometry.h"
-#include "TLorentzVector.h"
-#include "TNode.h"
-#include "TVirtualMC.h"
-#include "TGeoManager.h"
+#include <TDirectory.h>
+#include <TGeoGlobalMagField.h>
+#include <TGeoManager.h>
#include <TGeoMatrix.h>
#include <TGeoPhysicalNode.h>
#include <TGeoVolume.h>
+#include <TLorentzVector.h>
+#include <TVirtualMC.h>
#include "AliConst.h"
+#include "AliGeomManager.h"
#include "AliLog.h"
#include "AliMagF.h"
#include "AliMC.h"
#include "AliTOFGeometry.h"
#include "AliTOFv6T0.h"
-extern TDirectory *gDirectory;
extern TVirtualMC *gMC;
extern TGeoManager *gGeoManager;
const Float_t AliTOFv6T0::fgkInterCentrModBorder2 = 57.5 ; // cm
const Float_t AliTOFv6T0::fgkExterInterModBorder1 = 196.0 ; // cm
const Float_t AliTOFv6T0::fgkExterInterModBorder2 = 203.5 ; // cm
-const Float_t AliTOFv6T0::fgkLengthInCeModBorder = 4.7 ; // cm
-const Float_t AliTOFv6T0::fgkLengthExInModBorder = 7.0 ; // cm
+//const Float_t AliTOFv6T0::fgkLengthInCeModBorder = 7.2 ; // cm // it was 4.7 cm (AdC)
+const Float_t AliTOFv6T0::fgkLengthInCeModBorderU = 5.0 ; // cm
+const Float_t AliTOFv6T0::fgkLengthInCeModBorderD = 7.0 ; // cm
+const Float_t AliTOFv6T0::fgkLengthExInModBorder = 5.0 ; // cm // it was 7.0 cm (AdC)
const Float_t AliTOFv6T0::fgkModuleCoverThickness = 2.0 ; // cm
const Float_t AliTOFv6T0::fgkFEAwidth1 = 19.0; // cm
const Float_t AliTOFv6T0::fgkFEAwidth2 = 39.5;//38.5; // cm
fIdFTOC(-1),
fIdFLTA(-1),
fIdFLTB(-1),
- fIdFLTC(-1),
- fTOFHoles(kFALSE)
+ fIdFLTC(-1)//,
+//fTOFHoles(kFALSE)
{
//
// Default constructor
fIdFTOC(-1),
fIdFLTA(-1),
fIdFLTB(-1),
- fIdFLTC(-1),
- fTOFHoles(kFALSE)
+ fIdFLTC(-1)//,
+ //fTOFHoles(kFALSE)
{
//
// Standard constructor
//
+
//
// Check that FRAME is there otherwise we have no place where to
// put TOF
+ /*
AliModule* frame = (AliModule*)gAlice->GetModule("FRAME");
+
if(!frame) {
AliFatal("TOF needs FRAME to be present");
- } else{
-
+ } else {
if (fTOFGeometry) delete fTOFGeometry;
fTOFGeometry = new AliTOFGeometry();
if(frame->IsVersion()==1) {
AliDebug(1,Form("Frame version %d", frame->IsVersion()));
AliDebug(1,"Full Coverage for TOF");
- fTOFHoles=false;}
+ fTOFHoles=false;}
else {
AliDebug(1,Form("Frame version %d", frame->IsVersion()));
AliDebug(1,"TOF with Holes for PHOS");
- fTOFHoles=true;}
+ fTOFHoles=true;}
+
}
+ */
+
+ if (fTOFGeometry) delete fTOFGeometry;
+ fTOFGeometry = new AliTOFGeometry();
fTOFGeometry->SetHoles(fTOFHoles);
//AliTOF::fTOFGeometry = fTOFGeometry;
// Save the geometry
TDirectory* saveDir = gDirectory;
- gAlice->GetRunLoader()->CdGAFile();
+ AliRunLoader::Instance()->CdGAFile();
fTOFGeometry->Write("TOFgeometry");
saveDir->cd();
// eventual changes in the geometry.
//
+ AliGeomManager::ELayerID idTOF = AliGeomManager::kTOF;
+ Int_t modUID, modnum=0;
+
TString volPath;
TString symName;
for (Int_t isect = 0; isect < nSectors; isect++) {
for (Int_t istr = 1; istr <= nStrips; istr++) {
- //if (fTOFSectors[isect]==-1) continue;
+ modUID = AliGeomManager::LayerToVolUID(idTOF, modnum++);
+ if (fTOFSectors[isect]==-1) continue;
if (fTOFHoles && (isect==13 || isect==14 || isect==15)) {
if (istr<39) {
AliDebug(2,Form("symName=%s\n",symName.Data()));
AliDebug(2,"--------------------------------------------");
- gGeoManager->SetAlignableEntry(symName.Data(),volPath.Data());
+ if(!gGeoManager->SetAlignableEntry(symName.Data(),volPath.Data(),modUID))
+ AliError(Form("Alignable entry %s not set",symName.Data()));
//T2L matrices for alignment
- TGeoPNEntry *e = gGeoManager->GetAlignableEntry(symName.Data());
+ TGeoPNEntry *e = gGeoManager->GetAlignableEntryByUID(modUID);
if (e) {
- const char *path = e->GetTitle();
- if (!gGeoManager->cd(path)) {
- AliFatal(Form("Volume path %s not valid!",path));
- }
- TGeoHMatrix *globMatrix = gGeoManager->GetCurrentMatrix();
+ TGeoHMatrix *globMatrix = e->GetGlobalOrig();
Double_t phi = 20.0 * (isect % 18) + 10.0;
TGeoHMatrix *t2l = new TGeoHMatrix();
t2l->RotateZ(phi);
else {
AliError(Form("Alignable entry %s is not valid!",symName.Data()));
}
-
imod++;
}
}
symName = snSM;
symName += Form("%02d",isect);
- AliDebug(2,"--------------------------------------------");
- AliDebug(2,Form("Alignable object %d", isect+imod));
- AliDebug(2,Form("volPath=%s\n",volPath.Data()));
- AliDebug(2,Form("symName=%s\n",symName.Data()));
- AliDebug(2,"--------------------------------------------");
-
- gGeoManager->SetAlignableEntry(symName.Data(),volPath.Data());
-
- }
-
-}
-//____________________________________________________________________________
-void AliTOFv6T0::BuildGeometry()
-{
- //
- // Build TOF ROOT geometry for the ALICE event display
- //
- TNode *node, *top;
- const int kColorTOF = 27;
-
- TGeometry *globalGeometry = (TGeometry*)gAlice->GetGeometry();
-
- // Find top TNODE
- top = globalGeometry->GetNode("alice");
-
- // Position the different copies
- const Float_t krTof =(fTOFGeometry->Rmax()+fTOFGeometry->Rmin())/2.;
- const Float_t khTof = fTOFGeometry->Rmax()-fTOFGeometry->Rmin();
- const Int_t kNTof = fTOFGeometry->NSectors();
- const Float_t kangle = k2PI/kNTof;
-
- Float_t ang;
-
- // define offset for nodes
- Float_t zOffsetB = (fTOFGeometry->ZlenA()*0.5 + (fgkInterCentrModBorder1+fgkInterCentrModBorder2)*0.5)*0.5;
- Float_t zOffsetA = 0.;
+ AliDebug(2,"--------------------------------------------");
+ AliDebug(2,Form("Alignable object %d", isect+imod));
+ AliDebug(2,Form("volPath=%s\n",volPath.Data()));
+ AliDebug(2,Form("symName=%s\n",symName.Data()));
+ AliDebug(2,"--------------------------------------------");
- // Define TOF basic volume
- char nodeName0[16], nodeName1[16], nodeName2[16];
- char nodeName3[16], nodeName4[16], rotMatNum[16];
+ gGeoManager->SetAlignableEntry(symName.Data(),volPath.Data());
- if (fTOFHoles) {
- new TBRIK("S_TOF_B","TOF box","void",
- fTOFGeometry->StripLength()*0.5, khTof*0.5, fTOFGeometry->ZlenB()*0.5);
- new TBRIK("S_TOF_C","TOF box","void",
- fTOFGeometry->StripLength()*0.5, khTof*0.5, fTOFGeometry->ZlenB()*0.5);
}
- new TBRIK("S_TOF_A","TOF box","void",
- fTOFGeometry->StripLength()*0.5, khTof*0.5, fTOFGeometry->ZlenA()*0.5);
- for (Int_t nodeNum=1;nodeNum<kNTof+1;nodeNum++){
-
- if (nodeNum<10) {
- sprintf(rotMatNum,"rot50%i",nodeNum);
- sprintf(nodeName0,"FTO00%i",nodeNum);
- sprintf(nodeName1,"FTO10%i",nodeNum);
- sprintf(nodeName2,"FTO20%i",nodeNum);
- sprintf(nodeName3,"FTO30%i",nodeNum);
- sprintf(nodeName4,"FTO40%i",nodeNum);
- }
- if (nodeNum>9) {
- sprintf(rotMatNum,"rot5%i",nodeNum);
- sprintf(nodeName0,"FTO0%i",nodeNum);
- sprintf(nodeName1,"FTO1%i",nodeNum);
- sprintf(nodeName2,"FTO2%i",nodeNum);
- sprintf(nodeName3,"FTO3%i",nodeNum);
- sprintf(nodeName4,"FTO4%i",nodeNum);
- }
-
- new TRotMatrix(rotMatNum,rotMatNum,90,-20*nodeNum,90,90-20*nodeNum,0,0);
- ang = (4.5-nodeNum) * kangle;
-
- if (fTOFHoles) {
- top->cd();
- node = new TNode(nodeName2,nodeName2,"S_TOF_B", krTof*TMath::Cos(ang), krTof*TMath::Sin(ang), zOffsetB,rotMatNum);
- node->SetLineColor(kColorTOF);
- fNodes->Add(node);
-
- top->cd();
- node = new TNode(nodeName3,nodeName3,"S_TOF_C", krTof*TMath::Cos(ang), krTof*TMath::Sin(ang),-zOffsetB,rotMatNum);
- node->SetLineColor(kColorTOF);
- fNodes->Add(node);
- }
-
- top->cd();
- node = new TNode(nodeName4,nodeName4,"S_TOF_A", krTof*TMath::Cos(ang), krTof*TMath::Sin(ang), zOffsetA,rotMatNum);
- node->SetLineColor(kColorTOF);
- fNodes->Add(node);
- } // end loop on nodeNum
-
}
//_____________________________________________________________________________
//
AliDebug(1, "************************* TOF geometry **************************");
- AliDebug(1,Form(" xtof %d", xtof));
- AliDebug(1,Form(" ytof %d", ytof));
- AliDebug(1,Form(" zlenA %d", zlenA));
- AliDebug(2,Form(" zlenA*0.5 = %d", zlenA*0.5));
+ AliDebug(1,Form(" xtof %f", xtof));
+ AliDebug(1,Form(" ytof %f", ytof));
+ AliDebug(1,Form(" zlenA %f", zlenA));
+ AliDebug(2,Form(" zlenA*0.5 = %f", zlenA*0.5));
Float_t xFLT, yFLT, zFLTA;
xFLT = xtof - 2.*fgkModuleWallThickness;
Int_t *idtmed = fIdtmed->GetArray()-499;
- Int_t idrotm[8];
+ Int_t idrotm[8]; for (Int_t ii=0; ii<8; ii++) idrotm[ii]=0;
// Definition of the of fibre glass modules (FTOA, FTOB and FTOC)
Float_t par[3];
// Definition and positioning
// of the fibre glass walls between central and intermediate modules (FWZ1 and FWZ2)
Float_t alpha, tgal, beta, tgbe, trpa[11];
- tgal = (yFLT - 2.*fgkLengthInCeModBorder)/(fgkInterCentrModBorder2 - fgkInterCentrModBorder1);
+ //tgal = (yFLT - 2.*fgkLengthInCeModBorder)/(fgkInterCentrModBorder2 - fgkInterCentrModBorder1);
+ tgal = (yFLT - fgkLengthInCeModBorderU - fgkLengthInCeModBorderD)/(fgkInterCentrModBorder2 - fgkInterCentrModBorder1);
alpha = TMath::ATan(tgal);
beta = (kPi*0.5 - alpha)*0.5;
tgbe = TMath::Tan(beta);
trpa[1] = 0.;
trpa[2] = 0.;
trpa[3] = 2.*fgkModuleWallThickness;
- trpa[4] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
- trpa[5] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[4] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[5] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[4] = (fgkLengthInCeModBorderD - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[5] = (fgkLengthInCeModBorderD + 2.*fgkModuleWallThickness*tgbe)*0.5;
trpa[6] = TMath::ATan(tgbe*0.5)*kRaddeg; //TMath::ATan((trpa[5] - trpa[4])/(2.*trpa[3]))*kRaddeg;
trpa[7] = 2.*fgkModuleWallThickness;
- trpa[8] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
- trpa[9] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[8] = (fgkLengthInCeModBorderD - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[9] = (fgkLengthInCeModBorderD + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[8] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[9] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
trpa[10] = TMath::ATan(tgbe*0.5)*kRaddeg; //TMath::ATan((trpa[5] - trpa[4])/(2.*trpa[3]))*kRaddeg;
- gMC->Gsvolu("FWZ1", "TRAP", idtmed[503], trpa, 11); // Fibre glass
+ gMC->Gsvolu("FWZ1D", "TRAP", idtmed[503], trpa, 11); // Fibre glass
AliMatrix (idrotm[0],90., 90.,180.,0.,90.,180.);
AliMatrix (idrotm[1],90., 90., 0.,0.,90., 0.);
//xcoor = 0.;
- ycoor = -(yFLT - fgkLengthInCeModBorder)*0.5;
+ //ycoor = -(yFLT - fgkLengthInCeModBorder)*0.5;
+ ycoor = -(yFLT - fgkLengthInCeModBorderD)*0.5;
zcoor = fgkInterCentrModBorder1;
- gMC->Gspos("FWZ1", 1, "FLTA", xcoor, ycoor, zcoor, idrotm[0], "ONLY");
- gMC->Gspos("FWZ1", 2, "FLTA", xcoor, ycoor,-zcoor, idrotm[1], "ONLY");
+ gMC->Gspos("FWZ1D", 1, "FLTA", xcoor, ycoor, zcoor, idrotm[0], "ONLY");
+ gMC->Gspos("FWZ1D", 2, "FLTA", xcoor, ycoor,-zcoor, idrotm[1], "ONLY");
Float_t y0B, ycoorB, zcoorB;
if (fTOFHoles) {
- y0B = fgkLengthInCeModBorder - fgkModuleWallThickness*tgbe;
+ //y0B = fgkLengthInCeModBorder - fgkModuleWallThickness*tgbe;
+ y0B = fgkLengthInCeModBorderD - fgkModuleWallThickness*tgbe;
trpa[0] = xFLT*0.5;
trpa[1] = 0.;
trpa[2] = 0.;
//xcoor = 0.;
ycoorB = ycoor - fgkModuleWallThickness*0.5*tgbe;
zcoorB = (zlenA*0.5 - 2.*fgkModuleWallThickness - fgkInterCentrModBorder1)*0.5 - 2.*fgkModuleWallThickness;
- gMC->Gsvolu("FWZA", "TRAP", idtmed[503], trpa, 11); // Fibre glass
- gMC->Gspos("FWZA", 1, "FLTB", xcoor, ycoorB, zcoorB, idrotm[1], "ONLY");
- gMC->Gspos("FWZA", 2, "FLTC", xcoor, ycoorB,-zcoorB, idrotm[0], "ONLY");
+ gMC->Gsvolu("FWZAD", "TRAP", idtmed[503], trpa, 11); // Fibre glass
+ gMC->Gspos("FWZAD", 1, "FLTB", xcoor, ycoorB, zcoorB, idrotm[1], "ONLY");
+ gMC->Gspos("FWZAD", 2, "FLTC", xcoor, ycoorB,-zcoorB, idrotm[0], "ONLY");
}
+
+
+ tgal = (yFLT - fgkLengthInCeModBorderU - fgkLengthInCeModBorderD)/(fgkInterCentrModBorder2 - fgkInterCentrModBorder1);
+ alpha = TMath::ATan(tgal);
+ beta = (kPi*0.5 - alpha)*0.5;
+ tgbe = TMath::Tan(beta);
+ trpa[0] = xFLT*0.5;
+ trpa[1] = 0.;
+ trpa[2] = 0.;
+ trpa[3] = 2.*fgkModuleWallThickness;
+ //trpa[4] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[5] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[4] = (fgkLengthInCeModBorderU - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[5] = (fgkLengthInCeModBorderU + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[6] = TMath::ATan(tgbe*0.5)*kRaddeg; //TMath::ATan((trpa[5] - trpa[4])/(2.*trpa[3]))*kRaddeg;
+ trpa[7] = 2.*fgkModuleWallThickness;
+ trpa[8] = (fgkLengthInCeModBorderU - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[9] = (fgkLengthInCeModBorderU + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[8] = (fgkLengthInCeModBorder - 2.*fgkModuleWallThickness*tgbe)*0.5;
+ //trpa[9] = (fgkLengthInCeModBorder + 2.*fgkModuleWallThickness*tgbe)*0.5;
+ trpa[10] = TMath::ATan(tgbe*0.5)*kRaddeg; //TMath::ATan((trpa[5] - trpa[4])/(2.*trpa[3]))*kRaddeg;
+ gMC->Gsvolu("FWZ1U", "TRAP", idtmed[503], trpa, 11); // Fibre glass
+
+
AliMatrix (idrotm[2],90.,270., 0.,0.,90.,180.);
AliMatrix (idrotm[3],90.,270.,180.,0.,90., 0.);
//xcoor = 0.;
- ycoor = (yFLT - fgkLengthInCeModBorder)*0.5;
+ //ycoor = (yFLT - fgkLengthInCeModBorder)*0.5;
+ ycoor = (yFLT - fgkLengthInCeModBorderU)*0.5;
zcoor = fgkInterCentrModBorder2;
- gMC->Gspos("FWZ1", 3, "FLTA", xcoor, ycoor, zcoor,idrotm[2], "ONLY");
- gMC->Gspos("FWZ1", 4, "FLTA", xcoor, ycoor,-zcoor,idrotm[3], "ONLY");
+ gMC->Gspos("FWZ1U", 1, "FLTA", xcoor, ycoor, zcoor,idrotm[2], "ONLY");
+ gMC->Gspos("FWZ1U", 2, "FLTA", xcoor, ycoor,-zcoor,idrotm[3], "ONLY");
if (fTOFHoles) {
- y0B = fgkLengthInCeModBorder + fgkModuleWallThickness*tgbe;
+ //y0B = fgkLengthInCeModBorder + fgkModuleWallThickness*tgbe;
+ y0B = fgkLengthInCeModBorderU + fgkModuleWallThickness*tgbe;
trpa[0] = xFLT*0.5;
trpa[1] = 0.;
trpa[2] = 0.;
trpa[8] = (y0B - fgkModuleWallThickness*tgbe)*0.5;
trpa[9] = (y0B + fgkModuleWallThickness*tgbe)*0.5;
trpa[10] = TMath::ATan(tgbe*0.5)*kRaddeg; //TMath::ATan((trpa[5] - trpa[4])/(2.*trpa[3]))*kRaddeg;
- gMC->Gsvolu("FWZB", "TRAP", idtmed[503], trpa, 11); // Fibre glass
+ gMC->Gsvolu("FWZBU", "TRAP", idtmed[503], trpa, 11); // Fibre glass
//xcoor = 0.;
ycoorB = ycoor - fgkModuleWallThickness*0.5*tgbe;
zcoorB = (zlenA*0.5 - 2.*fgkModuleWallThickness - fgkInterCentrModBorder1)*0.5 -
(fgkInterCentrModBorder2 - fgkInterCentrModBorder1) - 2.*fgkModuleWallThickness;
- gMC->Gspos("FWZB", 1, "FLTB", xcoor, ycoorB, zcoorB, idrotm[3], "ONLY");
- gMC->Gspos("FWZB", 2, "FLTC", xcoor, ycoorB,-zcoorB, idrotm[2], "ONLY");
+ gMC->Gspos("FWZBU", 1, "FLTB", xcoor, ycoorB, zcoorB, idrotm[3], "ONLY");
+ gMC->Gspos("FWZBU", 2, "FLTC", xcoor, ycoorB,-zcoorB, idrotm[2], "ONLY");
}
trpa[0] = 0.5*(fgkInterCentrModBorder2 - fgkInterCentrModBorder1)/TMath::Cos(alpha);
AliMatrix (idrotm[5],180.-alpha*kRaddeg,90.,90.-alpha*kRaddeg,90.,90., 0.);
//xcoor = 0.;
- ycoor = 0.;
+ //ycoor = 0.;
+ ycoor = (fgkLengthInCeModBorderD - fgkLengthInCeModBorderU)*0.5;
zcoor = (fgkInterCentrModBorder2 + fgkInterCentrModBorder1)*0.5;
gMC->Gspos("FWZ2", 1, "FLTA", xcoor, ycoor, zcoor, idrotm[4], "ONLY");
gMC->Gspos("FWZ2", 2, "FLTA", xcoor, ycoor,-zcoor, idrotm[5], "ONLY");
//
// Fill BTOF_%i (for i=0,...17) volumes
// with volumes FTOA (MRPC strip container),
- // In case of TOF holes, two sectors (i.e. 13th, 14th and 15th)
+ // In case of TOF holes, three sectors (i.e. 13th, 14th and 15th)
// are filled with volumes: FTOB and FTOC (MRPC containers),
//
- Int_t idrotm[1];
+ const Int_t kSize=16;
+
+ Int_t idrotm[1]={0};
//AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,-90.);
AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,270.);
// Positioning of fibre glass modules (FTOA, FTOB and FTOC)
for(Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++){
if(fTOFSectors[isec]==-1)continue;
- char name[16];
- sprintf(name, "BTOF%d",isec);
+
+ char name[kSize];
+ snprintf(name, kSize, "BTOF%d",isec);
if (fTOFHoles && (isec==13 || isec==14 || isec==15)) {
//xcoor = 0.;
ycoor = (zlenA*0.5 + fgkInterCentrModBorder1)*0.5;
//
// Fill BTOF_%i (for i=0,...17) volumes
// with volumes FPEA (to separate strips from FEA cards)
- // In case of TOF holes, two sectors (i.e. 13th, 14th and 15th)
+ // In case of TOF holes, three sectors (i.e. 13th, 14th and 15th)
// are filled with FPEB volumes
// (to separate MRPC strips from FEA cards)
//
- Int_t idrotm[1];
+ const Int_t kSize=16;
+
+ Int_t idrotm[1]={0};
//AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,-90.);
AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,270.);
ycoor = 0.;
zcoor = fgkModuleCoverThickness*0.5;
- char name[16];
+ char name[kSize];
// Positioning of module covers (FPEA, FPEB)
for(Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++) {
if(fTOFSectors[isec]==-1)continue;
- sprintf(name, "BTOF%d",isec);
+ snprintf(name, kSize, "BTOF%d",isec);
if (fTOFHoles && (isec==13 || isec==14 || isec==15))
gMC->Gspos("FPEB", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
else
// filled with volumes FAIB (FEA cards and services container).
//
- Int_t idrotm[1];
+ const Int_t kSize=16;
+
+ Int_t idrotm[1]={0};
//AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,-90.);
AliMatrix(idrotm[0], 90., 0., 0., 0., 90.,270.);
ycoor = 0.;
zcoor = fgkModuleCoverThickness + (ytof*0.5 - fgkModuleCoverThickness)*0.5;
- char name[16];
+ char name[kSize];
// Positioning of FEA cards and services containers (FAIA, FAIC and FAIB)
for(Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++) {
if(fTOFSectors[isec]==-1)continue;
- sprintf(name, "BTOF%d",isec);
- if (!fgkFEAwithMasks[isec])
- gMC->Gspos("FAIC", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
+ snprintf(name, kSize, "BTOF%d",isec);
+ if (fgkFEAwithMasks[isec])
+ gMC->Gspos("FAIA", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
else {
if (fTOFHoles && (isec==13 || isec==14 || isec==15))
gMC->Gspos("FAIB", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
else
- gMC->Gspos("FAIA", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
+ gMC->Gspos("FAIC", 0, name, xcoor, ycoor, zcoor, idrotm[0], "ONLY");
}
}
fTOFGeometry->NStripB(),
fTOFGeometry->NStripC()};
- Int_t idrotm[91];
+ Int_t idrotm[91]; for (Int_t ii=0; ii<91; ii++) idrotm[ii]=0;
Int_t totalStrip = 0;
Float_t xpos, zpos, ypos, ang;
Int_t *idtmed = fIdtmed->GetArray()-499;
- Int_t idrotm[1];
+ Int_t idrotm[1]={0};
// Definition of the air card containers (FAIA, FAIC and FAIB)
Float_t feaParam[3] = {fgkFEAparameters[0], fgkFEAparameters[1], fgkFEAparameters[2]};
Float_t feaRoof1[3] = {fgkRoof1parameters[0], fgkRoof1parameters[1], fgkRoof1parameters[2]};
Float_t al3[3] = {fgkAl3parameters[0], fgkAl3parameters[1], fgkAl3parameters[2]};
- Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
+ //Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
// FEA card mother-volume definition
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
gMC->Gsvolu("FCA1", "BOX ", idtmed[500], carpar, 3); // Air
gMC->Gsvolu("FCA2", "BOX ", idtmed[500], carpar, 3); // Air
Float_t al1[3] = {fgkAl1parameters[0], fgkAl1parameters[1], fgkAl1parameters[2]};
Float_t al3[3] = {fgkAl3parameters[0], fgkAl3parameters[1], fgkAl3parameters[2]};
Float_t feaRoof1[3] = {fgkRoof1parameters[0], fgkRoof1parameters[1], fgkRoof1parameters[2]};
- Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
+ //Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
// FEA card volume positioning
gMC->Gsvolu("FRO1", "BOX ", idtmed[504], feaRoof1, 3); // Al
Float_t al3[3] = {fgkAl3parameters[0], fgkAl3parameters[1], fgkAl3parameters[2]};
- Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
+ //Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
// definition and positioning of a small air groove in the FRO1 volume
- Float_t airHole[3] = {feaRoof2[0], feaRoof2[1]*0.5, feaRoof1[2]};
+ Float_t airHole[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1]*0.5, feaRoof1[2]};
gMC->Gsvolu("FREE", "BOX ", idtmed[500], airHole, 3); // Air
gMC->Gspos("FREE", 1, "FRO1", 0., feaRoof1[1]-airHole[1], 0., 0, "ONLY");
gGeoManager->GetVolume("FRO1")->VisibleDaughters(kFALSE);
Float_t feaParam[3] = {fgkFEAparameters[0], fgkFEAparameters[1], fgkFEAparameters[2]};
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
// fourth FEA cooling element definition
// first FEA cooling element positioning
Float_t xcoor = xtof*0.5 - 25.;
- Float_t ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - al1[1];
+ Float_t ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - al1[1];
Float_t zcoor =-carpar[2] + 2.*feaRoof1[2] - al1[2];
gMC->Gspos("FAL1", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FAL1", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
// second FEA cooling element positioning
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - feaRoof1[1];
+ ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - feaRoof1[1];
zcoor =-carpar[2] + feaRoof1[2];
- gMC->Gspos("FRO1", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
- gMC->Gspos("FRO1", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
+ gMC->Gspos("FRO1", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "MANY"); // (AdC)
+ gMC->Gspos("FRO1", 4, "FCA1", xcoor, ycoor, zcoor, 0, "MANY"); // (AdC)
gMC->Gspos("FRO1", 1, "FCA2",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FRO1", 4, "FCA2", xcoor, ycoor, zcoor, 0, "ONLY");
xcoor = feaParam[0] + (fgkFEAwidth2*0.5 - fgkFEAwidth1);
- gMC->Gspos("FRO1", 2, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
- gMC->Gspos("FRO1", 3, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
+ gMC->Gspos("FRO1", 2, "FCA1",-xcoor, ycoor, zcoor, 0, "MANY"); // (AdC)
+ gMC->Gspos("FRO1", 3, "FCA1", xcoor, ycoor, zcoor, 0, "MANY"); // (AdC)
gMC->Gspos("FRO1", 2, "FCA2",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FRO1", 3, "FCA2", xcoor, ycoor, zcoor, 0, "ONLY");
// third FEA cooling element positioning
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - bar[1];
+ ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - bar[1];
zcoor =-carpar[2] + bar[2];
gMC->Gspos("FBAR", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FBAR", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
// fourth FEA cooling element positioning
Float_t tubepar[3] = {0., 0.4, xtof*0.5 - fgkCBLw};
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - bar[1];
+ ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - bar[1];
zcoor =-carpar[2] + 2.*bar[2] + 2.*tubepar[1] + bar1[2];
gMC->Gspos("FBA1", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FBA1", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
// fifth FEA cooling element positioning
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - bar2[1];
+ ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - bar2[1];
zcoor =-carpar[2] + 2.*bar[2] + bar2[2];
gMC->Gspos("FBA2", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FBA2", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FBA2", 3, "FCA2", xcoor, ycoor, zcoor, 0, "ONLY");
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - 2.*tubepar[1] - bar2[1];
+ ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - 2.*tubepar[1] - bar2[1];
zcoor =-carpar[2] + 2.*bar[2] + bar2[2];
gMC->Gspos("FBA2", 5, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FBA2", 8, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
Float_t feaParam[3] = {fgkFEAparameters[0], fgkFEAparameters[1], fgkFEAparameters[2]};
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
// first Nino ASIC mask volume positioning
// third Nino ASIC mask volume positioning
xcoor = xtof*0.5 - 25.;
- ycoor = carpar[1] - feaRoof2[1];
- zcoor = carpar[2] - 2.*al3[2] - feaRoof2[2];
+ ycoor = carpar[1] - fgkRoof2parameters[1];
+ zcoor = carpar[2] - 2.*al3[2] - fgkRoof2parameters[2];
gMC->Gspos("FRO2", 1, "FCA1",-xcoor, ycoor, zcoor, 0, "ONLY");
gMC->Gspos("FRO2", 4, "FCA1", xcoor, ycoor, zcoor, 0, "ONLY");
xcoor = feaParam[0] + (fgkFEAwidth2*0.5 - fgkFEAwidth1);
Int_t *idtmed = fIdtmed->GetArray()-499;
- Int_t idrotm[1];
+ Int_t idrotm[1]={0};
// cooling tube volume definition
Float_t tubepar[3] = {0., 0.4, xtof*0.5 - fgkCBLw - fgkSawThickness};
Float_t bar[3] = {fgkBar[0], fgkBar[1], fgkBar[2]};
Float_t bar2[3] = {fgkBar2[0], fgkBar2[1], fgkBar2[2]};
Float_t al3[3] = {fgkAl3parameters[0], fgkAl3parameters[1], fgkAl3parameters[2]};
- Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
+ //Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
Float_t ytub =-(ytof*0.5 - fgkModuleCoverThickness)*0.5 + carpar[1] +
- carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
+ carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
// Positioning of tubes for the SM cooling system
- Float_t ycoor = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
+ Float_t ycoor = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
Float_t zcoor =-carpar[2] + 2.*bar[2] + tubepar[1];
gMC->Gspos("FTUB", 1, "FCA1", 0., ycoor, zcoor, idrotm[0], "ONLY");
gMC->Gspos("FTUB", 1, "FCA2", 0., ycoor, zcoor, idrotm[0], "ONLY");
}
ycoor = ytub + (tubepar[1] + 2.*bar2[1] + lonpar1[1]);
- zcoor = (198.8 + 56.82)*0.5 - (zlenA*0.5 + fgkInterCentrModBorder2)*0.5;
+ zcoor = (198.8 + 56.82)*0.5;
gMC->Gspos("FLO2", 2, "FAIB",-24., ycoor,-zcoor, 0, "MANY");
gMC->Gspos("FLO2", 1, "FAIB",-24., ycoor, zcoor, 0, "MANY");
- zcoor = (366.9 + 198.8)*0.5 - (zlenA*0.5 + fgkInterCentrModBorder2)*0.5;
+ zcoor = (366.9 + 198.8)*0.5;
gMC->Gspos("FLO3", 2, "FAIB",-24., ycoor,-zcoor, 0, "MANY");
gMC->Gspos("FLO3", 1, "FAIB",-24., ycoor, zcoor, 0, "MANY");
ycoor = ytub - (tubepar[1] + 2.*bar2[1] + lonpar1[1]);
- zcoor = (198.8 + 56.82)*0.5 - (zlenA*0.5 + fgkInterCentrModBorder2)*0.5;
- gMC->Gspos("FLO2", 4, "FAIB",-24., ycoor,-zcoor, 0, "MANY");
- gMC->Gspos("FLO2", 3, "FAIB",-24., ycoor, zcoor, 0, "MANY");
- zcoor = (366.9 + 198.8)*0.5 - (zlenA*0.5 + fgkInterCentrModBorder2)*0.5;
- gMC->Gspos("FLO3", 4, "FAIB",-24., ycoor,-zcoor, 0, "MANY");
- gMC->Gspos("FLO3", 3, "FAIB",-24., ycoor, zcoor, 0, "MANY");
+ zcoor = (198.8 + 56.82)*0.5;
+ gMC->Gspos("FLO2", 4, "FAIB", 24., ycoor,-zcoor, 0, "MANY");
+ gMC->Gspos("FLO2", 3, "FAIB", 24., ycoor, zcoor, 0, "MANY");
+ zcoor = (366.9 + 198.8)*0.5;
+ gMC->Gspos("FLO3", 4, "FAIB", 24., ycoor,-zcoor, 0, "MANY");
+ gMC->Gspos("FLO3", 3, "FAIB", 24., ycoor, zcoor, 0, "MANY");
}
Float_t barS2[3] = {fgkBarS2[0], fgkBarS2[1], fgkBarS2[2]};
gMC->Gsvolu("FBS2", "BOX ", idtmed[504], barS2, 3); // Al
- Float_t ytubBis = carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - 2.*barS2[1] - tubepar[1];
+ Float_t ytubBis = carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - 2.*barS2[1] - tubepar[1];
ycoor = ytubBis;
zcoor =-carpar[2] + barS[2];
gMC->Gspos("FBAS", 1, "FCA1",-24., ycoor, zcoor, 0, "ONLY");
Int_t *idtmed = fIdtmed->GetArray()-499;
- Int_t idrotm[3];
+ Int_t idrotm[3]={0,0,0};
Float_t tubepar[3] = {0., 0.4, xtof*0.5 - fgkCBLw - fgkSawThickness};
Float_t al1[3] = {fgkAl1parameters[0], fgkAl1parameters[1], fgkAl1parameters[2]};
Float_t al3[3] = {fgkAl3parameters[0], fgkAl3parameters[1], fgkAl3parameters[2]};
Float_t feaRoof1[3] = {fgkRoof1parameters[0], fgkRoof1parameters[1], fgkRoof1parameters[2]};
- Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
+ //Float_t feaRoof2[3] = {fgkRoof2parameters[0], fgkRoof2parameters[1], fgkRoof2parameters[2]};
Float_t feaParam[3] = {fgkFEAparameters[0], fgkFEAparameters[1], fgkFEAparameters[2]};
// FEA cables definition
AliMatrix(idrotm[0], 180., 90., 90., 90., 90., 0.);
Float_t carpar[3] = {xtof*0.5 - fgkCBLw - fgkSawThickness,
- feaParam[1] + feaRoof1[1] + feaRoof2[1]*0.5,
+ feaParam[1] + feaRoof1[1] + fgkRoof2parameters[1]*0.5,
feaRoof1[2] + fgkBetweenLandMask*0.5 + al3[2]};
Float_t bar2[3] = {fgkBar2[0], fgkBar2[1], fgkBar2[2]};
Float_t ytub =-(ytof*0.5 - fgkModuleCoverThickness)*0.5 + carpar[1] +
- carpar[1] - 2.*feaRoof2[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
+ carpar[1] - 2.*fgkRoof2parameters[1]*0.5 - 2.*feaRoof1[1] - 2.*bar2[1] - tubepar[1];
// FEA cables positioning
Float_t xcoor = (tubepar[2] + (fgkFEAwidth2 - fgkFEAwidth1/6.)*0.5)*0.5;
Int_t *idtmed = fIdtmed->GetArray()-499;
- Int_t idrotm[18];
+ Int_t idrotm[18]; for (Int_t ii=0; ii<18; ii++) idrotm[ii]=0;
// volume definition
Float_t serpar[3] = {29.*0.5, 121.*0.5, 90.*0.5};
}
zcoor = (90. - 223.)*0.5;
- gMC->Gspos("FTOS", 1, "BBCE", ra, 0., zcoor, 0, "ONLY");
-
-}
-
-//_____________________________________________________________________________
-void AliTOFv6T0::DrawModule() const
-{
- //
- // Draw a shaded view of the Time Of Flight version 5
- //
-
- // Set everything unseen
- gMC->Gsatt("*", "seen", -1);
-
- //
- //Set volumes visible
- //
-
- //Set ALIC mother transparent
- gMC->Gsatt("ALIC","SEEN", 0);
-
-//=====> Level 1
- // Level 1 for TOF volumes
- gMC->Gsatt("B077","seen", 0);
-
-//=====> Level 2
- // Level 2 for TOF volumes
- gMC->Gsatt("B071","seen", 0);
- gMC->Gsatt("B074","seen", 0);
- gMC->Gsatt("B075","seen", 0);
- gMC->Gsatt("B076","seen",-1); // all B076 sub-levels skipped -
- gMC->Gsatt("B080","seen", 0); // B080 does not has sub-level
-
- // Level 2 of B071
- gMC->Gsatt("B056","seen", 0); // B056 does not has sub-levels -
- gMC->Gsatt("B063","seen",-1); // all B063 sub-levels skipped -
- gMC->Gsatt("B065","seen",-1); // all B065 sub-levels skipped -
- gMC->Gsatt("B067","seen",-1); // all B067 sub-levels skipped -
- gMC->Gsatt("B072","seen",-1); // all B072 sub-levels skipped -
-
- char name[16];
- for (Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++) {
- sprintf(name, "BREF%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BREF%d sub-levels skipped -
- sprintf(name, "BTRD%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BTRD%d sub-levels skipped -
- sprintf(name, "BTOF%d",isec);
- gMC->Gsatt(name,"seen",-2); // all BTOF%d sub-levels skipped -
- }
-
- gMC->Gdopt("hide", "on");
- gMC->Gdopt("shad", "on");
- gMC->Gsatt("*", "fill", 7);
- gMC->SetClipBox(".");
- gMC->SetClipBox("*", 100, 1000, 100, 1000, 100, 1000);
- gMC->DefaultRange();
- gMC->Gdraw("alic", 40, 30, 0, 10, 9.5, .018, .018);
- gMC->Gdhead(1111, "Time Of Flight");
- gMC->Gdman(18, 3, "MAN");
- gMC->Gdopt("hide","off");
-}
-//_____________________________________________________________________________
-void AliTOFv6T0::DrawDetectorModules() const
-{
- //
- // Draw a shaded view of the TOF detector SuperModules version 5
- //
-
- // Set everything unseen
- gMC->Gsatt("*", "seen", -1);
-
- //
- //Set volumes visible
- //
-
- //Set ALIC mother transparent
- gMC->Gsatt("ALIC","SEEN", 0);
-
-//=====> Level 1
- // Level 1 for TOF volumes
- gMC->Gsatt("B077","seen", 0);
-
-//=====> Level 2
- // Level 2 for TOF volumes
- gMC->Gsatt("B071","seen", 0);
- gMC->Gsatt("B074","seen", 0);
- gMC->Gsatt("B075","seen", 0);
- gMC->Gsatt("B076","seen",-1); // all B076 sub-levels skipped -
- gMC->Gsatt("B080","seen", 0); // B080 does not has sub-level
-
- // Level 2 of B071
- gMC->Gsatt("B056","seen", 0); // B056 does not has sub-levels -
- gMC->Gsatt("B063","seen",-1); // all B063 sub-levels skipped -
- gMC->Gsatt("B065","seen",-1); // all B065 sub-levels skipped -
- gMC->Gsatt("B067","seen",-1); // all B067 sub-levels skipped -
- gMC->Gsatt("B072","seen",-1); // all B072 sub-levels skipped -
-
- char name[16];
- for (Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++) {
- sprintf(name, "BREF%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BREF%d sub-levels skipped -
- sprintf(name, "BTRD%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BTRD%d sub-levels skipped -
- sprintf(name, "BTOF%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BTOF%d sub-levels skipped -
- }
-
- // Level 3 of B071, B075 and B074
- gMC->Gsatt("FTOA","seen",-2); // all FTOA sub-levels skipped -
- if (fTOFHoles) gMC->Gsatt("FTOB","seen",-2); // all FTOB sub-levels skipped -
- if (fTOFHoles) gMC->Gsatt("FTOC","seen",-2); // all FTOC sub-levels skipped -
-
- // Level 3 of B071, B075 and B074
- gMC->Gsatt("FAIA","seen",-1); // all FAIA sub-levels skipped -
- gMC->Gsatt("FAIC","seen",-1); // all FAIC sub-levels skipped -
- if (fTOFHoles) gMC->Gsatt("FAIB","seen",-1); // all FAIB sub-levels skipped -
-
- // Level 3 of B071, B075 and B074
- gMC->Gsatt("FPEA","seen",-2/*1*/); // all FPEA sub-levels skipped -
- if (fTOFHoles) gMC->Gsatt("FPEB","seen",-2/*1*/); // all FPEB sub-levels skipped -
-
- gMC->Gdopt("hide","on");
- gMC->Gdopt("shad","on");
- gMC->Gsatt("*", "fill", 5);
- gMC->SetClipBox(".");
- gMC->SetClipBox("*", 100, 1000, 100, 1000, 0, 1000);
- gMC->DefaultRange();
- gMC->Gdraw("alic", 40, 30, 0, 10, 9.5, .018, .018);
- gMC->Gdhead(1111,"TOF detector");
- gMC->Gdman(18, 3, "MAN");
- gMC->Gdopt("hide","off");
-}
-
-//_____________________________________________________________________________
-void AliTOFv6T0::DrawDetectorStrips() const
-{
- //
- // Draw a shaded view of the TOF strips for version 5
- //
-
- // Set everything unseen
- gMC->Gsatt("*", "seen", -1);
-
- //
- //Set volumes visible
- //
-
- //Set ALIC mother transparent
- gMC->Gsatt("ALIC","SEEN", 0);
-
-//=====> Level 1
- // Level 1 for TOF volumes
- gMC->Gsatt("B077","seen", 0);
-
-//=====> Level 2
- // Level 2 for TOF volumes
- gMC->Gsatt("B071","seen", 0);
- gMC->Gsatt("B074","seen", 0);
- gMC->Gsatt("B075","seen", 0);
- gMC->Gsatt("B076","seen",-1); // all B076 sub-levels skipped -
- gMC->Gsatt("B080","seen", 0); // B080 does not has sub-level
-
- // Level 2 of B071
- gMC->Gsatt("B063","seen",-1); // all B063 sub-levels skipped -
- gMC->Gsatt("B065","seen",-1); // all B065 sub-levels skipped -
- gMC->Gsatt("B067","seen",-1); // all B067 sub-levels skipped -
- gMC->Gsatt("B056","seen", 0); // B056 does not has sub-levels -
- gMC->Gsatt("B072","seen",-1); // all B072 sub-levels skipped -
-
- char name[16];
- for (Int_t isec=0; isec<fTOFGeometry->NSectors(); isec++) {
- sprintf(name, "BREF%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BREF%d sub-levels skipped -
- sprintf(name, "BTRD%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BTRD%d sub-levels skipped -
- sprintf(name, "BTOF%d",isec);
- gMC->Gsatt(name,"seen", 0); // all BTOF%d sub-levels skipped -
- }
-
- // Level 3 of B071, B074 and B075
- gMC->Gsatt("FTOA","SEEN", 0);
- if (fTOFHoles) gMC->Gsatt("FTOB","SEEN", 0);
- if (fTOFHoles) gMC->Gsatt("FTOC","SEEN", 0);
-
- // Level 4 of B071, B074 and B075
- gMC->Gsatt("FLTA","SEEN", 0);
- if (fTOFHoles) gMC->Gsatt("FLTB","SEEN", 0);
- if (fTOFHoles) gMC->Gsatt("FLTC","SEEN", 0);
-
- // Level 5 of B071, B074 and B075
- gMC->Gsatt("FAIA","SEEN", 0);
- gMC->Gsatt("FAIC","seen",-1); // all FAIC sub-levels skipped -
- if (fTOFHoles) gMC->Gsatt("FAIB","SEEN", 0);
-
- gMC->Gsatt("FPEA","SEEN", -2/*1*/);
- if (fTOFHoles) gMC->Gsatt("FPEB","SEEN", -2/*1*/);
-
- gMC->Gsatt("FSTR","SEEN",-2); // all FSTR sub-levels skipped -
-
- gMC->Gsatt("FWZ1","SEEN", 1);
- gMC->Gsatt("FWZ2","SEEN", 1);
- gMC->Gsatt("FWZ3","SEEN", 1);
- gMC->Gsatt("FWZ4","SEEN", 1);
- if (fTOFHoles) {
- gMC->Gsatt("FWZA","SEEN", 1);
- gMC->Gsatt("FWZB","SEEN", 1);
- gMC->Gsatt("FWZC","SEEN", 1);
- }
-
- // Level 2 of FAIA
- // Level 2 of FAIB
- // Level 2 of FAIC
- gMC->Gsatt("FCA1","SEEN", 0);
- gMC->Gsatt("FCA2","SEEN", 0);
- gMC->Gsatt("FCAB","SEEN", 0);
- gMC->Gsatt("FCAL","SEEN", 0);
- gMC->Gsatt("FTUB","SEEN",-1); // all FTUB sub-levels skipped -
- gMC->Gsatt("FTLN","SEEN", 0);
- gMC->Gsatt("FLO1","SEEN", 0);
- gMC->Gsatt("FLO2","SEEN", 0);
- gMC->Gsatt("FLO3","SEEN", 0);
- gMC->Gsatt("FCBL","SEEN", 0);
- if (fTOFHoles) gMC->Gsatt("FCBB","SEEN", 0);
- gMC->Gsatt("FSAW","SEEN", 0);
- gMC->Gsatt("FCOV","SEEN", 0);
- if (fTOFHoles) {
- gMC->Gsatt("FCOB","SEEN", 0);
- gMC->Gsatt("FCOP","SEEN", 0);
- }
+ gMC->Gspos("FTOS", 1, "BBCE", ra, -3., zcoor, 0, "ONLY");
- // Level 2 of FTUB
- gMC->Gsatt("FITU","SEEN", 0);
-
- // Level 2 of FSTR
- gMC->Gsatt("FHON","SEEN", 1);
- gMC->Gsatt("FPC1","SEEN", 1);
- gMC->Gsatt("FPC2","SEEN", 1);
- gMC->Gsatt("FPCB","SEEN", 1);
- gMC->Gsatt("FRGL","SEEN", 1);
- gMC->Gsatt("FGLF","SEEN", 1);
-
- // Level 2 of FPCB => Level 3 of FSTR
- gMC->Gsatt("FSEN","SEEN", 0);
- gMC->Gsatt("FSEZ","SEEN", 0);
- gMC->Gsatt("FPAD","SEEN", 1);
-
- gMC->Gdopt("hide","on");
- gMC->Gdopt("shad","on");
- gMC->Gsatt("*", "fill", 5);
- gMC->SetClipBox(".");
- gMC->SetClipBox("*", 0, 1000, 0, 1000, 0, 1000);
- gMC->DefaultRange();
- gMC->Gdraw("alic", 40, 30, 0, 10, 9.5, .018, .018);
- gMC->Gdhead(1111,"TOF Strips");
- gMC->Gdman(18, 3, "MAN");
- gMC->Gdopt("hide","off");
}
//_____________________________________________________________________________
//AliTOF::CreateMaterials();
- AliMagF *magneticField = (AliMagF*)gAlice->Field();
+ AliMagF *magneticField = (AliMagF*)((AliMagF*)TGeoGlobalMagField::Instance()->GetField());
Int_t isxfld = magneticField->Integ();
Float_t sxmgmx = magneticField->Max();
wmatg10[2]= we[2]*0.4;
wmatg10[3]= we[3]*0.4;
wmatg10[4]= we[4]*0.4;
- AliDebug(1,Form("wg10 %d %d %d %d %d", wmatg10[0], wmatg10[1], wmatg10[2], wmatg10[3], wmatg10[4]));
+ AliDebug(1,Form("wg10 %f %f %f %f %f", wmatg10[0], wmatg10[1], wmatg10[2], wmatg10[3], wmatg10[4]));
//Float_t densg10 = 1.7; //old value
Float_t densg10 = 2.0; // (+17.8%)
AliMC *mcApplication = (AliMC*)gAlice->GetMCApp();
- //AddTrackReference(mcApplication->GetCurrentTrackNumber(), AliTrackReference::kTOF);
- AddTrackReference(mcApplication->GetCurrentTrackNumber());
+ AddTrackReference(mcApplication->GetCurrentTrackNumber(), AliTrackReference::kTOF);
+ //AddTrackReference(mcApplication->GetCurrentTrackNumber());
// getting information about hit volumes
}
}
//-------------------------------------------------------------------
-void AliTOFv6T0::MaterialMixer(Float_t* p,Float_t* a,Float_t* m,Int_t n) const
+void AliTOFv6T0::MaterialMixer(Float_t * p, const Float_t * const a,
+ const Float_t * const m, Int_t n) const
{
// a[] atomic weights vector (in)
// (atoms present in more compound appear separately)