]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
- New virtual function in AliMUONVGeometryDESegmentation and in the daughters GetDire...
authormartinez <martinez@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 27 Jan 2005 13:20:51 +0000 (13:20 +0000)
committermartinez <martinez@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 27 Jan 2005 13:20:51 +0000 (13:20 +0000)
This returns an enum defined in AliMUONGeometryDirection kDirX, KDirY and kDirUndefined
This method gives the direction where the pad size of the chamber is constant.
In other words this corresponds with the coordinate where the spatial resolution is the best.
Normally kDirY will correspond with cathode segmentation for the bending plane and
kDirX  with cathode segmentation for the non bending plane
- README Info for running a test script of the MUON code

MUON/AliMUONGeometrySegmentation.cxx
MUON/AliMUONGeometrySegmentation.h
MUON/AliMUONSt12QuadrantSegmentation.cxx
MUON/AliMUONSt12QuadrantSegmentation.h
MUON/AliMUONSt345SlatSegmentation.h
MUON/AliMUONTest.cxx
MUON/AliMUONVGeometryDESegmentation.h
MUON/Config.C
MUON/MUONLinkDefGeometry.h
MUON/README

index a3210879a2b71fd8c53b77abfe3d82c179fd8411..e728618e878974d0c05c277cb798bcf6ab19ae60 100644 (file)
@@ -149,6 +149,17 @@ void AliMUONGeometrySegmentation::Add(Int_t detElemId,
   fDESegmentations->Add(detElemId, segmentation); 
 }  
 
+//______________________________________________________________________________
+AliMUONGeometryDirection 
+AliMUONGeometrySegmentation::GetDirection(Int_t detElemId) const
+{
+// Return direction with a constant pad size (Direction or coordinate where the resolution is the best)
+
+  if (!Notify(detElemId)) return kDirUndefined;
+
+  return fCurrentSegmentation->GetDirection();
+}
+
 //______________________________________________________________________________
 void AliMUONGeometrySegmentation::SetPadSize(Float_t p1, Float_t p2)
 {
index 94f832988655a23915075768f3d1766b6e67162b..80dc654242915b4506e65da24610015695487727 100644 (file)
@@ -17,6 +17,8 @@
 
 #include <TObject.h>
 
+#include "AliMUONGeometryDirection.h"
+
 class TObjArray;
 class TF1;
 
@@ -38,6 +40,8 @@ class AliMUONGeometrySegmentation : public TObject
  
     // get methods
     AliMUONGeometryModule* GetGeometry() const;              
+    virtual AliMUONGeometryDirection GetDirection(Int_t detElemId) const;
+                       // Direction with a constant pad size  (Direction or coordinate where the resolution is the best)
     
     //    
     // redefined methods from AliSegmentation interface
index 3979b9ea1dfda1979d2ac7e9ed266921d88f8175..e3bacdf6cd0c1e9aec358e64e7d5419c41c53f72 100644 (file)
@@ -210,6 +210,18 @@ Bool_t  AliMUONSt12QuadrantSegmentation::HasPad(Int_t ix, Int_t iy)
 }  
 
 
+//______________________________________________________________________________
+AliMUONGeometryDirection  AliMUONSt12QuadrantSegmentation::GetDirection()
+{
+// Returns the direction with a constant pad size  (Direction or coordinate where the resolution is the best)
+
+  switch ( fSector->GetDirection() ) {
+    case kX: return kDirX;
+    case kY: return kDirY;
+    default: return kDirUndefined;
+  }  
+}  
+
 //______________________________________________________________________________
 Float_t AliMUONSt12QuadrantSegmentation::GetAnod(Float_t xhit) const
 {
index fe8b2e6d9aadaa015b9359ecf6d67044610f3ad2..7dd8a77b5d4fa7f95fa7b3d702e676995d5bdc25 100644 (file)
@@ -55,6 +55,11 @@ class AliMUONSt12QuadrantSegmentation : public AliMUONVGeometryDESegmentation
     virtual Bool_t  HasPad(Int_t ix, Int_t iy);
                        // Returns true if a pad with given indices exists
 
+    // Quadrant type
+    //
+    virtual AliMUONGeometryDirection  GetDirection();
+                       // Returns the direction with a constant pad size
+
     // Transform from pad (wire) to real coordinates and vice versa
     //
     virtual Float_t GetAnod(Float_t xhit) const;
index d687ef2051efbca496ea69c151a8e5e0a1df6a3d..bd671227bdc49cad64f81688ebb0307252120055 100644 (file)
@@ -35,6 +35,7 @@ class AliMUONSt345SlatSegmentation : public AliMUONVGeometryDESegmentation
 
     virtual Bool_t   HasPad(Float_t /*x*/, Float_t /*y*/, Float_t /*z*/) { return true; }
     virtual Bool_t   HasPad(Int_t /*ix*/, Int_t /*iy*/) { return true; }
+    virtual AliMUONGeometryDirection  GetDirection() { return kDirUndefined; } 
 
     virtual Float_t  GetAnod(Float_t xhit) const;  // Anod wire coordinate closest to xhit
     virtual void     GetPadI(Float_t x ,Float_t y ,Int_t   &ix,Int_t &iy);  // Transform from pad to real coordinates
index f34bb8b9a1be57366e9804958c8fe3a988f1ee2b..d3cdc4e94defcdf26acc7c39d81f5456299b5b21 100644 (file)
@@ -876,6 +876,8 @@ void AliMUONTest::DrawPad(Int_t& counter,
   //printf(" ***** Pad position is ix: %d iy: %d x: %f y: %f sector: %d dpx: %f dpy: %f \n",
   //       ix, iy, x, y, sector, dpx, dpy);
 
+  if (!fCanvas) Before(kDrawPads);
+
   fCanvas->cd();
   TPave* pave = new TPave(x-dpx/2., y-dpy/2., x+dpx/2., y+dpy/2., 1);
   pave->Draw();
index a13e9096c3ab4eb9321fe106555f32773cf7cc61..6fa7c4e90d5658dca1e0e435acf63035e108f571 100644 (file)
@@ -17,6 +17,7 @@
 #define ALI_MUON_V_GEOMETRY_DE_SEGMENTATION_H
 
 #include "AliSegmentation.h"
+#include "AliMUONGeometryDirection.h"
 
 class AliMUONVGeometryDESegmentation : public AliSegmentation
 {
@@ -30,6 +31,14 @@ class AliMUONVGeometryDESegmentation : public AliSegmentation
     virtual Bool_t  HasPad(Int_t ix, Int_t iy) = 0;
                        // Returns true if a pad with given indices exists
 
+    virtual AliMUONGeometryDirection  GetDirection() = 0;
+    // Returns the direction with a constant pad size  (Direction or coordinate where the resolution is the best)
+    // This returns an enum defined in AliMUONGeometryDirection kDirX, KDirY and kDirUndefined
+    // This method gives the direction where the pad size of the chamber is constant.
+    // In other words this corresponds with the coordinate where the spatial resolution is the best.
+    // Normally kDirY will correspond with cathode segmentation for the bending plane and 
+    // kDirX  with cathode segmentation for the non bending plane
+
   protected:
     AliMUONVGeometryDESegmentation(const AliMUONVGeometryDESegmentation& rhs);
   
index c9bf673d2537f36f8d23ec7478513c6004b546fc..f0fa3ca259eceb602af4e30b7da1816ec48df819 100644 (file)
@@ -2,7 +2,7 @@
 // Remember to define the directory and option
 // gAlice->SetConfigFunction("Config('$HOME','box');");
 
-void Config(char directory[100]="", char option[6]="box")
+void Config(char directory[100]="", char option[6]="param")
 {
   //
   // Config file for MUON test
index 9c96ae8cce5147c735dfaf6e75ac2fe97d27214a..f61f914b9626277f88e862c2064677853231f1f6 100644 (file)
@@ -17,5 +17,7 @@
 #pragma link C++ class  AliMUONGeometryStore+;
 #pragma link C++ class  AliMUONVGeometryDESegmentation+;
 #pragma link C++ class  AliMUONGeometrySegmentation+;
+
+#pragma link C++ enum   AliMUONGeometryDirection;
 #endif
 
index 487e4df7040984896267a08fa3adbb6d4dd693e3..b8a2fddee27a2dd9c602bf9053c56a56df2e950a 100644 (file)
@@ -20,6 +20,21 @@ Please add  to this README file all information concerning
 config files, simulation, digitalization, clusterization, 
 reconstruction and macro analysis
 
+==========================================================
+ How to check that your aliroot is working well
+==========================================================
+There is a script file AlirootRun_MUONtest.script which 
+allows for simulating, reconstructing and making the
+invariant analysis of the generated Upsilon (1S).
+The used configuration file is Config.C in MUON 
+directory.
+There you have to type :
+
+source $ALICE_ROOT/MUON/AlirootRun_MUONtest.script
+
+If you do not recover a few Upsilons in their mass region 
+in the file MUONmassPlot.root
+
 ==========================================================
  How to run a MUON generation
 ==========================================================