]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALITOFPIDRESPONSE_H | |
2 | #define ALITOFPIDRESPONSE_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | //------------------------------------------------------- | |
8 | // TOF PID class | |
9 | // Origin: Iouri Belikov, CERN, Jouri.Belikov@cern.ch | |
10 | //------------------------------------------------------- | |
11 | ||
12 | #include "TObject.h" | |
13 | #include "AliPID.h" | |
14 | ||
15 | class AliTOFPIDResponse : public TObject { | |
16 | public: | |
17 | ||
18 | AliTOFPIDResponse(); | |
19 | AliTOFPIDResponse(Double_t *param); | |
20 | ~AliTOFPIDResponse(){} | |
21 | ||
22 | void SetTimeResolution(Float_t res) { fSigma = res; } | |
23 | void SetTimeZero(Double_t t0) { fTime0=t0; } | |
24 | Double_t GetTimeZero() const { return fTime0; } | |
25 | ||
26 | void SetMaxMismatchProbability(Double_t p) {fPmax=p;} | |
27 | Double_t GetMaxMismatchProbability() const {return fPmax;} | |
28 | ||
29 | Double_t GetExpectedSigma(Float_t mom, Float_t tof, Float_t mass) const; | |
30 | ||
31 | ||
32 | Double_t GetMismatchProbability(Double_t p,Double_t mass) const; | |
33 | ||
34 | void SetT0event(Float_t *t0event){for(Int_t i=0;i < fNmomBins;i++) fT0event[i] = t0event[i];}; | |
35 | void SetT0resolution(Float_t *t0resolution){for(Int_t i=0;i < fNmomBins;i++) fT0resolution[i] = t0resolution[i];}; | |
36 | void ResetT0info(){ for(Int_t i=0;i < fNmomBins;i++){ fT0event[i] = 0.0; fT0resolution[i] = 0.0;} }; | |
37 | void SetMomBoundary(); | |
38 | Int_t GetMomBin(Float_t p) const; | |
39 | Int_t GetNmomBins(){return fNmomBins;}; | |
40 | Float_t GetMinMom(Int_t ibin) const {if(ibin >=0 && ibin <= fNmomBins) return fPCutMin[ibin]; else return 0.0;}; | |
41 | Float_t GetMaxMom(Int_t ibin)const {if(ibin >=0 && ibin <= fNmomBins) return fPCutMin[ibin+1]; else return 0.0;}; | |
42 | void SetT0bin(Int_t ibin,Float_t t0bin){if(ibin >=0 && ibin <= fNmomBins) fT0event[ibin] = t0bin;}; | |
43 | void SetT0binRes(Int_t ibin,Float_t t0binRes){if(ibin >=0 && ibin <= fNmomBins) fT0resolution[ibin] = t0binRes;}; | |
44 | Float_t GetT0bin(Int_t ibin) const {if(ibin >=0 && ibin <= fNmomBins) return fT0event[ibin]; else return 0.0;}; | |
45 | Float_t GetT0binRes(Int_t ibin) const {if(ibin >=0 && ibin <= fNmomBins) return fT0resolution[ibin]; else return 0.0;}; | |
46 | ||
47 | // Get Start Time for a track | |
48 | Float_t GetStartTime(Float_t mom); | |
49 | Float_t GetStartTimeRes(Float_t mom); | |
50 | ||
51 | private: | |
52 | Double_t fSigma; // intrinsic TOF resolution | |
53 | ||
54 | // obsolete | |
55 | Double_t fPmax; // "maximal" probability of mismathing (at ~0.5 GeV/c) | |
56 | Double_t fTime0; // time zero | |
57 | //-------------- | |
58 | ||
59 | // About event time (t0) info | |
60 | static const Int_t fNmomBins = 10; // number of momentum bin | |
61 | Float_t fT0event[fNmomBins]; // t0 (best, T0, T0-TOF, ...) of the event as a function of p | |
62 | Float_t fT0resolution[fNmomBins]; // t0 (best, T0, T0-TOF, ...) resolution as a function of p | |
63 | Float_t fPCutMin[fNmomBins+1]; // min values for p bins | |
64 | ||
65 | ClassDef(AliTOFPIDResponse,2) // TOF PID class | |
66 | }; | |
67 | ||
68 | #endif |