rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

DELPHI_1995_I394052

$K^\pm$ and $p,\bar{p}$ spectra in hadronic $Z^0$ decays
Experiment: DELPHI (LEP)
Inspire ID: 394052
Status: VALIDATED
Authors:
  • Peter Richardson
References:
  • Nucl.Phys. B444 (1995) 3-26, 1995
Beams: e+ e-
Beam energies: (45.6, 45.6) GeV
Run details:
  • Hadronic Z decay events generated on the Z pole ($\sqrt{s} = 91.2$ GeV)

DELPHI results for the spectra for $K^\pm$ and $p,\bar{p}$ production in hadronic $Z^0$ decays.

Source code: DELPHI_1995_I394052.cc
 1// -*- C++ -*-
 2#include "Rivet/Analysis.hh"
 3#include "Rivet/Projections/FinalState.hh"
 4#include "Rivet/Projections/ChargedFinalState.hh"
 5#include "Rivet/Projections/Beam.hh"
 6
 7namespace Rivet {
 8
 9
10  /// @brief K+/- and protno spectra
11  class DELPHI_1995_I394052 : public Analysis {
12  public:
13
14    /// Constructor
15    RIVET_DEFAULT_ANALYSIS_CTOR(DELPHI_1995_I394052);
16
17
18    /// @name Analysis methods
19    //@{
20
21    /// Book histograms and initialise projections before the run
22    void init() {
23      declare(Beam(), "Beams");
24      declare(ChargedFinalState(), "FS");
25
26      // Book histograms
27      book(_h_kaon_p   , 3, 1, 1);
28      book(_h_kaon_x   , 5, 1, 1);
29      book(_h_proton_p , 4, 1, 1);
30      book(_h_proton_x , 6, 1, 1);
31    }
32
33
34    /// Perform the per-event analysis
35    void analyze(const Event& event) {
36
37      // First, veto on leptonic events by requiring at least 4 charged FS particles
38      const FinalState& fs = apply<FinalState>(event, "FS");
39      const size_t numParticles = fs.particles().size();
40
41      // Even if we only generate hadronic events, we still need a cut on numCharged >= 2.
42      if (numParticles < 2) {
43        MSG_DEBUG("Failed leptonic event cut");
44        vetoEvent;
45      }
46      MSG_DEBUG("Passed leptonic event cut");
47
48      // Get beams and average beam momentum
49      const ParticlePair& beams = apply<Beam>(event, "Beams").beams();
50      const double meanBeamMom = ( beams.first.p3().mod() +
51                                   beams.second.p3().mod() ) / 2.0;
52      MSG_DEBUG("Avg beam momentum = " << meanBeamMom);
53      for (const Particle& p : fs.particles(Cuts::abspid==321 or
54					       Cuts::abspid==2212)) {
55	double modp = p.p3().mod();
56        double xp = modp/meanBeamMom;
57	if(abs(p.pid())==321) {
58	  _h_kaon_p  ->fill(modp);
59	  _h_kaon_x  ->fill(xp  );
60	}
61	else {
62	  _h_proton_p->fill(modp);
63	  _h_proton_x->fill(xp  );
64	}
65      }
66    }
67
68
69    /// Normalise histograms etc., after the run
70    void finalize() {
71      scale(_h_kaon_p  ,1./sumOfWeights());
72      scale(_h_kaon_x  ,1./sumOfWeights());
73      scale(_h_proton_p,1./sumOfWeights());
74      scale(_h_proton_x,1./sumOfWeights());
75    }
76
77    //@}
78
79
80    /// @name Histograms
81    //@{
82    Histo1DPtr _h_kaon_p, _h_kaon_x, _h_proton_p, _h_proton_x;
83    //@}
84
85
86  };
87
88
89  // The hook for the plugin system
90  RIVET_DECLARE_PLUGIN(DELPHI_1995_I394052);
91
92
93}