Rivet analyses referenceBESII_2008_I801210Cross-sections for light hadrons at 3.773, 3.650 and 3.6648 GeVExperiment: BESII (BEPC II) Inspire ID: 801210 Status: VALIDATED Authors:
Beam energies: (1.9, 1.9); (1.8, 1.8); (1.8, 1.8) GeV Run details:
Cross section for $e^+e^-\to \pi^+\pi^-$, $K^+K^-$, $2\pi^+2\pi^-$, $K^+K^-\pi^+\pi^-$ and $3\pi^+3\pi^-$ together with a $\pi^0\pi^0$ pair at 3.773, 3.650 and 3.6648 GeV. Beam energy must be specified as analysis option "ENERGY" when rivet-merging samples. Source code: BESII_2008_I801210.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/FinalState.hh"
4
5namespace Rivet {
6
7
8 /// @brief Cross-sections for light hadrons at 3.773, 3.650 and 3.6648 GeV
9 class BESII_2008_I801210 : public Analysis {
10 public:
11
12 /// Constructor
13 RIVET_DEFAULT_ANALYSIS_CTOR(BESII_2008_I801210);
14
15
16 /// @name Analysis methods
17 /// @{
18
19 /// Book histograms and initialise projections before the run
20 void init() {
21
22 // Initialise and register projections
23 declare(FinalState(), "FS");
24
25 // Book histograms
26 for(unsigned int ix=1;ix<6;++ix)
27 book(_nMeson[ix], 1, 1, ix);
28 for (const string& en : _nMeson[1].binning().edges<0>()) {
29 const double end = std::stod(en)*GeV;
30 if (isCompatibleWithSqrtS(end)) {
31 _ecms = en;
32 break;
33 }
34 }
35 if (_ecms.empty())
36 MSG_ERROR("Beam energy incompatible with analysis.");
37 }
38
39
40 /// Perform the per-event analysis
41 void analyze(const Event& event) {
42 const FinalState& fs = apply<FinalState>(event, "FS");
43
44 map<long,int> nCount;
45 int ntotal(0);
46 for (const Particle& p : fs.particles()) {
47 nCount[p.pid()] += 1;
48 ++ntotal;
49 }
50 if(nCount[111]!=2) vetoEvent;
51
52 if(ntotal==4) {
53 if(nCount[211]==1 && nCount[-211]==1)
54 _nMeson[1]->fill(_ecms);
55 else if(nCount[321]==1 && nCount[-321]==1)
56 _nMeson[2]->fill(_ecms);
57 }
58 else if(ntotal==6) {
59 if(nCount[211]==2 && nCount[-211]==2)
60 _nMeson[3]->fill(_ecms);
61 else if(nCount[321]==1 && nCount[-321]==1 &&
62 nCount[211]==1 && nCount[-211]==1)
63 _nMeson[4]->fill(_ecms);
64 }
65 else if(ntotal==8) {
66 if(nCount[211]==3 && nCount[-211]==3)
67 _nMeson[5]->fill(_ecms);
68 }
69
70 }
71
72
73 /// Normalise histograms etc., after the run
74 void finalize() {
75 for(unsigned int ix=1;ix<6;++ix)
76 scale(_nMeson[ix], crossSection()/ sumOfWeights() /picobarn);
77 }
78
79 /// @}
80
81
82 /// @name Histograms
83 /// @{
84 BinnedHistoPtr<string> _nMeson[6];
85 string _ecms;
86 /// @}
87
88
89 };
90
91
92
93 RIVET_DECLARE_PLUGIN(BESII_2008_I801210);
94
95}
|