Int_t iphi=0;
Int_t ieta=0;
geom->GetCellIndex(d1->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
relid1[0]=ieta;
relid1[1]=iphi;
Int_t iphi1=0;
Int_t ieta1=0;
geom->GetCellIndex(d2->GetId(), nSupMod1,nTower1,nIphi1,nIeta1);
- geom->GetCellPhiEtaIndexInSModule(nTower1,nIphi1,nIeta1, iphi1,ieta1);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod1, nTower1,nIphi1,nIeta1, iphi1,ieta1);
Int_t relid2[2] ;
relid2[0]=ieta1;
relid2[1]=iphi1;
int nSupMod=0, nTower=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
geom->GetCellIndex(digit->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
///////////////////////////////////
// check that the digit is above the min E Cut
////////////////////
geom->GetCellIndex(digitN->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
////////////////
if(Calibrate(digitN->GetAmp()+addOn[nSupMod-1][ieta-1][iphi-1]) < fMinECut ) digitsC->Remove(digitN);
// cout<<" new digit above ECut "<<endl;
// Geometry class for EMCAL : singleton
// EMCAL consists of layers of scintillator and lead
// Places the the Barrel Geometry of The EMCAL at Midrapidity
-// between 0 and 120 degrees of Phi and
+// between 80 and 180(or 190) degrees of Phi and
// -0.7 to 0.7 in eta
// Number of Modules and Layers may be controlled by
// the name of the instance defined
// New geometry: EMCAL_55_25
// 24-aug-04 for shish-kebab
// SHISH_25 or SHISH_62
+ // 11-oct-05 - correction for final design
fgInit = kFALSE; // Assume failed until proven otherwise.
name = GetName();
- name.ToUpper();
+ name.ToUpper();
+ fKey110DEG = 0;
+ if(name.Contains("110DEG")) fKey110DEG = 1; // for GetAbsCellId
fNZ = 114; // granularity along Z (eta)
fNPhi = 168; // granularity in phi (azimuth)
if(name.Contains("FINAL")) { // 9-sep-05
fNumberOfSuperModules = 10;
+ if(name.Contains("110DEG")) {
+ fNumberOfSuperModules = 12;// last two modules have size 10 degree in phi (180<phi<190)
+ fArm1PhiMax = 200.0; // for XEN1 and turn angle of super modules
+ }
fPhiModuleSize = 12.26 - fPhiGapForSM / Float_t(fNPhi); // first assumption
fEtaModuleSize = fPhiModuleSize;
}
fNCellsInTower = fNPHIdiv*fNETAdiv;
fNCellsInSupMod = fNCellsInTower*fNPhi*fNZ;
fNCells = fNCellsInSupMod*fNumberOfSuperModules;
+ if(name.Contains("110DEG")) fNCells -= fNCellsInSupMod;
fLongModuleSize = fNECLayers*(fECScintThick + fECPbRadThickness);
if(name.Contains("MAY05")) fLongModuleSize += (fFrontSteelStrip + fPassiveScintThick);
if(fSteelFrontThick>0.)
printf(" fSteelFrontThick %6.3f cm \n", fSteelFrontThick);
printf(" fNPhi %i | fNZ %i \n", fNPhi, fNZ);
+ printf(" fNCellsInTower %i : fNCellsInSupMod %i : fNCells %i\n",fNCellsInTower, fNCellsInSupMod, fNCells);
if(name.Contains("MAY05")){
printf(" fFrontSteelStrip %6.4f cm (thickness of front steel strip)\n",
fFrontSteelStrip);
printf(" fEmptySpace %7.4f cm\n", fEmptySpace);
} else if(name.Contains("TRD1") && name.Contains("FINAL")){
printf(" fPhiGapForSM %7.4f cm \n", fPhiGapForSM);
+ if(name.Contains("110DEG"))printf(" Last two modules have size 10 degree in phi (180<phi<190)\n");
}
}
printf("Granularity: %d in eta and %d in phi\n", GetNZ(), GetNPhi()) ;
// == Shish-kebab cases ==
//
Int_t AliEMCALGeometry::GetAbsCellId(const int nSupMod, const int nTower, const int nIphi, const int nIeta)
-{ // 27-aug-04; corr. 21-sep-04
- static Int_t id; // have to change from 1 to fNCells
- id = fNCellsInSupMod*(nSupMod-1);
+{ // 27-aug-04;
+ // corr. 21-sep-04;
+ // 13-oct-05; 110 degree case
+ // 1 <= nSupMod <= fNumberOfSuperModules
+ // 1 <= nTower <= fNPHI * fNZ ( fNPHI * fNZ/2 for fKey110DEG=1)
+ // 1 <= nIphi <= fNPHIdiv
+ // 1 <= nIeta <= fNETAdiv
+ // 1 <= absid <= fNCells
+ static Int_t id=0; // have to change from 1 to fNCells
+ if(fKey110DEG == 1 && nSupMod > 10) { // 110 degree case; last two supermodules
+ id = fNCellsInSupMod*10 + (fNCellsInSupMod/2)*(nSupMod-11);
+ } else {
+ id = fNCellsInSupMod*(nSupMod-1);
+ }
id += fNCellsInTower *(nTower-1);
id += fNPHIdiv *(nIphi-1);
id += nIeta;
// printf(" nTower %6i\n", nTower);
// printf(" nIphi %6i\n", nIphi);
// printf(" nIeta %6i\n", nIeta);
- id = -1;
+ id = -TMath::Abs(id);
}
return id;
}
Bool_t AliEMCALGeometry::GetCellIndex(const Int_t absId,Int_t &nSupMod,Int_t &nTower,Int_t &nIphi,Int_t &nIeta)
{ // 21-sep-04
- static Int_t tmp=0;
+ // 19-oct-05;
+ static Int_t tmp=0, sm10=0;
if(absId<=0 || absId>fNCells) {
// Info("GetCellIndex"," wrong abs Id %i !! \n", absId);
return kFALSE;
}
- nSupMod = (absId-1) / fNCellsInSupMod + 1;
- tmp = (absId-1) % fNCellsInSupMod;
+ sm10 = fNCellsInSupMod*10;
+ if(fKey110DEG == 1 && absId > sm10) { // 110 degree case; last two supermodules
+ nSupMod = (absId-1-sm10) / (fNCellsInSupMod/2) + 11;
+ tmp = (absId-1-sm10) % (fNCellsInSupMod/2);
+ } else {
+ nSupMod = (absId-1) / fNCellsInSupMod + 1;
+ tmp = (absId-1) % fNCellsInSupMod;
+ }
nTower = tmp / fNCellsInTower + 1;
tmp = tmp % fNCellsInTower;
-
- nIphi = tmp / fNPHIdiv + 1;
- nIeta = tmp % fNPHIdiv + 1;
+ nIphi = tmp / fNPHIdiv + 1;
+ nIeta = tmp % fNPHIdiv + 1;
return kTRUE;
}
-void AliEMCALGeometry::GetCellPhiEtaIndexInSModule(const int nTower, const int nIphi, const int nIeta,
+void AliEMCALGeometry::GetTowerPhiEtaIndexInSModule(const Int_t nSupMod, const int nTower, int &iphit, int &ietat)
+{ // added nSupMod; have to check - 19-oct-05 !
+ static Int_t nphi;
+
+ if(fKey110DEG == 1 && nSupMod>=11) nphi = fNPhi/2;
+ else nphi = fNPhi;
+
+ ietat = (nTower-1)/nphi + 1; // have to change from 1 to fNZ
+
+ iphit = (nTower-1)%nphi + 1; // have to change from 1 to fNPhi
+}
+
+void AliEMCALGeometry::GetCellPhiEtaIndexInSModule(const Int_t nSupMod, const int nTower, const int nIphi, const int nIeta,
int &iphi, int &ieta)
-{ // don't check validity of nTower, nIphi and nIeta index
- // have to change - 1-nov-04 ??
- static Int_t iphit, ietat;
+{ // added nSupMod; have to check - 19-oct-05 !
+ static Int_t iphit, ietat, nphi;
+
+ if(fKey110DEG == 1 && nSupMod>=11) nphi = fNPhi/2;
+ else nphi = fNPhi;
- ietat = (nTower-1)/fNPhi;
- ieta = ietat*fNETAdiv + nIeta; // change from 1 to fNZ*fNETAdiv
+ ietat = (nTower-1)/nphi;
+ ieta = ietat*fNETAdiv + nIeta; // have to change from 1 to fNZ*fNETAdiv
- iphit = (nTower-1)%fNPhi;
- iphi = iphit*fNPHIdiv + nIphi; // change from 1 to fNPhi*fNPHIdiv
+ iphit = (nTower-1)%nphi;
+ iphi = iphit*fNPHIdiv + nIphi; // have to change from 1 to fNPhi*fNPHIdiv
}
// Dabs id <-> indexes; Shish-kebab case
Int_t GetAbsCellId(const Int_t nSupMod, const Int_t nTower, const Int_t nIphi, const Int_t nIeta);
Bool_t GetCellIndex(const Int_t absId, Int_t &nSupMod, Int_t &nTower, Int_t &nIphi, Int_t &nIeta);
- void GetCellPhiEtaIndexInSModule(const Int_t nTower, const Int_t nIphi, const Int_t nIeta, Int_t &iphi, Int_t &ieta);
+ void GetTowerPhiEtaIndexInSModule(const Int_t nSupMod, const Int_t nTower, Int_t &iphit, Int_t &ietat);
+ void GetCellPhiEtaIndexInSModule(const Int_t nSupMod, const Int_t nTower, const Int_t nIphi, const Int_t nIeta,
+ Int_t &iphi, Int_t &ieta);
Bool_t CheckAbsCellId(Int_t ind); // replace the IsInECA
// ---
Float_t AngleFromEta(Float_t eta){ // returns theta in radians for a given pseudorapidity
Float_t fEtaTileSize; //
Float_t fLongModuleSize; //
Int_t fNPhiSuperModule; // 6 - number supermodule in phi direction
- Int_t fNPHIdiv; // number phi dvizion
- Int_t fNETAdiv; // number eta divizion
+ Int_t fNPHIdiv; // number phi divizion of module
+ Int_t fNETAdiv; // number eta divizion of module
//
Int_t fNCells; // number of cells in calo
Int_t fNCellsInSupMod; // number cell in super module
Float_t fTrd1Angle; // angle in x-z plane (in degree)
Float_t f2Trd1Dx2; // 2*dx2 for TRD1
Float_t fPhiGapForSM; // Gap betweeen supermodules in phi direction
+ Int_t fKey110DEG; // for calculation abs cell id; 19-oct-05
// TRD2 options - 27-jan-07
Float_t fTrd2AngleY; // angle in y-z plane (in degree)
Float_t f2Trd2Dy2; // 2*dy2 for TRD2
Float_t fEmptySpace; // 2mm om fred drawing
- // Sumper module as TUBS
+ // Super module as TUBS
Float_t fTubsR; // radius of tubs
Float_t fTubsTurnAngle; // turn angle of tubs in degree
Int_t nSupMod, nTower, nIphi, nIeta, iphi, ieta;
for(Int_t absId=1; absId<=fGeometry->GetNCells(); absId++){
if(fGeometry->GetCellIndex(absId, nSupMod,nTower,nIphi,nIeta)){
- fGeometry->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ fGeometry->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
TVector3 *v = new TVector3;
v->SetX(fSMPositionEta[ieta-1].Y());
v->SetZ(fSMPositionEta[ieta-1].X());
}
}
-TVector3& AliEMCALGeometryOfflineTrd1::PosInSuperModule(const Int_t nTower,const Int_t nIphi,const Int_t nIeta)
+TVector3& AliEMCALGeometryOfflineTrd1::PosInSuperModule(const int nSupMod, const Int_t nTower,const Int_t nIphi,const Int_t nIeta)
{ // 10-nov-04
static Int_t iphi, ieta;
static TVector3 v;
- fGeometry->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ fGeometry->GetCellPhiEtaIndexInSModule(nSupMod, nTower,nIphi,nIeta, iphi,ieta);
// x-radius; y-phi; eta-z;
v.SetXYZ(fSMPositionEta[ieta].Y(), fSMPositionPhi[iphi], fSMPositionEta[ieta].X());
leta = fSMPositionEta[ie].X();
}
-void AliEMCALGeometryOfflineTrd1::PositionInSuperModule(const Int_t nTower, const Int_t nIphi, const Int_t nIeta,
+void AliEMCALGeometryOfflineTrd1::PositionInSuperModule(const int nSupMod, const Int_t nTower, const Int_t nIphi, const Int_t nIeta,
double &lphi, double &leta)
{
static Int_t iphi,ieta;
- fGeometry->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta,iphi,ieta);
+ fGeometry->GetCellPhiEtaIndexInSModule(nSupMod, nTower,nIphi,nIeta,iphi,ieta);
PositionInSuperModule(iphi,ieta, lphi,leta);
}
{
Int_t nSupMod, nTower, nIphi, nIeta, iphi, ieta;
if(fGeometry->GetCellIndex(absId, nSupMod,nTower,nIphi,nIeta)){
- fGeometry->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ fGeometry->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
TVector3 *v = CellPosition(absId);
printf("(%5i) X %8.3f Y %8.3f Z %8.3f | #sup.Mod %2i #tower %3i nIphi %1i nIeta %1i | iphi %2i ieta %2i\n",
absId, v->X(),v->Y(),v->Z(), nSupMod,nTower,nIphi,nIeta, iphi,ieta);
virtual ~AliEMCALGeometryOfflineTrd1() { /* nothing */ };
static AliEMCALGeometryOfflineTrd1* GetInstance();
// positon in SuperModule
- TVector3& PosInSuperModule(const int nTower, const int nIphi, const int nIeta);
+ TVector3& PosInSuperModule(const int nSupMod, const int nTower, const int nIphi, const int nIeta);
private:
AliEMCALGeometryOfflineTrd1();
public:
// One Super Module
void PositionInSuperModule(const int iphi, const int ieta, double &lphi, double &leta);
- void PositionInSuperModule(const int nTower, const int nIphi, const int nIeta, double &lphi, double &leta);
+ void PositionInSuperModule(const int nSupMod, const int nTower, const int nIphi, const int nIeta, double &lphi, double &leta);
// Position towers(cells)
TVector3* CellPosition(int absId); // from 0 to fGeometry->GetNCells()
// Global System
- TRotation* Rotation(Int_t module); // module chabge from 1 to 12;
+ TRotation* Rotation(Int_t module); // module change from 1 to 12;
// service methods
void PrintSuperModule(); // *MENU*
int nSupMod=0, nTower=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
geom->GetCellIndex(digit1->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
relid1[0]=ieta;
relid1[1]=iphi;
// geom->AbsToRelNumbering(digit1->GetId(), relid1) ;
int nSupMod1=0, nTower1=0, nIphi1=0, nIeta1=0;
int iphi1=0, ieta1=0;
geom->GetCellIndex(digit2->GetId(), nSupMod1,nTower1,nIphi1,nIeta1);
- geom->GetCellPhiEtaIndexInSModule(nTower1,nIphi1,nIeta1, iphi1,ieta1);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod1,nTower1,nIphi1,nIeta1, iphi1,ieta1);
relid2[0]=ieta1;
relid2[1]=iphi1;
// geom->AbsToRelNumbering(digit2->GetId(), relid2) ;
int nSupMod=0, nTower=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
geom->GetCellIndex(digit->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
etai=(Float_t)ieta;
phii=(Float_t)iphi;
// printf("%f,%d,%d \n", fAmp, ieta, iphi) ;
int nSupMod=0, nTower=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
geom->GetCellIndex(digit->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod, nTower,nIphi,nIeta, iphi,ieta); //19-oct-05
etai=(Float_t)ieta;
phii=(Float_t)iphi;
//Sub geom->EtaPhiFromIndex(digit->GetId(), etai, phii);
int nSupMod=0, nTower=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
geom->GetCellIndex(digit->GetId(), nSupMod,nTower,nIphi,nIeta);
- geom->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ geom->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
etai=(Float_t)ieta;
phii=(Float_t)iphi;
} else {
// This class places a Geometry of the EMCAL in the ALICE Detector as defined in AliEMCALGeometry.cxx
//*-- Author: Yves Schutz (SUBATECH)
//*-- and : Sahal Yacoob (LBL / UCT)
+// : Aleksei Pavlinov (WSU) SHASHLYK
// This Version of AliEMCALv0 reduces the number of volumes placed in XEN1 (the envelope) to less than five hundred
// The Envelope is Placed in Alice, And the Aluminium layer. Mini envelopes (XU) are then placed in XEN1.
// idAL = 1602;
Double_t par[10], xpos=0., ypos=0., zpos=0.;
- CreateSmod("XEN1"); // 18-may-05
+ CreateSmod("XEN1"); // 18-may-05
- CreateEmod("SMOD","EMOD"); // 18-may-95
+ CreateEmod("SMOD","EMOD"); // 18-may-05
+
+ if(gn.Contains("110DEG")) CreateEmod("SM10","EMOD"); // 12-oct-05
// Sensitive SC (2x2 tiles)
double parSCM0[5], *dummy = 0, parTRAP[11];
}
void AliEMCALv0::CreateSmod(const char* mother)
-{ // 18-may-05; mother="XEN1"; child="SMOD" or "SMON" and "SMOP"("TRD2" case)
+{ // 18-may-05; mother="XEN1";
+ // child="SMOD" from first to 10th, "SM10" (11th and 12th) (TRD1 case)
+ // child="SMON" and "SMOP"("TRD2" case)
AliEMCALGeometry * g = GetGeometry();
TString gn(g->GetName()); gn.ToUpper();
Double_t par[1], parTubs[5], xpos=0., ypos=0., zpos=0., rpos=0., dphi=0., phi=0.0, phiRad=0.;
+ Double_t par1C = 0.;
// ===== define Super Module from air - 14x30 module ==== ;
sampleWidth = double(g->GetECPbRadThick()+g->GetECScintThick());
- printf("\n ## Super Module | sampleWidth %5.3f ## \n", sampleWidth);
+ printf("\n ## Super Module | sampleWidth %5.3f ## %s \n", sampleWidth, gn.Data());
par[0] = g->GetShellThickness()/2.;
par[1] = g->GetPhiModuleSize()*g->GetNPhi()/2.;
par[2] = g->GetEtaModuleSize()*15.;
int nphism = g->GetNumberOfSuperModules()/2; // 20-may-05
if(nphism>0) {
dphi = (g->GetArm1PhiMax() - g->GetArm1PhiMin())/nphism;
+ // if(gn.Contains("110DEG")) dphi = (g->GetArm1PhiMax() - g->GetArm1PhiMin())/(nphism-1);
rpos = (g->GetEnvelop(0) + g->GetEnvelop(1))/2.;
- printf(" rpos %8.2f \n", rpos);
+ printf(" rpos %8.2f : dphi %6.1f degree \n", rpos, dphi);
}
if (gn.Contains("TRD2")) { // tubs - 27-jan-05
idtmed[idAIR], par[0],par[1],par[2]);
smodPar0 = par[0];
smodPar2 = par[2];
+ if(gn.Contains("110DEG")) { // 12-oct-05
+ par1C = par[1];
+ par[1] /= 2.;
+ gMC->Gsvolu("SM10", "BOX", idtmed[idAIR], par, 3);
+ printf(" Super module with name \"SM10\" was created too par[1] = %f\n", par[1]);
+ par[1] = par1C;
+ }
// Steel plate
if(g->GetSteelFrontThickness() > 0.0) { // 28-mar-05
par[0] = g->GetSteelFrontThickness()/2.;
}
}
- int nr=0, i0=0;
+ int nr=0, nrsmod=0, i0=0;
if(gn.Contains("TEST")) {nphism = 1;} // just only 2 super modules;
// Turn whole super module
printf("SMON %2i | %2i idrotm %3i phi %6.1f(%5.3f) xpos %7.2f ypos %7.2f zpos %7.2f \n",
i, nr, idrotm, phic, phicRad, xpos, ypos, -zpos);
}
- } else if(gn.Contains("WSUC")) {
- xpos = ypos = zpos = 0.0;
- idrotm = 0;
- gMC->Gspos("SMOD", 1, mother, xpos, ypos, zpos, idrotm, "ONLY") ;
- printf(" idrotm %3i phi %6.1f(%5.3f) xpos %7.2f ypos %7.2f zpos %7.2f \n",
- idrotm, phi, phiRad, xpos, ypos, zpos);
- nr++;
- } else {
+ } else if(gn.Contains("WSUC")) {
+ xpos = ypos = zpos = 0.0;
+ idrotm = 0;
+ gMC->Gspos("SMOD", 1, mother, xpos, ypos, zpos, idrotm, "ONLY") ;
+ printf(" idrotm %3i phi %6.1f(%5.3f) xpos %7.2f ypos %7.2f zpos %7.2f \n",
+ idrotm, phi, phiRad, xpos, ypos, zpos);
+ nr++;
+ } else {
+ TString smName("SMOD"); // 12-oct-05
+ if(i==5 && gn.Contains("110DEG")) {
+ smName = "SM10";
+ nrsmod = nr;
+ nr = 0;
+ }
phi = g->GetArm1PhiMin() + dphi*(2*i+1)/2.; // phi= 70, 90, 110, 130, 150, 170
phiRad = phi*TMath::Pi()/180.;
xpos = rpos * TMath::Cos(phiRad);
ypos = rpos * TMath::Sin(phiRad);
zpos = smodPar2; // 21-sep-04
-
+ if(i==5 && gn.Contains("110DEG")) {
+ xpos += (par1C/2. * TMath::Sin(phiRad));
+ ypos -= (par1C/2. * TMath::Cos(phiRad));
+ }
+
// 1th module in z-direction;
- gMC->Gspos("SMOD", ++nr, mother, xpos, ypos, zpos, idrotm, "ONLY") ;
- printf(" %2i idrotm %3i phi %6.1f(%5.3f) xpos %7.2f ypos %7.2f zpos %7.2f \n",
- nr, idrotm, phi, phiRad, xpos, ypos, zpos);
+ gMC->Gspos(smName.Data(), ++nr, mother, xpos, ypos, zpos, idrotm, "ONLY") ;
+ printf(" %s : %2i idrotm %3i phi %6.1f(%5.3f) xpos %7.2f ypos %7.2f zpos %7.2f : i %i \n",
+ smName.Data(), nr, idrotm, phi, phiRad, xpos, ypos, zpos, i);
// 2th module in z-direction;
if(gn.Contains("TWIST") || gn.Contains("TRD")) {
// turn arround X axis; 0<phi<360
if(phiy>=360.) phiy -= 360.;
AliMatrix(idrotm, 90.0, phi, 90.0, phiy, 180.0, 0.0);
- gMC->Gspos("SMOD", ++nr, mother, xpos, ypos, -zpos, idrotm, "ONLY");
- printf(" %2i idrotm %3i phiy %6.1f xpos %7.2f ypos %7.2f zpos %7.2f \n",
- nr, idrotm, phiy, xpos, ypos, -zpos);
+ gMC->Gspos(smName.Data(), ++nr, mother, xpos, ypos, -zpos, idrotm, "ONLY");
+ printf(" %s : %2i idrotm %3i phiy %6.1f xpos %7.2f ypos %7.2f zpos %7.2f \n",
+ smName.Data(), nr, idrotm, phiy, xpos, ypos, -zpos);
} else {
gMC->Gspos("SMOD", ++nr, mother, xpos, ypos, -zpos, idrotm, "ONLY");
}
}
}
- printf(" Number of Super Modules %i \n", nr);
+ printf(" Number of Super Modules %i \n", nr+nrsmod);
}
void AliEMCALv0::CreateEmod(const char* mother, const char* child)
gMC->Gsvolu(child, "BOX", idtmed[idSTEEL], par, 3);
} else if (gn.Contains("TRD1")){ // TRD1 system coordinate iz differnet
- parEMOD[0] = g->GetEtaModuleSize()/2.; // dx1
- parEMOD[1] = g->Get2Trd1Dx2()/2.; // dx2
- parEMOD[2] = g->GetPhiModuleSize()/2.;; // dy
- parEMOD[3] = g->GetLongModuleSize()/2.; // dz
- gMC->Gsvolu(child, "TRD1", idtmed[idSTEEL], parEMOD, 4);
- if(gn.Contains("WSUC") || gn.Contains("MAY05")){
- parSCPA[0] = g->GetEtaModuleSize()/2. + tanTrd1*g->GetFrontSteelStrip(); // dx1
- parSCPA[1] = parSCPA[0] + tanTrd1*g->GetPassiveScintThick(); // dx2
- parSCPA[2] = g->GetPhiModuleSize()/2.; // dy
- parSCPA[3] = g->GetPassiveScintThick()/2.; // dz
- gMC->Gsvolu("SCPA", "TRD1", idtmed[idSC], parSCPA, 4);
- zposSCPA = -parEMOD[3] + g->GetFrontSteelStrip() + g->GetPassiveScintThick()/2.;
- gMC->Gspos ("SCPA", ++nr, child, 0.0, 0.0, zposSCPA, 0, "ONLY");
+ if(strcmp(mother,"SMOD")==0) {
+ parEMOD[0] = g->GetEtaModuleSize()/2.; // dx1
+ parEMOD[1] = g->Get2Trd1Dx2()/2.; // dx2
+ parEMOD[2] = g->GetPhiModuleSize()/2.;; // dy
+ parEMOD[3] = g->GetLongModuleSize()/2.; // dz
+ gMC->Gsvolu(child, "TRD1", idtmed[idSTEEL], parEMOD, 4);
+ if(gn.Contains("WSUC") || gn.Contains("MAY05")){
+ parSCPA[0] = g->GetEtaModuleSize()/2. + tanTrd1*g->GetFrontSteelStrip(); // dx1
+ parSCPA[1] = parSCPA[0] + tanTrd1*g->GetPassiveScintThick(); // dx2
+ parSCPA[2] = g->GetPhiModuleSize()/2.; // dy
+ parSCPA[3] = g->GetPassiveScintThick()/2.; // dz
+ gMC->Gsvolu("SCPA", "TRD1", idtmed[idSC], parSCPA, 4);
+ zposSCPA = -parEMOD[3] + g->GetFrontSteelStrip() + g->GetPassiveScintThick()/2.;
+ gMC->Gspos ("SCPA", ++nr, child, 0.0, 0.0, zposSCPA, 0, "ONLY");
+ }
}
} else if (gn.Contains("TRD2")){ // TRD2 as for TRD1 - 27-jan-05
parEMOD[0] = g->GetEtaModuleSize()/2.; // dx1
}
} else if(gn.Contains("TRD")) { // 30-sep-04; 27-jan-05 - as for TRD1 as for TRD2
// X->Z(0, 0); Y->Y(90, 90); Z->X(90, 0)
- fShishKebabModules = new TList;
AliEMCALShishKebabTrd1Module *mod=0, *mTmp; // current module
- for(int iz=0; iz<g->GetNZ(); iz++) { // 27-may-05; g->GetNZ() -> 26
- if(iz==0) {
- mod = new AliEMCALShishKebabTrd1Module();
- } else {
- mTmp = new AliEMCALShishKebabTrd1Module(*mod);
- mod = mTmp;
- }
+ if(fShishKebabModules == 0) {
+ fShishKebabModules = new TList;
+ for(int iz=0; iz<g->GetNZ(); iz++) { // 27-may-05; g->GetNZ() -> 26
+ if(iz==0) {
+ mod = new AliEMCALShishKebabTrd1Module();
+ } else {
+ mTmp = new AliEMCALShishKebabTrd1Module(*mod);
+ mod = mTmp;
+ }
fShishKebabModules->Add(mod);
+ }
}
for(int iz=0; iz<g->GetNZ(); iz++) {
Double_t angle=90., phiOK=0;
- if(gn.Contains("TRD1")) { //27-jan-05 - as for TRD1 as for TRD2
+ if(gn.Contains("TRD1")) {
mod = (AliEMCALShishKebabTrd1Module*)fShishKebabModules->At(iz);
angle = mod->GetThetaInDegree();
if(!gn.Contains("WSUC")) { // ALICE
iz+1, angle, phiOK, angle-phiOK, mod->GetEtaOfCenterOfModule());
xpos = mod->GetPosXfromR() + g->GetSteelFrontThickness() - smodPar0;
zpos = mod->GetPosZ() - smodPar2;
- for(int iy=0; iy<g->GetNPhi(); iy++) { // flat in phi
- ypos = g->GetPhiModuleSize()*(2*iy+1 - g->GetNPhi())/2.;
+
+ int iyMax = g->GetNPhi();
+ if(strcmp(mother,"SMOD") && gn.Contains("110DEG")) {
+ iyMax /= 2;
+ }
+ for(int iy=0; iy<iyMax; iy++) { // flat in phi
+ ypos = g->GetPhiModuleSize()*(2*iy+1 - iyMax)/2.;
gMC->Gspos(child, ++nr, mother, xpos, ypos, zpos, idrotm, "ONLY") ;
//printf(" %2i xpos %7.2f ypos %7.2f zpos %7.2f idrotm %i\n", nr, xpos, ypos, zpos, idrotm);
}
//*--
//*-- Author: Yves Schutz (SUBATECH)
//*-- and : Sahal Yacoob (LBL / UCT)
+// : Aleksei Pavlinov (WSU) SHASHLYK
//#include <assert.h>
// --- ROOT system ---
/* $Id$ */
//_________________________________________________________________________
-//*-- Implementation version v2 of EMCAL Manager class
+//*-- Implementation version v2 of EMCAL Manager class; SHASHLYK version
//*-- An object of this class does not produce digits
//*-- It is the one to use if you do want to produce outputs in TREEH
//*--
-//*-- Author: Sahal Yacoob (LBL /UCT)
-//*-- : Jennifer Klay (LBL)
+//*-- Author : Aleksei Pavlinov (WSU)
+
// This Class not stores information on all particles prior to EMCAL entry - in order to facilitate analysis.
// This is done by setting fIShunt =2, and flagging all parents of particles entering the EMCAL.
-// 15/02/2002 .... Yves Schutz
-// 1. fSamplingFraction and fLayerToPreshowerRatio have been removed
-// 2. Timing signal is collected and added to hit
-
// --- ROOT system ---
#include "TParticle.h"
#include "TVirtualMC.h"
gMC->CurrentVolOffID(3, moduleNumber);
gMC->CurrentVolOffID(1, yNumber);
gMC->CurrentVolOffID(0, xNumber); // really x number now
+ if(strcmp(gMC->CurrentVolOffName(4),"SM10")==0) supModuleNumber += 10; // 13-oct-05
} else {
gMC->CurrentVolOffID(5, supModuleNumber);
gMC->CurrentVolOffID(4, moduleNumber);
gMC->CurrentVolOffID(1, yNumber);
- gMC->CurrentVolOffID(0, xNumber); // really x number now
- if (strcmp(gMC->CurrentVolOffName(5),"SMOP")==0) supModuleNumber = nSMOP[supModuleNumber-1];
+ gMC->CurrentVolOffID(0, xNumber);
+ if (strcmp(gMC->CurrentVolOffName(5),"SMOP")==0) supModuleNumber = nSMOP[supModuleNumber-1];
else if(strcmp(gMC->CurrentVolOffName(5),"SMON")==0) supModuleNumber = nSMON[supModuleNumber-1];
else assert(0); // something wrong
}
void AliEMCALv2::DrawCalorimeterCut(const char *name, int axis, double dcut)
{ // Size of tower is 5.6x5.6x24.8 (25.0); cut on Z axiz
+ TString g(fGeometry->GetName());
+ g.ToUpper();
gMC->Gsatt("*", "seen", 0);
int fill = 1;
TString sn(name);
if(sn.Contains("SCM")) colo=5;
SetVolumeAttributes(name, 1, colo, fill);
+ if(g.Contains("110DEG") && sn=="SMOD") SetVolumeAttributes("SM10", 1, colo, fill);
TString st(GetTitle());
st += ", zcut, ";
// printf(" de %f abs id %i smod %i tower %i | cell iphi %i : ieta %i\n",
// de, absId, nSupMod, nTower, nIphi, nIeta);
if(nSupMod==3) {
- fGeometry->GetCellPhiEtaIndexInSModule(nTower,nIphi,nIeta, iphi,ieta);
+ fGeometry->GetCellPhiEtaIndexInSModule(nSupMod,nTower,nIphi,nIeta, iphi,ieta);
// printf(" iphi %i : ieta %i\n", iphi,ieta);
h2->Fill(double(ieta),double(iphi), de);
}