Rivet analyses referenceKEDR_2019_I1673357Measurement of $R$ between 1.84 and 3.72 GeVExperiment: KEDR (VEPP-4M) Inspire ID: 1673357 Status: VALIDATED Authors:
Beam energies: ANY Run details:
Measurement of $R$ for centre-of-mass energies between 1.84 and 3.72 GeV by the KEDR experiment. Source code: KEDR_2019_I1673357.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/FinalState.hh"
4#include "Rivet/Projections/UnstableParticles.hh"
5
6namespace Rivet {
7
8
9 /// @brief Measurement of R
10 class KEDR_2019_I1673357 : public Analysis {
11 public:
12
13 /// Constructor
14 RIVET_DEFAULT_ANALYSIS_CTOR(KEDR_2019_I1673357);
15
16
17 /// @name Analysis methods
18 /// @{
19
20 /// Book histograms and initialise projections before the run
21 void init() {
22 // Initialise and register projections
23 declare(FinalState(), "FS");
24 declare(UnstableParticles(Cuts::pid==443 or Cuts::pid==100443
25 or Cuts::pid==30443), "UFS");
26
27 // Book histograms
28 book(_c_hadrons[0], "/TMP/sigma_hadrons_1",refData(1,1,1));
29 book(_c_hadrons[1], "/TMP/sigma_hadrons_2",refData(1,1,2));
30 book(_c_muons , "/TMP/sigma_muons" ,refData(1,1,1));
31 }
32
33
34 /// Perform the per-event analysis
35 void analyze(const Event& event) {
36 const FinalState& fs = apply<FinalState>(event, "FS");
37
38 map<long,int> nCount;
39 int ntotal(0);
40 for (const Particle& p : fs.particles()) {
41 nCount[p.pid()] += 1;
42 ++ntotal;
43 }
44 // mu+mu- + photons
45 if(nCount[-13]==1 and nCount[13]==1 &&
46 ntotal==2+nCount[22])
47 _c_muons->fill(sqrtS()/MeV);
48 // everything else
49 else {
50 const UnstableParticles & ufs = apply<UnstableParticles>(event, "UFS");
51 if(ufs.particles().empty()) _c_hadrons[0]->fill(sqrtS()/MeV);
52 _c_hadrons[1]->fill(sqrtS()/MeV);
53 }
54 }
55
56
57 /// Normalise histograms etc., after the run
58 void finalize() {
59 for(unsigned int ix=0;ix<2;++ix) {
60 Estimate1DPtr mult;
61 book(mult, 1, 1, 1+ix);
62 divide(_c_hadrons[ix],_c_muons,mult);
63 }
64 }
65
66 /// @}
67
68
69 /// @name Histograms
70 /// @{
71 Histo1DPtr _c_hadrons[2], _c_muons;
72 /// @}
73
74
75 };
76
77
78 RIVET_DECLARE_PLUGIN(KEDR_2019_I1673357);
79
80}
|