Updated MUONRawStreamTrackerErrorCount function
[u/mrichter/AliRoot.git] / HMPID / AliHMPIDRecon.h
d3da6dc4 1#ifndef AliHMPIDRecon_h
2#define AliHMPIDRecon_h
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
8// //
9// AliHMPIDRecon //
10// //
11// HMPID class to perfom pattern recognition based on Hough transfrom //
12// //
f21fc003 16#include <TNamed.h> //base class
d3da6dc4 17#include <TVector3.h> //fields
59280a5a 19class TClonesArray; //CkovAngle()
20class AliESDtrack; //CkovAngle()
ffb1ac19 21class AliHMPIDParam;//general pourpose
59280a5a 22
f21fc003 23class AliHMPIDRecon : public TNamed
d3da6dc4 24{
25public :
26 AliHMPIDRecon();
ffb1ac19 27 virtual ~AliHMPIDRecon() {;} //dtor
611e810d 28
ffb1ac19 29 void InitVars (Int_t n); //init space for variables
496c71b0 30 void DeleteVars ()const; //delete variables
97a4d538 31 void CkovAngle (AliESDtrack *pTrk,TClonesArray *pCluLst,Int_t index,Double_t nmean,Float_t xRa,Float_t yRa );//reconstructed Theta Cerenkov
a591e55f 32 Bool_t FindPhotCkov (Double_t cluX,Double_t cluY,Double_t &thetaCer,Double_t &phiCer ); //find ckov angle for single photon candidate
d3da6dc4 33 Double_t FindRingCkov (Int_t iNclus ); //best ckov for ring formed by found photon candidates
2d1a9b21 34 void FindRingGeom (Double_t ckovAng,Int_t level=1 ); //estimated area of ring in cm^2 and portion accepted by geometry
4598109f 35 TVector2 IntWithEdge (TVector2 p1,TVector2 p2 )const;//find intercection between plane and lines of 2 thetaC
a85edbf2 36 Int_t FlagPhot (Double_t ckov,TClonesArray *pCluLst,AliESDtrack *pTrk ); //is photon ckov near most probable track ckov
d3da6dc4 37 Double_t HoughResponse( ); //most probable track ckov angle
a591e55f 38 void Propagate (const TVector3 dir, TVector3 &pos,Double_t z )const;//propagate photon alogn the line
d3da6dc4 39 void Refract ( TVector3 &dir, Double_t n1, Double_t n2)const;//refract photon on the boundary
a591e55f 40 TVector2 TracePhot (Double_t ckovTh,Double_t ckovPh )const;//trace photon created by track to PC
90472d9d 41 void AddObjectToFriends(TClonesArray *pCluLst, Int_t photonIndex, AliESDtrack *pTrk ); // Add AliHMPIDCluster object to ESD friends
a591e55f 42 TVector2 TraceForward (TVector3 dirCkov )const;//tracing forward a photon from (x,y) to PC
2d1a9b21 43 void Lors2Trs (TVector3 dirCkov,Double_t &thetaCer,Double_t &phiCer )const;//LORS to TRS
44 void Trs2Lors (TVector3 dirCkov,Double_t &thetaCer,Double_t &phiCer )const;//TRS to LORS
606697a8 45 TVector2 GetMip ( )const
4598109f 46 {return fMipPos;} //mip coordinates
606697a8 47 Double_t GetRingArea ( )const
2d1a9b21 48 {return fRingArea;} //area of the current ring in cm^2
606697a8 49 Double_t GetRingAcc ( )const
2d1a9b21 50 {return fRingAcc;} //portion of the ring ([0,1]) accepted by geometry.To scale n. of photons
0b045c31 51 Double_t FindRingExt (Double_t ckov,Int_t ch,Double_t xPc,Double_t yPc,Double_t thRa,Double_t phRa);//find ring acceptance by external parameters
a591e55f 52 void SetTrack (Double_t xRad,Double_t yRad,Double_t theta,Double_t phi )
53 {fTrkDir.SetMagThetaPhi(1,theta,phi); fTrkPos.Set(xRad,yRad);} //set track parameter at RAD
54 void SetImpPC (Double_t xPc,Double_t yPc )
55 {fPc.Set(xPc,yPc);} //set track impact to PC
4598109f 56 void SetMip (Double_t xmip,Double_t ymip )
ffb1ac19 57 {fMipPos.Set(xmip,ymip);} //set track impact to PC
e26c20fa 58 enum ETrackingFlags {kNotPerformed=-20,kMipDistCut=-9,kMipQdcCut=-5,kNoPhotAccept=-11,kNoRad = -22};
43400d2d 59//
394d35c1 60protected:
ffb1ac19 61 Int_t fPhotCnt; // counter of photons candidate
62 Int_t *fPhotFlag; // flags of photon candidates
5637918c 63 Int_t *fPhotClusIndex; // cluster index of photon candidates
ffb1ac19 64 Double_t *fPhotCkov; // Ckov angles of photon candidates, [rad]
65 Double_t *fPhotPhi; // phis of photons candidates, [rad]
66 Double_t *fPhotWei; // weigths of photon candidates
67 Double_t fCkovSigma2; // sigma2 of the reconstructed ring
d3da6dc4 68
ffb1ac19 69 Bool_t fIsWEIGHT; // flag to consider weight procedure
70 Float_t fDTheta; // Step for sliding window
71 Float_t fWindowWidth; // Hough width of sliding window
2d1a9b21 73 Double_t fRingArea; // area of a given ring
74 Double_t fRingAcc; // fraction of the ring accepted by geometry
75 TVector3 fTrkDir; // track direction in LORS at RAD
76 TVector2 fTrkPos; // track positon in LORS at RAD
77 TVector2 fMipPos; // mip positon for a given track
78 TVector2 fPc; // track position at PC
e0085eed 79
2d1a9b21 80 AliHMPIDParam *fParam; // Pointer to AliHMPIDParam
8f05fd11 81
83 AliHMPIDRecon(const AliHMPIDRecon& r); //dummy copy constructor
84 AliHMPIDRecon &operator=(const AliHMPIDRecon& r); //dummy assignment operator
43400d2d 85//
f21fc003 86 ClassDef(AliHMPIDRecon,3)
d3da6dc4 87};
cf7e313e 88
d3da6dc4 89#endif // #ifdef AliHMPIDRecon_cxx