]> git.uio.no Git - u/mrichter/AliRoot.git/blame - RICH/AliRICHRecon.h
New Geom, support for ESD- major change
[u/mrichter/AliRoot.git] / RICH / AliRICHRecon.h
CommitLineData
5cb4dfc3 1#ifndef AliRICHRecon_h
2#define AliRICHRecon_h
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
88dd9ad4 7//////////////////////////////////////////////////////////////////////////
8// //
9// AliRICHRecon //
10// //
11// RICH class to perfom pattern recognition based on Hough transfrom //
12// //
13//////////////////////////////////////////////////////////////////////////
14
15
5cb4dfc3 16#include <TTask.h>
5cb4dfc3 17
998b831f 18class AliRICHHelix;
b068561d 19
20class AliRICHRecon : public TTask
21{
22public :
998b831f 23 AliRICHRecon(AliRICHHelix *pHelix,TClonesArray *pClusters,Int_t iMipId);
24 virtual ~AliRICHRecon(){;}
5cb4dfc3 25
998b831f 26 Double_t ThetaCerenkov(); // it returns reconstructed Theta Cerenkov
88dd9ad4 27 void FindThetaPhotonCerenkov(); //
28 void FindAreaAndPortionOfRing(); //
29 void FindEmissionPoint(); //
30 void FindPhotonAnglesInDRS(); //
31 void FindPhiPoint(); //
32 void FindThetaAtQuartz(Float_t ThetaCer); //
33 void HoughResponse(); //
34 void HoughFiltering(float HCS[]); //
35 void FlagPhotons(); //
36 void FindWeightThetaCerenkov(); //
37 void EstimationOfTheta(); //
38 void FindIntersectionWithDetector(); //
88dd9ad4 39 Float_t Cerenkovangle(Float_t n, Float_t b);//
88dd9ad4 40 Int_t PhotonInBand(); //
88dd9ad4 41 Int_t CheckDetectorAcceptance() const; //
42 Int_t GetFittedHoughPhotons() const{ return fFittedHoughPhotons;} //
43 Int_t GetPhotonFlag() const{ return fPhotonFlag[fPhotonIndex];} //
44 Int_t GetTrackCharge() const{ return fTrackCharge;} //
45 Int_t GetPhotonsNumber() const{ return fPhotonsNumber;} //
46 Int_t GetPhotonIndex() const{ return fPhotonIndex;} //
47 Int_t GetMipIndex() const{ return fMipIndex;} //
48 Int_t GetTrackIndex() const{ return fTrackIndex;} //
49 Int_t GetCandidatePhotonsNumber() const{ return fCandidatePhotonsNumber;} //
50 Int_t GetHoughPhotons() const{ return fHoughPhotons;} //
88dd9ad4 51 Float_t GetPhotonEnergy() const{ return fPhotonEnergy;} //
52 Float_t GetFreonRefractiveIndex() const{ return fFreonRefractiveIndex;} //
53 Float_t GetQuartzRefractiveIndex() const{ return fQuartzRefractiveIndex;} //
54 Float_t GetGasRefractiveIndex() const{ return fGasRefractiveIndex;} //
88dd9ad4 55 Float_t GetEmissionPoint() const{ return fLengthEmissionPoint;} //
56 Float_t GetMassHypotesis() const{ return fMassHypotesis;} //
57 Float_t GetBetaOfParticle() const{ return fTrackBeta;} //
58 Float_t GetEntranceX() const{ return fXtoentr;} //
59 Float_t GetEntranceY() const{ return fYtoentr;} //
60 Float_t GetThetaCerenkov() const{ return fThetaCerenkov;} //
61 Float_t GetThetaPhotonCerenkov() const{ return fThetaPhotonCerenkov;} //
88dd9ad4 62 Float_t GetTrackTheta() const{ return fTrackTheta;} //
63 Float_t GetTrackPhi() const{ return fTrackPhi;} //
88dd9ad4 64 Float_t GetXPointOnCathode() const{ return fPhotonLimitX;} //
65 Float_t GetYPointOnCathode() const{ return fPhotonLimitY;} //
66 Float_t GetThetaPhotonInDRS() const{ return fThetaPhotonInDRS;} //
67 Float_t GetPhiPhotonInDRS() const{ return fPhiPhotonInDRS;} //
68 Float_t GetThetaPhotonInTRS() const{ return fThetaPhotonInTRS;} //
69 Float_t GetPhiPhotonInTRS() const{ return fPhiPhotonInTRS;} //
70 Float_t GetThetaAtQuartz() const{ return fThetaAtQuartz;} //
71 Float_t GetPhiPoint() const{ return fPhiPoint;} //
72 Float_t GetXCoordOfEmission() const{ return fXEmiss;} //
73 Float_t GetYCoordOfEmission() const{ return fYEmiss;} //
74 Float_t GetXInnerRing() const{ return fXInner;} //
75 Float_t GetYInnerRing() const{ return fYInner;} //
76 Float_t GetRadiusInnerRing() const{ return fInnerRadius;} //
77 Float_t GetXOuterRing() const{ return fXOuter;} //
78 Float_t GetYOuterRing() const{ return fYOuter;} //
79 Float_t GetRadiusOuterRing() const{ return fOuterRadius;} //
80 Float_t GetShiftX() const{ return fShiftX;} //
81 Float_t GetShiftY() const{ return fShiftY;} //
82 Float_t GetDetectorWhereX() const{ return fXcoord;} //
83 Float_t GetDetectorWhereY() const{ return fYcoord;} //
84 Float_t GetIntersectionX() const{ return fIntersectionX;} //
85 Float_t GetIntersectionY() const{ return fIntersectionY;} //
86 Float_t GetThetaOfRing() const{ return fThetaOfRing;} //
87 Float_t GetAreaOfRing() const{ return fAreaOfRing;} //
88 Float_t GetPortionOfRing() const{ return fPortionOfRing;} //
89 Float_t GetHoughArea() const{ return fHoughArea;} //
90 Float_t GetPhotonEta() const{ return fPhotonEta[fPhotonIndex];} //
91 Float_t GetPhotonWeight() const{ return fPhotonWeight[fPhotonIndex];} //
92 Float_t GetHoughRMS() const{ return fHoughRMS;} //
88dd9ad4 93 Float_t GetFittedTrackTheta() const{ return fFittedTrackTheta;} //
94 Float_t GetFittedTrackPhi() const{ return fFittedTrackPhi;} //
95 Float_t GetFittedThetaCerenkov() const{ return fFittedThetaCerenkov;} //
96 Float_t GetEstimationOfTheta() const{ return fEstimationOfTheta;} //
97 Float_t GetEstimationOfThetaRMS() const{ return fEstimationOfThetaRMS;} //
88dd9ad4 98 void SetPhotonEnergy(Float_t PhotonEnergy) { fPhotonEnergy = PhotonEnergy;} //
99 void SetFreonRefractiveIndex() {fFreonRefractiveIndex = fFreonScaleFactor*(1.177+0.0172*fPhotonEnergy);}//
100 void SetQuartzRefractiveIndex() {fQuartzRefractiveIndex = sqrt(1+(46.411/(113.763556-TMath::Power(fPhotonEnergy,2)))+(228.71/(328.51563-TMath::Power(fPhotonEnergy,2))));}//
101 void SetGasRefractiveIndex() { fGasRefractiveIndex = 1.;} //
102 void SetFreonScaleFactor(Float_t FreonScaleFactor) {fFreonScaleFactor = FreonScaleFactor;} //
103 void SetEmissionPoint(Float_t LengthEmissionPoint) { fLengthEmissionPoint = LengthEmissionPoint;} //
88dd9ad4 104 void SetEntranceX(Float_t Xtoentr) { fXtoentr = Xtoentr;} //
105 void SetEntranceY(Float_t Ytoentr) { fYtoentr = Ytoentr;} //
106 void SetThetaPhotonInTRS(Float_t Theta) {fThetaPhotonInTRS = Theta;} //
107 void SetPhiPhotonInTRS(Float_t Phi) {fPhiPhotonInTRS = Phi;} //
108 void SetThetaPhotonInDRS(Float_t Theta) {fThetaPhotonInDRS = Theta;} //
109 void SetPhiPhotonInDRS(Float_t Phi) {fPhiPhotonInDRS = Phi;} //
110 void SetThetaAtQuartz(Float_t ThetaAtQuartz) {fThetaAtQuartz = ThetaAtQuartz;} //
111 void SetPhiPoint(Float_t PhiPoint){ fPhiPoint = PhiPoint;} //
112 void SetXCoordOfEmission(Float_t XEmiss) {fXEmiss = XEmiss;} //
113 void SetYCoordOfEmission(Float_t YEmiss) {fYEmiss = YEmiss;} //
114 void SetXPointOnCathode(Float_t PhotonLimitX) { fPhotonLimitX = PhotonLimitX;} //
115 void SetYPointOnCathode(Float_t PhotonLimitY) { fPhotonLimitY = PhotonLimitY;} //
116 void SetXInnerRing(Float_t XInner) {fXInner = XInner;} //
117 void SetYInnerRing(Float_t YInner) {fYInner = YInner;} //
118 void SetRadiusInnerRing(Float_t InnerRadius) {fInnerRadius = InnerRadius;} //
119 void SetXOuterRing(Float_t XOuter) {fXOuter = XOuter;} //
120 void SetYOuterRing(Float_t YOuter) {fYOuter = YOuter;} //
121 void SetRadiusOuterRing(Float_t OuterRadius) {fOuterRadius = OuterRadius;} //
122 void SetThetaCerenkov(Float_t ThetaCer) {fThetaCerenkov = ThetaCer;} //
123 void SetThetaPhotonCerenkov(Float_t ThetaPhotCer) {fThetaPhotonCerenkov = ThetaPhotCer;} //
88dd9ad4 124 void SetTrackTheta(Float_t TrackTheta) { fTrackTheta = TrackTheta;} //
125 void SetTrackPhi(Float_t TrackPhi) { fTrackPhi = TrackPhi;} //
88dd9ad4 126 void SetTrackCharge(Int_t TrackCharge) { fTrackCharge = TrackCharge;} //
88dd9ad4 127 void SetShiftX(Float_t ShiftX) { fShiftX = ShiftX;} //
128 void SetShiftY(Float_t ShiftY) { fShiftY = ShiftY;} //
129 void SetDetectorWhereX(Float_t Xcoord) { fXcoord = Xcoord;} //
130 void SetDetectorWhereY(Float_t Ycoord) { fYcoord = Ycoord;} //
131 void SetIntersectionX(Float_t IntersectionX) { fIntersectionX = IntersectionX;} //
132 void SetIntersectionY(Float_t IntersectionY) { fIntersectionY = IntersectionY;} //
133 void SetThetaOfRing(Float_t ThetaOfRing) { fThetaOfRing = ThetaOfRing;} //
134 void SetAreaOfRing(Float_t AreaOfRing) { fAreaOfRing = AreaOfRing;} //
135 void SetPortionOfRing(Float_t PortionOfRing) { fPortionOfRing = PortionOfRing;} //
136 void SetHoughArea(Float_t HoughArea) { fHoughArea = HoughArea;} //
137 void SetPhotonsNumber(Int_t PhotonsNumber) { fPhotonsNumber = PhotonsNumber;} //
138 void SetPhotonIndex(Int_t PhotonIndex) { fPhotonIndex = PhotonIndex;} //
139 void SetPhotonEta(Float_t PhotonEta) { fPhotonEta[fPhotonIndex] = PhotonEta;} //
140 void SetPhotonFlag(Int_t PhotonFlag) { fPhotonFlag[fPhotonIndex] = PhotonFlag;} //
141 void SetPhotonWeight(Float_t PhotonWeight) { fPhotonWeight[fPhotonIndex] = PhotonWeight;} //
142 void SetHoughRMS(Float_t HoughRMS) { fHoughRMS = HoughRMS;} //
143 void SetMipIndex(Int_t MipIndex) { fMipIndex = MipIndex;} //
144 void SetTrackIndex(Int_t TrackIndex) { fTrackIndex = TrackIndex;} //
88dd9ad4 145 void SetHoughPhotons(Int_t HoughPhotons) { fHoughPhotons = HoughPhotons;} //
146 void SetHoughPhotonsNorm(Float_t HoughPhotonsNorm) { fHoughPhotonsNorm = HoughPhotonsNorm;} //
147 void SetFittedTrackTheta(Float_t FittedTrackTheta) { fFittedTrackTheta = FittedTrackTheta;} //
148 void SetFittedTrackPhi(Float_t FittedTrackPhi) { fFittedTrackPhi = FittedTrackPhi;} //
149 void SetFittedThetaCerenkov(Float_t FittedThetaCerenkov) { fFittedThetaCerenkov = FittedThetaCerenkov;}//
150 void SetFittedHoughPhotons(Int_t FittedHoughPhotons) { fFittedHoughPhotons = FittedHoughPhotons;} //
151 void SetEstimationOfTheta(Float_t EstimationOfTheta) { fEstimationOfTheta = EstimationOfTheta;} //
152 void SetEstimationOfThetaRMS(Float_t EstimationOfThetaRMS) { fEstimationOfThetaRMS = EstimationOfThetaRMS;}//
153 void FindBetaFromTheta(Float_t ThetaCerenkov) {fTrackBeta = 1/(fFreonRefractiveIndex*cos(ThetaCerenkov));}//
154 Float_t SnellAngle(Float_t n1, Float_t n2, Float_t theta1); //
155 Float_t FromEmissionToCathode(); //
156
b068561d 157protected:
998b831f 158 TClonesArray *fpClusters; // poiter to clusters
88dd9ad4 159 Int_t fTrackCharge; // charge track
160 Int_t fMipIndex; // index for Mip
161 Int_t fTrackIndex; // index for track
162 Int_t fPhotonsNumber; // Number of photons candidate
163 Int_t fPhotonIndex; // index of photons
164 Int_t fPhotonFlag[3000]; // flag for photons
165 Int_t fCandidatePhotonsNumber; // number of candidate photons
166 Int_t fHoughPhotons; // n. photons after Hough
167 Int_t fFittedHoughPhotons; // n. photons after Hough and after minimization
998b831f 168
88dd9ad4 169 Float_t fTrackTheta; // Theta of track at RICH
170 Float_t fTrackPhi; // Phi of track at RICH
88dd9ad4 171 Float_t fMinDist; // min distance between extrapolated track and MIP
172 Float_t fTrackBeta; // beta of the track
173 Float_t fXtoentr; // X entrance to RICH
174 Float_t fYtoentr; // Y entrance to RICH
175 Float_t fThetaPhotonInTRS; // Theta of photon in the Track Reference System (TRS)
176 Float_t fPhiPhotonInTRS; // Phi of photon in TRS
177 Float_t fThetaPhotonInDRS; // Theta of photon in Detector Reference System (DRS)
178 Float_t fPhiPhotonInDRS; // Phi of photon in DRS
179 Float_t fThetaAtQuartz; // Theta at the quartz entrance
180 Float_t fPhiPoint; // phi of ring point
181 Float_t fXEmiss; // x emission
182 Float_t fYEmiss; // y emission
183 Float_t fXInner; // X inner ring
184 Float_t fYInner; // Y inner ring
185 Float_t fXOuter; // X outer ring
186 Float_t fYOuter; // Y outer ring
187 Float_t fInnerRadius; // inner radius
188 Float_t fOuterRadius; // outer radius
189 Float_t fPhotonEnergy; // photon energy
190 Float_t fFreonRefractiveIndex; // n freon
191 Float_t fQuartzRefractiveIndex; // n quartz
192 Float_t fGasRefractiveIndex; // n gas
193 Float_t fFreonScaleFactor; // scale factor for n freon
194 Float_t fLengthEmissionPoint; // lenght of emmission point
195 Float_t fPhotonLimitX; // X phys limit for photon
196 Float_t fPhotonLimitY; // Y phys limit for photon
197 Float_t fDistanceFromCluster; // distance from cluster
88dd9ad4 198 Float_t fCerenkovAnglePad; // cherenkov angle of pad
199 Float_t fThetaPhotonCerenkov; // theta cerenkov for photon
200 Float_t fShiftX; // x shift to entrance in radiator
201 Float_t fShiftY; // y shift to entrance in radiator
202 Float_t fXcoord; // ..
203 Float_t fYcoord; // ..
204 Float_t fIntersectionX; // ..
205 Float_t fIntersectionY; // ..
998b831f 206 Float_t fMassHypotesis; //
88dd9ad4 207 Float_t fThetaOfRing; // theta of ring
208 Float_t fAreaOfRing; // area of the ring
209 Float_t fPortionOfRing; // fraction of the accepted ring
210 Float_t fHoughArea; // area Hough
211 Float_t fPhotonEta[3000]; // theta cerenkov of photon candidates
212 Float_t fPhotonWeight[3000]; // weigth
213 Float_t fHoughRMS; // rms Hough
214 Float_t* fCandidatePhotonX; // x photon candidates
215 Float_t* fCandidatePhotonY; // y photon candidates
216 Float_t fHoughPhotonsNorm; // n. photons norm.
217 Float_t fFittedTrackTheta; // theta track after minim.
218 Float_t fFittedTrackPhi; // phi track after minim.
219 Float_t fFittedThetaCerenkov; // thetacerenkov after minim.
220 Float_t fEstimationOfTheta; // theta estimate
221 Float_t fEstimationOfThetaRMS; // theta RMS
222 Int_t fThetaBin; // bin in theta
223 Float_t fThetaMin,fThetaMax; // min max
224 Float_t fXmin,fXmax,fYmin,fYmax; // xy min max
88dd9ad4 225 Int_t fNrings; //current number of reconstructed rings
88dd9ad4 226 Bool_t fIsWEIGHT; // flag to consider weight procedure
227 Bool_t fIsBACKGROUND; // flag to simulate bkg
88dd9ad4 228 Float_t fRadiatorWidth; // radiator width
229 Float_t fQuartzWidth; // quartz width
230 Float_t fGapWidth; // gap width
231 Float_t fDTheta; // Step for sliding window
232 Float_t fWindowWidth; // Hough width of sliding window
233
234 Int_t fNumEtaPhotons; // Number of photons
235 Int_t fEtaFlag[3000]; // flag for good photons
236 Float_t fEtaPhotons[3000]; // Cerenkov angle each photon
237 Float_t fWeightPhotons[3000]; // weight for each photon
238 Float_t fThetaCerenkov; // Theta angle for Hough
239 Float_t fWeightThetaCerenkov; // Theta Cerenkov angle weighted
240 Float_t fThetaPeakPos; // Peak position
241
242
b068561d 243 ClassDef(AliRICHRecon,0)
5cb4dfc3 244};
245
246#endif // #ifdef AliRICHRecon_cxx
247