Line data Source code
1 : #ifndef ALIITSPIDRESPONSE_H
2 : #define ALIITSPIDRESPONSE_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 : // ITS PID response class
10 : //
11 : //
12 : //-------------------------------------------------------
13 : //#include <Rtypes.h>
14 : #include <TObject.h>
15 : #include "AliPID.h"
16 :
17 : class AliVTrack;
18 : class AliITSPidParams;
19 :
20 0 : class AliITSPIDResponse : public TObject {
21 :
22 : public:
23 : AliITSPIDResponse(Bool_t isMC=kFALSE);
24 : //AliITSPIDResponse(Double_t *param);
25 52 : ~AliITSPIDResponse() {}
26 :
27 : void SetBetheBlochParamsITSTPC(Double_t* param){
28 0 : for(Int_t iPar=0; iPar<5; iPar++) fBBtpcits[iPar]=param[iPar];
29 0 : }
30 : void SetBetheBlochParamsITSTPCDeuteron(Double_t* param){
31 0 : for(Int_t iPar=0; iPar<5; iPar++) fBBdeu[iPar]=param[iPar];
32 0 : }
33 : void SetBetheBlochParamsITSTPCTriton(Double_t* param){
34 0 : for(Int_t iPar=0; iPar<5; iPar++) fBBtri[iPar]=param[iPar];
35 0 : }
36 : void SetBetheBlochParamsITSsa(Double_t* param){
37 0 : for(Int_t iPar=0; iPar<5; iPar++) fBBsa[iPar]=param[iPar];
38 0 : }
39 : void SetBetheBlochHybridParamsITSsa(Double_t* param){
40 0 : for(Int_t iPar=0; iPar<9; iPar++) fBBsaHybrid[iPar]=param[iPar];
41 0 : }
42 : void SetElectronBetheBlochParamsITSsa(Double_t* param){
43 0 : for(Int_t iPar=0; iPar<5; iPar++) fBBsaElectron[iPar]=param[iPar];
44 0 : }
45 :
46 : Double_t BetheAleph(Double_t p,Double_t mass) const;
47 : Double_t Bethe(Double_t p, Double_t mass, Bool_t isSA=kFALSE) const;
48 : Double_t Bethe(Double_t p, AliPID::EParticleType species, Bool_t isSA=kFALSE) const;
49 : Double_t BetheITSsaHybrid(Double_t p, Double_t mass) const;
50 : Double_t GetResolution(Double_t bethe, Int_t nPtsForPid=4, Bool_t isSA=kFALSE,Double_t p=0., AliPID::EParticleType type=AliPID::kPion) const;
51 : void GetITSProbabilities(Float_t mom, Double_t qclu[4], Double_t condprobfun[AliPID::kSPECIES], Bool_t isMC = kFALSE) const;
52 : void GetITSProbabilities(Float_t mom, Double_t qclu[4], Double_t condprobfun[AliPID::kSPECIES], AliITSPidParams *pars) const;
53 :
54 : Double_t GetNumberOfSigmas( const AliVTrack* track, AliPID::EParticleType species) const;
55 :
56 : Double_t GetSignalDelta( const AliVTrack* track, AliPID::EParticleType species, Bool_t ratio=kFALSE) const;
57 :
58 : Float_t GetNumberOfSigmas(Float_t mom, Float_t signal, AliPID::EParticleType type, Int_t nPtsForPid=4, Bool_t isSA=kFALSE) const {
59 0 : if(type==AliPID::kDeuteron && mom<0.4) return -999.;
60 0 : if(type==AliPID::kTriton && mom<0.55) return -999.;
61 0 : const Double_t chargeFactor = TMath::Power(AliPID::ParticleCharge(type),2.);
62 0 : Float_t bethe = Bethe(mom,type,isSA)*chargeFactor;
63 0 : return (signal - bethe)/GetResolution(bethe,nPtsForPid,isSA,mom,type);
64 0 : }
65 : Int_t GetParticleIdFromdEdxVsP(Float_t mom, Float_t signal, Bool_t isSA=kFALSE) const;
66 :
67 : private:
68 :
69 :
70 : // Data members for truncated mean method
71 : Float_t fRes; // relative dEdx resolution
72 : Double_t fKp1; // ALEPH BB param 1
73 : Double_t fKp2; // ALEPH BB param 2
74 : Double_t fKp3; // ALEPH BB param 3
75 : Double_t fKp4; // ALEPH BB param 4
76 : Double_t fKp5; // ALEPH BB param
77 : Double_t fBBsa[5]; // parameters of BB for SA tracks
78 : Double_t fBBsaHybrid[9]; // parameters of Hybrid BB for SA tracks, PHOB + Polinomial al low beta*gamma
79 : Double_t fBBsaElectron[5];// parameters of electron BB for SA tracks
80 : Double_t fBBtpcits[5]; // parameters of BB for TPC+ITS tracks
81 : Double_t fBBdeu[5]; // parameters of deuteron BB for TPC+ITS tracks
82 : Double_t fBBtri[5]; // parameters of triton BB for TPC+ITS tracks
83 : Float_t fResolSA[5]; // resolutions vs. n. of SDD/SSD points
84 : Float_t fResolTPCITS[5]; // resolutions vs. n. of SDD/SSD points
85 : Double_t fResolTPCITSDeu3[3]; // deuteron resolutions vs. p for tracks with 3 SDD/SSD points
86 : Double_t fResolTPCITSDeu4[3]; // deuteron resolutions vs. p for tracks with 4 SDD/SSD points
87 : Double_t fResolTPCITSTri3[3]; // triton resolutions vs. p for tracks with 3 SDD/SSD points
88 : Double_t fResolTPCITSTri4[3]; // triton resolutions vs. p for tracks with 4 SDD/SSD points
89 :
90 : Double_t Bethe(Double_t bg, const Double_t * const par, Bool_t isNuclei) const;
91 176 : ClassDef(AliITSPIDResponse,5) // ITS PID class
92 : };
93 :
94 : #endif
95 :
96 :
|