D0_2006_S6438750.cc
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #include "Rivet/Analysis.hh" 00003 #include "Rivet/Tools/Logging.hh" 00004 #include "Rivet/Projections/FinalState.hh" 00005 #include "Rivet/Projections/LeadingParticlesFinalState.hh" 00006 #include "Rivet/Projections/VetoedFinalState.hh" 00007 #include "Rivet/RivetYODA.hh" 00008 00009 namespace Rivet { 00010 00011 00012 /// @brief D0 inclusive isolated photon cross-section vs. \f$ p_\perp(gamma) \f$. 00013 /// @author Andy Buckley 00014 /// @author Gavin Hesketh 00015 class D0_2006_S6438750 : public Analysis { 00016 00017 public: 00018 00019 /// @name Constructors etc. 00020 //@{ 00021 00022 /// Default constructor. 00023 D0_2006_S6438750() 00024 : Analysis("D0_2006_S6438750") 00025 { } 00026 00027 //@} 00028 00029 00030 /// @name Analysis methods 00031 //@{ 00032 00033 void init() { 00034 // General FS for photon isolation 00035 FinalState fs; 00036 addProjection(fs, "AllFS"); 00037 00038 // Get leading photon 00039 LeadingParticlesFinalState photonfs(FinalState(-0.9, 0.9, 23.0*GeV)); 00040 photonfs.addParticleId(PHOTON); 00041 addProjection(photonfs, "LeadingPhoton"); 00042 00043 // Book histograms 00044 _h_pTgamma = bookHisto1D(1, 1, 1); 00045 } 00046 00047 00048 /// Do the analysis 00049 void analyze(const Event& event) { 00050 00051 // Get the photon 00052 const FinalState& photonfs = applyProjection<FinalState>(event, "LeadingPhoton"); 00053 if (photonfs.particles().size() != 1) { 00054 vetoEvent; 00055 } 00056 const FourMomentum photon = photonfs.particles().front().momentum(); 00057 00058 // Isolate photon by ensuring that a 0.4 cone around it contains less than 10% of the photon's energy 00059 double E_P = photon.E(); 00060 double eta_P = photon.pseudorapidity(); 00061 double phi_P = photon.azimuthalAngle(); 00062 double econe = 0.0; 00063 foreach (const Particle& p, applyProjection<FinalState>(event, "AllFS").particles()) { 00064 if (deltaR(eta_P, phi_P, 00065 p.momentum().pseudorapidity(), p.momentum().azimuthalAngle()) < 0.4) { 00066 econe += p.momentum().E(); 00067 if (econe/E_P > 1.1) { 00068 vetoEvent; 00069 } 00070 } 00071 } 00072 00073 // Fill histo 00074 const double weight = event.weight(); 00075 _h_pTgamma->fill(photon.pT(), weight); 00076 } 00077 00078 00079 00080 // Finalize 00081 void finalize() { 00082 const double lumi_gen = sumOfWeights()/crossSection(); 00083 // Divide by effective lumi, plus rapidity bin width of 1.8 00084 scale(_h_pTgamma, 1/lumi_gen * 1/1.8); 00085 } 00086 00087 //@} 00088 00089 00090 private: 00091 00092 /// @name Histograms 00093 //@{ 00094 Histo1DPtr _h_pTgamma; 00095 //@} 00096 00097 }; 00098 00099 00100 00101 // The hook for the plugin system 00102 DECLARE_RIVET_PLUGIN(D0_2006_S6438750); 00103 00104 } Generated on Fri Dec 21 2012 15:03:40 for The Rivet MC analysis system by ![]() |