]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TRD/AliTRDpadPlane.h
Retrieval of parameters from config file implemented
[u/mrichter/AliRoot.git] / TRD / AliTRDpadPlane.h
index 195d078acea1447f173d1a51064a929dbbddf6f0..40105543804962c2e84616ec5072877abaeadba1 100644 (file)
@@ -5,16 +5,16 @@
 
 /* $Id$ */
 
-//////////////////////////////////////////////////
-//                                              //
-//  TRD pad plane class                         //
-//                                              //
-//  Contains the information on pad postions,   //
-//  pad dimensions, tilting angle, etc.         //
-//  It also provides methods to identify the    //
-//  current pad number from global coordinates. //
-//                                              //
-//////////////////////////////////////////////////
+////////////////////////////////////////////////////////////////////////////
+//                                                                        //
+//  TRD pad plane class                                                   //
+//                                                                        //
+//  Contains the information on ideal pad positions, pad dimensions,      //
+//  tilting angle, etc.                                                   //
+//  It also provides methods to identify the current pad number from      //
+//  local tracking coordinates.                                           //
+//                                                                        //
+////////////////////////////////////////////////////////////////////////////
 
 #include <TObject.h>
 
@@ -24,14 +24,14 @@ class AliTRDpadPlane : public TObject {
  public:
 
   AliTRDpadPlane();
-  AliTRDpadPlane(Int_t plane, Int_t chamber);
+  AliTRDpadPlane(Int_t layer, Int_t stack);
   AliTRDpadPlane(const AliTRDpadPlane &p);
   virtual           ~AliTRDpadPlane();
   AliTRDpadPlane    &operator=(const AliTRDpadPlane &p);
   virtual void       Copy(TObject &p) const;
 
-  void     SetPlane(Int_t p)                   { fPla            = p; };
-  void     SetChamber(Int_t c)                 { fCha            = c; };
+  void     SetLayer(Int_t l)                   { fLayer          = l; };
+  void     SetStack(Int_t s)                   { fStack          = s; };
   void     SetRowSpacing(Double_t s)           { fRowSpacing     = s; };
   void     SetColSpacing(Double_t s)           { fColSpacing     = s; };
   void     SetLengthRim(Double_t l)            { fLengthRim      = l; };
@@ -50,9 +50,8 @@ class AliTRDpadPlane : public TObject {
   void     SetWidthOPad(Double_t w)            { fWidthOPad      = w; };
   void     SetLengthIPad(Double_t l)           { fLengthIPad     = l; };
   void     SetWidthIPad(Double_t w)            { fWidthIPad      = w; };
-  void     SetTiltingAngle(Double_t t)         { fTiltingAngle   = t; 
-                                                 fTiltingTan     = TMath::Tan(TMath::Pi()/180.0 * fTiltingAngle); };
   void     SetPadRowSMOffset(Double_t o)       { fPadRowSMOffset = o; };
+  void     SetTiltingAngle(Double_t t);
 
   Int_t    GetPadRowNumber(Double_t z) const;
   Int_t    GetPadRowNumberROC(Double_t z) const;
@@ -64,7 +63,7 @@ class AliTRDpadPlane : public TObject {
   Double_t GetPadRowOffset(Int_t row, Double_t z) const
                                              { if ((row < 0) || (row >= fNrows))
                                                  return -1.0;
-                                               else 
+                                                else 
                                                  return fPadRow[row] + fPadRowSMOffset - z;        };
   Double_t GetPadRowOffsetROC(Int_t row, Double_t z) const
                                              { if ((row < 0) || (row >= fNrows))
@@ -76,7 +75,7 @@ class AliTRDpadPlane : public TObject {
                                              { if ((col < 0) || (col >= fNcols))
                                                  return -1.0;
                                                else
-                                                 return fPadCol[col] - rphi; };
+                                                 return rphi - fPadCol[col]; };
 
   Double_t GetTiltingAngle() const           { return fTiltingAngle; };
 
@@ -89,7 +88,7 @@ class AliTRDpadPlane : public TObject {
 
   Double_t GetRowEnd() const                 { return fPadRow[fNrows-1] - fLengthOPad + fPadRowSMOffset; };
   Double_t GetRowEndROC() const              { return fPadRow[fNrows-1] - fLengthOPad; };
-  Double_t GetColEnd() const                 { return fPadCol[fNcols-1] - fWidthOPad;  };
+  Double_t GetColEnd() const                 { return fPadCol[fNcols-1] + fWidthOPad;  };
 
   Double_t GetRowPos(Int_t row) const        { return fPadRow[row] + fPadRowSMOffset;  };
   Double_t GetRowPosROC(Int_t row) const     { return fPadRow[row];  };
@@ -102,7 +101,7 @@ class AliTRDpadPlane : public TObject {
   Double_t GetColSize(Int_t col) const       { if ((col == 0) || (col == fNcols-1))
                                                  return fWidthOPad;
                                                else
-                                                  return fWidthIPad; };
+                                                 return fWidthIPad;  };
 
   Double_t GetLengthRim() const              { return fLengthRim;    };
   Double_t GetWidthRim() const               { return fWidthRim;     };
@@ -118,8 +117,8 @@ class AliTRDpadPlane : public TObject {
 
  protected:
 
-  Int_t     fPla;             //  Plane number
-  Int_t     fCha;             //  Chamber number
+  Int_t     fLayer;           //  Layer number
+  Int_t     fStack;           //  Stack number
 
   Double_t  fLength;          //  Length of pad plane in z-direction (row)
   Double_t  fWidth;           //  Width of pad plane in rphi-direction (col)
@@ -147,7 +146,7 @@ class AliTRDpadPlane : public TObject {
 
   Double_t  fPadRowSMOffset;  //  To be added to translate local ROC system to local SM system
 
-  ClassDef(AliTRDpadPlane,4)  //  TRD ROC pad plane
+  ClassDef(AliTRDpadPlane,5)  //  TRD ROC pad plane
 
 };