]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TRD/AliTRDgeometry.h
Updated ideal geometry, including ACORDE
[u/mrichter/AliRoot.git] / TRD / AliTRDgeometry.h
CommitLineData
dd9a6ee3 1#ifndef ALITRDGEOMETRY_H
2#define ALITRDGEOMETRY_H
f7336fa3 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
db30bf0f 6/* $Id$ */
f7336fa3 7
0a29d0f1 8///////////////////////////////////////////////////////////////////////////////
9// //
10// TRD geometry class //
11// //
12///////////////////////////////////////////////////////////////////////////////
13
94de3818 14#include "AliGeometry.h"
2745a409 15
b4a9cd27 16#include "TObjArray.h"
2745a409 17
b4a9cd27 18class TGeoHMatrix;
5443e65e 19
f162af62 20class AliRunLoader;
21
22class AliTRDpadPlane;
23
f7336fa3 24class AliTRDgeometry : public AliGeometry {
25
26 public:
27
7925de54 28 enum { kNplan = 6
29 , kNcham = 5
30 , kNsect = 18
31 , kNdet = 540
32 , kNdets = 30 };
dd56b762 33
f7336fa3 34 AliTRDgeometry();
2745a409 35 AliTRDgeometry(const AliTRDgeometry &g);
8230f242 36 virtual ~AliTRDgeometry();
2745a409 37 AliTRDgeometry &operator=(const AliTRDgeometry &g);
f7336fa3 38
793ff80c 39 virtual void Init();
030b4415 40 virtual void CreateGeometry(Int_t *idtmed);
41 virtual Int_t IsVersion() { return 1; }
25ca55ce 42 virtual Bool_t Impact(const TParticle* ) const { return kTRUE; }
030b4415 43 virtual Bool_t IsHole(Int_t /*p*/, Int_t /*c*/, Int_t /*s*/) const { return kFALSE; }
bd0f8685 44
2669905c 45 virtual Bool_t RotateBack(Int_t det, Double_t *loc, Double_t *glb) const;
793ff80c 46
9bf8c575 47 Bool_t ChamberInGeometry(Int_t det);
48
bd0f8685 49 void GroupChamber(Int_t iplan, Int_t icham, Int_t *idtmed);
50 void CreateFrame(Int_t *idtmed);
51 void CreateServices(Int_t *idtmed);
52
9a96f175 53 Bool_t CreateClusterMatrixArray();
54 TGeoHMatrix *GetClusterMatrix(Int_t det) { return (TGeoHMatrix *)
55 fClusterMatrixArray->At(det); }
030b4415 56
57 void SetSMstatus(Int_t sm, Char_t status) { fSMstatus[sm] = status; }
58
9c782af4 59 static Int_t GetDetectorSec(Int_t p, Int_t c);
60 static Int_t GetDetector(Int_t p, Int_t c, Int_t s);
c6011b06 61 static Int_t GetPlane(Int_t d);
afc51ac2 62 virtual Int_t GetChamber(Int_t d) const;
d9950a5a 63 virtual Int_t GetChamber(Double_t z, Int_t plane);
0a5f3331 64 virtual Int_t GetSector(Int_t d) const;
afc51ac2 65
f162af62 66 void CreatePadPlaneArray();
67 AliTRDpadPlane *CreatePadPlane(Int_t p, Int_t c);
68 AliTRDpadPlane *GetPadPlane(Int_t p, Int_t c);
625f5260 69 AliTRDpadPlane *GetPadPlane(Int_t det) { return GetPadPlane(GetPlane(det)
70 ,GetChamber(det)); }
71 Int_t GetRowMax(Int_t p, Int_t c, Int_t /*s*/);
f162af62 72 Int_t GetColMax(Int_t p);
73 Double_t GetRow0(Int_t p, Int_t c, Int_t /*s*/);
74 Double_t GetCol0(Int_t p);
75
ecf39416 76 // Translation from MCM to Pad and vice versa (these functions are now in feeParam)
77 //virtual Int_t GetPadRowFromMCM(Int_t irob, Int_t imcm) const;
78 //virtual Int_t GetPadColFromADC(Int_t irob, Int_t imcm, Int_t iadc) const;
79 //virtual Int_t GetMCMfromPad(Int_t irow, Int_t icol) const;
80 //virtual Int_t GetROBfromPad(Int_t irow, Int_t icol) const;
81 //virtual Int_t GetRobSide(Int_t irob) const;
82 //virtual Int_t GetColSide(Int_t icol) const;
7925de54 83
030b4415 84 static Float_t GetTime0(Int_t p) { return fgkTime0[p]; }
0a770ac9 85
030b4415 86 Char_t GetSMstatus(Int_t sm) const { return fSMstatus[sm]; }
87 Float_t GetChamberWidth(Int_t p) const { return fCwidth[p]; }
88 Float_t GetChamberLength(Int_t p, Int_t c) const { return fClength[p][c]; }
f7336fa3 89
25ca55ce 90 virtual void GetGlobal(const AliRecPoint*, TVector3&, TMatrixF& ) const { };
91 virtual void GetGlobal(const AliRecPoint*, TVector3& ) const { };
9a96f175 92
030b4415 93 static Double_t GetAlpha() { return 2.0
94 * 3.14159265358979324
95 / fgkNsect; }
96
97 static Int_t Nsect() { return fgkNsect; }
98 static Int_t Nplan() { return fgkNplan; }
99 static Int_t Ncham() { return fgkNcham; }
100 static Int_t Ndet() { return fgkNdet; }
101
030b4415 102 static Float_t Cheight() { return fgkCH; }
103 static Float_t Cspace() { return fgkVspace; }
104 static Float_t CraHght() { return fgkCraH; }
105 static Float_t CdrHght() { return fgkCdrH; }
106 static Float_t CamHght() { return fgkCamH; }
107 static Float_t CroHght() { return fgkCroH; }
108 static Float_t CroWid() { return fgkCroW; }
109 static Float_t MyThick() { return fgkMyThick; }
110 static Float_t DrThick() { return fgkDrThick; }
111 static Float_t AmThick() { return fgkAmThick; }
112 static Float_t DrZpos() { return fgkDrZpos; }
113 static Float_t RpadW() { return fgkRpadW; }
114 static Float_t CpadW() { return fgkCpadW; }
115
116 static Float_t Cwidcha() { return (fgkSwidth2 - fgkSwidth1)
117 / fgkSheight
118 * (fgkCH + fgkVspace); }
119
7925de54 120 static Int_t MCMmax() { return fgkMCMmax; }
121 static Int_t MCMrow() { return fgkMCMrow; }
122 static Int_t ROBmaxC0() { return fgkROBmaxC0; }
123 static Int_t ROBmaxC1() { return fgkROBmaxC1; }
124 static Int_t ADCmax() { return fgkADCmax; }
125 static Int_t TBmax() { return fgkTBmax; }
126 static Int_t Padmax() { return fgkPadmax; }
127 static Int_t Colmax() { return fgkColmax; }
128 static Int_t RowmaxC0() { return fgkRowmaxC0; }
129 static Int_t RowmaxC1() { return fgkRowmaxC1; }
130
793ff80c 131 protected:
0a5f3331 132
030b4415 133 static const Int_t fgkNsect; // Number of sectors in the full detector (18)
134 static const Int_t fgkNplan; // Number of planes of the TRD (6)
135 static const Int_t fgkNcham; // Number of chambers in z-direction (5)
136 static const Int_t fgkNdet; // Total number of detectors (18 * 6 * 5 = 540)
137
b640260a 138 static const Float_t fgkTlength; // Length of the TRD-volume in spaceframe (BTRD)
139
140 static const Float_t fgkSheight; // Height of the supermodule
141 static const Float_t fgkSwidth1; // Lower width of the supermodule
142 static const Float_t fgkSwidth2; // Upper width of the supermodule
143 static const Float_t fgkSlength; // Length of the supermodule
144
145 static const Float_t fgkFlength; // Length of the service space in front of a supermodule
030b4415 146
147 static const Float_t fgkSMpltT; // Thickness of the super module side plates
148
149 static const Float_t fgkCraH; // Height of the radiator part of the chambers
150 static const Float_t fgkCdrH; // Height of the drift region of the chambers
151 static const Float_t fgkCamH; // Height of the amplification region of the chambers
152 static const Float_t fgkCroH; // Height of the readout of the chambers
153 static const Float_t fgkCH; // Total height of the chambers
154
155 static const Float_t fgkVspace; // Vertical spacing of the chambers
156 static const Float_t fgkHspace; // Horizontal spacing of the chambers
157 static const Float_t fgkVrocsm; // Radial distance of the first ROC to the outer SM plates
158 static const Float_t fgkCalT; // Thickness of the lower aluminum frame
0a5f3331 159 static const Float_t fgkCalW; // Width of additional aluminum on lower frame
160 static const Float_t fgkCclsT; // Thickness of the lower Wacosit frame sides
161 static const Float_t fgkCclfT; // Thickness of the lower Wacosit frame front
162 static const Float_t fgkCglT; // Thichness of the glue around the radiator
163 static const Float_t fgkCcuT; // Thickness of the upper Wacosit frame
164 static const Float_t fgkCauT; // Thickness of the aluminum frame of the back panel
030b4415 165
166 static const Float_t fgkCroW; // Additional width of the readout chamber frames
167
168 static const Float_t fgkCpadW; // Difference of outer chamber width and pad plane width
169 static const Float_t fgkRpadW; // Difference of outer chamber width and pad plane width
170
030b4415 171 static const Float_t fgkMyThick; // Thickness of the mylar-layer
0a5f3331 172 static const Float_t fgkRaThick; // Thickness of the radiator
030b4415 173 static const Float_t fgkXeThick; // Thickness of the gas volume
174 static const Float_t fgkDrThick; // Thickness of the drift region
175 static const Float_t fgkAmThick; // Thickness of the amplification region
0a5f3331 176 static const Float_t fgkWrThick; // Thickness of the wire planes
030b4415 177 static const Float_t fgkCuThick; // Thickness of the pad plane
0a5f3331 178 static const Float_t fgkGlThick; // Thickness of the glue layer
179 static const Float_t fgkSuThick; // Thickness of the NOMEX support structure
030b4415 180 static const Float_t fgkRpThick; // Thickness of the PCB readout boards
181 static const Float_t fgkRcThick; // Thickness of the PCB copper layers
0a5f3331 182 static const Float_t fgkRoThick; // Thickness of all other ROB componentes (caps, etc.)
030b4415 183
184 static const Float_t fgkRaZpos; // Position of the radiator
030b4415 185 static const Float_t fgkDrZpos; // Position of the drift region
186 static const Float_t fgkAmZpos; // Position of the amplification region
0a5f3331 187 static const Float_t fgkWrZpos; // Position of the wire planes
030b4415 188 static const Float_t fgkCuZpos; // Position of the pad plane
0a5f3331 189 static const Float_t fgkGlZpos; // Position of the glue layer
030b4415 190 static const Float_t fgkSuZpos; // Position of the HEXCEL+G10 support structure
030b4415 191 static const Float_t fgkRpZpos; // Position of the PCB readout boards
192 static const Float_t fgkRcZpos; // Position of the PCB copper layers
0a5f3331 193 static const Float_t fgkRoZpos; // Position of all other ROB componentes (caps, etc.)
030b4415 194
7925de54 195 static const Int_t fgkMCMmax; // Maximum number of MCMs per ROB
196 static const Int_t fgkMCMrow; // Maximum number of MCMs per ROB Row
197 static const Int_t fgkROBmaxC0; // Maximum number of ROBs per C0 chamber
198 static const Int_t fgkROBmaxC1; // Maximum number of ROBs per C1 chamber
199 static const Int_t fgkADCmax; // Maximum number of ADC channels per MCM
200 static const Int_t fgkTBmax; // Maximum number of Time bins
201 static const Int_t fgkPadmax; // Maximum number of pads per MCM
202 static const Int_t fgkColmax; // Maximum number of pads per padplane row
203 static const Int_t fgkRowmaxC0; // Maximum number of Rows per C0 chamber
204 static const Int_t fgkRowmaxC1; // Maximum number of Rows per C1 chamber
205
030b4415 206 Char_t fSMstatus[kNsect]; // Super module status byte
207
208 Float_t fCwidth[kNplan]; // Outer widths of the chambers
209 Float_t fClength[kNplan][kNcham]; // Outer lengths of the chambers
210
030b4415 211 Float_t fRotB11[kNsect]; // Matrix elements for the backward rotation
212 Float_t fRotB12[kNsect]; // Matrix elements for the backward rotation
213 Float_t fRotB21[kNsect]; // Matrix elements for the backward rotation
214 Float_t fRotB22[kNsect]; // Matrix elements for the backward rotation
215
216 static const Double_t fgkTime0Base; // Base value for calculation of Time-position of pad 0
217 static const Float_t fgkTime0[kNplan]; // Time-position of pad 0
3551db50 218
030b4415 219 Float_t fChamberUAorig[3*kNdets][3]; // Volumes origin in
220 Float_t fChamberUDorig[3*kNdets][3]; // the chamber
221 Float_t fChamberUForig[3*kNdets][3]; // [3] = x, y, z
2745a409 222 Float_t fChamberUUorig[3*kNdets][3]; //
9c782af4 223
030b4415 224 Float_t fChamberUAboxd[3*kNdets][3]; // Volumes box
225 Float_t fChamberUDboxd[3*kNdets][3]; // dimensions (half)
226 Float_t fChamberUFboxd[3*kNdets][3]; // [3] = x, y, z
2745a409 227 Float_t fChamberUUboxd[3*kNdets][3]; //
bd0f8685 228
9a96f175 229 TObjArray *fClusterMatrixArray; //! Transformation matrices loc. cluster to tracking cs
f162af62 230 TObjArray *fPadPlaneArray; //! Array of pad plane objects
231
b640260a 232 ClassDef(AliTRDgeometry,16) // TRD geometry class
f7336fa3 233
234};
235
236#endif