1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
17 // Does PID either on a x% electron efficiency basis or on dE/dx
18 // For more information please check the implementation file
20 #ifndef ALIHFEPIDTRD_H
21 #define ALIHFEPIDTRD_H
23 #ifndef ALIHFEPIDBASE_H
24 #include "AliHFEpidBase.h"
28 class AliAODMCParticle;
30 class AliHFEcollection;
36 class AliHFEpidTRD : public AliHFEpidBase{
46 kHistTRDlikeBefore = 0,
47 kHistTRDlikeAfter = 1,
48 kHistTRDthresholds = 2,
51 kHistOverallSpecies = 5
54 AliHFEpidTRD(const Char_t *name);
55 AliHFEpidTRD(const AliHFEpidTRD &ref);
56 AliHFEpidTRD& operator=(const AliHFEpidTRD &ref);
57 virtual ~AliHFEpidTRD();
59 virtual Bool_t InitializePID();
60 virtual Int_t IsSelected(AliHFEpidObject *track);
61 virtual Bool_t HasQAhistos() const { return kTRUE; };
63 Double_t GetTRDSignalV1(AliESDtrack *track, Int_t mcPID);
64 Double_t GetTRDSignalV2(AliESDtrack *track, Int_t mcPID);
66 Bool_t IsCalculateTRDSignals() const { return TestBit(kTRDsignals); }
67 void SetPIDMethod(PIDMethodTRD_t method) { fPIDMethod = method; };
68 void SetElectronEfficiency(Double_t electronEfficiency) { fElectronEfficiency = electronEfficiency; }
69 void SetMinP(Double_t p) { fMinP = p; }
70 void CalculateTRDSignals(Bool_t docalc) { SetBit(kTRDsignals, docalc); }
72 Double_t GetTRDthresholds(Double_t electronEff, Double_t p);
77 void Copy(TObject &ref) const;
78 Int_t MakePIDesd(AliESDtrack *esdTrack, AliMCParticle *mcTrack);
79 Int_t MakePIDaod(AliAODTrack *aofTrack, AliAODMCParticle *aodMC);
80 Int_t GetMCpid(AliESDtrack *track);
81 void InitParameters();
82 void InitParameters1DLQ();
83 virtual void AddQAhistograms(TList *l);
84 void GetParameters(Double_t electronEff, Double_t *parameters);
86 void FillStandardQA(Int_t whenFilled, AliESDtrack *esdTrack);
87 void FillHistogramsTRDSignal(Double_t signal, Double_t p, Int_t species, UInt_t version);
89 static const Double_t fgkVerySmall; // Check for 0
90 Double_t fMinP; // Minimum momentum above which TRD PID is applied
91 Double_t fElectronEfficiency; // Cut on electron efficiency
92 PIDMethodTRD_t fPIDMethod; // PID Method: 2D Likelihood or Neural Network
93 Double_t fThreshParams[kThreshParams]; // Threshold parametrisation
94 AliHFEcollection *fContainer; // QA Histogram Container
95 ClassDef(AliHFEpidTRD, 1) // TRD electron ID class