D0_2007_S7075677.cc
Go to the documentation of this file.00001
00002 #include "Rivet/Analysis.hh"
00003 #include "Rivet/RivetAIDA.hh"
00004 #include "Rivet/Tools/Logging.hh"
00005 #include "Rivet/Projections/ZFinder.hh"
00006
00007 namespace Rivet {
00008
00009
00010
00011
00012
00013
00014 class D0_2007_S7075677 : public Analysis {
00015
00016 public:
00017
00018
00019 D0_2007_S7075677() : Analysis("D0_2007_S7075677")
00020 {
00021
00022 }
00023
00024
00025
00026
00027
00028
00029 void init() {
00030 ZFinder zfinder(-MAXRAPIDITY, MAXRAPIDITY, 0.0*GeV, ELECTRON,
00031 71.0*GeV, 111.0*GeV, 0.2, true, true);
00032 addProjection(zfinder, "ZFinder");
00033
00034 _h_yZ = bookHistogram1D(1, 1, 1);
00035 }
00036
00037
00038
00039 void analyze(const Event & e) {
00040 const double weight = e.weight();
00041
00042 const ZFinder& zfinder = applyProjection<ZFinder>(e, "ZFinder");
00043 if (zfinder.bosons().size() == 1) {
00044 const ParticleVector& el(zfinder.constituents());
00045 if (el[0].momentum().pT() > 25.0*GeV || el[1].momentum().pT() > 25.0*GeV) {
00046 double yZ = fabs(zfinder.bosons()[0].momentum().rapidity());
00047 _h_yZ->fill(yZ, weight);
00048 }
00049 }
00050 else {
00051 MSG_DEBUG("No unique lepton pair found.");
00052 }
00053 }
00054
00055
00056
00057 void finalize() {
00058
00059
00060 normalize(_h_yZ, 0.5);
00061 }
00062
00063
00064
00065
00066 private:
00067
00068
00069
00070 AIDA::IHistogram1D * _h_yZ;
00071
00072
00073 };
00074
00075
00076
00077
00078 DECLARE_RIVET_PLUGIN(D0_2007_S7075677);
00079
00080 }