Macro to calculate the needed HV values as a function of the required MIP signal.
[u/mrichter/AliRoot.git] / VZERO / AliVZEROv7.cxx
index 0cf8221..d1c637f 100644 (file)
@@ -48,6 +48,7 @@
 #include "TGeoTube.h"
 #include "TGeoArb8.h"
 #include "TGeoCompositeShape.h"
+#include <TTree.h>
 
 // --- AliRoot header files ---
 #include "AliRun.h"
@@ -76,7 +77,7 @@ AliVZEROv7:: AliVZEROv7():AliVZERO(),
    fV0CLidThickness(0.30),
    fV0CCellThickness(2.00),
    fV0CBoxThickness(4.70),
-   fV0COffsetFibers(1.0),
+   fV0COffsetFibers(1.125),
    fV0CLightYield(93.75),
    fV0CLightAttenuation(0.05),
    fV0CnMeters(15.0),
@@ -138,7 +139,7 @@ AliVZEROv7::AliVZEROv7(const char *name, const char *title):AliVZERO(name,title)
    fV0CLidThickness(0.30),
    fV0CCellThickness(2.00),
    fV0CBoxThickness(4.70),
-   fV0COffsetFibers(1.0),
+   fV0COffsetFibers(1.125),
    fV0CLightYield(93.75),
    fV0CLightAttenuation(0.05),
    fV0CnMeters(15.0),
@@ -272,13 +273,45 @@ void AliVZEROv7::CreateGeometry()
     partube[0] =   fV0CRMin;
     partube[1] =   fV0CRBox;
     partube[2] =   fV0CLidThickness/2.0;
-    TGeoTube   *sV0CA = new TGeoTube("V0CA", partube[0], partube[1], partube[2]);
-    TGeoVolume *v0CA  = new TGeoVolume("V0CA",sV0CA,medV0CCar);
-    TGeoTranslation *tr2 = new TGeoTranslation(0.,0., fV0CBoxThickness/2.0-partube[2]);
-    TGeoTranslation *tr3 = new TGeoTranslation(0.,0.,-fV0CBoxThickness/2.0+partube[2]);
-    v0RI->AddNode(v0CA,1,tr2);
-    v0RI->AddNode(v0CA,2,tr3);
-    v0CA->SetLineColor(kYellow);
+    //    TGeoTube   *sV0CA = new TGeoTube("V0CA", partube[0], partube[1], partube[2]);
+    //    TGeoVolume *v0CA  = new TGeoVolume("V0CA",sV0CA,medV0CCar);
+    //    TGeoTranslation *tr2 = new TGeoTranslation(0.,0., fV0CBoxThickness/2.0-partube[2]);
+    //    TGeoTranslation *tr3 = new TGeoTranslation(0.,0.,-fV0CBoxThickness/2.0+partube[2]);
+    //    v0RI->AddNode(v0CA,1,tr2);
+    //    v0RI->AddNode(v0CA,2,tr3);
+    //    v0CA->SetLineColor(kYellow);
+
+    Float_t rInt1 = 11.5, rOut1 = 20.0, rInt2 = 9.0;
+
+    TGeoTube   *sV0CA4 = new TGeoTube("V0CA4", partube[0], rInt2, partube[2] - 0.1);
+    TGeoVolume *v0CA4  = new TGeoVolume("V0CA4",sV0CA4,medV0CCar);
+    TGeoTranslation *tr21 = new TGeoTranslation(0.,0., fV0CBoxThickness/2.0-partube[2] + 0.1);
+    v0RI->AddNode(v0CA4,1,tr21);
+    v0CA4->SetLineColor(kYellow);
+
+    TGeoTube   *sV0CA5 = new TGeoTube("V0CA5", rInt2, partube[1], partube[2]);
+    TGeoVolume *v0CA5  = new TGeoVolume("V0CA5",sV0CA5,medV0CCar);
+    TGeoTranslation *tr22 = new TGeoTranslation(0.,0., fV0CBoxThickness/2.0-partube[2]);
+    v0RI->AddNode(v0CA5,1,tr22);
+    v0CA5->SetLineColor(kYellow);
+
+    TGeoTube   *sV0CA1 = new TGeoTube("V0CA1",partube[0], rInt1, partube[2]);
+    TGeoVolume *v0CA1  = new TGeoVolume("V0CA1",sV0CA1,medV0CCar);
+    TGeoTranslation *tr31 = new TGeoTranslation(0.,0.,-fV0CBoxThickness/2.0+partube[2]);
+    v0RI->AddNode(v0CA1,1,tr31);
+    v0CA1->SetLineColor(kYellow);
+
+    TGeoTube   *sV0CA2 = new TGeoTube("V0CA2", rInt1, rOut1, partube[2] - 0.1);
+    TGeoVolume *v0CA2  = new TGeoVolume("V0CA2",sV0CA2,medV0CCar);
+    TGeoTranslation *tr32 = new TGeoTranslation(0.,0.,-fV0CBoxThickness/2.0+partube[2] - 0.1);
+    v0RI->AddNode(v0CA2,1,tr32);
+    v0CA2->SetLineColor(kYellow);
+
+    TGeoTube   *sV0CA3 = new TGeoTube("V0CA3", rOut1, partube[1], partube[2]);
+    TGeoVolume *v0CA3  = new TGeoVolume("V0CA3",sV0CA3,medV0CCar);
+    TGeoTranslation *tr33 = new TGeoTranslation(0.,0.,-fV0CBoxThickness/2.0+partube[2]);
+    v0RI->AddNode(v0CA3,1,tr33);
+    v0CA3->SetLineColor(kYellow);
 
     // Creation of aluminum rings 3.0 mm thick to maintain the v0RI pieces : 
     partube[0] =   fV0CRMin - 0.3;
@@ -312,7 +345,7 @@ void AliVZEROv7::CreateGeometry()
     TGeoTubeSeg *sV0R1 = new TGeoTubeSeg("V0R1", partubs[0], partubs[1], partubs[2],
                                         partubs[3], partubs[4]);
     TGeoVolume  *v0R1  = new TGeoVolume("V0R1",sV0R1,medV0CSci);                                      
-    TGeoTranslation *tr4 = new TGeoTranslation(0.,0.,-offset);
+    TGeoTranslation *tr4 = new TGeoTranslation(0.,0., offset);
     v0R0->AddNode(v0R1,1,tr4);
     v0R1->SetLineColor(kColorVZERO);
 
@@ -324,7 +357,7 @@ void AliVZEROv7::CreateGeometry()
     TGeoTubeSeg *sV0R2 = new TGeoTubeSeg("V0R2", partubs[0], partubs[1], partubs[2],
                                         partubs[3], partubs[4]);
     TGeoVolume  *v0R2  = new TGeoVolume("V0R2",sV0R2,medV0CSci);
-    TGeoTranslation *tr5 = new TGeoTranslation(0.0,0.2,-offset + fV0COffsetFibers);
+    TGeoTranslation *tr5 = new TGeoTranslation(0.0,0.2, offset - fV0COffsetFibers);
     v0R0->AddNode(v0R2,1,tr5);
     v0R2->SetLineColor(kColorVZERO);
 
@@ -338,7 +371,7 @@ void AliVZEROv7::CreateGeometry()
     TGeoTubeSeg *sV0R3 = new TGeoTubeSeg("V0R3", partubs[0], partubs[1], partubs[2],
                                         partubs[3], partubs[4]);
     TGeoVolume  *v0R3  = new TGeoVolume("V0R3",sV0R3,medV0CSci);
-    TGeoTranslation *tr6 = new TGeoTranslation(0.,0.2,-offset + 2.0*fV0COffsetFibers);
+    TGeoTranslation *tr6 = new TGeoTranslation(0.,0.2, offset - 2.0*fV0COffsetFibers);
     v0R0->AddNode(v0R3,1,tr6);
     v0R3->SetLineColor(kColorVZERO);
     partubs[3]     = 112.5-22.5;
@@ -359,7 +392,7 @@ void AliVZEROv7::CreateGeometry()
     TGeoTubeSeg *sV0R5 = new TGeoTubeSeg("V0R5", partubs[0], partubs[1], partubs[2],
                                         partubs[3], partubs[4]);
     TGeoVolume  *v0R5  = new TGeoVolume("V0R5",sV0R5,medV0CSci);
-    TGeoTranslation *tr7 = new TGeoTranslation(0.,0.0,-offset + 2.0*fV0COffsetFibers);                                       
+    TGeoTranslation *tr7 = new TGeoTranslation(0.,0.0, offset - 2.0*fV0COffsetFibers + 0.25);                                        
     v0R0->AddNode(v0R5,1,tr7);
     v0R5->SetLineColor(kColorVZERO);
     partubs[3]     = 112.5-22.5+x;
@@ -449,13 +482,13 @@ void AliVZEROv7::CreateGeometry()
     TGeoRotation *rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0);
-    double FEEshiftR2Sec1 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
-    TGeoCombiTrans *posFicFEEBSec1 = new TGeoCombiTrans("posFicFEEBSec1", FEEshiftR2Sec1*cos225 + 2.0, 0, 7.5, rot);
+    double aFEEshiftR2Sec1 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
+    TGeoCombiTrans *posFicFEEBSec1 = new TGeoCombiTrans("posFicFEEBSec1", aFEEshiftR2Sec1*cos225 + 2.0, 0, 7.5, rot);
     posFicFEEBSec1->RegisterYourself();
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0+45.0);
-    TGeoCombiTrans *posFicFEEBUpSec1 = new TGeoCombiTrans("posFicFEEBUpSec1", (FEEshiftR2Sec1*cos225 + 2.0 )*cos45, (FEEshiftR2Sec1*cos225 + 2.0 )*sin45, 7.5, rot);
+    TGeoCombiTrans *posFicFEEBUpSec1 = new TGeoCombiTrans("posFicFEEBUpSec1", (aFEEshiftR2Sec1*cos225 + 2.0 )*cos45, (aFEEshiftR2Sec1*cos225 + 2.0 )*sin45, 7.5, rot);
     posFicFEEBUpSec1->RegisterYourself();
     for (int i=0;i<2;i++) {
     v0APts[0+8*i] = fV0AOctH2/2.;             v0APts[1+8*i] = fV0AFEEBHt/2. + 2.5;
@@ -464,11 +497,11 @@ void AliVZEROv7::CreateGeometry()
     v0APts[6+8*i] = -fV0AOctH2/2.;            v0APts[7+8*i] = fV0AFEEBHt/2.+ 2.5;
     }
     new TGeoArb8("sV0AFicOct2Sec1", (fV0ASciWd+2*fV0AOctWd)/2., v0APts);
-    TGeoTranslation *posFicOct2Sec1 = new TGeoTranslation("posFicOct2Sec1",(FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
+    TGeoTranslation *posFicOct2Sec1 = new TGeoTranslation("posFicOct2Sec1",(aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
     posFicOct2Sec1->RegisterYourself();  
     rot = new TGeoRotation("rot");
     rot->RotateZ(-90.0+45.0+90.0);
-    TGeoCombiTrans *posFicOct2UpSec1 = new TGeoCombiTrans("posFicOct2UpSec1",((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
+    TGeoCombiTrans *posFicOct2UpSec1 = new TGeoCombiTrans("posFicOct2UpSec1",((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
     posFicOct2UpSec1->RegisterYourself(); 
 
     /// Frame
@@ -747,8 +780,8 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(+90.0);
-    double FEEshiftR = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
-    v0LE->AddNode(v0AFEE,1, new TGeoCombiTrans( FEEshiftR*cos225+2.0, 0, 7.5, rot));
+    double aFEEshiftR = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
+    v0LE->AddNode(v0AFEE,1, new TGeoCombiTrans( aFEEshiftR*cos225+2.0, 0, 7.5, rot));
     for (int i=0;i<2;i++) {
     v0APts[0+8*i] = fV0AOctH2/2.;             v0APts[1+8*i] = fV0AFEEBHt/2. + 2.5;
     v0APts[2+8*i] = fV0AOctH2/2.;              v0APts[3+8*i] = -fV0AFEEBHt/2.- 2.5;
@@ -758,7 +791,7 @@ void AliVZEROv7::CreateGeometry()
     TGeoArb8 *sV0AFEEOct2 = new TGeoArb8("sV0AFEEOct2", (fV0ASciWd+2*fV0AOctWd)/2., v0APts);
     TGeoVolume *v0AFEEOct2 = new TGeoVolume("V0AFEEOct2",sV0AFEEOct2, medV0ASup);
     v0AFEEOct2->SetLineColor(kV0AColorOct);
-    v0LE->AddNode(v0AFEEOct2,1, new TGeoTranslation((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0));
+    v0LE->AddNode(v0AFEEOct2,1, new TGeoTranslation((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0));
 
 
     /// Definition sector 2
@@ -798,8 +831,8 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0);
-    double FEEshiftR2Sec2 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
-    TGeoCombiTrans *posFicFEEBSec2 = new TGeoCombiTrans("posFicFEEBSec2", FEEshiftR2Sec2*cos225 + 2.0, 0, 7.5, rot);
+    double aFEEshiftR2Sec2 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
+    TGeoCombiTrans *posFicFEEBSec2 = new TGeoCombiTrans("posFicFEEBSec2", aFEEshiftR2Sec2*cos225 + 2.0, 0, 7.5, rot);
     posFicFEEBSec2->RegisterYourself();
     for (int i=0;i<2;i++) {
     v0APts[0+8*i] = fV0AOctH2/2.;             v0APts[1+8*i] = fV0AFEEBHt/2. + 2.5;
@@ -808,7 +841,7 @@ void AliVZEROv7::CreateGeometry()
     v0APts[6+8*i] = -fV0AOctH2/2.;            v0APts[7+8*i] = fV0AFEEBHt/2.+ 2.5;
     }
     new TGeoArb8("sV0AFicOct2Sec2", (fV0ASciWd+2*fV0AOctWd)/2., v0APts);
-    TGeoTranslation *posFicOct2Sec2 = new TGeoTranslation("posFicOct2Sec2",(FEEshiftR2Sec2*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
+    TGeoTranslation *posFicOct2Sec2 = new TGeoTranslation("posFicOct2Sec2",(aFEEshiftR2Sec2*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
     posFicOct2Sec2->RegisterYourself();  
 
     /// Frame
@@ -1051,10 +1084,10 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(+90.0-45.0+90);
-    v0LE->AddNode(v0AFEE2,1, new TGeoCombiTrans( (FEEshiftR2Sec1*cos225 + 2.0)*cos45, (FEEshiftR2Sec1*cos225 + 2.0)*sin45, 7.5, rot));
+    v0LE->AddNode(v0AFEE2,1, new TGeoCombiTrans( (aFEEshiftR2Sec1*cos225 + 2.0)*cos45, (aFEEshiftR2Sec1*cos225 + 2.0)*sin45, 7.5, rot));
     rot = new TGeoRotation("rot");
     rot->RotateZ(-90.0+45.0+90.0);
-    v0LE->AddNode(v0AFEEOct2,2, new TGeoCombiTrans(((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot));
+    v0LE->AddNode(v0AFEEOct2,2, new TGeoCombiTrans(((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot));
 
    
     //Upper supports
@@ -1113,11 +1146,11 @@ void AliVZEROv7::CreateGeometry()
     new TGeoCompositeShape("sV0AChaSec3","sV0ACha12Sec3+sV0ANailsSciHolesSec3");
     new TGeoTubeSeg("sV0AFicR5Sec3", fV0AR4+fV0AFraWd/2., fV0AR4 + fV0AR0, fV0ASciWd/2.+2*preShapeSec3, 0, 45);
     new TGeoBBox("sV0AFicFEEBSec3", fV0AFEEBWd/2., fV0AFEEBHt/2., fV0AFEEBTh/2.);
-    double FEEshiftR2Sec3 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
+    double aFEEshiftR2Sec3 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0+45.0);
-    TGeoCombiTrans *posFicFEEBSec3 = new TGeoCombiTrans("posFicFEEBSec3", (FEEshiftR2Sec3*cos225 + 2.0 )*cos45, (FEEshiftR2Sec3*cos225 + 2.0 )*sin45, 7.5, rot);
+    TGeoCombiTrans *posFicFEEBSec3 = new TGeoCombiTrans("posFicFEEBSec3", (aFEEshiftR2Sec3*cos225 + 2.0 )*cos45, (aFEEshiftR2Sec3*cos225 + 2.0 )*sin45, 7.5, rot);
     posFicFEEBSec3->RegisterYourself();
     for (int i=0;i<2;i++) {
     v0APts[0+8*i] = fV0AOctH2/2.;             v0APts[1+8*i] = fV0AFEEBHt/2. + 2.5;
@@ -1128,7 +1161,7 @@ void AliVZEROv7::CreateGeometry()
     new TGeoArb8("sV0AFicOct2Sec3", (fV0ASciWd+2*fV0AOctWd)/2., v0APts); 
     rot = new TGeoRotation("rot");
     rot->RotateZ(-90.0+45.0+90.0);
-    TGeoCombiTrans *posFicOct2UpSec3 = new TGeoCombiTrans("posFicOct2UpSec3",((FEEshiftR2Sec3*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((FEEshiftR2Sec3*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
+    TGeoCombiTrans *posFicOct2UpSec3 = new TGeoCombiTrans("posFicOct2UpSec3",((aFEEshiftR2Sec3*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((aFEEshiftR2Sec3*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
     posFicOct2UpSec3->RegisterYourself();
 
     /// Frame
@@ -1371,10 +1404,10 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0+45.0-90);
-    v0LE->AddNode(v0AFEE3,1, new TGeoCombiTrans( -(FEEshiftR2Sec1*cos225 + 2.0)*cos45, (FEEshiftR2Sec1*cos225 + 2.0)*sin45, 7.5, rot) );
+    v0LE->AddNode(v0AFEE3,1, new TGeoCombiTrans( -(aFEEshiftR2Sec1*cos225 + 2.0)*cos45, (aFEEshiftR2Sec1*cos225 + 2.0)*sin45, 7.5, rot) );
     rot = new TGeoRotation("rot");
     rot->RotateZ(+90.0-45.0-90.0);
-    v0LE->AddNode(v0AFEEOct2,3, new TGeoCombiTrans(-((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot)); 
+    v0LE->AddNode(v0AFEEOct2,3, new TGeoCombiTrans(-((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot)); 
 
 
     /// Definition sector 4
@@ -1414,13 +1447,13 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0);
-    double FEEshiftR2Sec4 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
-    TGeoCombiTrans *posFicFEEBSec4 = new TGeoCombiTrans("posFicFEEBSec4", FEEshiftR2Sec4*cos225 + 2.0, 0, 7.5, rot);
+    double aFEEshiftR2Sec4 = fV0AR6  +  fV0AOctH2 + fV0APlaAl;
+    TGeoCombiTrans *posFicFEEBSec4 = new TGeoCombiTrans("posFicFEEBSec4", aFEEshiftR2Sec4*cos225 + 2.0, 0, 7.5, rot);
     posFicFEEBSec4->RegisterYourself();
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0+45.0);
-    TGeoCombiTrans *posFicFEEBUpSec4 = new TGeoCombiTrans("posFicFEEBUpSec4", (FEEshiftR2Sec4*cos225 + 2.0 )*cos45, (FEEshiftR2Sec4*cos225 + 2.0 )*sin45, 7.5, rot);
+    TGeoCombiTrans *posFicFEEBUpSec4 = new TGeoCombiTrans("posFicFEEBUpSec4", (aFEEshiftR2Sec4*cos225 + 2.0 )*cos45, (aFEEshiftR2Sec4*cos225 + 2.0 )*sin45, 7.5, rot);
     posFicFEEBUpSec4->RegisterYourself();
     for (int i=0;i<2;i++) {
     v0APts[0+8*i] = fV0AOctH2/2.;             v0APts[1+8*i] = fV0AFEEBHt/2. + 2.5;
@@ -1429,11 +1462,11 @@ void AliVZEROv7::CreateGeometry()
     v0APts[6+8*i] = -fV0AOctH2/2.;            v0APts[7+8*i] = fV0AFEEBHt/2.+ 2.5;
     }
     new TGeoArb8("sV0AFicOct2Sec4", (fV0ASciWd+2*fV0AOctWd)/2., v0APts);
-    TGeoTranslation *posFicOct2Sec4 = new TGeoTranslation("posFicOct2Sec4",(FEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
+    TGeoTranslation *posFicOct2Sec4 = new TGeoTranslation("posFicOct2Sec4",(aFEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0,0.0,0.0);
     posFicOct2Sec4->RegisterYourself();  
     rot = new TGeoRotation("rot");
     rot->RotateZ(-90.0+45.0+90.0);
-    TGeoCombiTrans *posFicOct2UpSec4 = new TGeoCombiTrans("posFicOct2UpSec4",((FEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((FEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
+    TGeoCombiTrans *posFicOct2UpSec4 = new TGeoCombiTrans("posFicOct2UpSec4",((aFEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*cos45,((aFEEshiftR2Sec4*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0)*sin45,0.0,rot);
     posFicOct2UpSec4->RegisterYourself(); 
 
     /// Frame
@@ -1676,8 +1709,8 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0);
-    v0LE->AddNode(v0AFEE4,1, new TGeoCombiTrans( -FEEshiftR2Sec1*cos225-2.0, 0, 7.5, rot));   
-    v0LE->AddNode(v0AFEEOct2,4, new TGeoTranslation(-1.0*((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0),0.0,0.0));
+    v0LE->AddNode(v0AFEE4,1, new TGeoCombiTrans( -aFEEshiftR2Sec1*cos225-2.0, 0, 7.5, rot));   
+    v0LE->AddNode(v0AFEEOct2,4, new TGeoTranslation(-1.0*((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0),0.0,0.0));
 
 
     //Definition of sector 5
@@ -1726,9 +1759,9 @@ void AliVZEROv7::CreateGeometry()
     rot = new TGeoRotation("rot");
     rot->RotateX(90);
     rot->RotateZ(-90.0);
-    TGeoCombiTrans *posFicFEEBSec5 = new TGeoCombiTrans("posFicFEEBSec5", -FEEshiftR2Sec1*cos225 - 2.0, 0, 7.5, rot);
+    TGeoCombiTrans *posFicFEEBSec5 = new TGeoCombiTrans("posFicFEEBSec5", -aFEEshiftR2Sec1*cos225 - 2.0, 0, 7.5, rot);
     posFicFEEBSec5->RegisterYourself();
-    TGeoTranslation *posFicOct2Sec5 = new TGeoTranslation("posFicOct2Sec5",-1.0*((FEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0),0.0,0.0);
+    TGeoTranslation *posFicOct2Sec5 = new TGeoTranslation("posFicOct2Sec5",-1.0*((aFEEshiftR2Sec1*cos225 + 2.0) - fV0AFEEBTh/2. - 1.0),0.0,0.0);
     posFicOct2Sec5->RegisterYourself(); 
 
     /// Frame
@@ -2867,15 +2900,6 @@ void AliVZEROv7::CreateMaterials()
 }
 
 //_____________________________________________________________________________
-void AliVZEROv7::DrawModule() const
-{
-//  Drawing is done in DrawVZERO.C
-
-   AliDebug(2,"DrawModule");
-}
-
-
-//_____________________________________________________________________________
 void AliVZEROv7::DrawGeometry() 
 {
 //  Drawing of V0 geometry done in DrawV0.C
@@ -3137,31 +3161,21 @@ void AliVZEROv7::AddHit(Int_t track, Int_t *vol, Float_t *hits)
 }
 
 //_____________________________________________________________________________
-void AliVZEROv7::AddDigits(Int_t *tracks, Int_t* digits) 
-{
-//  Adds a VZERO digit
-
-   TClonesArray  &ldigits = *fDigits;
-   new(ldigits[fNdigits++]) AliVZEROdigit(tracks, digits);
-}
-
-//_____________________________________________________________________________
 void AliVZEROv7::MakeBranch(Option_t *option)
 {
 // Creates new branches in the current Root Tree
     
-  char branchname[10];
-  sprintf(branchname,"%s",GetName());
+  TString branchname(Form("%s",GetName()));
   AliDebug(2,Form("fBufferSize = %d",fBufferSize));
   const char *cH = strstr(option,"H");
   if (fHits   && fLoader->TreeH() && cH) {
-    fLoader->TreeH()->Branch(branchname,&fHits, fBufferSize);
-    AliDebug(2,Form("Making Branch %s for hits",branchname));
+    fLoader->TreeH()->Branch(branchname.Data(),&fHits, fBufferSize);
+    AliDebug(2,Form("Making Branch %s for hits",branchname.Data()));
   }     
   const char *cD = strstr(option,"D");
   if (fDigits   && fLoader->TreeD() && cD) {
-    fLoader->TreeD()->Branch(branchname,&fDigits, fBufferSize);
-    AliDebug(2,Form("Making Branch %s for digits",branchname));
+    fLoader->TreeD()->Branch(branchname.Data(),&fDigits, fBufferSize);
+    AliDebug(2,Form("Making Branch %s for digits",branchname.Data()));
   }  
 }