File indexing completed on 2026-04-07 08:08:32
0001 #ifndef AN_NEUTRAL_MESON_H__
0002 #define AN_NEUTRAL_MESON_H__
0003
0004 #include "ClusterSmallInfoContainer.h"
0005
0006 #include <fun4all/SubsysReco.h>
0007 #include <calobase/TowerInfoContainer.h>
0008 #include <calobase/RawClusterContainer.h>
0009
0010
0011 #include <ffarawobjects/Gl1Packet.h>
0012 #include <globalvertex/GlobalVertexMap.h>
0013 #include <globalvertex/MbdVertexMap.h>
0014
0015 #include <ffaobjects/SyncDefs.h>
0016 #include <ffaobjects/SyncObject.h>
0017
0018 #include <vector>
0019 #include <utility>
0020 #include <map>
0021 #include <fstream>
0022
0023 class Fun4AllHistoManager;
0024 class PHCompositeNode;
0025
0026 class TFile;
0027 class TH2F;
0028 class TH1F;
0029 class TH1;
0030 class TF1;
0031
0032
0033 const int nbunches = 120;
0034
0035 class AnNeutralMeson : public SubsysReco
0036 {
0037 public:
0038
0039
0040 AnNeutralMeson(const std::string &name = "AnNeutralMeson", const int& runnumber = 48748, const std::string &fname = "file.root", const std::string& folder = "");
0041
0042
0043 virtual ~AnNeutralMeson();
0044
0045
0046 int Init(PHCompositeNode *);
0047
0048
0049 int InitRun(PHCompositeNode *);
0050
0051
0052 int process_event(PHCompositeNode *);
0053 int process_towers(PHCompositeNode *);
0054
0055
0056 void CreateNodes(PHCompositeNode *);
0057
0058
0059 int End(PHCompositeNode *);
0060
0061 protected:
0062 int _runnumber;
0063 std::string outfilename;
0064 std::string outfolder;
0065 TFile *outfile_histograms = nullptr;
0066
0067
0068 Gl1Packet *gl1packet = nullptr;
0069 GlobalVertexMap *vertexmap = nullptr;
0070 RawClusterContainer *clusterContainer = nullptr;
0071 TowerInfoContainer *towers = nullptr;
0072
0073
0074 TH1F* h_event_vtx_z;
0075
0076
0077 TH1F* h_clusE;
0078 TH1F* h_clus_eta;
0079 TH1F* h_clus_phi;
0080 TH2F *h_clus_eta_phi;
0081 TH2F *h_clus_eta_E;
0082 TH2F *h_clus_eta_vtxz;
0083 TH1F* h_clus_pt;
0084 TH1F* h_clus_chisq;
0085 TH2F* h_etaphi_clus;
0086
0087
0088 float EMCal_E_cut = 0;
0089
0090
0091 float clus_chisq_cut = 1000;
0092 float clus_E_cut = 0.5;
0093
0094
0095 int _eventcounter;
0096 int _eventcounter_selection1 = 0;
0097 int _eventcounter_selection2 = 0;
0098 int _clustercounter = 0;
0099 int _clustercounter_selection = 0;
0100 unsigned long _countentry = 0;
0101
0102 bool getVtx = false;
0103
0104
0105 int bunchnumber = 0;
0106 unsigned long live_trigger = 0;
0107 unsigned long scaled_trigger = 0;
0108 float vtx_z = 0;
0109
0110
0111 std::string ClusterSmallInfoNodeName;
0112 ClusterSmallInfoContainer *_smallclusters;
0113
0114 SyncObject *syncobject{nullptr};
0115 };
0116
0117 #endif