mikesStarStandardEventCut.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. /***************************************************************************
  2. *
  3. * $Id: mikesStarStandardEventCut.h,v 1.3 2003/09/02 17:58:21 perev Exp $
  4. *
  5. * Author: Mike Lisa, Ohio State, lisa@mps.ohio-state.edu
  6. ***************************************************************************
  7. *
  8. * Description: part of STAR HBT Framework: StHbtMaker package
  9. * A simple event-wise cut that selects on multiplicity and z-position
  10. * of primary vertex. This one calculates and then cuts on the number of
  11. * negative primary tracks with -0.5<eta<0.5, which is the STAR standard.
  12. * The cuts are (copied from StEventUtilities/StuRefMult.hh
  13. * primary tracks only
  14. * flag > 0
  15. * charge < 0
  16. * fit points >= 10
  17. * abs(eta) < 0.5
  18. * dca < 3 cm
  19. *
  20. ***************************************************************************
  21. *
  22. * $Log: mikesStarStandardEventCut.h,v $
  23. * Revision 1.3 2003/09/02 17:58:21 perev
  24. * gcc 3.2 updates + WarnOff
  25. *
  26. * Revision 1.2 2001/04/25 17:57:46 perev
  27. * HPcorrs
  28. *
  29. * Revision 1.1 2000/09/04 16:27:15 lisa
  30. * added StarStandard multiplicity cut and modified mikesTrackCut to allow NOT cutting on charge sign
  31. *
  32. *
  33. **************************************************************************/
  34. #ifndef mikesStarStandardEventCut_hh
  35. #define mikesStarStandardEventCut_hh
  36. #include "StHbtMaker/Base/StHbtEventCut.h"
  37. #ifdef HPUX
  38. #include "Stiostream.h"
  39. #else
  40. #include <fstream>
  41. #endif
  42. class mikesStarStandardEventCut : public StHbtEventCut {
  43. public:
  44. mikesStarStandardEventCut();
  45. mikesStarStandardEventCut(mikesStarStandardEventCut&);
  46. // ~mikesStarStandardEventCut();
  47. void SetEventMult(const int& lo,const int& hi);
  48. void SetVertZPos(const float& lo, const float& hi);
  49. int NEventsPassed();
  50. int NEventsFailed();
  51. virtual StHbtString Report();
  52. virtual bool Pass(const StHbtEvent*);
  53. mikesStarStandardEventCut* Clone();
  54. private: // here are the quantities I want to cut on...
  55. int mEventMult[2]; // range of multiplicity
  56. float mVertZPos[2]; // range of z-position of vertex
  57. long mNEventsPassed;
  58. long mNEventsFailed;
  59. ofstream* mOutFile; //!
  60. #ifdef __ROOT__
  61. ClassDef(mikesStarStandardEventCut, 0)
  62. #endif
  63. };
  64. inline void mikesStarStandardEventCut::SetEventMult(const int& lo, const int& hi){mEventMult[0]=lo; mEventMult[1]=hi;}
  65. inline void mikesStarStandardEventCut::SetVertZPos(const float& lo, const float& hi){mVertZPos[0]=lo; mVertZPos[1]=hi;}
  66. inline int mikesStarStandardEventCut::NEventsPassed() {return mNEventsPassed;}
  67. inline int mikesStarStandardEventCut::NEventsFailed() {return mNEventsFailed;}
  68. inline mikesStarStandardEventCut* mikesStarStandardEventCut::Clone() { mikesStarStandardEventCut* c = new mikesStarStandardEventCut(*this); return c;}
  69. inline mikesStarStandardEventCut::mikesStarStandardEventCut(mikesStarStandardEventCut& c) : StHbtEventCut(c) {
  70. mEventMult[0] = c.mEventMult[0];
  71. mEventMult[1] = c.mEventMult[1];
  72. mVertZPos[0] = c.mVertZPos[0];
  73. mVertZPos[1] = c.mVertZPos[1];
  74. mNEventsPassed = 0;
  75. mNEventsFailed = 0;
  76. }
  77. #endif