]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/AliTPCParam.h
Correct reference to Code Development section
[u/mrichter/AliRoot.git] / TPC / AliTPCParam.h
CommitLineData
8c555625 1#ifndef TPCParam_H
2#define TPCParam_H
3da30618 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8c555625 8////////////////////////////////////////////////
9// Manager class for TPC parameters //
10////////////////////////////////////////////////
8c555625 11
1283eee5 12#include "TObject.h"
13
14// the last things from AliTPCSecGeo
15//const Float_t z_end = 250.;
16//const Float_t alpha_low=0.523598775; // 30 degrees
17//const Float_t alpha_up=0.261799387; // 15 degrees
18//const Float_t q_el = 1.602e-19; // elementary charge
19//const Float_t adc_sat = 1023; // dynamic range (10 bits)
20//const Float_t dyn_range = 2000.; // output dynamic range (mV)
21
22
8c555625 23
24class AliTPCParam : public TObject {
25 //////////////////////////////////////////////////////
26 //////////////////////////////////////////////////////
27 //ALITPCParam object to be possible change
28 //geometry and some other parameters of TPC
29 //used by AliTPC and AliTPCSector
30public:
31 AliTPCParam();
32 virtual ~AliTPCParam() {;} //dummy destructor
33
34 void XYZtoCRXYZ(Float_t *xyz,
35 Int_t &sector, Int_t &padrow, Int_t option=3);
36 //transform global position to the position relative to the sector padrow
37 //if option=0 X calculate absolute calculate sector
38 //if option=1 X absolute use input sector
39 //if option=2 X relative to pad row calculate sector
40 //if option=3 X relative use input sector
41
42 void CRXYZtoXYZ(Float_t *xyz,
43 const Int_t &sector, const Int_t & padrow, Int_t option=3) const;
44 //transform relative position to the gloabal position
45
46 void CRTimePadtoYZ(Float_t &y, Float_t &z,
47 const Float_t &time, const Float_t &pad,
48 Int_t sector, Int_t padrow );
49 //transform position in digit units (time slices and pads) to "normal"
50 //units (cm)
51 void CRYZtoTimePad(const Float_t &y, const Float_t &z,
52 Float_t &time, Float_t &pad,
53 Int_t sector, Int_t padrow);
54 //transform position in cm to position in digit unit
55 Double_t GetLowMaxY(Int_t irow) const {return irow*0.;}
56 Double_t GetUpMaxY(Int_t irow) const {return irow*0;}
57 //additional geometrical function
58 Int_t GetPadRow(Int_t isec, Float_t &x);
59 //return pad row for given sector and position x
60 //if res=-1 it is out of sector
61
62 Int_t GetWire(Float_t &x);
63 Int_t GetIndex(Int_t sector, Int_t row); //give index of the given sector and pad row
64 Bool_t AdjustSectorRow(Int_t index, Int_t & sector, Int_t &row); //return sector and padrow
65 //for given index
66 Int_t GetNRowsTotal(){return fNtRows;} //get total nuber of rows
67 void SetDefault(); //set defaut TPCparam
68 Bool_t Update(); //recalculate and check geometric parameters
69 Bool_t GetStatus(); //get information about object consistency
70
71
72 void AdjustAngles(Int_t isec, Float_t &cos, Float_t &sin) const;
73 //set cosinus and sinus of rotation angles for sector isec
74 Int_t GetNRowLow() const; //get the number of pad rows in low sector
75 Int_t GetNRowUp() const; //get the number of pad rows in up sector
1283eee5 76 Int_t GetNRow(Int_t isec) {return ((isec<fNInnerSector) ? fnRowLow:fnRowUp);}
8c555625 77 //get the nuber of pad row in given sector
78 Float_t GetPadRowRadiiLow(Int_t irow) const; //get the pad row (irow) radii
79 Float_t GetPadRowRadiiUp(Int_t irow) const; //get the pad row (irow) radii
80 Float_t GetPadRowRadii(Int_t isec,Int_t irow) const {
1283eee5 81 return ( (isec < fNInnerSector) ?GetPadRowRadiiLow(irow):GetPadRowRadiiUp(irow));}
8c555625 82 //retrun raii of the pad row irow in sector i
83 Int_t GetNPadsLow(Int_t irow) const; //get the number of pads in row irow
84 Int_t GetNPadsUp(Int_t irow) const; //get the number of pads in row irow
85 Int_t GetNPads(Int_t isector,Int_t irow){
1283eee5 86 return ( (isector < fNInnerSector) ?GetNPadsLow(irow) : GetNPadsUp(irow));}
8c555625 87 //get the number of pads in given sector and row
88 // Int_t GetNPads(Int_t isector, Int_t irow) const;
89 //get the number of pads in sector isector and row irow
90
91 void SetInnerRadiusLow(Float_t InnerRadiusLow ) { fInnerRadiusLow=InnerRadiusLow;}
92 void SetOuterRadiusLow(Float_t OuterRadiusLow ){ fOuterRadiusLow=OuterRadiusLow;}
93 void SetInnerRadiusUp(Float_t InnerRadiusUp){ fInnerRadiusUp= InnerRadiusUp;}
94 void SetOuterRadiusUp(Float_t OuterRadiusUp){ fOuterRadiusUp= OuterRadiusUp;}
1283eee5 95
96 void SetSectorAngles(Float_t innerangle, Float_t innershift, Float_t outerangle,
97 Float_t outershift,Bool_t inDegree=kTRUE);
98
99 void SetInSecLowEdge(Float_t isle){fInSecLowEdge=isle;}
100 void SetInSecUpEdge(Float_t isue){fInSecUpEdge=isue;}
101 void SetOuSecLowEdge(Float_t osle){fOuSecLowEdge=osle;}
102 void SetOuSecUpEdge(Float_t osue){fOuSecUpEdge=osue;}
103
104 void SetEdge(Float_t edge){fEdge = edge;}
105 void SetDeadZone(Float_t zone){fDeadZone = zone;}
106
8c555625 107
108 void SetPadPitchLength(Float_t PadPitchLength){ fPadPitchLength=PadPitchLength;}
109 void SetPadPitchWidth(Float_t PadPitchWidth){ fPadPitchWidth = PadPitchWidth;}
110 void SetPadLength(Float_t PadLength){ fPadLength=PadLength;}
111 void SetPadWidth(Float_t PadWidth) { fPadWidth=PadWidth;}
112 void SetDiffT(Float_t DiffT){ fDiffT= DiffT;}
113 void SetDiffL(Float_t DiffL){ fDiffL=DiffL;}
114 void SetDriftV(Float_t DriftV){ fDriftV= DriftV;}
115 void SetOmegaTau(Float_t OmegaTau){ fOmegaTau=OmegaTau;}
116 void SetAttCoef(Float_t AttCoef){ fAttCoef=AttCoef;}
117 void SetOxyCont(Float_t OxyCont){ fOxyCont=OxyCont;}
118
119 void SetNoise(Float_t Noise ){ fNoise= Noise;}
120 void SetChipGain(Float_t ChipGain){ fChipGain= ChipGain;}
121 void SetGasGain(Float_t GasGain){ fGasGain=GasGain;}
122 void SetTSample(Float_t TSample){ fTSample=TSample;}
123 void SetTSigma(Float_t Sigma){ fTSigma=Sigma;}
124 void SetPadCoupling(Float_t PadCoupling){ fPadCoupling=PadCoupling;}
125 void SetNWires(Int_t nWires){ fnWires=nWires;}
126 void SetWWPitch(Float_t WWPitch){ fWWPitch=WWPitch;}
127 void SetZeroSup(Int_t ZeroSup){ fZeroSup=ZeroSup;}
128
129 Float_t GetInnerRadiusLow(){return fInnerRadiusLow;}
130 Float_t GetOuterRadiusLow(){return fOuterRadiusLow;}
131 Float_t GetInnerRadiusUp(){return fInnerRadiusUp;}
132 Float_t GetOuterRadiusUp(){return fOuterRadiusUp;}
133
1283eee5 134 Float_t GetInnerAngle(){return fInnerAngle;}
135 Float_t GetInnerAngleShift(){return fInnerAngleShift;}
136 Float_t GetOuterAngle(){return fOuterAngle;}
137 Float_t GetOuterAngleShift(){return fOuterAngleShift;}
138 Int_t GetNInnerSector(){return fNInnerSector;}
139 Int_t GetNOuterSector(){return fNOuterSector;}
140 Int_t GetNSector(){return fNSector;}
141
142 Float_t GetInSecLowEdge(){return fInSecLowEdge;}
143 Float_t GetInSecUpEdge(){return fInSecUpEdge;}
144 Float_t GetOuSecLowEdge(){return fOuSecLowEdge;}
145 Float_t GetOuSecUpEdge(){return fOuSecUpEdge;}
146
147 Float_t GetEdge(){return fEdge;}
148 Float_t GetDeadZone(){return fDeadZone;}
149
8c555625 150 Float_t GetPadPitchLength(){return fPadPitchLength;}
151 Float_t GetPadPitchWidth(){return fPadPitchWidth;}
152 Float_t GetPadLength(){return fPadLength;}
153 Float_t GetPadWidth() {return fPadWidth;}
154 Float_t GetDiffT(){return fDiffT;}
155 Float_t GetDiffL(){return fDiffL;}
156 Float_t GetDriftV(){return fDriftV;}
157 Float_t GetOmegaTau(){return fOmegaTau;}
158 Float_t GetAttCoef(){return fAttCoef;}
159 Float_t GetOxyCont(){return fOxyCont;}
160
161 Float_t GetNoise(){return fNoise;}
162 Float_t GetChipGain(){return fChipGain;}
163 Float_t GetGasGain(){return fGasGain;}
164 Float_t GetTSample(){return fTSample;}
165 Float_t GetTSigma(){return fTSigma;}
166 Float_t GetZWidth(){return fZWidth;}
167 Float_t GetZSigma(){return fTSigma*fDriftV;}
168 Float_t GetPadCoupling(){return fPadCoupling;}
169 Int_t GetNWires(){return fnWires;}
170 Float_t GetWWPitch(){return fWWPitch;}
171 Int_t GetZeroSup(){return fZeroSup;}
1283eee5 172 Int_t GetMaxTBin(){return fMaxTBin;}
8c555625 173
174private :
175 Bool_t fbStatus; //indicates consistency of the data
176 //---------------------------------------------------------------------
177 // ALICE TPC sector geometry
178 //--------------------------------------------------------------------
179
180 Float_t fInnerRadiusLow; // lower radius of inner sector
181 Float_t fOuterRadiusLow; // lower radius of outer sector
182 Float_t fInnerRadiusUp; // upper radius of inner sector
183 Float_t fOuterRadiusUp; // upper radius of outer sector
184
1283eee5 185 Float_t fInnerAngle; //opening angle of Inner sector
186 Float_t fInnerAngleShift; //shift of first inner sector center to the 0
187 Float_t fOuterAngle; //opening angle of outer sector
188 Float_t fOuterAngleShift; //shift of first sector center to the 0
189
190 Int_t fNInnerSector; //!number of inner sectors
191 Int_t fNOuterSector; //!number of outer sectors
192 Int_t fNSector; //! total number of sectors
193
194 Float_t fInSecLowEdge; // inner sector lower edge
195 Float_t fInSecUpEdge; // inner sector upper edge
196 Float_t fOuSecLowEdge; // outer sector lower edge
197 Float_t fOuSecUpEdge; // outer sector upper edge
198
199 Float_t fEdge; // thickness of the sector edge
200 Float_t fDeadZone; // dead zone due to the sector mounting etc.
201
202 //---------------------------------------------------------------------
203 // ALICE TPC pad parameters
204 //--------------------------------------------------------------------
8c555625 205 Float_t fPadPitchLength; //pad pitch length
206 Float_t fPadPitchWidth; //pad pitch width
207 Float_t fPadLength; //pad length
208 Float_t fPadWidth; //pad width
209
210
211 Int_t fnRowLow; // number of pad rows per low sector
212 Int_t fnRowUp; // number of pad rows per sector up
213 Float_t fPadRowLow[600]; // Lower sector, pad row radii
214 Float_t fPadRowUp[600]; // Upper sector, pad row radii
215 Int_t fnPadsLow[600]; // Lower sector, number of pads per row
216 Int_t fnPadsUp[600]; // Upper sector, number of pads per row
217 Float_t fRotAngle[200]; // sin and cos of rotation angles for
218 // diferent sectors
219
220 Int_t fnWires; // Number of wires per pad
221 Float_t fWWPitch; // pitch between wires
222 //---------------------------------------------------------------------
223 // ALICE TPC Gas Parameters
224 //--------------------------------------------------------------------
225 Float_t fDiffT; //tangencial diffusion constant
226 Float_t fDiffL; //longutudinal diffusion constant
227 Float_t fGasGain; //gas gain constant
228 Float_t fDriftV; //drift velocity constant
229 Float_t fOmegaTau; //omega tau ExB coeficient
230 Float_t fAttCoef; //attachment coefitients
231 Float_t fOxyCont; //oxygen content
232 //---------------------------------------------------------------------
233 // ALICE TPC Electronics Parameters
234 //--------------------------------------------------------------------
235 Float_t fPadCoupling; //coupling factor ration of anode signal
236 //and total pads signal
237 Int_t fZeroSup; //zero suppresion constant
238 Float_t fNoise; //noise sigma constant
239 Float_t fChipGain; //preamp shaper constant
240 Float_t fTSample; // sampling time
241 Float_t fZWidth; //derived value calculated using TSample and driftw
242 Float_t fTSigma; // width of the Preamp/Shaper function
1283eee5 243 Int_t fMaxTBin; //maximum time bin number
8c555625 244 //--------------------------------------------------------
245 //
246 Int_t fNtRows; //total number of rows in TPC
247 ClassDef(AliTPCParam,2) //parameter object for set:TPC
248};
249
250
1283eee5 251/////////////////////////////////////////////////////////////////////////////
252//
253//---------------------------------------------------------------------
254// ALICE TPC Cluster Parameters
255//--------------------------------------------------------------------
256//
257//
258// Sigma rphi
259/*const Float_t a_rphi=0.41818e-2;
260const Float_t b_rphi=0.17460e-4;
261const Float_t c_rphi=0.30993e-2;
262const Float_t d_rphi=0.41061e-3;
263// Sigma z
264const Float_t a_z=0.39614e-2;
265const Float_t b_z=0.22443e-4;
266const Float_t c_z=0.51504e-1;
267// Cluster width in rphi
268const Float_t ac_rphi=0.18322;
269const Float_t bc_rphi=0.59551e-3;
270const Float_t cc_rphi=0.60952e-1;
271// Cluster width in z
272const Float_t ac_z=0.19081;
273const Float_t bc_z=0.55938e-3;
274const Float_t cc_z=0.30428;
275*/
8c555625 276
277
278
279#endif