AliPhysics  9074f74 (9074f74)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Go to the documentation of this file.
1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. */
2 /* See cxx source for full Copyright notice */
3 /* $Id$ */
5 // AliFlowTrackESDCuts:
6 // A cut class for ESD, AOD and MC particles for the flow framework
7 // author: Mikolaj Krzewicki (
8 // mods: Redmer A. Bertens (
13 #include <TMatrix.h>
14 #include <TList.h>
15 #include "AliFlowTrackSimpleCuts.h"
16 #include "AliFlowTrackSimple.h"
17 #include "AliESDtrackCuts.h"
18 #include "TMCProcess.h"
19 #include "AliESDtrack.h"
20 #include "AliMuonTrackCuts.h" // XZhang 20120604
21 #include "AliPID.h"
22 #include "AliESDpid.h"
23 #include "TF2.h"
26 class TBrowser;
27 class TArrayD;
28 class AliVParticle;
29 class AliMCParticle;
30 class AliFlowTrack;
31 class AliMCEvent;
32 class AliInputEventHandler;
33 class AliVEvent;
34 class AliMultiplicity;
35 class AliAODTracklets; // XZhang 20120615
36 class AliAODTrack;
37 class AliESDtrack;
38 class AliESDPmdTrack;
39 class AliFlowBayesianPID;
40 class AliESDkink;
41 class AliESDv0;
42 class AliESDVZERO;
43 class AliPIDResponse;
47  public:
49  AliFlowTrackCuts(const char* name);
50  AliFlowTrackCuts(const AliFlowTrackCuts& someCuts);
52  virtual ~AliFlowTrackCuts();
54  static AliFlowTrackCuts* GetAODTrackCutsForFilterBit(UInt_t bit = 1, TString suffix = "");
58  static AliFlowTrackCuts* GetStandardITSTPCTrackCuts2009(Bool_t selPrimaries=kTRUE);
62  // beta test, don't use for results
64  // end of beta test
65  static AliFlowTrackCuts* GetStandardMuonTrackCuts(Bool_t isMC=kFALSE, Int_t passN=2); // XZhang 20120604
67  Int_t Count(AliVEvent* event=NULL);
74  kV0, //neutral reconstructed v0 particle
75  kVZERO, //forward VZERO detector
76  kMUON, // XZhang 20120604
79  kUserA, // reserved for custom cuts
80  kUserB, // reserved for custom cuts
81  kBetaVZERO, // temporary enum for beta testing of new vzero calibration
82  kDeltaVZERO // temporary enum for beta testing of new vzero calibration
83  };
91  };
92  enum PIDsource {
93  kTPCpid, // default TPC pid (via GetTPCpid)
94  kTOFpid, // default TOF pid (via GetTOFpid)
95  kTOFbayesian, // TOF bayesian pid (F.Noferini)
96  kTOFbeta, // asymmetric cuts of TOF beta signal
97  kTPCdedx, // asymmetric cuts of TPC dedx signal
98  kTOFbetaSimple, //simple TOF only cut
99  kTPCbayesian, //bayesian cutTPC
100  kTPCNuclei, // added by Natasha for Nuclei
101  kTPCTOFNsigma, // simple cut on combined tpc tof nsigma
102  kTPCTOFNsigmaPurity, // purity>0.8 cut on combined tpc tof nsigma
104  };
106  //setters (interface to AliESDtrackCuts)
107  Int_t MaxSharedITSClusterCuts(AliESDtrack* track);
108  Double_t MaxChi2perITSClusterCuts(AliESDtrack* track);
111  void SetMaxChi2perITSCluster(Double_t b){fCutITSChi2 = kTRUE; fMaxITSChi2 = b;}
115  void SetClusterRequirementITS( AliESDtrackCuts::Detector det,
116  AliESDtrackCuts::ITSClusterRequirement req = AliESDtrackCuts::kOff )
117  { InitESDcuts(); fAliESDtrackCuts->SetClusterRequirementITS(det,req); }
120  void SetMaxChi2PerClusterITS( Float_t a ) {InitESDcuts(); fAliESDtrackCuts->SetMaxChi2PerClusterITS(a);}
121  void SetRequireTPCRefit( Bool_t a ) {InitESDcuts(); fAliESDtrackCuts->SetRequireTPCRefit(a);}
122  void SetRequireTPCStandAlone( Bool_t a) {InitESDcuts(); fAliESDtrackCuts->SetRequireTPCStandAlone(a);}
123  void SetRequireITSRefit( Bool_t a ) {InitESDcuts(); fAliESDtrackCuts->SetRequireITSRefit(a);}
124  void SetRequireITSStandAlone( Bool_t a) {InitESDcuts(); fAliESDtrackCuts->SetRequireITSStandAlone(a);}
125  void SetAcceptKinkDaughters( Bool_t a ) {InitESDcuts(); fAliESDtrackCuts->SetAcceptKinkDaughters(a);}
126  void SetMaxDCAToVertexZ( Float_t a ) {InitESDcuts(); fAliESDtrackCuts->SetMaxDCAToVertexZ(a);fCutDCAToVertexZ=kTRUE;}
127  void SetMaxDCAToVertexXY( Float_t a ) {InitESDcuts(); fAliESDtrackCuts->SetMaxDCAToVertexXY(a);fCutDCAToVertexXY=kTRUE;}
128  void SetMaxDCAToVertexXYPtDep( const char* a ) {InitESDcuts(); fAliESDtrackCuts->SetMaxDCAToVertexXYPtDep(a);}
129  void SetRequireSigmaToVertex(Bool_t a) {InitESDcuts(); fAliESDtrackCuts->SetRequireSigmaToVertex(a);}
130  void SetMaxNsigmaToVertex(Float_t sigma=1e10) {InitESDcuts(); fAliESDtrackCuts->SetMaxNsigmaToVertex(sigma); }
131  void SetDCAToVertex2D( Bool_t a ) {InitESDcuts(); fAliESDtrackCuts->SetDCAToVertex2D(a);}
132  void SetEtaRange( Float_t r1, Float_t r2 ) { SetEtaMin(r1); SetEtaMax(r2); }
133  void SetPtRange( Float_t r1, Float_t r2 ) { SetPtMin(r1); SetPtMax(r2); }
134  void SetRequireCharge( Bool_t r ) {fRequireCharge=r;}
135  void SetFakesAreOK( Bool_t b ) {fFakesAreOK=b;}
138  void SetIgnoreTPCzRange( Double_t min, Double_t max )
140  void SetAODfilterBit( UInt_t a ) {fAODFilterBit = a; fUseAODFilterBit = kTRUE;}
141  void SetMinimalTPCdedx(Double_t d=10.) {fMinimalTPCdedx=d; fCutMinimalTPCdedx=kTRUE;}
142  void SetPmdDetPlane(Int_t pmdDet){fCutPmdDet=kTRUE; fPmdDet = pmdDet; }
143  void SetPmdAdc(Float_t pmdAdc){fCutPmdAdc=kTRUE; fPmdAdc = pmdAdc; }
144  void SetPmdNcell(Float_t pmdNcell) {fCutPmdNcell=kTRUE; fPmdNcell = pmdNcell; }
145  void SetPriors(Float_t centr = 0); // set my favourite priors for Bayesian PID (requested if Bayesian PID is used)
147  AliMuonTrackCuts *GetMuonTrackCuts() { InitMuonCuts(); return fMuonTrackCuts; } // XZhang 20121014
148  void SetStandardMuonTrackCuts() { InitMuonCuts(); fMuonTrackCuts->SetDefaultFilterMask(); return; } // XZhang 20120604
149  void SetIsMuonMC(Bool_t isMC) { InitMuonCuts(); fMuonTrackCuts->SetIsMC(isMC); return; } // XZhang 20120604
150  void SetMuonPassNumber(Int_t passN) { InitMuonCuts(); fMuonTrackCuts->SetPassNumber(passN); return; } // XZhang 20121013
151  void SetRunsMuon(const AliInputEventHandler* eventHandler) { if (fMuonTrackCuts) fMuonTrackCuts->SetRun(eventHandler); } // XZhang 20120604
155  //Kinks
156  void SetMinKinkAngle(Double_t a) {fMinKinkAngle=a;}
157  void SetMinKinkRadius(Double_t r) {fMinKinkRadius=r;}
158  void SetMaxKinkRAdius(Double_t r) {fMaxKinkRadius=r;}
159  void SetMinKinkQt(Double_t m) {fMinKinkQt=m;}
160  void SetMaxKinkQt(Double_t m) {fMaxKinkQt=m;}
164  Double_t GetMinKinkAngle() const {return fMinKinkAngle;}
165  Double_t GetMinKinkRadius() const {return fMinKinkRadius;}
166  Double_t GetMaxKinkRadius() const {return fMaxKinkRadius;}
167  Double_t GetMinKinkQt() const {return fMinKinkQt;}
168  Double_t GetMaxKinkQt() const {return fMaxKinkQt;}
169  Double_t GetMaxKinkInvMassKmu() const {return fMaxKinkInvMassKmu;}
170  Double_t GetMinKinkInvMassKmu() const {return fMinKinkInvMassKmu;}
172  Int_t GetMinNClustersTPC() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMinNClusterTPC();}
173  Int_t GetMinNClustersITS() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMinNClustersITS();}
174  AliESDtrackCuts::ITSClusterRequirement GetClusterRequirementITS( AliESDtrackCuts::Detector det ) const
175  {if (!fAliESDtrackCuts) return AliESDtrackCuts::kOff; return fAliESDtrackCuts->GetClusterRequirementITS(det); }
176  Float_t GetMaxChi2PerClusterTPC() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxChi2PerClusterTPC();}
177  Float_t GetMaxChi2PerClusterITS() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxChi2PerClusterITS();}
178  Bool_t GetRequireTPCRefit() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetRequireTPCRefit();}
179  Bool_t GetRequireTPCStandAlone() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetRequireTPCStandAlone();}
180  Bool_t GetRequireITSRefit() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetRequireITSRefit();}
181  Bool_t GetRequireITSStandAlone() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetRequireITSStandAlone();}
182  Bool_t GetAcceptKinkDaughters() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetAcceptKinkDaughters();}
183  Float_t GetMaxDCAToVertexZ() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxDCAToVertexZ();}
184  Float_t GetMaxDCAToVertexXY() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxDCAToVertexXY();}
185  const char* GetMaxDCAToVertexXYPtDep() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxDCAToVertexXYPtDep();}
186  Bool_t GetRequireSigmaToVertex() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetRequireSigmaToVertex();}
187  Float_t GetMaxNsigmaToVertex() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetMaxNsigmaToVertex(); }
188  Bool_t GetDCAToVertex2D() const {if (!fAliESDtrackCuts) return 0; return fAliESDtrackCuts->GetDCAToVertex2D();}
189  void GetEtaRange( Float_t& r1, Float_t& r2 ) const { r1=GetEtaMin(); r2=GetEtaMax(); }
190  void GetPtRange( Float_t& r1, Float_t& r2 ) const { r1=GetPtMin(); r2=GetPtMax(); }
191  Bool_t GetRequireCharge() const {return fRequireCharge;}
192  Bool_t GetFakesAreOK() const {return fFakesAreOK;}
195  UInt_t GetAODFilterBit() const {if (!fUseAODFilterBit) return 0; return fAODFilterBit;}
196  Double_t GetMinimalTPCdedx() const {return fMinimalTPCdedx;}
197  Int_t GetPmdDetPlane()const {return fPmdDet; }
198  Float_t GetPmdAdc()const {return fPmdAdc;}
199  Float_t GetPmdNcell() const {return fPmdNcell; }
200  Float_t GetBeta(const AliVTrack* t, Bool_t QAmode = kFALSE);
201  Float_t Getdedx(const AliESDtrack* t) const;
202  Float_t GetBayesianProb() const {return fProbBayes;};
207  void SetQA(Bool_t b=kTRUE) {if (b) DefineHistograms();}
208  TList* GetQA() const {return fQA;}
209  TH1* QAbefore(Int_t i) {return static_cast<TH1*>(static_cast<TList*>(fQA->At(0))->At(i));}
210  TH1* QAafter(Int_t i) {return static_cast<TH1*>(static_cast<TList*>(fQA->At(1))->At(i));}
212  //MC stuff
213  void SetIgnoreSignInMCPID( Bool_t b=kTRUE ) {fIgnoreSignInMCPID=b;}
214  void SetCutMC( Bool_t b=kTRUE );
216  void SetMCprocessType( TMCProcess t ) { fMCprocessType = t; fCutMCprocessType=kTRUE; SetCutMC();}
217  void SetMCisPrimary( Bool_t b=kTRUE ) { fMCisPrimary=b; fCutMCisPrimary=kTRUE; SetCutMC();}
218  void SetMCPID( Int_t pid ) { fMCPID=pid; fCutMCPID=kTRUE; SetCutMC(); }
220  TMCProcess GetMCprocessType() const { return fMCprocessType; }
221  Bool_t GetMCisPrimary() const {return fMCisPrimary;}
222  Int_t GetMCPID() const {return fMCPID;}
225  void SetParamType(trackParameterType paramType) {fParamType=paramType;}
227  static const char* GetParamTypeName(trackParameterType type);
228  void SetParamMix(trackParameterMix paramMix) {fParamMix=paramMix;}
231  virtual Bool_t IsSelected(TObject* obj, Int_t id=-666);
232  virtual Bool_t IsSelectedMCtruth(TObject* obj, Int_t id=-666);
233  AliVParticle* GetTrack() const {return fTrack;}
234  AliMCParticle* GetMCparticle() const {return fMCparticle;}
235  //AliFlowTrack* MakeFlowTrack() const;
236  Bool_t FillFlowTrack(AliFlowTrack* track) const;
237  //FillFlowTrackV0(TObjArray* trackCollection, Int_t trackIndex) const
238  AliFlowTrack* FillFlowTrack(TObjArray* trackCollection, Int_t trackIndex) const;
239  Bool_t IsPhysicalPrimary() const;
240  static Bool_t IsPhysicalPrimary(AliMCEvent* p, Int_t label, Bool_t requiretransported=kTRUE);
242  void SetMCevent(AliMCEvent* mcEvent) {fMCevent=mcEvent;}
243  AliMCEvent* GetMCevent() const {return fMCevent;}
244  void SetEvent(AliVEvent* event, AliMCEvent* mcEvent=NULL);
245  AliVEvent* GetEvent() const {return fEvent;}
246  Int_t GetNumberOfInputObjects() const;
247  TObject* GetInputObject(Int_t i);
248  void Clear(Option_t* option="");
249  void ClearTrack(Option_t* option="");
251  Double_t GetPmdEta(Float_t xPos, Float_t yPos, Float_t zPos);
252  Double_t GetPmdPhi(Float_t xPos, Float_t yPos);
254  //PID
255  void SetPID(AliPID::EParticleType pid, PIDsource s=kTOFpid, Double_t prob=0.9)
257  AliPID::EParticleType GetParticleID() const {return fParticleID;}
258  Bool_t GetCutPID() const {return fCutPID;}
259  void SetTPCpidCuts(const TMatrixF* mat) {fTPCpidCuts=new TMatrixF(*mat);}
260  void SetTOFpidCuts(const TMatrixF* mat) {fTOFpidCuts=new TMatrixF(*mat);}
261  static const char* PIDsourceName(PIDsource s);
262  AliESDpid& GetESDpid() {return fESDpid;}
270  //these should maybe be protected
271  Bool_t PassesCuts(AliVParticle* track);
272  Bool_t PassesESDcuts(AliESDtrack* track);
273  Bool_t PassesAODcuts(const AliAODTrack* track, Bool_t passFid=kTRUE);
274  Bool_t PassesPMDcuts(const AliESDPmdTrack* track);
275  Bool_t PassesVZEROcuts(Int_t id);
276  Bool_t PassesCuts(const AliFlowTrackSimple* track);
277  Bool_t PassesCuts(const AliMultiplicity* track, Int_t id);
278  Bool_t PassesCuts(const AliAODTracklets* track, Int_t id); // XZhang 20120615
279  Bool_t PassesCuts(const AliESDkink* kink);
280  Bool_t PassesCuts(const AliESDv0* v0);
281  Bool_t PassesMCcuts();
282  Bool_t PassesMCcuts(AliMCEvent* mcevent, Int_t label);
283  Bool_t PassesTPCdedxCut(const AliESDtrack* track);
284  Bool_t PassesTPCbayesianCut(const AliESDtrack* track);
285  Bool_t PassesTPCpidCut(const AliESDtrack* track) const;
286  Bool_t PassesTOFbetaCut(const AliESDtrack* track);
287  Bool_t PassesTOFbetaSimpleCut(const AliESDtrack* track);
288  Bool_t PassesTOFpidCut(const AliESDtrack* track) const;
289  Bool_t PassesESDpidCut(const AliESDtrack* track);
290  Bool_t PassesAODpidCut(const AliAODTrack* track);
291  Bool_t PassesMuonCuts(AliVParticle* track); // XZhang 20120604
292  Bool_t PassesTPCbayesianCut(const AliAODTrack* track);
293  Bool_t PassesTOFbayesianCut(const AliAODTrack* track);
294  Bool_t PassesTOFbetaCut(const AliAODTrack* track);
296  void Browse(TBrowser* b);
297  Long64_t Merge(TCollection* list);
299  void SetTPCTOFNsigmaPIDPurityFunctions(Float_t purityLevel);
302  void SetPtTOFPIDoff(Double_t pt) {fPtTOFPIDoff = pt;} // added by B.Hohlweger
303  Double_t GetPtTOFPIDoff() {return fPtTOFPIDoff;}
305  //gain equalization and recentering
308  void SetVZEROApol(Int_t ring, Float_t f) {fVZEROApol[ring]=f;}
309  void SetVZEROCpol(Int_t ring, Float_t f) {fVZEROCpol[ring]=f;}
310  // set the flag for recentering (which is done in AliFlowEvent)
311  void SetApplyRecentering(Bool_t r) { fApplyRecentering = r; }
312  Bool_t GetApplyRecentering() const { return fApplyRecentering;}
315  void SetDivSigma(Bool_t r) { fDivSigma = r; }
316  Bool_t GetDivSigma() const { return fDivSigma;}
317  // exclude vzero rings: 0 through 7 can be excluded by calling this setter multiple times
318  // 0 corresponds to segment ID 0 through 7, etc
319  // disabled vzero rings get weight 0
320  void SetUseVZERORing(Int_t i, Bool_t u) {
321  fUseVZERORing[i] = u;
322  fVZEROgainEqualizationPerRing = kTRUE; // must be true for this option
323  }
324  Bool_t GetUseVZERORing(Int_t i) const {return fUseVZERORing[i];}
325  void SetChi2A(TArrayD* Chi2A) {fChi2A = Chi2A;} // chi vs cent for vzero A ep_2
326  void SetChi3A(TArrayD* Chi3A) {fChi3A = Chi3A;}
327  void SetChi2C(TArrayD* Chi2C) {fChi2C = Chi2C;}
328  void SetChi3C(TArrayD* Chi3C) {fChi3C = Chi3C;}
330  TArrayD* GetChi2A() {return fChi2A;} // chi vs cent for vzero A ep_2
331  TArrayD* GetChi3A() {return fChi3A;}
332  TArrayD* GetChi2C() {return fChi2C;}
333  TArrayD* GetChi3C() {return fChi3C;}
335  void SetNumberOfSigmas(Float_t val) {fNsigmaCut2 = val*val;};
336  Float_t GetNumberOfSigmas() const {return TMath::Sqrt(fNsigmaCut2);};
338  void SetRun(Int_t const run) {this->fRun = run;};
339  Int_t GetRun() const {return this->fRun;};
341  protected:
342  //AliFlowTrack* MakeFlowTrackSPDtracklet() const;
343  //AliFlowTrack* MakeFlowTrackPMDtrack() const;
344  //AliFlowTrack* MakeFlowTrackVZERO() const;
345  //AliFlowTrack* MakeFlowTrackVParticle() const;
346  Bool_t FillFlowTrackVParticle(AliFlowTrack* t) const;
347  Bool_t FillFlowTrackGeneric(AliFlowTrack* t) const;
348  AliFlowTrack* FillFlowTrackKink(TObjArray* trackCollection, Int_t trackIndex) const;
349  AliFlowTrack* FillFlowTrackVZERO(TObjArray* trackCollection, Int_t trackIndex) const;
350  AliFlowTrack* FillFlowTrackGeneric(TObjArray* trackCollection, Int_t trackIndex) const;
351  AliFlowTrack* FillFlowTrackVParticle(TObjArray* trackCollection, Int_t trackIndex) const;
352  void HandleESDtrack(AliESDtrack* track);
353  void HandleVParticle(AliVParticle* track);
354  void DefineHistograms();
355  void InitPIDcuts();
356  void InitESDcuts() {if (!fAliESDtrackCuts) {fAliESDtrackCuts=new AliESDtrackCuts();}}
357  void InitMuonCuts() { if (!fMuonTrackCuts) fMuonTrackCuts =new AliMuonTrackCuts("StdMuCuts","StdMuCuts"); return; } // XZhang 20120604
358  // part added by F. Noferini
359  Bool_t PassesTOFbayesianCut(const AliESDtrack* track);
360  Bool_t PassesNucleiSelection(const AliESDtrack* track); // added by Natasha
361  Bool_t PassesTPCTOFNsigmaCut(const AliAODTrack* track);
362  Bool_t PassesTPCTOFNsigmaCut(const AliESDtrack* track);
363  Bool_t PassesTPCTOFNsigmaPurityCut(const AliAODTrack* track);
364  Bool_t TPCTOFagree(const AliVTrack *track);
365  // end part added by F. Noferini
366  Bool_t PassesTPCTPCTOFNsigmaCut(const AliAODTrack* track); // added by B. Hohlweger
368  //the cuts
369  AliESDtrackCuts* fAliESDtrackCuts; //alianalysis cuts
370  AliMuonTrackCuts* fMuonTrackCuts; // muon selection cuts // XZhang 20120604
371  TList* fQA; //qa histograms go here
372  Bool_t fCutMC; //do we cut on MC?
373  Bool_t fCutMChasTrackReferences; //did we leave a trace in the detector?
374  Bool_t fCutMCprocessType; //do we cut on mc process type?
375  TMCProcess fMCprocessType; //mc process type
376  Bool_t fCutMCPID; //cut on MC pid?
377  Int_t fMCPID; //MC PID
378  Bool_t fCutMCfirstMotherPID; //cut on PID of first mother?
379  Int_t fMCfirstMotherPID; //PID of the first mother of track
380  Bool_t fIgnoreSignInMCPID; //when MC PID cut is set, pass also the antiparticle
381  Bool_t fCutMCisPrimary; //do we cut on primaryness?
382  Bool_t fRequireTransportBitForPrimaries; //require the transport bit to be set for primaries
383  Bool_t fMCisPrimary; //is MC primary
384  Bool_t fRequireCharge; //is charged?
385  Bool_t fFakesAreOK; //are fakes (negative labels) ok?
386  Bool_t fCutSPDtrackletDeltaPhi; //are we cutting on the trcklet deltaphi?
387  Double_t fSPDtrackletDeltaPhiMax; //maximal deltaphi for tracklets
388  Double_t fSPDtrackletDeltaPhiMin; //minimal deltaphi for tracklets
389  Bool_t fIgnoreTPCzRange; //ignore tracks going close to central membrane
390  Double_t fIgnoreTPCzRangeMax; //max z to ignore
391  Double_t fIgnoreTPCzRangeMin; //min z to ignore
392  Bool_t fCutChi2PerClusterTPC; //cut on tpc chi2
393  Float_t fMaxChi2PerClusterTPC; //max chi2 tpc/cluster
394  Float_t fMinChi2PerClusterTPC; //min chi2 tpc/cluster
395  Bool_t fCutNClustersTPC; //cut on clusters?
396  Int_t fNClustersTPCMax; //max tpc ncls
397  Int_t fNClustersTPCMin; //min tpc clusters
398  Bool_t fCutNClustersITS; //cut on clusters?
399  Int_t fNClustersITSMax; //max tpc ncls
400  Int_t fNClustersITSMin; //min tpc clusters
401  Bool_t fUseAODFilterBit; //use AOD filter bit selection?
402  UInt_t fAODFilterBit; //AOD filter bit to select
403  Bool_t fCutDCAToVertexXY; //dca xy cut
404  Bool_t fCutDCAToVertexZ; //dca z cut
405  Bool_t fCutMinimalTPCdedx; //cut on minimal dedx in TPC to reject noise tracks
406  Double_t fMinimalTPCdedx; //value for minimal TPC dedx
407  Bool_t fLinearizeVZEROresponse; //linearize VZERO response using AliESDUtil
409  Int_t fCentralityPercentileMin; //centrality min
410  Int_t fCentralityPercentileMax; //centrality max
411  Float_t fPurityLevel; //Purity cut percentage
413  Bool_t fCutPmdDet; //cut on PMD detector plane
414  Int_t fPmdDet; // value of PMD detector plane
415  Bool_t fCutPmdAdc; //cut on cluster ADC
416  Float_t fPmdAdc; //value of cluster ADC
417  Bool_t fCutPmdNcell; //cut on cluster ncell
418  Float_t fPmdNcell; //value of cluster ncell
420  Double_t fMinKinkAngle; //max kink angle
421  Double_t fMinKinkRadius; //min kink radius
422  Double_t fMaxKinkRadius; //max kink radius
423  Double_t fMinKinkQt; //min kink qt
424  Double_t fMaxKinkQt; //max kink qt
425  Double_t fMinKinkInvMassKmu; //max kink inv mass
426  Double_t fMaxKinkInvMassKmu; //max kink inv mass
427  Bool_t fForceTPCstandalone; //use TPC parameters when applying cuts on the kink mother
428  Bool_t fRequireKinkDaughters; //well, the name says it all
430  trackParameterType fParamType; //parameter type tu cut on
431  trackParameterMix fParamMix; //parameter mixing
433  AliESDkink* fKink;
434  AliESDv0* fV0;
435  AliVParticle* fTrack;
436  Double_t fTrackMass;
437  Double_t fTrackPt;
438  Double_t fTrackPhi;
439  Double_t fTrackEta;
440  Double_t fTrackWeight;
441  Int_t fTrackLabel;
442  AliMCEvent* fMCevent;
443  AliMCParticle* fMCparticle;
444  AliVEvent* fEvent;
445  AliESDtrack fTPCtrack;
447  //PID
448  AliESDpid fESDpid; //pid obj
450  PIDsource fPIDsource; //pid source
451  TMatrixF* fTPCpidCuts; //tpc pid cuts
452  TMatrixF* fTOFpidCuts; //tof pid cuts
453  AliPID::EParticleType fParticleID; //alipid
454  Double_t fParticleProbability; //desired prob for a particle type
455  Bool_t fAllowTOFmismatchFlag; //allow TOFmismatch flag=1 in ESD
456  Bool_t fRequireStrictTOFTPCagreement; //require stricter than TOFmismatch flag TOF-TPC agreement
457  Bool_t fCutRejectElectronsWithTPCpid; //reject electrons with TPC pid
459  // part added by F. Noferini
460  static const Int_t fgkPIDptBin = 20; // pT bins for priors
461  Float_t fC[fgkPIDptBin][5],fBinLimitPID[fgkPIDptBin]; // pt bin limit and priors
462  Float_t fProbBayes; // bayesian probability
463  Float_t fCurrCentr; // current centrality used for set the priors
464  // end part added by F. Noferini
465  Double_t fPtTOFPIDoff;
467  //gain equalization and recentering for vzero
470  Bool_t fApplyRecentering; // apply recentering of q-sub vectors in AliFlowEvent ?
471  Bool_t fVZEROgainEqualizationPerRing; // per ring vzero gain calibration
472  Bool_t fDivSigma; // divide by after recentering
473  Float_t fVZEROApol[4];
474  Float_t fVZEROCpol[4];
475  Bool_t fUseVZERORing[8]; // kTRUE means the ring is included
476  static const Int_t fgkNumberOfVZEROtracks=64; //number of VZERO channels
477  TArrayD* fChi2A; // chi vs cent for vzero A ep_2
478  TArrayD* fChi2C; // chi vs cent for vzero C ep_2
479  TArrayD* fChi3A; // chi vs cent for vzero A ep_3
480  TArrayD* fChi3C; // chi vs cent for vzero C ep_3
482  AliPIDResponse *fPIDResponse;
483  Float_t fNsigmaCut2; // Number of sigma^2 (cut value) for TPC+TOF nsigma cut
487  //TPC TOF nsigma Purity based cut functions
489  TDirectory *fPurityFunctionsList;
491  TF2 *fPurityFunction[180]; //TF2 purity functions
493  Bool_t fCutITSclusterShared; // cut fMaxITSClusterShared
494  Int_t fMaxITSclusterShared; // fMaxITSclusterShared
495  Bool_t fCutITSChi2; // cut fMaxITSChi2
496  Double_t fMaxITSChi2; // fMaxITSChi2
498  Int_t fRun; // run number
502  ClassDef(AliFlowTrackCuts,18)
503 };
505 #endif
Double_t fTrackPt
mass of the particle
void GetPtRange(Float_t &r1, Float_t &r2) const
void SetRequireTPCStandAlone(Bool_t a)
Bool_t PassesESDcuts(AliESDtrack *track)
Double_t fIgnoreTPCzRangeMax
void SetMaxNsigmaToVertex(Float_t sigma=1e10)
static AliFlowTrackCuts * GetStandardVZEROOnlyTrackCuts2011()
void SetChi3C(TArrayD *Chi3C)
Double_t GetMinKinkRadius() const
void SetDCAToVertex2D(Bool_t a)
AliESDtrackCuts::ITSClusterRequirement GetClusterRequirementITS(AliESDtrackCuts::Detector det) const
void SetStandardMuonTrackCuts()
AliPID::EParticleType fParticleID
void SetMaxChi2PerClusterTPC(Float_t a)
void SetMaxDCAToVertexZ(Float_t a)
virtual Bool_t IsSelectedMCtruth(TObject *obj, Int_t id=-666)
void SetRequireCharge(Bool_t r)
void SetRun(Int_t const run)
TObject * GetInputObject(Int_t i)
TFile * fPurityFunctionsFile
void SetApplyRecentering(Bool_t r)
void SetAllowTOFmismatchFlag(Bool_t b=kTRUE)
void SetMCisPrimary(Bool_t b=kTRUE)
AliESDkink * fKink
Bool_t GetRequireSigmaToVertex() const
Float_t GetBayesianProb() const
void SetPmdDetPlane(Int_t pmdDet)
void SetPID(AliPID::EParticleType pid, PIDsource s=kTOFpid, Double_t prob=0.9)
void SetIsMuonMC(Bool_t isMC)
static AliFlowTrackCuts * GetStandardITSTPCTrackCuts2009(Bool_t selPrimaries=kTRUE)
void SetMaxKinkInvMassKmu(Double_t m)
void SetChi3A(TArrayD *Chi3A)
void SetMaxDCAToVertexXYPtDep(const char *a)
static AliFlowTrackCuts * GetStandardGlobalTrackCuts2010()
Double_t GetMinimalTPCdedx() const
Double_t GetMaxKinkQt() const
TList * list
void SetMaxKinkQt(Double_t m)
Double_t MaxChi2perITSClusterCuts(AliESDtrack *track)
Bool_t FillFlowTrackVParticle(AliFlowTrack *t) const
Bool_t GetRequireITSRefit() const
AliMuonTrackCuts * fMuonTrackCuts
Int_t GetRun() const
Bool_t PassesPMDcuts(const AliESDPmdTrack *track)
Float_t fMinChi2PerClusterTPC
Bool_t GetRequireTPCStandAlone() const
static const Int_t fgkNumberOfVZEROtracks
void SetDivSigma(Bool_t r)
static AliFlowTrackCuts * GetAODTrackCutsForFilterBit(UInt_t bit=1, TString suffix="")
Bool_t PassesNucleiSelection(const AliESDtrack *track)
TArrayD * GetChi2A()
void SetMaxChi2perITSCluster(Double_t b)
Bool_t GetRequireITSStandAlone() const
AliPID::EParticleType GetParticleID() const
void SetChi2A(TArrayD *Chi2A)
Float_t GetMaxChi2PerClusterITS() const
Int_t Count(AliVEvent *event=NULL)
Double_t GetPtTOFPIDoff()
virtual Bool_t IsSelected(TObject *obj, Int_t id=-666)
void SetParamType(trackParameterType paramType)
void SetMaxDCAToVertexXY(Float_t a)
static AliFlowTrackCuts * GetStandardVZEROOnlyTrackCuts2010()
Float_t GetNumberOfSigmas() const
AliESDpid fESDpid
placeholder for TPC only track to avoid new/delete on every track
Int_t fTrackLabel
track weight
Double_t GetPmdEta(Float_t xPos, Float_t yPos, Float_t zPos)
void SetEtaMax(Double_t max)
void SetVZEROgainEqualisationCen(TH2 *g)
TArrayD * GetChi2C()
void HandleESDtrack(AliESDtrack *track)
TDirectory * fPurityFunctionsList
purity functions file
Double_t fTrackPhi
track pt
void Clear(Option_t *option="")
AliESDv0 * fV0
placeholder for the current kink
AliESDtrackCuts * fAliESDtrackCuts
trackParameterType GetParamType() const
void SetFakesAreOK(Bool_t b)
void SetAODfilterBit(UInt_t a)
Float_t GetBeta(const AliVTrack *t, Bool_t QAmode=kFALSE)
Double_t fSPDtrackletDeltaPhiMax
Bool_t PassesAODcuts(const AliAODTrack *track, Bool_t passFid=kTRUE)
Float_t fMaxChi2PerClusterTPC
void SetRequireTPCRefit(Bool_t a)
void SetMCprocessType(TMCProcess t)
Bool_t PassesTOFbayesianCut(const AliAODTrack *track)
Double_t GetMinKinkInvMassKmu() const
void SetMinNClustersITS(Int_t a)
AliFlowBayesianPID * fBayesianResponse
Bool_t GetVZEROgainEqualizationPerRing() const
Bool_t PassesTOFpidCut(const AliESDtrack *track) const
TList * GetQA() const
static const char * GetParamTypeName(trackParameterType type)
Bool_t fRequireStrictTOFTPCagreement
void SetClusterRequirementITS(AliESDtrackCuts::Detector det, AliESDtrackCuts::ITSClusterRequirement req=AliESDtrackCuts::kOff)
Double_t GetMinKinkAngle() const
Bool_t TPCTOFagree(const AliVTrack *track)
void HandleVParticle(AliVParticle *track)
void SetSPDtrackletDeltaPhiMax(Double_t m)
Long64_t Merge(TCollection *list)
static AliFlowTrackCuts * GetStandardMuonTrackCuts(Bool_t isMC=kFALSE, Int_t passN=2)
Double_t * sigma
Int_t GetMinNClustersITS() const
Bool_t GetApplyRecentering() const
Bool_t PassesTPCpidCut(const AliESDtrack *track) const
Int_t GetNumberOfInputObjects() const
Bool_t fRequireTransportBitForPrimaries
void SetPtRange(Float_t r1, Float_t r2)
void SetVZEROgainEqualizationPerRing(Bool_t s)
void SetMinKinkRadius(Double_t r)
Bool_t PassesTPCbayesianCut(const AliESDtrack *track)
Bool_t fVZEROgainEqualizationPerRing
Bool_t PassesCuts(AliVParticle *track)
void SetRequireSigmaToVertex(Bool_t a)
const char * GetMaxDCAToVertexXYPtDep() const
void SetMinimalTPCdedx(Double_t d=10.)
AliMuonTrackCuts * GetMuonTrackCuts()
static AliFlowTrackCuts * GetStandardTPCStandaloneTrackCuts()
TH1 * QAafter(Int_t i)
void SetCutMChasTrackReferences(Bool_t b=kTRUE)
AliMCParticle * GetMCparticle() const
void SetIgnoreTPCzRange(Double_t min, Double_t max)
Float_t Getdedx(const AliESDtrack *t) const
Float_t GetMaxChi2PerClusterTPC() const
AliMCEvent * GetMCevent() const
Bool_t FillFlowTrack(AliFlowTrack *track) const
Double_t fMinKinkInvMassKmu
AliVEvent * fEvent
mc particle
void SetRequireITSRefit(Bool_t a)
void SetRejectElectronsWithTPCpid(Bool_t b=kTRUE)
TMCProcess GetMCprocessType() const
TH1 * QAbefore(Int_t i)
AliFlowTrack * FillFlowTrackVZERO(TObjArray *trackCollection, Int_t trackIndex) const
Bool_t PassesMuonCuts(AliVParticle *track)
void SetMinKinkAngle(Double_t a)
static AliFlowTrackCuts * GetStandardTPCStandaloneTrackCuts2010()
Bool_t GetForceTPCstandalone() const
Bool_t fUseVZERORing[8]
calibration info per ring
Float_t fNsigmaCut2
Pid reponse to manage Nsigma cuts.
Float_t fVZEROCpol[4]
calibration info per ring
trackParameterMix fParamMix
void SetVZEROCpol(Int_t ring, Float_t f)
static const Int_t fgkPIDptBin
Bool_t PassesESDpidCut(const AliESDtrack *track)
TArrayD * GetChi3A()
TMCProcess fMCprocessType
Bool_t GetDivSigma() const
PIDsource fPIDsource
Baysian response with all the TOF tuning (using fESDpid)
trackParameterMix GetParamMix() const
Double_t GetSPDtrackletDeltaPhiMax() const
void SetVZEROgainEqualisation(TH1 *g)
Bool_t GetMCisPrimary() const
void SetTPCpidCuts(const TMatrixF *mat)
TMatrixF * fTPCpidCuts
void SetEtaMin(Double_t min)
Double_t GetMaxKinkInvMassKmu() const
Bool_t IsPhysicalPrimary() const
Bool_t fLinearizeVZEROresponse
Double_t fTrackWeight
track eta
void SetIgnoreSignInMCPID(Bool_t b=kTRUE)
Double_t GetSPDtrackletDeltaPhiMin() const
Int_t GetMCPID() const
AliVEvent * GetEvent() const
Int_t GetPmdDetPlane() const
Bool_t GetRequireTPCRefit() const
Bool_t PassesTPCTOFNsigmaCut(const AliAODTrack *track)
void SetMCfirstMotherPID(Int_t pid)
AliPIDResponse * fPIDResponse
Bool_t GetDCAToVertex2D() const
Bool_t PassesTOFbetaSimpleCut(const AliESDtrack *track)
AliMCEvent * fMCevent
track label, or its absolute value if FakesAreOK
void SetMuonPassNumber(Int_t passN)
Bool_t PassesAODpidCut(const AliAODTrack *track)
UInt_t GetAODFilterBit() const
Bool_t PassesTPCdedxCut(const AliESDtrack *track)
AliFlowTrack * FillFlowTrackKink(TObjArray *trackCollection, Int_t trackIndex) const
void SetMinKinkQt(Double_t m)
trackParameterType fParamType
AliFlowBayesianPID * GetBayesianResponse() const
Double_t centMax
static const char * PIDsourceName(PIDsource s)
void SetParamMix(trackParameterMix paramMix)
Bool_t GetCutPID() const
void SetMCevent(AliMCEvent *mcEvent)
Bool_t GetUseVZERORing(Int_t i) const
void SetAcceptKinkDaughters(Bool_t a)
Bool_t PassesTOFbetaCut(const AliESDtrack *track)
Double_t fParticleProbability
Bool_t isMC
void SetCentralityPercentile(Int_t centMin, Int_t centMax)
Bool_t PassesVZEROcuts(Int_t id)
void SetMaxKinkRAdius(Double_t r)
void SetRunsMuon(const AliInputEventHandler *eventHandler)
Bool_t fCutRejectElectronsWithTPCpid
Double_t GetMaxKinkRadius() const
void SetEvent(AliVEvent *event, AliMCEvent *mcEvent=NULL)
void SetQA(Bool_t b=kTRUE)
TArrayD * GetChi3C()
Float_t GetMaxDCAToVertexXY() const
Bool_t fCutMChasTrackReferences
void SetPmdAdc(Float_t pmdAdc)
Float_t GetMaxDCAToVertexZ() const
AliMCParticle * fMCparticle
mc event
TH2 * fVZEROgainEqualizationCen
equalization histo
void SetPmdNcell(Float_t pmdNcell)
void SetMinNClustersTPC(Int_t a)
void SetNumberOfSigmas(Float_t val)
Int_t GetMinNClustersTPC() const
TF2 * fPurityFunction[180]
purity functions list
Float_t fC[fgkPIDptBin][5]
Bool_t GetRequireCharge() const
Double_t GetPmdPhi(Float_t xPos, Float_t yPos)
AliESDtrack fTPCtrack
placeholder for current event
AliESDpid & GetESDpid()
Float_t GetMaxNsigmaToVertex() const
void SetRequireStrictTOFTPCagreement(Bool_t b=kTRUE)
void SetForceTPCstandalone(Bool_t b)
void SetMaxChi2PerClusterITS(Float_t a)
Bool_t fCutSPDtrackletDeltaPhi
void SetMinChi2PerClusterTPC(Float_t a)
void SetRequireTransportBitForPrimaries(Bool_t b)
AliFlowTrackCuts & operator=(const AliFlowTrackCuts &someCuts)
void SetPtTOFPIDoff(Double_t pt)
Double_t fTrackEta
track phi
Bool_t GetAcceptKinkDaughters() const
Double_t fSPDtrackletDeltaPhiMin
void SetCutMC(Bool_t b=kTRUE)
Bool_t PassesTPCTOFNsigmaPurityCut(const AliAODTrack *track)
Double_t GetMinKinkQt() const
void SetUseVZERORing(Int_t i, Bool_t u)
void SetPriors(Float_t centr=0)
Bool_t FillFlowTrackGeneric(AliFlowTrack *t) const
AliVParticle * GetTrack() const
TMatrixF * fTOFpidCuts
Bool_t GetFakesAreOK() const
void SetRequireITSStandAlone(Bool_t a)
Int_t MaxSharedITSClusterCuts(AliESDtrack *track)
Bool_t GetAllowTOFmismatchFlag() const
void SetChi2C(TArrayD *Chi2C)
Bool_t PassesTPCTPCTOFNsigmaCut(const AliAODTrack *track)
Float_t fBinLimitPID[fgkPIDptBin]
Double_t fIgnoreTPCzRangeMin
static AliFlowTrackCuts * GetBetaVZEROOnlyTrackCuts()
void SetSPDtrackletDeltaPhiMin(Double_t m)
void GetEtaRange(Float_t &r1, Float_t &r2) const
Double_t fMaxKinkInvMassKmu
void SetMaxSharedITSCluster(Int_t b)
static AliFlowTrackCuts * GetStandardVZEROOnlyTrackCuts()
void SetTOFpidCuts(const TMatrixF *mat)
void Browse(TBrowser *b)
void ClearTrack(Option_t *option="")
void SetMinKinkInvMassKmu(Double_t m)
Float_t GetPmdNcell() const
Bool_t GetRequireStrictTOFTPCagreement() const
void SetLinearizeVZEROresponse(Bool_t b=kTRUE)
void SetVZEROApol(Int_t ring, Float_t f)
Float_t GetPmdAdc() const
Double_t centMin
void SetMCPID(Int_t pid)
Bool_t fApplyRecentering
equalization histo per centrality bin
void SetEtaRange(Float_t r1, Float_t r2)
Double_t fTrackMass
the track to apply cuts on
void SetTPCTOFNsigmaPIDPurityFunctions(Float_t purityLevel)
AliVParticle * fTrack
placeholder for the current V0