]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Fixed some debug stuff - need more docs on the geom construction
authorcholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 23 Nov 2004 16:39:58 +0000 (16:39 +0000)
committercholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 23 Nov 2004 16:39:58 +0000 (16:39 +0000)
16 files changed:
FMD/AliFMD.cxx
FMD/AliFMD.h
FMD/AliFMD1.cxx
FMD/AliFMD2.cxx
FMD/AliFMD3.cxx
FMD/AliFMD3.h
FMD/AliFMD3Support.h
FMD/AliFMDRing.cxx
FMD/AliFMDSubDetector.cxx
FMD/AliFMDSubDetector.h
FMD/AliFMDv1.cxx
FMD/Config.C
FMD/scripts/DrawDetail.C
FMD/scripts/DrawFMD3.C
FMD/scripts/ShowDigits.C
FMD/scripts/ShowRaw.C

index d0b4f79d153b7bee96ec3af7d20e9d7c816a7269..8f252b9287118b86439850b9600ff5a7e9acc40f 100644 (file)
@@ -156,7 +156,7 @@ AliFMD::AliFMD()
   //
   // Default constructor for class AliFMD
   //
-  AliDebug(0, "Default CTOR");
+  AliDebug(0, "\tDefault CTOR");
   fHits     = 0;
   fDigits   = 0;
   fIshunt   = 0;
@@ -216,7 +216,7 @@ AliFMD::AliFMD(const char *name, const char *title, bool detailed)
   //
   // Standard constructor for Forward Multiplicity Detector
   //
-  AliDebug(0, "Standard CTOR");
+  AliDebug(0, "\tStandard CTOR");
 
   // Initialise Hit array
   HitsArray();
@@ -375,7 +375,7 @@ AliFMD::CreateGeometry()
   //   
 
   // DebugGuard guard("AliFMD::CreateGeometry");
-  AliDebug(10, "Creating geometry");
+  AliDebug(10, "\tCreating geometry");
 
   fInner->Init();
   fOuter->Init();
@@ -429,7 +429,7 @@ void AliFMD::CreateMaterials()
   // Also defined are two rotation matricies. 
   //
   // DebugGuard guard("AliFMD::CreateMaterials");
-  AliDebug(10, "Creating materials");
+  AliDebug(10, "\tCreating materials");
   Int_t    id;
   Double_t a                = 0;
   Double_t z                = 0;
@@ -621,7 +621,7 @@ AliFMD::BuildGeometry()
   // 
   // The actual building of the TNodes is done by
   // AliFMDSubDetector::SimpleGeometry. 
-  AliDebug(10, "Creating a simplified geometry");
+  AliDebug(10, "\tCreating a simplified geometry");
 
   TNode* top = gAlice->GetGeometry()->GetNode("alice");
   
@@ -638,7 +638,7 @@ AliFMD::DrawDetector()
   // Draw a shaded view of the Forward multiplicity detector
   //
   // DebugGuard guard("AliFMD::DrawDetector");
-  AliDebug(10, "Draw detector");
+  AliDebug(10, "\tDraw detector");
   
   //Set ALIC mother transparent
   gMC->Gsatt("ALIC","SEEN",0);
@@ -1083,8 +1083,7 @@ AliFMD::SetLegLength(Double_t length)
   // Set lenght of plastic legs that hold the hybrid (print board and
   // silicon sensor) onto the honeycomp support
   //
-  // DebugGuard guard("AliFMD::SetLegLength");
-  AliDebug(10, "AliFMD::SetLegLength");
+  AliDebug(10, Form("\tLeg length set to %lf cm", length));
   fLegLength = length;
   fInner->SetLegLength(fLegLength);
   fOuter->SetLegLength(fLegLength);
@@ -1098,8 +1097,7 @@ AliFMD::SetLegOffset(Double_t offset)
   // hybrid (print board and silicon sensor) onto the honeycomp
   // support 
   //
-  // DebugGuard guard("AliFMD::SetLegOffset");
-  AliDebug(10, "AliFMD::SetLegOffset");
+  AliDebug(10, Form("\tLeg offset set to %lf cm", offset));
   fInner->SetLegOffset(offset);
   fOuter->SetLegOffset(offset);
 }
@@ -1111,8 +1109,7 @@ AliFMD::SetLegRadius(Double_t radius)
   // Set the diameter of the plastic legs that hold the hybrid (print
   // board and silicon sensor) onto the honeycomp support
   //
-  // DebugGuard guard("AliFMD::SetLegRadius");
-  AliDebug(10, "AliFMD::SetLegRadius");
+  AliDebug(10, Form("\tLeg radius set to %lf cm", radius));
   fLegRadius = radius;
   fInner->SetLegRadius(fLegRadius);
   fOuter->SetLegRadius(fLegRadius);
@@ -1125,8 +1122,7 @@ AliFMD::SetModuleSpacing(Double_t spacing)
   // Set the distance between the front and back sensor modules
   // (module staggering). 
   //
-  // DebugGuard guard("AliFMD::SetModuleSpacing");
-  AliDebug(10, "AliFMD::SetModuleSpacing");  
+  AliDebug(10, Form("\tModule spacing set to %lf cm", spacing));  
   fModuleSpacing = spacing;
   fInner->SetModuleSpacing(fModuleSpacing);
   fOuter->SetModuleSpacing(fModuleSpacing);
@@ -1142,7 +1138,7 @@ AliFMD::Browse(TBrowser* b)
 {
   // Browse this object. 
   //
-  AliDebug(10, "AliFMD::Browse");
+  AliDebug(30, "\tBrowsing the FMD");
   AliDetector::Browse(b);
   if (fInner) b->Add(fInner, "Inner Ring");
   if (fOuter) b->Add(fOuter, "Outer Ring");
index f18942e530323c37ece0c375c037fe3de3141d4b..050180c88be6c503e83119e3d2da8b91f16dc50c 100644 (file)
@@ -104,7 +104,7 @@ public:
   // Set various parameters 
   void     SetLegLength(Double_t     length=1);
   void     SetLegRadius(Double_t     radius=.5);
-  void     SetLegOffset(Double_t     offset=.5);
+  void     SetLegOffset(Double_t     offset=2);
   void     SetModuleSpacing(Double_t spacing=1);
   void     SetSiDensity(Float_t r=2.33)         { fSiDensity = r; }
   void     SetSiThickness(Float_t r=0.03)       { fSiThickness = r; }
index 34ab3c63db238cffe3ab0cf227419af675c6d9b8..cd115ca026c9e3575cd356b0d1fc4eb22a435360 100644 (file)
@@ -54,6 +54,7 @@ AliFMD1::SetupGeometry(Int_t airId, Int_t alId, Int_t /* cId */)
   //     airId         Id # of the Air medium 
   //     alId     Id # of the Aluminium medium 
   // 
+  AliDebug(10, "\tDefining the geometry for FMD1");
   fInnerHoneyLowR  = fInner->GetLowR() + 1;
   fInnerHoneyHighR = fInner->GetHighR() + 1;
   fOuterHoneyLowR  = 0;
@@ -91,7 +92,8 @@ AliFMD1::Geometry(const char* mother, Int_t pbRotId,
   //
   // The Z passed in isn't used. 
   z = fInnerZ + fDz;
-  gMC->Gspos("FMD1", 1, mother, 0, 0, z, fRotationId);
+  AliDebug(10, Form("\tPutting FMD1 in %s at z=%lf cm", mother, z));
+  gMC->Gspos("FMD1", 1, mother, 0, 0, z, fRotationId, "ONLY");
 
   AliFMDSubDetector::Geometry("FMD1", pbRotId, idRotId, z);
 }
index 9bae6ae2c1fbae209e689ddf77a7dfebd127986c..7f89b67b14ffb4e8a050643fb366b3ab3f2486e6 100644 (file)
@@ -54,6 +54,7 @@ AliFMD2::SetupGeometry(Int_t airId, Int_t alId, Int_t cId)
   //     airId         Id # of the Air medium 
   //     alId     Id # of the Aluminium medium 
   // 
+  AliDebug(10, "\tDefining the geometry for FMD1");
   fInnerHoneyLowR  = fInner->GetLowR() + 1;
   fInnerHoneyHighR = fOuter->GetHighR() + 1;
   fOuterHoneyLowR  = fOuter->GetLowR() + 1;
@@ -91,6 +92,7 @@ AliFMD2::Geometry(const char* mother, Int_t pbRotId,
   //     z          Z position (not really used here, but passed down)
   //
   z = fDz + fOuterZ;
+  AliDebug(10, Form("\tPutting FMD2 in %s at z=%lf cm", mother, z));
   AliFMDSubDetector::Geometry("FMD2", pbRotId, idRotId, z);
   gMC->Gspos("FMD2", 1, mother, 0, 0, z, fRotationId);  
 }
index b350fc2eab1429adda24cf1cd15157194405391a..6dc808f32dbec01beabdfd95c3a450f5e3f28626 100644 (file)
@@ -39,6 +39,7 @@ AliFMD3::AliFMD3()
     fVolumeId(0)
 {
   // Default constructor for the FMD3 sub-detector 
+  AliDebug(10, "\t\tDefault CTOR");
 }
 
 
@@ -46,6 +47,7 @@ AliFMD3::AliFMD3()
 AliFMD3::~AliFMD3() 
 {
   // Destructor - does nothing 
+  AliDebug(10, "\t\tDTOR");
 }
 
 
@@ -60,6 +62,7 @@ AliFMD3::SetupGeometry(Int_t airId, Int_t alId, Int_t carbonId)
   //     airId         Id # of the Air medium 
   //     kaptionId     Id # of the Aluminium medium 
   // 
+  AliDebug(10, "\tSetting up the geometry for FMD3");
   Double_t innerZl = fInnerZ;
   Double_t innerZh = (fInnerZ 
                      - fInner->GetModuleSpacing() 
@@ -90,6 +93,7 @@ AliFMD3::SetupGeometry(Int_t airId, Int_t alId, Int_t carbonId)
   gMC->Matrix(fRotationId, 90, 0, 90, 90, 0, 0); 
   //0, 180, 90, 90, 180, 0);
 
+
   AliFMDSubDetector::SetupGeometry(airId, alId, carbonId);
 }
 
@@ -108,9 +112,9 @@ AliFMD3::Geometry(const char* mother, Int_t pbRotId,
   //     z          Z position (not really used here, but passed down)
   //
   z = fSupport.GetZ();
-  AliDebug(10, Form("Passing z=%lf to ring volumes", z));
-  AliFMDSubDetector::Geometry("FMD3", pbRotId, idRotId, z);
   fSupport.Geometry(mother, fRotationId, z);
+  AliDebug(10, Form("\t\tPassing z=%lf to ring volumes", z));
+  AliFMDSubDetector::Geometry("FMD3", pbRotId, idRotId, z);
 }
 
   
@@ -149,6 +153,7 @@ AliFMD3::SimpleGeometry(TList* nodes,
   //    a  = (fOuterHoneyHighR - fInnerHoneyHighR) / (x1 - x2)
   //    
   // 
+  AliDebug(10, "\tCreating simplified geometry for FMD3");
   Double_t dz = (TMath::Abs(fInnerZ - fOuterZ) 
                 + fOuter->GetSiThickness() 
                 + fOuter->GetPrintboardThickness() 
@@ -197,8 +202,10 @@ AliFMD3::SimpleGeometry(TList* nodes,
 
 //____________________________________________________________________
 void 
-AliFMD3::Gsatt() 
+AliFMD3::Gsatt() const
 {
+  // Set draw attributes for the FMD3
+  AliDebug(10, "Setting drawing attributes for FMD3");
   AliFMDSubDetector::Gsatt();
   fSupport.Gsatt();
 }
index b2b1659438a833c7fb879996e03a0b45d70eb3f0..c3f9cd22118604253a8b5f308244affd1baf674a 100644 (file)
@@ -21,7 +21,7 @@ public:
                          Int_t idRotId, Double_t z=0);
   virtual void   SimpleGeometry(TList* nodes, TNode* mother, 
                                Int_t colour, Double_t zMother);
-  virtual void   Gsatt();
+  virtual void   Gsatt() const;
 protected:
   Int_t          fVolumeId;  // Volume ID
   AliFMD3Support fSupport;   // Support for FMD3 
index cad316c24c030ea6d2960a0139ae398d0f089cba..b714616c821ba079a67b04efc2ab462b85b78188 100644 (file)
@@ -21,7 +21,7 @@ public:
                               Double_t innerRl, Double_t outerZl, 
                               Double_t outerZh, Double_t outerRl);
   virtual void   Geometry(const char* mother, Int_t idRotId, Double_t z=0);
-  virtual void   Gsatt();
+  virtual void   Gsatt() const;
   
   void SetNoseZ(Double_t         x=-46)                { fNoseZ = x; }
   void SetNoseLowR(Double_t      x=5.5)                { fNoseLowR = x; }
index 8cf5571b72e811b42749adafefd69ef4aacb02be..0b1150184d2d68f50020655e4b7db6ea8df6092a 100644 (file)
@@ -178,7 +178,7 @@ AliFMDRing::Init()
 {
   // Initialize the ring object.
   // DebugGuard guard("AliFMDRing::Init");
-  AliDebug(10, "AliFMDRing::Init");
+  AliDebug(30, Form("\tInitializing ring %c", fId));
   fPolygon.Clear();
   SetupCoordinates();  
 }
@@ -187,6 +187,7 @@ AliFMDRing::Init()
 AliFMDRing::~AliFMDRing() 
 {
   // Destructor - deletes shape and rotation matricies 
+  AliDebug(30, Form("\tDestructing ring %c", fId));
   if (fShape) delete fShape;
   if (fRotMatricies) delete fRotMatricies;
 }
@@ -197,7 +198,7 @@ void
 AliFMDRing::Browse(TBrowser* /* b */)
 {
   // DebugGuard guard("AliFMDRing::Browse");
-  AliDebug(10, "AliFMDRing::Browse");
+  AliDebug(30, Form("\tBrowsing ring %c", fId));
 }
 
   
@@ -207,10 +208,11 @@ AliFMDRing::SetupCoordinates()
 {
   // Calculates the parameters of the polygon shape. 
   // 
-  // DebugGuard guard("AliFMDRing::SetupCoordinates");
-  AliDebug(10, "AliFMDRing::SetupCoordinates");
+  //
+
   // Get out immediately if we have already done all this 
   if (fPolygon.GetNVerticies() > 1) return;
+  AliDebug(10, Form("\tSetting up the coordinates for ring %c", fId));
 
   double tanTheta  = TMath::Tan(fTheta * TMath::Pi() / 180.);
   double tanTheta2 = TMath::Power(tanTheta,2);
@@ -242,7 +244,8 @@ AliFMDRing::IsWithin(size_t moduleNo, double x, double y) const
   // Checks if a point (x,y) is inside the module with number moduleNo 
   //
   // DebugGuard guard("AliFMDRing::IsWithin");
-  AliDebug(10, "AliFMDRing::IsWithin");
+  AliDebug(20, Form("\tChecking wether the hit at (%lf,%lf) in module %d "
+                   "is within this ring (%c)", x, y, moduleNo, fId));
   bool   ret            = false;
   double r2             = x * x + y * y;
   if (r2 < fHighR * fHighR && r2 > fLowR * fLowR) {
@@ -272,7 +275,7 @@ AliFMDRing::Draw(Option_t* option) const
   // hits in the detector. 
   // 
   // DebugGuard guard("AliFMDRing::Draw");
-  AliDebug(10, "AliFMDRing::Draw");
+  AliDebug(20, Form("\tDrawing ring %c", fId));
   // The unrotated coordinates of the polygon verticies
   if (fPolygon.GetNVerticies() < 1) return;
   
@@ -354,7 +357,7 @@ AliFMDRing::SetupGeometry(Int_t vacuumId, Int_t siId, Int_t pcbId,
   //   idRotId         Identity rotation matrix 
   //
   // DebugGuard guard("AliFMDRing::SetupGeometry");
-  AliDebug(10, "AliFMDRing::SetupGeometry");
+  AliDebug(10, Form("\tSetting up the geometry for ring %c", fId));
 
   const TVector2& bCorner   = fPolygon.GetVertex(3); // Third  corner
   const TVector2& aCorner   = fPolygon.GetVertex(5); // First  corner
@@ -459,7 +462,8 @@ AliFMDRing::SetupGeometry(Int_t vacuumId, Int_t siId, Int_t pcbId,
     // Place virtual module volume 
     name = Form(fgkVirtualFormat, fId, (isFront ? 'F' : 'B'));
     dz   = (w - fRingDepth) / 2;
-    gMC->Gspos(name.Data(), id, name2.Data(), 0., 0., dz,fRotations[i]);
+    gMC->Gspos(name.Data(), id, name2.Data(), 0., 0., dz,fRotations[i], 
+              "ONLY");
 
     // We only need to place the children once, they are copied when
     // we place the other virtual volumes. 
@@ -470,7 +474,7 @@ AliFMDRing::SetupGeometry(Int_t vacuumId, Int_t siId, Int_t pcbId,
     // the silicon is on the edge of the virtual volume. 
     name  = Form(fgkActiveFormat, fId);
     dz    = (w - fSiThickness) / 2;
-    gMC->Gspos(name.Data(), id, name2.Data(),0.,0.,dz,idRotId);
+    gMC->Gspos(name.Data(), id, name2.Data(),0.,0.,dz,idRotId, "ONLY");
 
     // Place print board.  This is put immediately behind the silicon
     name = Form(fgkPrintboardFormat, fId, 'T');
@@ -487,10 +491,12 @@ AliFMDRing::SetupGeometry(Int_t vacuumId, Int_t siId, Int_t pcbId,
             - (fLegLength + (isFront ? fModuleSpacing : 0)) /2);
     name  = (isFront ? AliFMD::fgkLongLegName : AliFMD::fgkShortLegName);
     gMC->Gspos(name.Data(), id*10 + 1, name2.Data(), 
-              aCorner.X() + fLegOffset + fLegRadius, 0., dz, idRotId, "");
+              aCorner.X() + fLegOffset + fLegRadius, 0., dz, idRotId, "ONLY");
     Double_t y = cCorner.Y() - yoffset - fLegOffset - fLegRadius;
-    gMC->Gspos(name.Data(),id*10+2,name2.Data(),cCorner.X(), y,dz,idRotId,"");
-    gMC->Gspos(name.Data(),id*10+3,name2.Data(),cCorner.X(), -y,dz,idRotId,"");
+    gMC->Gspos(name.Data(),id*10+2,name2.Data(),cCorner.X(),y,dz,
+              idRotId,"ONLY");
+    gMC->Gspos(name.Data(),id*10+3,name2.Data(),cCorner.X(),-y,dz,
+              idRotId,"ONLY");
   }
 }
 //____________________________________________________________________
@@ -510,15 +516,15 @@ AliFMDRing::Geometry(const char* mother, Int_t baseId, Double_t z,
   //    idRotId   Identity rotation matrix 
   // 
   // DebugGuard guard("AliFMDRing::Geometry");
-  AliDebug(10, "AliFMDRing::Geometry");
   TString  name;
   Double_t offsetZ   = (fSiThickness 
                        + fPrintboardThickness 
                        + fLegLength + fModuleSpacing) / 2;
   name = Form(fgkRingFormat, fId);
-  AliDebug(10, Form("Placing ring %s in %s at z=%lf-%lf=%lf", 
-                   name.Data(), mother, z, offsetZ, z-offsetZ));
-  gMC->Gspos(name.Data(), baseId, mother, 0., 0., z - offsetZ, idRotId, "");
+  AliDebug(10, Form("\tPlacing ring %s in %s at z=%lf-%lf=%lf (base ID: %d)", 
+                   name.Data(), mother, z, offsetZ, z-offsetZ, baseId));
+  gMC->Gspos(name.Data(), baseId, mother, 0., 0., z - offsetZ, idRotId, 
+            "ONLY");
 }
 
 //____________________________________________________________________
@@ -544,11 +550,14 @@ AliFMDRing::SimpleGeometry(TList* nodes,
   //    n         Detector number
   //
   // DebugGuard guard("AliFMDRing::SimpleGeometry");
-  AliDebug(10, "AliFMDRing::SimpleGeometry");
   SetupCoordinates();
 
+  AliDebug(10, Form("\tCreating simple geometry for "
+                   "ring %c at z=%lf cm in %s", 
+                   fId, z, mother->GetName()));
   // If the shape hasn't been defined yet, we define it here. 
   if (!fShape) {
+
     TString name(Form(fgkActiveFormat, fId));
     TString title(Form("Shape of modules in %c Rings", fId));
     Int_t n = fPolygon.GetNVerticies();
@@ -609,7 +618,7 @@ AliFMDRing::Gsatt()
   // Set drawing attributes for the RING 
   // 
   // DebugGuard guard("AliFMDRing::Gsatt");
-  AliDebug(10, "AliFMDRing::Gsatt");
+  AliDebug(10, Form("\tSetting drawing attributes for Ring %c", fId));
   TString name;
   name = Form(fgkRingFormat,fId);
   gMC->Gsatt(name.Data(), "SEEN", 0);
index 133c9b9bea2e85d9240adaaf7df6afcc9a062003..ea9d9cd3180a476b3637187c7d5b4d31f64ed9d0 100644 (file)
@@ -51,6 +51,7 @@ AliFMDSubDetector::AliFMDSubDetector(Int_t n)
     fInner(0), 
     fOuter(0)
 {
+  // Normal CTOR
   SetAlThickness();
   SetHoneycombThickness();
 }
@@ -61,7 +62,18 @@ void
 AliFMDSubDetector::Draw(Option_t* /* opt */) const 
 {
   // DebugGuard guard("AliFMDSubDetector::Draw");
-  AliDebug(10, "AliFMDSubDetector::Draw");
+  AliDebug(30, Form("\tDrawing FMD%d", fId));
+  Gsatt();
+  gMC->Gdraw(Form("FMD%d", fId));
+}
+
+//____________________________________________________________________
+void 
+AliFMDSubDetector::DrawSpecs() const 
+{
+  // DebugGuard guard("AliFMDSubDetector::Draw");
+  AliDebug(30, Form("\tDrawing specs foro FMD%d", fId));
+  gMC->DrawOneSpec(Form("FMD%d", fId));
 }
 
 //____________________________________________________________________
@@ -70,6 +82,8 @@ AliFMDSubDetector::CheckHit(Char_t ring, Int_t module, Double_t x, Double_t y)
 {
   // Check if a hit (x,y) in module module of ring ring is within the
   // actual shape. 
+  AliDebug(30, Form("\tChecking wether the hit at (%lf,%lf) "
+                   "is in ring %c module %d", x, y, ring, module));
   Bool_t ret = kFALSE;
   switch (ring) {
   case 'i':
@@ -102,7 +116,8 @@ AliFMDSubDetector::SimpleGeometry(TList* nodes,
   //    colour    Colour of the nodes 
   //    zMother   Z position of the node in the mother volume 
   // 
-  for (int i = 0; i < 2; i++) {
+  AliDebug(20, Form("\tCreating simple geometry for FMD%d", fId));
+  for (int i = 0; i < 2; i++) { 
     AliFMDRing* r = 0;
     Double_t z = 0;
     switch (i) {
@@ -143,7 +158,7 @@ AliFMDSubDetector::SetupGeometry(Int_t airId, Int_t alId, Int_t /* cId
   //   alId       Medium of honeycomb
   // 
   // DebugGuard guard("AliFMDSubDetector::SetupGeometry");
-  AliDebug(10, "AliFMDSubDetector::SetupGeometry");
+  AliDebug(20, Form("\tSetting up the geometry for FMD%d", fId));
   TString name;
   Double_t par[5];
 
@@ -215,7 +230,8 @@ AliFMDSubDetector::Geometry(const char* mother, Int_t pbRotId, Int_t idRotId,
   // support in the mother volume 
   // 
   // DebugGuard guard("AliFMDSubDetector::Geometry");
-  AliDebug(10, "AliFMDSubDetector::Geometry");
+  AliDebug(20, Form("\tDefining the rings in  %s (z=%lf cm)", 
+                   mother, zMother));
 
   Double_t  ringW;
   Double_t  z = 0;
@@ -245,7 +261,7 @@ AliFMDSubDetector::Geometry(const char* mother, Int_t pbRotId, Int_t idRotId,
     Double_t z2 = z;
     z2 -= zMother;
     if (zMother > 0) z2 *= -1;
-    AliDebug(10, Form("Putting ring %c in %s at z=%lf-%lf=%lf", 
+    AliDebug(10, Form("\tPutting ring %c in %s at z=%lf-%lf=%lf", 
                      c, mother, z, zMother, z2));
     r->Geometry(mother, fId, z2, pbRotId, idRotId);
     ringW =  r->GetRingDepth();
@@ -253,32 +269,32 @@ AliFMDSubDetector::Geometry(const char* mother, Int_t pbRotId, Int_t idRotId,
 
     // Top of honeycomb
     name   = Form(fgkHoneyTopFormat, fId, c);
-    gMC->Gspos(name.Data(), 1, mother, 0, 0, z2, idRotId);
+    gMC->Gspos(name.Data(), 1, mother, 0, 0, z2, idRotId, "ONLY");
 
     // Air in top of honeycomb
     name2 = name;
     name   = Form(fgkHoneyTopInnerFormat, fId, c);
-    gMC->Gspos(name.Data(), 1, name2.Data(),0,fAlThickness,0,idRotId);
+    gMC->Gspos(name.Data(), 1, name2.Data(),0,fAlThickness,0,idRotId,"ONLY");
     
     // Bottom of honeycomb
     name   = Form(fgkHoneyBottomFormat, fId, c);
-    gMC->Gspos(name.Data(), 1, mother, 0, 0, z2, idRotId);
+    gMC->Gspos(name.Data(), 1, mother, 0, 0, z2, idRotId, "ONLY");
 
     // Air in bottom of honeycomb
     name2 = name;
     name   = Form(fgkHoneyBottomInnerFormat, fId, c);
-    gMC->Gspos(name.Data(),1,name2.Data(),0,-fAlThickness,0,idRotId);
+    gMC->Gspos(name.Data(),1,name2.Data(),0,-fAlThickness,0,idRotId, "ONLY");
   }
 }
 
 //____________________________________________________________________
 void
-AliFMDSubDetector::Gsatt() 
+AliFMDSubDetector::Gsatt() const
 {
   // Set drawing attributes for the detector 
   // 
   // DebugGuard guard("AliFMDSubDetector::Gsatt");
-  AliDebug(10, "AliFMDSubDetector::Gsatt");
+  AliDebug(30, Form("\tSetting draw attributs for FMD%d", fId));
   TString name;
 
   name = Form("FMD%d", fId);
index 09f6d1977f7aa33ca57533f24714cdc948f1f6f3..9f158baf70628da5f41d03979976450a03778984 100644 (file)
@@ -33,8 +33,9 @@ public:
                                Int_t colour, 
                                Double_t zMother);
   
-  virtual void   Gsatt();
+  virtual void   Gsatt() const;
   virtual void   Draw(Option_t* option="BIOL0") const; //*MENU*
+  virtual void   DrawSpecs() const; // *MENU*
   virtual Bool_t CheckHit(Char_t ring, Int_t module, Double_t x, Double_t y);
 
   void   SetInner(AliFMDRing* r)             { fInner = r; }
index 8f82e459f6180fa112364a8586403fe814e869f6..273bdcd5047169cf5f7739681e79b0a8e8e56dbe 100644 (file)
@@ -100,9 +100,6 @@ AliFMDv1::StepManager()
   //   - ENDIF
   //     
   //
-  // DebugGuard guard("AliFMDv1::StepManager");
-  AliDebug(10, "AliFMDv1::StepManager");
-  // return;
   AliDebug(10, Form("Is inside %s", gMC->CurrentVolName()));
 
   // If the track is gone, return
@@ -169,7 +166,14 @@ AliFMDv1::StepManager()
                     || gMC->IsTrackDisappeared() 
                     || gMC->IsTrackStop() 
                     || !isWithin);
-// Reset the energy deposition for this track, and update some of
+
+  AliDebug(2, Form("Is inside FMD%d%c[%02d,%03d]: particle is %s", 
+                  detector, ring, sector, strip, 
+                  (entering ? "entering" : 
+                   (inside ? "inside" : 
+                    "exiting"))));
+
+  // Reset the energy deposition for this track, and update some of
   // our parameters.
   if (entering) {
     fCurrentDeltaE = 0;
index 2badda0588c4c6910e7eacf92754a57b0a65421f..937e442686a5d578b6b02a692e164bf26367e4bc 100644 (file)
@@ -66,6 +66,7 @@ enum EG_t {
   kParam_8000,                 //
   kParam_4000,                 //
   kParam_2000,                 //
+  kParam_fmd,                  //
   kHijing_cent1,               //
   kHijing_cent2,               //
   kHijing_per1,                        //
@@ -124,6 +125,7 @@ const char* egName[kEgMax] = {
   "kParam_8000",               //
   "kParam_4000",               //
   "kParam_2000",               //
+  "kParam_fmd",                        //
   "kHijing_cent1",             //
   "kHijing_cent2",             //
   "kHijing_per1",              //
@@ -213,7 +215,7 @@ Config()
   //____________________________________________________________________
   // This part for configuration    
   //static EG_t eg = test50;
-  EG_t  eg   = kParam_2000;
+  EG_t  eg   = kParam_fmd;
   Geo_t geo  = kNoHoles;
   Rad_t rad  = kGluonRadiation;
   Mag_t mag  = k5kG;
@@ -726,6 +728,19 @@ GeneratorFactory(EG_t eg, Rad_t rad, TString& comment)
       gGener=gener;
     }
     break;
+  case kParam_fmd:
+    {
+      comment = comment.Append("HIJINGparam N=100");
+      AliGenHIJINGpara *gener = new AliGenHIJINGpara(100);
+      gener->SetMomentumRange(0, 999999.);
+      gener->SetPhiRange(0., 360.);
+      // Set pseudorapidity range from -8 to 8.
+      Float_t thmin = EtaToTheta(8);   // theta min. <---> eta max
+      Float_t thmax = EtaToTheta(-8);  // theta max. <---> eta min 
+      gener->SetThetaRange(thmin,thmax);
+      gGener=gener;
+    }
+    break;
     //
     //  Hijing Central
     //
index ed5c1a7f16545cedd3524d1a8fbf81870e607b8e..d0bb38de3bb9246890e1cac71d808a64e2a86aad 100644 (file)
@@ -4,10 +4,11 @@
 void DrawDetail()
 {
   // gAlice->Init("FMD/scripts/ConfigInner.C");
-  gAlice->Init("FMD/scripts/ConfigFmdOnly.C");
+  AliLog::SetModuleDebugLevel("FMD", 6);
+  gAlice->Init("$(ALICE)/FMD/Config.C");
   gMC->Gsatt("*", "seen", -1);
   gMC->Gsatt("alic", "seen", 0);
-  gROOT->LoadMacro("FMD/ViewFMD.C");
+  gROOT->LoadMacro("$(ALICE)/FMD/ViewFMD.C");
   gInterpreter->ProcessLine("ViewFMD()");
   // gROOT->LoadMacro("VZERO/ViewVZERO.C");
   // gInterpreter->ProcessLine("ViewVZERO()");
@@ -53,9 +54,9 @@ void DrawDetail()
   gMC->SetClipBox(".");
   gMC->SetClipBox("*", 0, 10000, -1000, 1000, -1000, 1000);
   gMC->DefaultRange();
-  gMC->Gdraw("alic", 60, 0, 0, -5, 10, .3, .3);
+  gMC->Gdraw("alic", 90, 0, 0, -5, 10, .15, .15);
 
   gPad->Modified();
   gPad->cd();
-  // gPad->Print("FMD3_detail.png");
+  gPad->Print("FMD3_detail.png");
 }
index 5e34196e4887026949bed80799ebe00a4ede439e..8d9f69f1806909ddd96fd64809ff847b3638c164 100644 (file)
@@ -4,10 +4,10 @@
 void DrawFMD3()
 {
   // gAlice->Init("FMD/scripts/ConfigInner.C");
-  gAlice->Init("FMD/scripts/ConfigFmdOnly.C");
+  gAlice->Init("$(ALICE)/FMD/Config.C");
   gMC->Gsatt("*", "seen", -1);
   gMC->Gsatt("alic", "seen", 0);
-  gROOT->LoadMacro("FMD/ViewFMD.C");
+  gROOT->LoadMacro("$(ALICE)/FMD/ViewFMD.C");
   gInterpreter->ProcessLine("ViewFMD()");
   gMC->Gdopt("hide", "on");
   gMC->Gdopt("shad", "on");
@@ -51,5 +51,5 @@ void DrawFMD3()
   
   gPad->Modified();
   gPad->cd();
-  gPad->Print("FMD3_detail.png");
+  gPad->Print("FMD3.png");
 }
index f7ec4ad0e62216453c44c9629f847d9bed91458a..570ce2bf0c585fb320b4ebd770185549e3894725 100644 (file)
@@ -2,7 +2,7 @@
 // Script to digit multiplicity information to std::cout. 
 //
 void
-ShowDigits()
+ShowDigits(Int_t det=2)
 {
   AliRunLoader* runLoader = AliRunLoader::Open("galice.root");
   runLoader->LoadgAlice();
@@ -12,6 +12,7 @@ ShowDigits()
   AliLoader*    fmdLoader  = runLoader->GetLoader("FMDLoader");
   fmdLoader->LoadDigits("READ");
   
+  TH1* h = new TH1F("digitData", "Digit Data", 128, 0, 1024);
   Int_t nEvents = runLoader->TreeE()->GetEntries();
   for (Int_t event = 0; event < nEvents; event++) {
     cout << "Event # " << event << endl;
@@ -35,8 +36,16 @@ ShowDigits()
          digit->Print();
          total++;
        }
+       if (digit->Detector() == det) 
+         h->Fill(digit->Counts());
       }
     }
     cout << "Total number of digits: " << total << endl;
   }
+
+  TCanvas* c = new TCanvas("digit", "Digit Data");
+  c->SetFillColor(0);
+  c->SetLogy();
+  c->SetBorderMode(0);
+  h->Draw();
 }
index d60f69310b967f68e382a327ba73f88f36f413a8..f41696831ca1113260eec0072447f6cc0455575c 100644 (file)
@@ -10,7 +10,7 @@ ShowRaw(Int_t det=2,  bool verbose=false, Int_t event=0)
 
   std::cout << "Reading raw data file " << file << std::endl;
   
-  TH1* h = new TH1F("rawData", "Raw Data", 90, 0, 90);
+  TH1* h = new TH1F("rawData", "Raw Data", 128, 0, 1024);
   
   
   // This method creates a text file containing the same information
@@ -58,6 +58,11 @@ ShowRaw(Int_t det=2,  bool verbose=false, Int_t event=0)
       break;
     }
   }//end while
+
+  TCanvas* c = new TCanvas("raw", "Raw Data");
+  c->SetFillColor(0);
+  c->SetLogy();
+  c->SetBorderMode(0);
   h->Draw();
   return;
 }