Updated flags
[u/mrichter/AliRoot.git] / ALIFAST / AliFTrackMaker.h
1 #ifndef AliFTrackMaker_H
2 #define AliFTrackMaker_H
3
4 //////////////////////////////////////////////////////////////////////////
5 //                                                                      //
6 // AliFast TrackMaker class.                                            //
7 //                                                                      //
8 //                                                                      //
9 //////////////////////////////////////////////////////////////////////////
10
11 class TH1D; 
12
13 #include "AliFDet.h"
14 #include "AliFMaker.h"
15
16 class AliFTrack;
17
18 class AliFTrackMaker : public AliFMaker {
19 public:
20                   AliFTrackMaker();
21                   AliFTrackMaker(const char *name, const char *title);
22                   AliFTrackMaker(const AliFTrackMaker &aftmk);
23
24    AliFTrackMaker& operator = (const AliFTrackMaker &aftmk) 
25      {aftmk.Copy(*this); return (*this);}
26
27    virtual       ~AliFTrackMaker();
28    virtual void   Clear(Option_t *option="");
29    virtual void   Draw(Option_t *option="");
30    virtual void   Finish();
31    virtual void   Init();
32    virtual void   Make();
33    virtual void   MakeTest(Int_t n);
34    virtual void   PrintInfo() {}
35    AliFTrack     *AddTrack(Int_t code, Double_t charge, Double_t pT, Double_t eta, Double_t phi,
36                   Double_t v11, Double_t v22, Double_t v33, 
37                   Double_t v12, Double_t v13, Double_t v23, Int_t iFlag);
38            void   LogLikelyhood(Int_t idTrack, Double_t pInvers,  Double_t lambda);
39            void   TPCResolution(Double_t ptransv, Double_t radiPad, Double_t lambda); 
40    Double_t       ParticleMass(Int_t idTrack) const;  
41    Double_t       Rapidity(Double_t pT, Double_t pZ);  
42    Double_t       Angle(Double_t pX, Double_t pY);  
43    Int_t          Charge(Int_t kf);
44    Int_t          Compress(Int_t kf);
45            void   ErrorMatrix(Int_t idTrack, Double_t pT,  Double_t eta,
46                               Double_t &v11, Double_t &v22, Double_t &v33, 
47                               Double_t &v12, Double_t &v13, Double_t &v23, Int_t &iFlag);
48
49 //    Getters
50    Double_t       HH(Int_t id1, Int_t id2) const {return fHH[id1][id2];}
51    Double_t       HHI(Int_t id1, Int_t id2) const {return fHHI[id1][id2];}
52    Double_t       SigmaRPhiSQ() const {return fSigmaRPhiSQ;}
53    Double_t       SigmaZSQ() const {return fSigmaZSQ;}
54    Int_t          NTracks() const {return fNTracks;}
55
56
57 //     Getters Tracks histograms
58
59
60
61 //    Setters for tracks
62    //masses
63    void           SetPionMass(Double_t val=0.1395679e0) {fPionMass=val;}
64    void           SetKaonMass(Double_t val=0.493646e0) {fKaonMass=val;}
65    void           SetElectronMass(Double_t val=0.51099906e-3) {fElectronMass=val;}
66    void           SetProtonMass(Double_t val=0.93827231e0) {fProtonMass=val;}
67    void           SetHH(Int_t id1, Int_t id2, Double_t hh) {fHH[id1][id2]=hh;}
68    void           SetHHI(Int_t id1, Int_t id2, Double_t hhi) {fHHI[id1][id2]=hhi;}
69    void           SetSigmaRPhiSQ(Double_t val){fSigmaRPhiSQ=val;}
70    void           SetSigmaZSQ(Double_t val){fSigmaZSQ=val;}
71    void           SetRecTrack(Int_t val=100){fRecTrack=val;}
72
73 protected:
74    void Copy(TObject &aftmk) const;
75
76    Int_t           fNTracks;          // Number of tracks
77    Int_t           fRecTrack;         // Tracks reconstruction  on/off
78    //masses
79    Double_t        fPionMass;         // Mass of pion
80    Double_t        fKaonMass;         // Mass of kaon
81    Double_t        fElectronMass;     // Mass of electron
82    Double_t        fProtonMass;       // Mass of proton
83    //matrices
84    Double_t        fHH[kNMaxDet2][kNMaxDet2];   // Matrix 
85    Double_t        fHHI[kNMaxDet2][kNMaxDet2];  // Matrix
86    //TPC resolution
87    Double_t        fSigmaRPhiSQ;                // Sigma R-PHI
88    Double_t        fSigmaZSQ;                   // Sigma Z^2
89    //     Tracks histograms (control)
90    TH1D          *fResID11;          //histogram ID11 Elec: delta(1/pTot)/pTot
91    TH1D          *fResID12;          //histogram ID12 Elec: delta(lambda)/lambda
92    TH1D          *fResID13;          //histogram ID13 Elec: delta(phi)/phi
93    TH1D          *fResID21;          //histogram ID21 Pion: delta(1/pTot)/pTot
94    TH1D          *fResID22;          //histogram ID22 Pion: delta(lambda)/lambda
95    TH1D          *fResID23;          //histogram ID23 Pion: delta(phi)/phi
96    TH1D          *fResID31;          //histogram ID31 Kaon: delta(1/pTot)/pTot
97    TH1D          *fResID32;          //histogram ID32 Kaon: delta(lambda)/lambda
98    TH1D          *fResID33;          //histogram ID33 Kaon: delta(phi)/phi
99    TH1D          *fResID41;          //histogram ID41 Proton: delta(1/pTot)/pTot
100    TH1D          *fResID42;          //histogram ID42 Proton: delta(lambda)/lambda
101    TH1D          *fResID43;          //histogram ID43 Proton: delta(phi)/phi
102    //     Tracks histograms (Test job)
103    TH1D          *fResID1Test;       //histogram ID1 in res.f 
104    TH1D          *fResID2Test;       //histogram ID2 in res.f 
105    TH1D          *fResID3Test;       //histogram ID3 in res.f 
106    TH1D          *fResID4Test;       //histogram ID4 in res.f 
107    TH1D          *fResID5Test;       //histogram ID5 in res.f 
108
109    // 
110    ClassDef(AliFTrackMaker, 1)   //AliFast TrackMaker
111 };
112
113 #endif
114
115
116
117
118
119
120
121