ROOT logo
///////////////////////////////////////////////////////////////////////////
//                                                                       //
// AliFemtoQATrackCut: A basic track cut that used information from     //
// ALICE ESD to accept or reject the track.                              //  
// Enables the selection on charge, transverse momentum, rapidity,       //
// pid probabilities, number of ITS and TPC clusters                     //
// Author: Marek Chojnacki (WUT), mchojnacki@knf.pw.edu.pl               //
//                                                                       //
///////////////////////////////////////////////////////////////////////////

#ifndef AliFemtoQATrackCut_H
#define AliFemtoQATrackCut_H

//#ifndef StMaker_H
//#include "StMaker.h"
//#endif

#include "AliFemtoTrackCut.h"

class AliFemtoQATrackCut : public AliFemtoTrackCut 
{

 public:
  AliFemtoQATrackCut();
  virtual ~AliFemtoQATrackCut();

  virtual bool Pass(const AliFemtoTrack* aTrack);

  virtual AliFemtoString Report();
  virtual TList *ListSettings();
  virtual AliFemtoParticleType Type(){return hbtTrack;}

  void SetPt(const float& lo, const float& hi);
  void SetRapidity(const float& lo, const float& hi);
  void SetCharge(const int& ch);
  void SetPidProbElectron(const float& lo, const float& hi);
  void SetPidProbPion(const float& lo, const float& hi);
  void SetPidProbKaon(const float& lo, const float& hi);
  void SetPidProbProton(const float& lo, const float& hi);
  void SetPidProbMuon(const float& lo, const float& hi);
  void SetLabel(const bool& flag);
  void SetStatus(const long& w);
  void SetminTPCclsF(const short& s);
  void SetminTPCncls(const short& s);
  void SetminITScls(const int& s);
  void SetminTPCchiNdof(const float& s);
  void SetRemoveKinks(const bool& flag);
  void SetMaxTPCncls(const short& s);
  void SetMaxITSChiNdof(const float& maxchi);
  void SetMaxTPCChiNdof(const float& maxchi);
  void SetMaxSigmaToVertex(const float& maxsig);
  void SetMostProbablePion();
  void SetMostProbableKaon();
  void SetMostProbableProton();
  void SetNoMostProbable(); 
  
  void SetTPCnclsExclusionSwitch(const bool& excluSwitch);
  void SetTPCnclsExclusion(const short& lo, const short& hi);
  void SetTPCchiNdofExclusionSwitch(const bool& excluSwitch);
  void SetTPCchiNdofExclusion(const float& lo, const float& hi);

 private:   // here are the quantities I want to cut on...

  int               fCharge;             // particle charge
  float             fPt[2];              // bounds for transverse momentum
  float             fRapidity[2];        // bounds for rapidity
  float             fPidProbElectron[2]; // bounds for electron probability
  float             fPidProbPion[2];     // bounds for pion probability
  float             fPidProbKaon[2];     // bounds for kaon probability
  float             fPidProbProton[2];   // bounds for proton probability
  float             fPidProbMuon[2];     // bounds for muon probability 
  bool              fLabel;              // if true label<0 will not pass throught 
  long              fStatus;             // staus flag

  short             fminTPCclsF;         // min number of findable clusters in the TPC
  short             fminTPCncls;         // min number of clusters in the TPC
  int               fminITScls;          // min number of clusters assigned in the ITS 
  float             fminTPCchiNdof;      // min allowed chi2/ndof for TPC clusters
  short             fMaxTPCncls;         // maximum allowed clusters in the TPC
  float             fMaxITSchiNdof;      // maximum allowed chi2/ndof for ITS clusters
  float             fMaxTPCchiNdof;      // maximum allowed chi2/ndof for TPC clusters
  float             fMaxSigmaToVertex;   // maximum allowed sigma to primary vertex
  long              fNTracksPassed;      // passed tracks count
  long              fNTracksFailed;      // failed tracks count
  bool              fRemoveKinks;        // if true particles with any kink label will not pass
  int               fMostProbable;       // this particle type is required to be most probable
  
  bool    fTPCnclsExclusionSwitch;       // turn on/off TPCncls exclusion zone (true=on)
  short   fTPCnclsExclusion[2];          // lower and upper limit of TPCncls QA exclusion zone
  bool    fTPCchiNdofExclusionSwitch;        // turn on/off TPCchi exclusion zone (true=on)
  float   fTPCchiNdofExclusion[2];           // lower and upper limit of TPCchi QA exclusion zone

  float PidFractionElectron(float mom) const;
  float PidFractionPion(float mom) const;
  float PidFractionKaon(float mom) const;
  float PidFractionProton(float mom) const;

#ifdef __ROOT__ 
  ClassDef(AliFemtoQATrackCut, 1)
#endif
    };


inline void AliFemtoQATrackCut::SetPt(const float& lo, const float& hi){fPt[0]=lo; fPt[1]=hi;}
inline void AliFemtoQATrackCut::SetRapidity(const float& lo,const float& hi){fRapidity[0]=lo; fRapidity[1]=hi;}
inline void AliFemtoQATrackCut::SetCharge(const int& ch){fCharge = ch;}
inline void AliFemtoQATrackCut::SetPidProbElectron(const float& lo,const float& hi){fPidProbElectron[0]=lo; fPidProbElectron[1]=hi;}
inline void AliFemtoQATrackCut::SetPidProbPion(const float& lo,const float& hi){fPidProbPion[0]=lo; fPidProbPion[1]=hi;}
inline void AliFemtoQATrackCut::SetPidProbKaon(const float& lo,const float& hi){fPidProbKaon[0]=lo; fPidProbKaon[1]=hi;}
inline void AliFemtoQATrackCut::SetPidProbProton(const float& lo,const float& hi){fPidProbProton[0]=lo; fPidProbProton[1]=hi;}
inline void AliFemtoQATrackCut::SetPidProbMuon(const float& lo,const float& hi){fPidProbMuon[0]=lo; fPidProbMuon[1]=hi;}
inline void AliFemtoQATrackCut::SetLabel(const bool& flag){fLabel=flag;}
inline void AliFemtoQATrackCut::SetStatus(const long& status){fStatus=status;}
inline void AliFemtoQATrackCut::SetminTPCclsF(const short& minTPCclsF){fminTPCclsF=minTPCclsF;}
inline void AliFemtoQATrackCut::SetminTPCncls(const short& s){fminTPCncls=s;}
inline void AliFemtoQATrackCut::SetminITScls(const int& minITScls){fminITScls=minITScls;}
inline void AliFemtoQATrackCut::SetminTPCchiNdof(const float& s){fminTPCchiNdof = s;}
inline void AliFemtoQATrackCut::SetMostProbablePion() { fMostProbable = 2; }
inline void AliFemtoQATrackCut::SetMostProbableKaon() { fMostProbable = 3; }
inline void AliFemtoQATrackCut::SetMostProbableProton() { fMostProbable = 4; }
inline void AliFemtoQATrackCut::SetNoMostProbable() { fMostProbable = 0; }
inline void AliFemtoQATrackCut::SetMaxTPCncls(const short& s){fMaxTPCncls=s;}
inline void AliFemtoQATrackCut::SetMaxITSChiNdof(const float& maxchi) { fMaxITSchiNdof = maxchi; }
inline void AliFemtoQATrackCut::SetMaxTPCChiNdof(const float& maxchi) { fMaxTPCchiNdof = maxchi; }
inline void AliFemtoQATrackCut::SetMaxSigmaToVertex(const float& maxsig) { fMaxSigmaToVertex = maxsig; }

inline void AliFemtoQATrackCut::SetTPCnclsExclusionSwitch(const bool& excluSwitch) { fTPCnclsExclusionSwitch = excluSwitch; }
inline void AliFemtoQATrackCut::SetTPCnclsExclusion(const short& lo, const short& hi) {fTPCnclsExclusion[0] = lo; fTPCnclsExclusion[1] = hi;}
inline void AliFemtoQATrackCut::SetTPCchiNdofExclusionSwitch(const bool& excluSwitch) { fTPCchiNdofExclusionSwitch = excluSwitch; }
inline void AliFemtoQATrackCut::SetTPCchiNdofExclusion(const float& lo, const float& hi) {fTPCchiNdofExclusion[0] = lo; fTPCchiNdofExclusion[1] = hi;}

#endif

 AliFemtoQATrackCut.h:1
 AliFemtoQATrackCut.h:2
 AliFemtoQATrackCut.h:3
 AliFemtoQATrackCut.h:4
 AliFemtoQATrackCut.h:5
 AliFemtoQATrackCut.h:6
 AliFemtoQATrackCut.h:7
 AliFemtoQATrackCut.h:8
 AliFemtoQATrackCut.h:9
 AliFemtoQATrackCut.h:10
 AliFemtoQATrackCut.h:11
 AliFemtoQATrackCut.h:12
 AliFemtoQATrackCut.h:13
 AliFemtoQATrackCut.h:14
 AliFemtoQATrackCut.h:15
 AliFemtoQATrackCut.h:16
 AliFemtoQATrackCut.h:17
 AliFemtoQATrackCut.h:18
 AliFemtoQATrackCut.h:19
 AliFemtoQATrackCut.h:20
 AliFemtoQATrackCut.h:21
 AliFemtoQATrackCut.h:22
 AliFemtoQATrackCut.h:23
 AliFemtoQATrackCut.h:24
 AliFemtoQATrackCut.h:25
 AliFemtoQATrackCut.h:26
 AliFemtoQATrackCut.h:27
 AliFemtoQATrackCut.h:28
 AliFemtoQATrackCut.h:29
 AliFemtoQATrackCut.h:30
 AliFemtoQATrackCut.h:31
 AliFemtoQATrackCut.h:32
 AliFemtoQATrackCut.h:33
 AliFemtoQATrackCut.h:34
 AliFemtoQATrackCut.h:35
 AliFemtoQATrackCut.h:36
 AliFemtoQATrackCut.h:37
 AliFemtoQATrackCut.h:38
 AliFemtoQATrackCut.h:39
 AliFemtoQATrackCut.h:40
 AliFemtoQATrackCut.h:41
 AliFemtoQATrackCut.h:42
 AliFemtoQATrackCut.h:43
 AliFemtoQATrackCut.h:44
 AliFemtoQATrackCut.h:45
 AliFemtoQATrackCut.h:46
 AliFemtoQATrackCut.h:47
 AliFemtoQATrackCut.h:48
 AliFemtoQATrackCut.h:49
 AliFemtoQATrackCut.h:50
 AliFemtoQATrackCut.h:51
 AliFemtoQATrackCut.h:52
 AliFemtoQATrackCut.h:53
 AliFemtoQATrackCut.h:54
 AliFemtoQATrackCut.h:55
 AliFemtoQATrackCut.h:56
 AliFemtoQATrackCut.h:57
 AliFemtoQATrackCut.h:58
 AliFemtoQATrackCut.h:59
 AliFemtoQATrackCut.h:60
 AliFemtoQATrackCut.h:61
 AliFemtoQATrackCut.h:62
 AliFemtoQATrackCut.h:63
 AliFemtoQATrackCut.h:64
 AliFemtoQATrackCut.h:65
 AliFemtoQATrackCut.h:66
 AliFemtoQATrackCut.h:67
 AliFemtoQATrackCut.h:68
 AliFemtoQATrackCut.h:69
 AliFemtoQATrackCut.h:70
 AliFemtoQATrackCut.h:71
 AliFemtoQATrackCut.h:72
 AliFemtoQATrackCut.h:73
 AliFemtoQATrackCut.h:74
 AliFemtoQATrackCut.h:75
 AliFemtoQATrackCut.h:76
 AliFemtoQATrackCut.h:77
 AliFemtoQATrackCut.h:78
 AliFemtoQATrackCut.h:79
 AliFemtoQATrackCut.h:80
 AliFemtoQATrackCut.h:81
 AliFemtoQATrackCut.h:82
 AliFemtoQATrackCut.h:83
 AliFemtoQATrackCut.h:84
 AliFemtoQATrackCut.h:85
 AliFemtoQATrackCut.h:86
 AliFemtoQATrackCut.h:87
 AliFemtoQATrackCut.h:88
 AliFemtoQATrackCut.h:89
 AliFemtoQATrackCut.h:90
 AliFemtoQATrackCut.h:91
 AliFemtoQATrackCut.h:92
 AliFemtoQATrackCut.h:93
 AliFemtoQATrackCut.h:94
 AliFemtoQATrackCut.h:95
 AliFemtoQATrackCut.h:96
 AliFemtoQATrackCut.h:97
 AliFemtoQATrackCut.h:98
 AliFemtoQATrackCut.h:99
 AliFemtoQATrackCut.h:100
 AliFemtoQATrackCut.h:101
 AliFemtoQATrackCut.h:102
 AliFemtoQATrackCut.h:103
 AliFemtoQATrackCut.h:104
 AliFemtoQATrackCut.h:105
 AliFemtoQATrackCut.h:106
 AliFemtoQATrackCut.h:107
 AliFemtoQATrackCut.h:108
 AliFemtoQATrackCut.h:109
 AliFemtoQATrackCut.h:110
 AliFemtoQATrackCut.h:111
 AliFemtoQATrackCut.h:112
 AliFemtoQATrackCut.h:113
 AliFemtoQATrackCut.h:114
 AliFemtoQATrackCut.h:115
 AliFemtoQATrackCut.h:116
 AliFemtoQATrackCut.h:117
 AliFemtoQATrackCut.h:118
 AliFemtoQATrackCut.h:119
 AliFemtoQATrackCut.h:120
 AliFemtoQATrackCut.h:121
 AliFemtoQATrackCut.h:122
 AliFemtoQATrackCut.h:123
 AliFemtoQATrackCut.h:124
 AliFemtoQATrackCut.h:125
 AliFemtoQATrackCut.h:126
 AliFemtoQATrackCut.h:127
 AliFemtoQATrackCut.h:128
 AliFemtoQATrackCut.h:129
 AliFemtoQATrackCut.h:130
 AliFemtoQATrackCut.h:131
 AliFemtoQATrackCut.h:132
 AliFemtoQATrackCut.h:133