]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TRD/AliTRDpadPlane.h
Change needed on alphacxx6
[u/mrichter/AliRoot.git] / TRD / AliTRDpadPlane.h
CommitLineData
e0d47c25 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 */
5
6/* $Id: AliTRDpadPlane.h,v */
7
8//////////////////////////////////////////////////
9// //
10// TRD pad plane class //
11// //
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. //
16// //
17//////////////////////////////////////////////////
18
19#include <TObject.h>
20
21class AliTRDgeometry;
22
23//_____________________________________________________________________________
24class AliTRDpadPlane : public TObject {
25
26 public:
27
28 AliTRDpadPlane();
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;
34
a5cadd36 35 Int_t GetPadRowNumber(const Double_t z) const;
36 Int_t GetPadColNumber(const Double_t rphi, const Double_t rowOffset) const;
e0d47c25 37
a5cadd36 38 Double_t GetPadRowOffset(const Int_t row, const Double_t z) const
39 { if ((row < 0) || (row >= fNrows))
40 return -1.0;
41 else
42 return fPadRow[row] - z; };
43
44 Double_t GetPadColOffset(const Int_t col, const Double_t rphi) const
45 { if ((col < 0) || (col >= fNcols))
46 return -1.0;
47 else
48 return fPadCol[col] - rphi; };
49
50 Double_t GetTiltingAngle() const { return fTiltingAngle; };
51
52 Int_t GetNrows() const { return fNrows; };
53 Int_t GetNcols() const { return fNcols; };
54
55 Double_t GetRow0() const { return fPadRow[0]; };
56 Double_t GetCol0() const { return fPadCol[0]; };
57
58 Double_t GetRowEnd() const { return fPadRow[fNrows-1] - fLengthOPad; };
59 Double_t GetColEnd() const { return fPadCol[fNcols-11] - fWidthOPad; };
60
61 Double_t GetRowPos(const Int_t row) const { return fPadRow[row]; };
62 Double_t GetColPos(const Int_t col) const { return fPadCol[col]; };
e0d47c25 63
a5cadd36 64 Double_t GetRowSize(const Int_t row) const { if ((row == 0) || (row == fNrows-1))
65 return fLengthOPad;
66 else
67 return fLengthIPad; };
68 Double_t GetColSize(const Int_t col) const { if ((col == 0) || (col == fNcols-1))
69 return fWidthOPad;
70 else
71 return fWidthIPad; };
72
e0d47c25 73 protected:
74
75 AliTRDgeometry *fGeo; //! TRD geometry
76
77 Int_t fPla; // Plane number
78 Int_t fCha; // Chamber number
79
80 Double_t fLength; // Length of pad plane in z-direction (row)
81 Double_t fWidth; // Width of pad plane in rphi-direction (col)
82
83 Double_t fLengthRim; // Length of the rim in z-direction (row)
84 Double_t fWidthRim; // Width of the rim in rphi-direction (col)
85
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)
88
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)
91
92 Double_t fRowSpacing; // Spacing between the pad rows
93 Double_t fColSpacing; // Spacing between the pad columns
94
95 Int_t fNrows; // Number of rows
96 Int_t fNcols; // Number of columns
97
98 Double_t fTiltingAngle; // Pad tilting angle
4ffb371b 99 Double_t fTiltingTan; // Tangens of pad tilting angle
e0d47c25 100
101 Double_t *fPadRow; //! Pad border positions in row direction
102 Double_t *fPadCol; //! Pad border positions in column direction
103
4ffb371b 104 ClassDef(AliTRDpadPlane,2) // TRD ROC pad plane
e0d47c25 105
106};
107
108#endif