]>
Commit | Line | Data |
---|---|---|
0cf0c402 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
3 | * See cxx source for full Copyright notice * | |
4 | **************************************************************************/ | |
5 | ||
6 | /* $Id: AliRsnPID.h,v 1.5 2007/02/21 14:33:25 pulvir Exp $ */ | |
7 | ||
8 | //------------------------------------------------------------------------- | |
9 | // Class AliRsnPID | |
10 | // Simple collection of reconstructed tracks, selected from an ESD event | |
06351446 | 11 | // |
0cf0c402 | 12 | // author: A. Pulvirenti (email: alberto.pulvirenti@ct.infn.it) |
13 | //------------------------------------------------------------------------- | |
14 | ||
15 | #ifndef ALIRSNPID_H | |
16 | #define ALIRSNPID_H | |
17 | ||
e2bafbbc | 18 | #include <TNamed.h> |
19 | ||
0cf0c402 | 20 | class AliRsnDaughter; |
21 | class AliRsnEvent; | |
22 | ||
e2bafbbc | 23 | class AliRsnPID : public TNamed |
0cf0c402 | 24 | { |
aec0ec32 | 25 | public: |
06351446 | 26 | |
0cf0c402 | 27 | // types enum |
aec0ec32 | 28 | enum EType |
29 | { | |
30 | kElectron = 0, | |
31 | kMuon, | |
32 | kPion, | |
33 | kKaon, | |
34 | kProton, | |
35 | kUnknown, | |
36 | kSpecies = 5, | |
37 | kPhi=6, | |
38 | kJPsi, | |
39 | kSpeciesAll = 8 | |
0cf0c402 | 40 | }; |
06351446 | 41 | |
e2bafbbc | 42 | AliRsnPID(); |
43 | virtual ~AliRsnPID() {} | |
06351446 | 44 | |
45 | // conversions from PDG code to local type | |
e2bafbbc | 46 | static EType InternalType(Int_t pdgCode); |
aec0ec32 | 47 | |
0cf0c402 | 48 | // retrieve particle informations from internal type |
e2bafbbc | 49 | static Int_t PDGCode(EType pid); |
50 | static const char* ParticleName(EType pid, Bool_t shortName = kTRUE); | |
51 | static const char* ParticleNameLatex(EType pid); | |
52 | static Double_t ParticleMass(EType pid); | |
06351446 | 53 | |
0cf0c402 | 54 | // identification routines |
e2bafbbc | 55 | Bool_t Process(AliRsnEvent *e); |
56 | Bool_t ComputeProbs(AliRsnDaughter *d); | |
57 | Bool_t IdentifiedAs(AliRsnDaughter *d, EType type, Short_t charge = 0); | |
58 | EType TrackType(AliRsnDaughter *d); | |
59 | ||
60 | // data members | |
61 | void SetPriorProbability(EType type, Double_t p); | |
62 | void SetMinProb(Double_t p) {fMinProb = p;} | |
63 | void SetMaxPt(Double_t p) {fMaxPt = p;} | |
64 | Double_t GetPriorProbability(EType type) {return fPrior[(Int_t)type];} | |
65 | Double_t GetMinProb() {return fMinProb;} | |
66 | Double_t GetMaxPt() {return fMaxPt;} | |
67 | ||
68 | // other | |
69 | void DumpPriors(); | |
06351446 | 70 | |
aec0ec32 | 71 | private: |
0cf0c402 | 72 | |
e2bafbbc | 73 | Double_t fPrior[kSpecies]; // prior probabilities |
74 | Double_t fMaxPt; // pt threshold for realistic PID | |
75 | Double_t fMinProb; // threshold on acceptable largest probability | |
06351446 | 76 | |
aec0ec32 | 77 | static const Double_t fgkParticleMass[kSpeciesAll + 1]; // PDG particle mass |
78 | static const char* fgkParticleNameShort[kSpeciesAll + 1]; // short particle name | |
79 | static const char* fgkParticleNameLong[kSpeciesAll + 1]; // long particle name | |
80 | static const char* fgkParticleNameLatex[kSpeciesAll + 1]; // latex particle name | |
81 | static const Int_t fgkParticlePDG[kSpeciesAll + 1]; // PDG code of particle | |
0cf0c402 | 82 | |
83 | ClassDef(AliRsnPID,1); | |
84 | }; | |
85 | ||
86 | #endif |