]>
Commit | Line | Data |
---|---|---|
720a0a16 | 1 | #ifndef ALITRDCALPID_H |
2 | #define ALITRDCALPID_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
8 | /////////////////////////////////////////////////////////////////////////////// | |
9 | // // | |
10 | // Container for the distributions of dE/dx and the time bin of the // | |
11 | // max. cluster for electrons and pions // | |
12 | // // | |
13 | // Authors: // | |
14 | // Prashant Shukla <shukla@pi0.physi.uni-heidelberg.de> // | |
15 | // Alex Bercuci <A.Bercuci@gsi.de> // | |
16 | // // | |
17 | /////////////////////////////////////////////////////////////////////////////// | |
18 | ||
19 | #ifndef ROOT_TNamed | |
20 | #include <TNamed.h> | |
21 | #endif | |
22 | ||
23 | class TH1; | |
24 | class TObjArray; | |
25 | class AliTRDCalPID : public TNamed { | |
26 | public: | |
27 | enum { | |
28 | kNMom = 11, | |
29 | kNLength = 4 | |
30 | }; | |
31 | ||
32 | AliTRDCalPID(); | |
33 | AliTRDCalPID(const Text_t *name, const Text_t *title); | |
34 | AliTRDCalPID(const AliTRDCalPID& pd); | |
35 | virtual ~AliTRDCalPID(); | |
36 | AliTRDCalPID& operator=(const AliTRDCalPID &c); | |
37 | virtual void Copy(TObject &c) const; | |
38 | ||
39 | Bool_t LoadLQReferences(Char_t* refFile); | |
40 | Bool_t LoadNNReferences(Char_t* /*refFile*/) {return kTRUE;} | |
41 | //void SetMeanChargeRatio(Double_t ratio) { fMeanChargeRatio = ratio; } | |
42 | ||
43 | //Double_t GetMeanChargeRatio() const { return fMeanChargeRatio; } | |
44 | static Double_t GetMomentum(Int_t ip) { return (ip<0 || ip>=kNMom) ? -1. : fTrackMomentum[ip]; } | |
45 | static Double_t GetLength(Int_t il) { return (il<0 || il>=kNLength) ? -1. : fTrackSegLength[il]; } | |
46 | //Double_t GetMean(Int_t iType, Int_t ip) const; | |
47 | //Double_t GetNormalization(Int_t iType, Int_t ip) const; | |
48 | ||
49 | TH1* GetHistogram(Int_t iType, Int_t ip/*, Int_t il*/) const; | |
50 | TH1* GetHistogramT(Int_t iType, Int_t ip) const; | |
51 | Double_t GetProbability(Int_t spec, Float_t mom, Float_t *dedx, Float_t length) const; | |
52 | Double_t GetProbabilityT(Int_t spec, Double_t mom, Int_t timbin) const; | |
53 | ||
54 | protected: | |
55 | ||
56 | void Init(); | |
57 | inline Int_t GetHistID(Int_t part, Int_t mom/*, Int_t length=0*/) const { return part*kNMom + mom; } | |
58 | void CleanUp(); | |
59 | ||
60 | public: | |
61 | static Char_t *fpartName[5]; //! Names of particle species | |
62 | static Char_t *fpartSymb[5]; //! Symbols of particle species | |
63 | ||
64 | protected: | |
65 | static Float_t fTrackMomentum[kNMom]; // Track momenta for which response functions are available | |
66 | static Float_t fTrackSegLength[kNLength]; // Track segment lengths for which response functions are available | |
67 | Double_t fMeanChargeRatio; // Ratio of mean charge from real Det. to prob. dist. | |
68 | TObjArray *fHistdEdx; // Prob. of dEdx for 5 particles and for several momenta | |
69 | TObjArray *fHistTimeBin; // Prob. of max time bin for 5 particles and for several momenta | |
70 | ||
71 | ||
72 | ClassDef(AliTRDCalPID, 1) // The TRD PID response container class | |
73 | ||
74 | }; | |
75 | ||
76 | #endif | |
77 |