StFemtoDstPythia6Maker.h 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. #ifndef STFEMTODSTPYTHIA6MAKER_HH
  2. #define STFEMTODSTPYTHIA6MAKER_HH
  3. #include "StMaker.h"
  4. #include "TFile.h"
  5. #include "TTree.h"
  6. #include "TPythia6.h"
  7. #include "TMCParticle.h"
  8. #include "TRandom3.h"
  9. #include "StFemtoEvent.h"
  10. #include "StFemtoTrack.h"
  11. #include <TVectorT.h>
  12. #include <TMatrixTLazy.h>
  13. #include <TMatrixDSymEigen.h>
  14. #include <iostream>
  15. #ifndef St_NO_NAMESPACES
  16. using namespace std;
  17. #endif
  18. //Predefinisions
  19. class StFemtoEvent;
  20. class StFemtoTrack;
  21. //_________________
  22. class StFemtoDstPythia6Maker : public StMaker {
  23. public:
  24. StFemtoDstPythia6Maker(TPythia6 *pythiaDst,
  25. const Char_t *oFileName);
  26. ~StFemtoDstPythia6Maker();
  27. //StMaker requirement
  28. void Clear(Option_t *option = "");
  29. Int_t Init();
  30. Int_t Make();
  31. Int_t Finish();
  32. void CleanVariables();
  33. //Event
  34. void SetTriggerId(const UInt_t& id) { mTriggerId = id;}
  35. void SetIsFullField(const Bool_t& field) { mIsFullField = field;}
  36. void SetSphericityCut(float ptCut) { mPtCut = ptCut; }
  37. //Track
  38. void SetParticleMomentum(const Float_t& lo, const Float_t& hi) { mTrackMomentum[0]=lo; mTrackMomentum[1]=hi; }
  39. void SetTrackDca(const Float_t& lo, const Float_t& hi) { mTrackDca[0]=lo; mTrackDca[1]=hi; }
  40. void SetTrackDcaGlobal(const Float_t& lo, const Float_t& hi) { mTrackDcaGlobal[0]=lo; mTrackDcaGlobal[1]=hi; }
  41. void SetTrackEta(const Float_t& lo, const Float_t& hi) { mTrackEta[0]=lo; mTrackEta[1]=hi; }
  42. //Exclusion cuts
  43. void SetRemovePions(Bool_t &remove) { mRemovePions = remove; }
  44. void SetRemoveKaons(Bool_t &remove) { mRemoveKaons = remove; }
  45. void SetRemoveProtons(Bool_t &remove) { mRemoveProtons = remove; }
  46. private:
  47. const Char_t *mOutFileName;
  48. TFile *mOutFile;
  49. TTree *mTree;
  50. Int_t mCompression;
  51. TPythia6* mPythiaDst; //Pointer to the pythia
  52. TRandom3 *randy;
  53. Int_t mNBytes;
  54. Int_t mNEventsIn;
  55. Bool_t mEventIsGood;
  56. Bool_t mIsGoodTrack;
  57. //Event information
  58. UInt_t mTriggerId;
  59. Bool_t mIsFullField;
  60. //Single-particle cuts
  61. Float_t mTrackMomentum[2];
  62. Float_t mTrackDca[2];
  63. Float_t mTrackDcaGlobal[2];
  64. Float_t mTrackEta[2];
  65. //Cuts for exclusion
  66. Bool_t mRemovePions;
  67. Bool_t mRemoveKaons;
  68. Bool_t mRemoveProtons;
  69. //
  70. // Sphericity
  71. //
  72. TMatrixTSym<double> *mMatrix; // transverse sphericity matrix
  73. float mPtCut;
  74. //Femto event structure
  75. StFemtoEvent *mFemtoEvent;
  76. //Main cut
  77. Bool_t AcceptTrack(TMCParticle *trk, Int_t charge);
  78. //dEdx calculation
  79. Double_t dedxMean(Double_t mass, Double_t momentum);
  80. ClassDef(StFemtoDstPythia6Maker, 2)
  81. };
  82. #endif