MpdFemtoFxtTrackCutMonitor.h 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272
  1. /**
  2. * \class MpdFemtoFxtTrackCutMonitor
  3. * \brief Track cut monitor for basic analysis
  4. *
  5. * The class provides histograms for monitoring track cuts
  6. *
  7. * \author Grigory Nigmatkulov (NRNU MEPhI)
  8. * \date May 18, 2019
  9. * \email nigmatkulov@gmail.com
  10. */
  11. #ifndef MpdFemtoFxtTrackCutMonitor_h
  12. #define MpdFemtoFxtTrackCutMonitor_h
  13. // MpdFemtoMaker headers
  14. // Base
  15. #include "MpdFemtoBaseCutMonitor.h"
  16. // ROOT headers
  17. #include "TH1F.h"
  18. #include "TH2F.h"
  19. // Forward declaration
  20. class MpdFemtoTrack;
  21. //_________________
  22. class MpdFemtoFxtTrackCutMonitor : public MpdFemtoBaseCutMonitor {
  23. public:
  24. /// Constructor with mass
  25. MpdFemtoFxtTrackCutMonitor(const char*, const double);
  26. /// Copy constructor
  27. MpdFemtoFxtTrackCutMonitor(const MpdFemtoFxtTrackCutMonitor& cutMoni);
  28. /// Assignment operator
  29. MpdFemtoFxtTrackCutMonitor operator=(const MpdFemtoFxtTrackCutMonitor& c);
  30. /// Destructor
  31. virtual ~MpdFemtoFxtTrackCutMonitor();
  32. /// Fill histograms with track information
  33. virtual void fill(const MpdFemtoTrack* track);
  34. /// Write all histograms
  35. void writeOutHistos();
  36. /// Ouput list with histograms
  37. virtual TList* getOutputList();
  38. // These dummy Fill() functions were introduced to remove a compiler
  39. // warning related to overloaded base-class Fill() functions being
  40. // hidden by a single version of Fill() in this derived class
  41. void fill(const MpdFemtoEvent* /* d */) {
  42. ;
  43. }
  44. void fill(const MpdFemtoV0* /* d */) {
  45. ;
  46. }
  47. void fill(const MpdFemtoXi* /* xi */) {
  48. ;
  49. }
  50. void fill(const MpdFemtoKink* /* d */) {
  51. ;
  52. }
  53. void fill(const MpdFemtoPair* /* d */) {
  54. ;
  55. }
  56. void fill(const MpdFemtoParticleCollection* /* d */) {
  57. ;
  58. }
  59. void fill(const MpdFemtoEvent* /* d1 */, const MpdFemtoParticleCollection* /* d2 */) {
  60. ;
  61. }
  62. void fill(const MpdFemtoParticleCollection* /* d1 */, const MpdFemtoParticleCollection* /* d2 */) {
  63. ;
  64. }
  65. /// DCA of the track
  66. TH1F* dcaGlobal() {
  67. return (mDCAGlobal) ? mDCAGlobal : nullptr;
  68. }
  69. /// DCA of the track
  70. TH1F* DCAGlobal() {
  71. return dcaGlobal();
  72. }
  73. /// Number of hits
  74. TH1F* nHits() {
  75. return (mNhits) ? mNhits : nullptr;
  76. }
  77. /// Number of hits
  78. TH1F* NHits() {
  79. return nHits();
  80. }
  81. /// Track momentum
  82. TH1F* p() {
  83. return (mP) ? mP : nullptr;
  84. }
  85. /// Track momentum
  86. TH1F* P() {
  87. return p();
  88. }
  89. /// Track transverse momentum
  90. TH1F* pt() {
  91. return (mPt) ? mPt : nullptr;
  92. }
  93. /// Track transverse momentum
  94. TH1F* Pt() {
  95. return pt();
  96. }
  97. /// nSigma(pion) vs pT
  98. TH2F* nSigmaPionVsPt() {
  99. return (mPtVsNsigmaPion) ? mPtVsNsigmaPion : nullptr;
  100. }
  101. /// nSigma(pion) vs pT
  102. TH2F* NSigmaPionVsPt() {
  103. return nSigmaPionVsPt();
  104. }
  105. /// nSigma(pion) vs pT
  106. TH2F* PtVsNsigmaPion() {
  107. return nSigmaPionVsPt();
  108. }
  109. /// nSigma(kaon) vs pT
  110. TH2F* nSigmaKaonVsPt() {
  111. return (mPtVsNsigmaKaon) ? mPtVsNsigmaKaon : nullptr;
  112. }
  113. /// nSigma(kaon) vs pT
  114. TH2F* NSigmaKaonVsPt() {
  115. return nSigmaKaonVsPt();
  116. }
  117. /// nSigma(kaon) vs pT
  118. TH2F* PtVsNsigmaKaon() {
  119. return nSigmaKaonVsPt();
  120. }
  121. /// nSigma(proton) vs pT
  122. TH2F* nSigmaProtonVsPt() {
  123. return (mPtVsNsigmaProton) ? mPtVsNsigmaProton : nullptr;
  124. }
  125. /// nSigma(proton) vs pT
  126. TH2F* NSigmaProtonVsPt() {
  127. return nSigmaProtonVsPt();
  128. }
  129. /// nSigma(proton) vs pT
  130. TH2F* PtVsNsigmaProton() {
  131. return nSigmaProtonVsPt();
  132. }
  133. /// dE/dx vs momentum
  134. TH2F* dEdxVsP() {
  135. return (mPvsDedx) ? mPvsDedx : nullptr;
  136. }
  137. /// dE/dx vs momentum
  138. TH2F* DedxVsP() {
  139. return dEdxVsP();
  140. }
  141. /// dE/dx vs momentum
  142. TH2F* PvsDedx() {
  143. return dEdxVsP();
  144. }
  145. /// Pseudorapidity
  146. TH1F* eta() {
  147. return (mPseudoRapidity) ? mPseudoRapidity : nullptr;
  148. }
  149. /// Pseudorapidity
  150. TH1F* Eta() {
  151. return eta();
  152. }
  153. /// Pseudorapidity
  154. TH1F* PseudoRapidity() {
  155. return eta();
  156. }
  157. /// Square of mass vs. momentum
  158. TH2F* massSqrVsP() {
  159. return (mPvsMassSqr) ? mPvsMassSqr : nullptr;
  160. }
  161. /// Square of mass vs. momentum
  162. TH2F* MassSqrVsP() {
  163. return massSqrVsP();
  164. }
  165. /// Square of mass vs. momentum
  166. TH2F* PvsMassSqr() {
  167. return massSqrVsP();
  168. }
  169. /// Inversed beta vs. momentum
  170. TH2F* inversedBetaVsP() {
  171. return (mPvsInvBeta) ? mPvsInvBeta : nullptr;
  172. }
  173. /// Inversed beta vs. momentum
  174. TH2F* InversedBetaVsP() {
  175. return inversedBetaVsP();
  176. }
  177. /// Inversed beta vs. momentum
  178. TH2F* PvsInvBeta() {
  179. return inversedBetaVsP();
  180. }
  181. /// Transverse momenum vs. pseudorapidity
  182. TH2F* ptVsEta() {
  183. return (mPtVsEta) ? mPtVsEta : nullptr;
  184. }
  185. /// Transverse momenum vs. pseudorapidity
  186. TH2F* PtVsEta() {
  187. return ptVsEta();
  188. }
  189. /// Inveresed beta minus inversed beta for pion hypothesis vs. momentum
  190. TH2F* inversedBetaDiffPionVsP() {
  191. return (mInvBetaDiffPionVsP) ? mInvBetaDiffPionVsP : nullptr;
  192. }
  193. /// Inveresed beta minus inversed beta for pion hypothesis vs. momentum
  194. TH2F* InversedBetaDiffPionVsP() {
  195. return inversedBetaDiffPionVsP();
  196. }
  197. /// Inveresed beta minus inversed beta for kaon hypothesis vs. momentum
  198. TH2F* inversedBetaDiffKaonVsP() {
  199. return (mInvBetaDiffKaonVsP) ? mInvBetaDiffKaonVsP : nullptr;
  200. }
  201. /// Inveresed beta minus inversed beta for kaon hypothesis vs. momentum
  202. TH2F* InversedBetaDiffKaonVsP() {
  203. return inversedBetaDiffKaonVsP();
  204. }
  205. /// Inveresed beta minus inversed beta for proton hypothesis vs. momentum
  206. TH2F* inversedBetaDiffProtonVsP() {
  207. return (mInvBetaDiffProtonVsP) ? mInvBetaDiffProtonVsP : nullptr;
  208. }
  209. /// Inveresed beta minus inversed beta for proton hypothesis vs. momentum
  210. TH2F* InversedBetaDiffProtonVsP() {
  211. return inversedBetaDiffProtonVsP();
  212. }
  213. private:
  214. /// DCA of the track to primary vertex
  215. TH1F* mDCAGlobal;
  216. /// Number of hits
  217. TH1F* mNhits;
  218. /// Momentum
  219. TH1F* mP;
  220. /// Transverse momentum
  221. TH1F* mPt;
  222. /// nSigma(pi) vs. transverse momentum
  223. TH2F* mPtVsNsigmaPion;
  224. /// nSigma(K) vs. transverse momentum
  225. TH2F* mPtVsNsigmaKaon;
  226. /// nSigma(p) vs. transverse momentum
  227. TH2F* mPtVsNsigmaProton;
  228. /// dE/dx vs. momentum
  229. TH2F* mPvsDedx;
  230. /// Rapidity
  231. TH1F* mRapidity;
  232. /// Pseudorapidity
  233. TH1F* mPseudoRapidity;
  234. /// Squared mass vs. momentum
  235. TH2F* mPvsMassSqr;
  236. /// Inversed beta vs. momentum
  237. TH2F* mPvsInvBeta;
  238. /// Pseudorapidity vs. transverse momentum
  239. TH2F* mPtVsEta;
  240. /// Inversed beta minus inversed beta for pion hypothesis vs. momentum
  241. TH2F* mInvBetaDiffPionVsP;
  242. /// Inversed beta minus inversed beta for kaon hypothesis vs. momentum
  243. TH2F* mInvBetaDiffKaonVsP;
  244. /// Inversed beta minus inversed beta for proton hypothesis vs. momentum
  245. TH2F* mInvBetaDiffProtonVsP;
  246. /// Particle mass
  247. double monMass;
  248. ClassDef(MpdFemtoFxtTrackCutMonitor, 3)
  249. };
  250. #endif // #define MpdFemtoFxtTrackCutMonitor_h