Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MultiDetectorMultiplicity.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file MultiDetectorMultiplicity.h
1 #ifndef MULTIDETECTORMULTIPLICITY_H__
2 #define MULTIDETECTORMULTIPLICITY_H__
3 
4 #include <fun4all/SubsysReco.h>
5 
7 class PHCompositeNode;
8 class TFile;
9 class TTree;
10 class TH1;
11 class TH2;
12 
15 {
16  public:
17  enum OBJECT
18  {
19  VERTEX = 0,
21  TRACKS = 2,
27  };
28 
30  MultiDetectorMultiplicity(const std::string &name = "MultiDetectorMultiplicity",
31  const std::string &fname = "MultiDetectorMultiplicity.root");
32 
33  // Destructor
35 
37  int Init(PHCompositeNode *);
38 
41 
43  int End(PHCompositeNode *);
44 
45  void initializeObjects();
46  float getFilteredNtracks(PHCompositeNode *topNode);
47  float getMVTXnclusters(PHCompositeNode *topNode);
48  float getEMCalTotalEnergy(PHCompositeNode *topNode);
49  float getIHCalTotalEnergy(PHCompositeNode *topNode);
50  float getOHCalTotalEnergy(PHCompositeNode *topNode);
51  float getsEPDTotalEnergy(PHCompositeNode *topNode);
52  void setCentralityHistoLabel(TH2 *histo, bool doYaxisLabels = false);
53  bool isVertexAccepted(PHCompositeNode *topNode);
54 
55  private:
58  const float _zVertexAcceptance = 10.; //cm
59  const unsigned int _nlayers_maps = 3;
60  const unsigned int _nlayers_intt = 4;
61  const unsigned int _nlayers_tpc = 48;
62 
64  TH2 *_tracks_EMCALenergy; // Track multiplicity (with selections) vs total EMCal energy
65  TH2 *_tracks_IHCALenergy; // Track multiplicity (with selections) vs total IHCal energy
66  TH2 *_tracks_OHCALenergy; // Track multiplicity (with selections) vs total OHCal energy
67  TH2 *_tracks_AllCALenergy; // Track multiplicity (with selections) vs total EMCal+IHCal+OHCal energy
68  TH2 *_tracks_MVTXclusters; // Track multiplicity (with selections) vs MVTX cluster multiplicity
69 
70  TH2 *_MVTXclusters_EMCALenergy; // MVTX cluster multiplicity vs total EMCal energy
71  TH2 *_MVTXclusters_IHCALenergy; // MVTX cluster multiplicity vs total IHCal energy
72  TH2 *_MVTXclusters_OHCALenergy; // MVTX cluster multiplicity vs total OHCal energy
73  TH2 *_MVTXclusters_AllCALenergy; // MVTX cluster multiplicity vs total EMCal+IHCal+OHCal energy
74 
75  TH2 *_EMCALenergy_IHCALenergy; // Total EMCal energy vs total IHCal energy
76  TH2 *_EMCALenergy_OHCALenergy; // Total EMCal energy vs total OHCal energy
77  TH2 *_IHCALenergy_OHCALenergy; // Total IHCal energy vs total OHCal energy
78 
79  TH2 *_MBDcentrality_tracks; // Centrality percentile (MBD) vs track multiplicity (with selections)
80  TH2 *_MBDcentrality_MVTXclusters; // Centrality percentile (MBD) vs MVTX cluster multiplicity
81  TH2 *_MBDcentrality_EMCALenergy; // Centrality percentile (MBD) vs total EMCal energy
82  TH2 *_MBDcentrality_IHCALenergy; // Centrality percentile (MBD) vs total IHCal energy
83  TH2 *_MBDcentrality_OHCALenergy; // Centrality percentile (MBD) vs total OHCal energy
84  TH2 *_MBDcentrality_AllCALenergy; // Centrality percentile (MBD) vs total EMCal+IHCal+OHCal energy
85  TH2 *_MBDcentrality_EPDenergy; // Centrality percentile (MBD) vs total sEPD energy
86 
87  TH2 *_EPDcentrality_tracks; // Centrality percentile (sEPD) vs track multiplicity (with selections)
88  TH2 *_EPDcentrality_MVTXclusters; // Centrality percentile (sEPD) vs MVTX cluster multiplicity
89  TH2 *_EPDcentrality_EMCALenergy; // Centrality percentile (sEPD) vs total EMCal energy
90  TH2 *_EPDcentrality_IHCALenergy; // Centrality percentile (sEPD) vs total IHCal energy
91  TH2 *_EPDcentrality_OHCALenergy; // Centrality percentile (sEPD) vs total OHCal energy
92  TH2 *_EPDcentrality_AllCALenergy; // Centrality percentile (sEPD) vs total EMCal+IHCal+OHCal energy
93  TH2 *_EPDcentrality_EPDenergy; // Centrality percentile (sEPD) vs total sEPD energy
94 
95  TH2 *_EPDcentrality_MBDcentrality; // Centrality percentile (sEPD) vs centrality percentile (sEPD)
96 
97  TH2 *_EPDenergy_tracks; // Total sEPD energy vs track multiplicity (with selections)
98  TH2 *_EPDenergy_MVTXclusters; // Total sEPD energy vs MVTX cluster multiplicity
99  TH2 *_EPDenergy_EMCALenergy; // Total sEPD energy vs total EMCal energy
100  TH2 *_EPDenergy_IHCALenergy; // Total sEPD energy vs total IHCal energy
101  TH2 *_EPDenergy_OHCALenergy; // Total sEPD energy vs total OHCal energy
102  TH2 *_EPDenergy_AllCALenergy; // Total sEPD energy vs total EMCal+IHCal+OHCal energy
103 
104  // This histo keeps track of the number of times certain objects were not found.
105  // Ideally this histogram should be EMPTY!!!
106  // For future updates including other objects, be sure to not reject the event before all objects are checked
108 
109 
110 
112  TFile *_outfile;
115 
116  const int _nbins = 100;
117  const float _track_bin_max = 1000.;
118  const float _mvtx_bin_max = 20000.;
119  const float _emcal_bin_max = 2000.;
120  const float _ihcal_bin_max = 200.;
121  const float _ohcal_bin_max = 500.;
123  const float _epd_bin_max = 20000.;
124 
125 };
126 
127 #endif