Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DCustomAction_p2gamma_hists.h
Go to the documentation of this file.
1 // $Id$
2 //
3 // File: DCustomAction_p2gamma_hists.h
4 // Created: Wed Jan 21 16:53:41 EST 2015
5 // Creator: jrsteven (on Linux ifarm1401 2.6.32-431.el6.x86_64 x86_64)
6 //
7 
8 #ifndef _DCustomAction_p2gamma_hists_
9 #define _DCustomAction_p2gamma_hists_
10 
11 #include <string>
12 #include <iostream>
13 
14 #include "TH1.h"
15 
16 #include "JANA/JEventLoop.h"
17 #include "JANA/JApplication.h"
18 
20 #include "ANALYSIS/DReaction.h"
23 
24 using namespace std;
25 using namespace jana;
26 
28 {
29  public:
30 
31  DCustomAction_p2gamma_hists(const DReaction* locReaction, bool locUseKinFitResultsFlag, string locActionUniqueString = "") :
32  DAnalysisAction(locReaction, "Custom_p2gamma_hists", locUseKinFitResultsFlag, locActionUniqueString) {}
33 
34  void Initialize(JEventLoop* locEventLoop);
35  void Reset_NewEvent(void){dPreviousSourceObjects.clear();}
36 
37  private:
38 
39  bool Perform_Action(JEventLoop* locEventLoop, const DParticleCombo* locParticleCombo);
40 
41  // Parameters for event selection to fill histograms
43  double cohmin_energy, cohedge_energy, endpoint_energy;
44  double dEdxCut, minMM2Cut, maxMM2Cut, missingEnergyCut, min2gMassCut, max2gMassCut;
45 
46  // Optional: Useful utility functions.
47  //const DAnalysisUtilities* dAnalysisUtilities;
48 
49  set<set<pair<const JObject*, Particle_t> > > dPreviousSourceObjects;
50 
51  //Store any histograms as member variables here
52  TH1I *dEgamma;
53 
54  TH2I *dMM2_M2g, *dProton_dEdx_P, *dProton_P_Theta, *dProtonPhi_Egamma, *dProtonPhi_Theta, *dProtonPhi_t;
55  TH2I *dPi0Phi_Egamma, *dPi0Phi_Theta, *dDeltaE_M2g, *dPi0EgammaCorr;
56  TH2I *dMM2_M2g_ProtonTag, *dDeltaE_M2g_ProtonTag, *dMM2_DeltaE_ProtonTag;
57  TH2I *dMM2_M2g_CoplanarTag, *dDeltaE_M2g_CoplanarTag, *dMM2_DeltaE_CoplanarTag;
58  TH2I *dDeltaPhi_M2g, *dPhi2g_PhiP;
61 };
62 
63 #endif // _DCustomAction_p2gamma_hists_
64 
DCustomAction_p2gamma_hists(const DReaction *locReaction, bool locUseKinFitResultsFlag, string locActionUniqueString="")
set< set< pair< const JObject *, Particle_t > > > dPreviousSourceObjects