rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

NA49_2009_I818217

Inclusive production of protons, anti-protons and neutrons in p+p collisions at 158 GeV/c beam momentum
Experiment: NA49 (SPS)
Inspire ID: 818217
Status: UNVALIDATED
Authors:
  • Viktar Kireyeu
References:
  • https://link.springer.com/article/10.1140/epjc/s10052-009-1172-2
Beams: p+ p+
Beam energies: (8.7, 8.7) GeV
Run details:
  • $pp$ collisions at 17.3 GeV. Minimum bias events.

Production of $p$, $\bar{p}$ and neutrons in fixed target, $p_{\mathrm{lab}} = $158 GeV/c. The elastic trigger is implemented by looking for elastic final states with only 2 particles, instead of attempting to reproduce the experimental trigger, which cannot be directly unfolded.

Source code: NA49_2009_I818217.cc
 1// -*- C++ -*-
 2#include "Rivet/Analysis.hh"
 3#include "Rivet/Projections/FinalState.hh"
 4#include "Rivet/Particle.hh"
 5
 6namespace Rivet {
 7
 8
 9  class NA49_2009_I818217 : public Analysis {
10  public:
11
12    /// @name Constructors etc.
13    /// @{
14    /// Constructor
15    NA49_2009_I818217() : Analysis("NA49_2009_I818217"){}
16
17    void init() {
18      declare(FinalState(), "FS");
19      book(_h_dndxf, 1,1,1);
20      book(_p_mptxf, 2,1,1);
21      book(_h_dndy,  3,1,1);
22      book(_c_ninel, "nInelastic");
23    }
24
25    void analyze(const Event& event) {
26      const FinalState& fs = apply<FinalState>(event, "FS");
27      const size_t numParticles = fs.particles().size();
28      const float SRT = event.sqrtS();
29
30      // Inelastic events selection
31      if (numParticles <= 2) {
32        MSG_DEBUG("Elastic event");
33        vetoEvent;
34      }
35      _c_ninel -> fill();
36
37      // Plot distributions
38      for(const Particle& p : fs.particles()) {
39        if(p.pid() == PID::PROTON){
40          double xF = p.pz() / (SRT/2.);
41          _h_dndxf -> fill(xF);
42          _h_dndy  -> fill(p.rapidity());
43          _p_mptxf -> fill(xF, p.pt());
44        }
45      }
46    }
47
48    void finalize() {
49      scale(_h_dndxf, 1./ *_c_ninel);   // Scale by the number of inelastic events
50      for (auto& b : _h_dndxf->bins()) b.scaleW(1./b.xWidth());  // Scale by the bin width (dxF)
51
52      scale(_h_dndy, 1./ *_c_ninel);
53      for (auto& by : _h_dndy->bins()) by.scaleW(1./by.xWidth());
54    }
55
56  private:
57    CounterPtr   _c_ninel;  // Counter of inelastic events
58    Histo1DPtr   _h_dndxf;  // dn/dxf histogram
59    Histo1DPtr   _h_dndy;   // dn/dy histogram
60    Profile1DPtr _p_mptxf;  // mean pT vs xF profile
61  };
62
63  RIVET_DECLARE_PLUGIN(NA49_2009_I818217);
64}