File indexing completed on 2025-08-05 08:11:06
0001 #ifndef SigmaTimingNtuple_h__
0002 #define SigmaTimingNtuple_h__
0003
0004 #include <fun4all/SubsysReco.h>
0005
0006 #ifndef __CINT__
0007 #include <gsl/gsl_rng.h>
0008 #endif
0009
0010 #include <map>
0011 #include <set>
0012 #include <string>
0013 #include <vector>
0014
0015
0016 class Fun4AllHistoManager;
0017 class PHCompositeNode;
0018 class PHG4Hit;
0019 class TFile;
0020 class TH1;
0021 class TH2;
0022 class TNtuple;
0023
0024 class SigmaTimingNtuple: public SubsysReco
0025 {
0026 public:
0027
0028
0029 SigmaTimingNtuple( const std::string &name = "SigmaTimingNtuple", const std::string &filename = "SigmaTimingNtuple.root" );
0030
0031
0032 virtual ~SigmaTimingNtuple();
0033
0034
0035 int Init(PHCompositeNode *);
0036
0037
0038 int process_event(PHCompositeNode *);
0039
0040
0041 int End(PHCompositeNode *);
0042
0043 void AddNode(const std::string &name, const int detid=0);
0044
0045 protected:
0046 double get_dtotal(const PHG4Hit *hit, const double phi, const double theta);
0047 int nblocks;
0048 Fun4AllHistoManager *hm;
0049 std::vector<TH1 *> nhits;
0050 std::vector<TH1 *> eloss;
0051
0052 std::string _filename;
0053 std::set<std::string> _node_postfix;
0054 std::map<std::string, int> _detid;
0055 TNtuple *ntupprim;
0056 TNtuple *ntupsec;
0057 TNtuple *ntupt;
0058 TNtuple *ntupsigma;
0059 TFile *outfile;
0060 #ifndef __CINT__
0061 gsl_rng *RandomGenerator;
0062 #endif
0063 };
0064
0065 #endif