StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StBET4pMaker.h
1 // -*- mode: c++;-*-
2 // $Id: StBET4pMaker.h,v 1.19 2014/08/06 11:43:22 jeromel Exp $
3 #ifndef STBET4PMAKER_H
4 #define STBET4PMAKER_H
5 
6 class StMuDstMaker;
9 class StBET4pMakerImp;
10 
12 
13 class StjTrackListCut;
18 
19 #include "StFourPMaker.h"
20 
21 class StBET4pMaker : public StFourPMaker {
22 
23 public:
24 
25  StBET4pMaker(const char* name, StMuDstMaker* maker, bool doTowerSwapFix = true, StjAbstractTowerEnergyCorrectionForTracks* correctTowerEnergyForTracks = 0);
26 
27  virtual ~StBET4pMaker() {}
28 
29  Int_t Init();
30  Int_t Make();
31 
32  void Clear(Option_t* opt = "");
33 
34  const vector<VertexNode>& getVertexNodes() const { return _vertexNodes; }
35 
36  void setUseTPC(bool v = true) { _useTPC = v; }
37  void setUseBEMC(bool v = true) { _useBEMC = v; }
38  void setUseEndcap(bool v = true) { _useEEMC = v; }
39  void setUse2003Cuts(bool v = true) { _use2003Cuts = v; }
40  void setUse2005Cuts(bool v = true) { _use2005Cuts = v; }
41  void setUse2006Cuts(bool v = true) { _use2006Cuts = v; }
42  void setUse2009Cuts(bool v = true) { _use2009Cuts = v; }
43  void setUseBEMCEnergySum(bool v = true) { _useBEMCEnergySum = v; }
44  void setUseBEMCEnergyVariation(bool v = true) { _useBEMCEnergyVariation = v; }
45  void setBEMCEnergyVariationRatio(double ratio) { _bemcEnergyVariationRatio= ratio; }
46 
47  // This method tells the maker to use a random selector when collecting
48  // tracks.
49  // v Specifies whether or not the random selector should be used. If
50  // true, then the random selector should be used. If false, the
51  // random selector should not be used.
52  void setUseRandomSelector(bool v = true) { _useRandomSelector = v; }
53 
54  // This method specifies how the random selector should be built.
55  // newProb The probability of randomly selecting a track for
56  // inclusion. This is a ratio in the range of [0,1].
57  // newAt Whether or not the specified probability should be an
58  // absolute threshold, so that exactly that ratio of tracks
59  // are selected. If true, then the probability represents an
60  // absolute threshold.
61  // newSeed The seed for the random number generator used in the
62  // RandomSelector. Zero specifies that a random seed should
63  // be generated. Keep in mind that if random seeds are
64  // generated too quickly by specifying "zero" that seeds may
65  // be identical. Seeds should be generated using this method
66  // at second intervals.
67  void setRandomSelector(
68  double newProb = 1.0,
69  bool newAt = false,
70  unsigned int newSeed = 0
71  )
72  {
73  _randomSelectorProb = newProb;
74  _randomSelectorAt = newAt;
75  _randomSelectorSeed = newSeed;
76  }
77 
78  int nDylanPoints() const;
79  double sumEmcEt() const;
80 
81  bool bemcCorrupt() const { return isBemcCorrupted(); }
82 
83  StBET4pMakerImp* GetImp() { return _imp; }
84 
85  const char* GetCVS() const
86  {static const char cvs[]="Tag $Name: $ $Id: StBET4pMaker.h,v 1.19 2014/08/06 11:43:22 jeromel Exp $ built " __DATE__ " " __TIME__; return cvs;}
87 
88 private:
89 
90  StjTreeEntryMaker* _entryMaker;
91 
92  StMuDstMaker* _uDstMaker;
93  bool _doTowerSwapFix;
94  StjAbstractTowerEnergyCorrectionForTracks* _correctTowerEnergyForTracks;
95 
96  bool _useTPC;
97  bool _useBEMC;
98  bool _useEEMC;
99  bool _use2003Cuts;
100  bool _use2005Cuts;
101  bool _use2006Cuts;
102  bool _use2009Cuts;
103  bool _useBEMCEnergySum;
104  bool _useRandomSelector;
105  bool _useBEMCEnergyVariation;
106  double _bemcEnergyVariationRatio;
107 
108  StBET4pMakerImp* _imp;
109  StjeBemcEnergySumCalculator* _bemcEnergySumCalculator;
112 
113  double _randomSelectorProb;
114  bool _randomSelectorAt;
115  unsigned int _randomSelectorSeed;
116 
117  bool isBemcCorrupted() const;
118 
119  ClassDef(StBET4pMaker,0)
120 };
121 
122 #endif // STBET4PMAKER_H
void Clear(Option_t *opt="")
User defined functions.