123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161 |
- #ifndef gregsTrackCut_hh
- #define gregsTrackCut_hh
- #include <Stsstream.h>
- #include "StHbtMaker/Base/StHbtTrackCut.h"
- class gregsTrackCut : public StHbtTrackCut
- {
- public:
- gregsTrackCut();
- gregsTrackCut(gregsTrackCut& );
- ~gregsTrackCut();
-
- virtual bool Pass(const StHbtTrack*);
- virtual StHbtString Report();
- void SetNSigmaElectron(const float& lo, const float& hi);
- void SetNSigmaPion(const float& lo, const float& hi);
- void SetNSigmaKaon(const float& lo, const float& hi);
- void SetNSigmaProton(const float& lo, const float& hi);
- void SetTofTrackTpcNSigmaElectron(const float& lo, const float& hi);
- void SetTofTrackTpcNSigmaPion(const float& lo, const float& hi);
- void SetTofTrackTpcNSigmaKaon(const float& lo, const float& hi);
- void SetTofTrackTpcNSigmaProton(const float& lo, const float& hi);
- void SetNHits(const int& lo, const int& hi);
- void SetNHitsFit(const int& lo, const int& hi);
- void SetNdEdxHits(const int& lo, const int& hi);
- void SetP(const float& lo, const float& hi);
- void SetPt(const float& lo, const float& hi);
- void SetPx(const float& lo, const float& hi);
- void SetPy(const float& lo, const float& hi);
- void SetPz(const float& lo, const float& hi);
- void SetRapidity(const float& lo, const float& hi);
- void SetEta(const float& lo, const float& hi);
- void SetDCA(const float& lo, const float& hi);
- void SetDCAGlobal(const float& lo, const float& hi);
- void SetCharge(const int&);
- void SetType(const short&);
- void SetTofMassSqr(const float& lo, const float& hi);
- void SetAntiSplit(const float& lo);
- void SetPIDSelection(const int& pidSel); //0-TPC, 1-ToF, 2-TnT, 3-ToT, 4-ToT(ToF+TPC or TPC only)
- void SetTpcTrackMom(const float& lo, const float& hi);
- void SetTpcTrackPt(const float& lo, const float& hi);
- void SetTofTrackMom(const float& lo, const float& hi);
- void SetTofTrackPt(const float& lo, const float& hi);
- void SetPartIdSelection(const int& val); //1-elec, 2-muon, 3-pion, 4-kaon, 5-proton
- void SetInverseBetaDifference(const float& lo, const float& hi);
- gregsTrackCut* Clone();
- ostrstream* finalReport() const;
- //private: // here are the quantities I want to cut on...
- protected:
- short mType;
- int mCharge;
- float mNSigmaElectron[2];
- float mNSigmaPion[2];
- float mNSigmaKaon[2];
- float mNSigmaProton[2];
- float mTofNSigmaElectron[2];
- float mTofNSigmaPion[2];
- float mTofNSigmaKaon[2];
- float mTofNSigmaProton[2];
- int mNHits[2];
- int mNHitsFit[2];
- int mNdEdxHits[2];
- float mP[2];
- float mPt[2];
- float mPx[2];
- float mPy[2];
- float mPz[2];
- float mRapidity[2];
- float mEta[2];
- float mDCA[2];
- float mDCAGlobal[2];
- float mTofMassSqr[2];
- float mAntiSplit;
- int mPIDSelection; //0-TPC, 1-ToF, 2-TnT, 3-ToT
- float mTpcTrackMom[2];
- float mTpcTrackPt[2];
- float mTofTrackMom[2];
- float mTofTrackPt[2];
- int mPartId; //1-elec, 2-muon, 3-pion, 4-kaon, 5-proton
- float mInverseBetaDifferce[2];
- protected:
- long mNTracksPassed;
- long mNTracksFailed;
- #ifdef __ROOT__
- ClassDef(gregsTrackCut, 1)
- #endif
- };
- inline void gregsTrackCut::SetPartIdSelection(const int& val) {mPartId = val;}
- inline void gregsTrackCut::SetNSigmaElectron(const float& lo, const float& hi) {
- mNSigmaElectron[0]=lo; mNSigmaElectron[1]=hi;}
- inline void gregsTrackCut::SetNSigmaPion(const float& lo, const float& hi) {
- mNSigmaPion[0]=lo; mNSigmaPion[1]=hi;}
- inline void gregsTrackCut::SetNSigmaKaon(const float& lo, const float& hi) {
- mNSigmaKaon[0]=lo; mNSigmaKaon[1]=hi;}
- inline void gregsTrackCut::SetNSigmaProton(const float& lo, const float& hi) {
- mNSigmaProton[0]=lo; mNSigmaProton[1]=hi;}
- inline void gregsTrackCut::SetPIDSelection(const int& pid) {mPIDSelection = pid;}
- inline void gregsTrackCut::SetNHits(const int& lo, const int& hi) {
- mNHits[0]=lo; mNHits[1]=hi;}
- inline void gregsTrackCut::SetNHitsFit(const int& lo, const int& hi) {
- mNHitsFit[0]=lo; mNHitsFit[1]=hi;}
- inline void gregsTrackCut::SetNdEdxHits(const int& lo, const int& hi) {
- mNdEdxHits[0]=lo; mNdEdxHits[1]=hi;}
- inline void gregsTrackCut::SetP(const float& lo, const float& hi) {mP[0]=lo; mP[1]=hi;}
- inline void gregsTrackCut::SetPt(const float& lo, const float& hi) {mPt[0]=lo; mPt[1]=hi;}
- inline void gregsTrackCut::SetPx(const float& lo, const float& hi) {mPx[0]=lo; mPx[1]=hi;}
- inline void gregsTrackCut::SetPy(const float& lo, const float& hi) {mPy[0]=lo; mPy[1]=hi;}
- inline void gregsTrackCut::SetPz(const float& lo, const float& hi) {mPz[0]=lo; mPz[1]=hi;}
- inline void gregsTrackCut::SetRapidity(const float& lo,const float& hi) {
- mRapidity[0]=lo; mRapidity[1]=hi;}
- inline void gregsTrackCut::SetEta(const float& lo,const float& hi) {mEta[0]=lo; mEta[1]=hi;}
- inline void gregsTrackCut::SetDCA(const float& lo,const float& hi) {mDCA[0]=lo; mDCA[1]=hi;}
- inline void gregsTrackCut::SetDCAGlobal(const float& lo,const float& hi) {
- mDCAGlobal[0]=lo; mDCAGlobal[1]=hi;}
- inline void gregsTrackCut::SetCharge(const int& ch) {mCharge = ch;}
- inline void gregsTrackCut::SetType(const short& type) {mType = type;}
- inline void gregsTrackCut::SetTofMassSqr(const float& lo, const float& hi) {
- mTofMassSqr[0]=lo; mTofMassSqr[1]=hi;}
- inline void gregsTrackCut::SetAntiSplit(const float& lo) {mAntiSplit = lo;}
- inline void gregsTrackCut::SetTpcTrackMom(const float& lo, const float& hi) {
- mTpcTrackMom[0]=lo; mTpcTrackMom[1]=hi;}
- inline void gregsTrackCut::SetTpcTrackPt(const float& lo, const float& hi) {
- mTpcTrackPt[0]=lo; mTpcTrackPt[1]=hi;}
- inline void gregsTrackCut::SetTofTrackMom(const float& lo, const float& hi) {
- mTofTrackMom[0]=lo; mTofTrackMom[1]=hi;}
- inline void gregsTrackCut::SetTofTrackPt(const float& lo, const float& hi) {
- mTofTrackPt[0]=lo; mTofTrackPt[1]=hi;}
- inline gregsTrackCut* gregsTrackCut::Clone() {
- gregsTrackCut* c = new gregsTrackCut(*this); return c;}
- inline void gregsTrackCut::SetInverseBetaDifference(const float& lo, const float& hi) {
- mInverseBetaDifferce[0]=lo; mInverseBetaDifferce[1]=hi;
- }
- inline void gregsTrackCut::SetTofTrackTpcNSigmaElectron(const float& lo, const float& hi) {
- mTofNSigmaElectron[0]=lo; mTofNSigmaElectron[1]=hi;
- }
- inline void gregsTrackCut::SetTofTrackTpcNSigmaPion(const float& lo, const float& hi) {
- mTofNSigmaPion[0]=lo; mTofNSigmaPion[1]=hi;
- }
- inline void gregsTrackCut::SetTofTrackTpcNSigmaKaon(const float& lo, const float& hi) {
- mTofNSigmaKaon[0]=lo; mTofNSigmaKaon[1]=hi;
- }
- inline void gregsTrackCut::SetTofTrackTpcNSigmaProton(const float& lo, const float& hi) {
- mTofNSigmaProton[0]=lo; mTofNSigmaProton[1]=hi;
- }
- #endif
|