1 #ifndef ALITRDPADPLANE_H
2 #define ALITRDPADPLANE_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 /* $Id: AliTRDpadPlane.h,v */
8 //////////////////////////////////////////////////
10 // TRD pad plane class //
12 // Contains the information on pad postions, //
13 // pad dimensions, tilting angle, etc. //
14 // It also provides methods to identify the //
15 // current pad number from global coordinates. //
17 //////////////////////////////////////////////////
23 //_____________________________________________________________________________
24 class AliTRDpadPlane : public TObject {
29 AliTRDpadPlane(Int_t p, Int_t c);
30 AliTRDpadPlane(const AliTRDpadPlane &p);
31 virtual ~AliTRDpadPlane();
32 AliTRDpadPlane &operator=(const AliTRDpadPlane &p);
33 virtual void Copy(TObject &p) const;
35 Int_t GetPadRowNumber(Double_t z) const;
36 Int_t GetPadColNumber(Double_t rphi, Double_t rowOffset) const;
37 Double_t GetTiltOffset(Double_t rowOffset) const {return fTiltingTan * (rowOffset-0.5*fLengthOPad);}
38 Double_t GetPadRowOffset(Int_t row, Double_t z) const
39 { if ((row < 0) || (row >= fNrows))
42 return fPadRow[row] - z; };
44 Double_t GetPadColOffset(Int_t col, Double_t rphi) const
45 { if ((col < 0) || (col >= fNcols))
48 return fPadCol[col] - rphi; };
50 Double_t GetTiltingAngle() const { return fTiltingAngle; };
52 Int_t GetNrows() const { return fNrows; };
53 Int_t GetNcols() const { return fNcols; };
55 Double_t GetRow0() const { return fPadRow[0]; };
56 Double_t GetCol0() const { return fPadCol[0]; };
58 Double_t GetRowEnd() const { return fPadRow[fNrows-1] - fLengthOPad; };
59 Double_t GetColEnd() const { return fPadCol[fNcols-1] - fWidthOPad; };
61 Double_t GetRowPos(Int_t row) const { return fPadRow[row]; };
62 Double_t GetColPos(Int_t col) const { return fPadCol[col]; };
64 Double_t GetRowSize(Int_t row) const { if ((row == 0) || (row == fNrows-1))
67 return fLengthIPad; };
68 Double_t GetColSize(Int_t col) const { if ((col == 0) || (col == fNcols-1))
75 AliTRDgeometry *fGeo; //! TRD geometry
77 Int_t fPla; // Plane number
78 Int_t fCha; // Chamber number
80 Double_t fLength; // Length of pad plane in z-direction (row)
81 Double_t fWidth; // Width of pad plane in rphi-direction (col)
83 Double_t fLengthRim; // Length of the rim in z-direction (row)
84 Double_t fWidthRim; // Width of the rim in rphi-direction (col)
86 Double_t fLengthOPad; // Length of an outer pad in z-direction (row)
87 Double_t fWidthOPad; // Width of an outer pad in rphi-direction (col)
89 Double_t fLengthIPad; // Length of an inner pad in z-direction (row)
90 Double_t fWidthIPad; // Width of an inner pad in rphi-direction (col)
92 Double_t fRowSpacing; // Spacing between the pad rows
93 Double_t fColSpacing; // Spacing between the pad columns
95 Int_t fNrows; // Number of rows
96 Int_t fNcols; // Number of columns
98 Double_t fTiltingAngle; // Pad tilting angle
99 Double_t fTiltingTan; // Tangens of pad tilting angle
101 Double_t *fPadRow; //! Pad border positions in row direction
102 Double_t *fPadCol; //! Pad border positions in column direction
104 ClassDef(AliTRDpadPlane,2) // TRD ROC pad plane