Rivet analyses referenceL3_1991_I314407$\pi^0$ and charged particle spectra at 91 GeVExperiment: L3 (LEP) Inspire ID: 314407 Status: VALIDATED Authors:
Beam energies: (45.6, 45.6) GeV Run details:
Measurement of the momentum distribution of the $\pi^0$ mesons and charged particles at 91.2 GeV in $e^+e^-$ collisions by the L3 collaboration. Source code: L3_1991_I314407.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/ChargedFinalState.hh"
4#include "Rivet/Projections/UnstableParticles.hh"
5
6namespace Rivet {
7
8
9 /// @brief pi0 and charged particle spectra
10 class L3_1991_I314407 : public Analysis {
11 public:
12
13 /// Constructor
14 RIVET_DEFAULT_ANALYSIS_CTOR(L3_1991_I314407);
15
16
17 /// @name Analysis methods
18 /// @{
19
20 /// Book histograms and initialise projections before the run
21 void init() {
22 // projections
23 declare(ChargedFinalState(), "FS");
24 declare(UnstableParticles(), "UFS");
25 // book histos
26 book(_h_pi0_x ,3,1,1);
27 book(_h_pi0_xi ,4,1,1);
28 book(_h_charged_x ,5,1,1);
29 book(_h_charged_xi,6,1,1);
30 }
31
32
33 /// Perform the per-event analysis
34 void analyze(const Event& event) {
35 const FinalState& fs = apply<FinalState>(event, "FS");
36 for (const Particle& p : fs.particles()) {
37 const double x = 2.*p.momentum().p3().mod()/sqrtS();
38 _h_charged_x ->fill(x);
39 _h_charged_xi->fill(-log(x));
40
41
42 }
43 const UnstableParticles& ufs = apply<UnstableParticles>(event, "UFS");
44 for (const Particle & p : ufs.particles(Cuts::pid==PID::PI0)) {
45 const double x = 2.*p.momentum().p3().mod()/sqrtS();
46 _h_pi0_x ->fill(x);
47 _h_pi0_xi->fill(-log(x));
48 }
49 }
50
51
52 /// Normalise histograms etc., after the run
53 void finalize() {
54 scale(_h_pi0_x , 1./sumOfWeights());
55 scale(_h_pi0_xi , 1./sumOfWeights());
56 scale(_h_charged_x , 1./sumOfWeights());
57 scale(_h_charged_xi, 1./sumOfWeights());
58 }
59
60 /// @}
61
62
63 /// @name Histograms
64 /// @{
65 Histo1DPtr _h_pi0_x,_h_pi0_xi,_h_charged_x,_h_charged_xi;
66 /// @}
67
68
69 };
70
71
72 RIVET_DECLARE_PLUGIN(L3_1991_I314407);
73
74}
|