3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
16 class AliTRDpid : public TNamed {
21 AliTRDpid(const char* name, const char* title);
22 AliTRDpid(const AliTRDpid &p);
24 AliTRDpid &operator=(const AliTRDpid &p);
26 virtual void Copy(TObject &p);
27 virtual Bool_t Init();
28 virtual Bool_t AssignLikelihood();
29 virtual Bool_t AssignLikelihood(TObjArray *tarray);
30 virtual Bool_t AssignLikelihood(AliTRDtrack *t) = 0;
31 virtual Bool_t FillSpectra();
32 virtual Bool_t FillSpectra(TObjArray *tarray);
33 virtual Bool_t FillSpectra(const AliTRDtrack *t) = 0;
34 virtual Bool_t Open(const Char_t *name, Int_t event = 0);
35 virtual Bool_t Open(const Char_t *namekine
36 , const Char_t *namecluster
37 , const Char_t *nametracks, Int_t event = 0);
38 virtual Int_t MCpid(const AliTRDtrack *t);
39 virtual Int_t MCpid(const AliTRDtrack *t, Int_t *pdg, Int_t *nFound, Int_t *indices);
40 virtual Bool_t ReadCluster(const Char_t *name);
41 virtual Bool_t ReadTracks(const Char_t *name);
42 virtual Bool_t ReadKine(const Char_t *name, Int_t event);
43 virtual Bool_t SumCharge(const AliTRDtrack *t, Float_t *charge, Int_t *nCluster);
45 virtual Int_t GetIndex(const AliTRDtrack *t) = 0;
47 void SetGeometry(AliTRDgeometry *geo) { fGeometry = geo; };
48 void SetTrackArray(TObjArray *tarray) { fTrackArray = tarray; };
49 void SetClusterArray(TObjArray *carray) { fClusterArray = carray; };
51 void SetPIDratioMin(Float_t min) { fPIDratioMin = min; };
52 void SetPIDpurePoints(Bool_t pure) { fPIDpurePoints = pure; };
53 void SetPIDindexMin(Int_t min) { fPIDindexMin = min; };
54 void SetPIDindexMax(Int_t max) { fPIDindexMax = max; };
56 void SetThreePadOnly(Bool_t only) { fThreePadOnly = only; };
57 void SetEvent(Int_t event) { fEvent = event; };
59 TObjArray *GetTrackArray() { return fTrackArray; };
60 TObjArray *GetClusterArray() { return fClusterArray; };
62 Float_t GetPIDratioMin() { return fPIDratioMin; };
63 Bool_t GetPIDpurePoints() { return fPIDpurePoints; };
64 Float_t GetPIDindexMin() { return fPIDindexMin; };
65 Float_t GetPIDindexMax() { return fPIDindexMax; };
67 Bool_t GetThreePadOnly() { return fThreePadOnly; };
72 kNpid = 2, // Number of pid types (pion + electron)
73 kElectron = 0, // Electron pid
77 Float_t fPIDratioMin; // Minimum fraction of cluster from one particle
78 Bool_t fPIDpurePoints; // Require pure (nono overlapping) cluster
79 Int_t fPIDindexMin; // Lower index MC particles to be considered
80 Int_t fPIDindexMax; // Upper index MC particles to be considered
82 Bool_t fThreePadOnly; // Use only three pad cluster in the charge sum
84 Int_t fEvent; // Event number
86 TObjArray *fTrackArray; //! Array containing the tracks
87 TObjArray *fClusterArray; //! Array containing the cluster
88 AliTRDgeometry *fGeometry; //! The TRD geometry
89 TFile *fFileKine; //! The kine input file
91 ClassDef(AliTRDpid,1) // Assigns the e/pi propability to the tracks