Rivet analyses referenceBESIII_2019_I1685351Cross sections for $e^+e^-\to\mu^+\mu^-$, $\pi^+\pi^-\eta$ and $2\pi^+2\pi^-\pi^0$ near the $J/\psi$Experiment: BESIII (BEPC) Inspire ID: 1685351 Status: VALIDATED NOHEPDATA SINGLEWEIGHT Authors:
Beam energies: ANY Run details:
Measurement of the cross sections for $e^+e^-\to\mu^+\mu^-$, $\pi^+\pi^-\eta$ and $2\pi^+2\pi^-\pi^0$ near the $J/\psi$, not corrected for photon ISR which should be included in the simulation. Useful for looking at the simulation of QED ISR at low energies. As the analyses requires the beam energy smearing described in the paper then central CMS energy should be specified using the ECENT (in MeV) option. Source code: BESIII_2019_I1685351.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/FinalState.hh"
4#include "Rivet/Projections/UnstableParticles.hh"
5#include "Rivet/Projections/Beam.hh"
6
7namespace Rivet {
8
9
10 /// @brief e+ e- > mu+ mu-, pi+ pi- eta and 5pi near J/psi
11 class BESIII_2019_I1685351 : public Analysis {
12 public:
13
14 /// Constructor
15 RIVET_DEFAULT_ANALYSIS_CTOR(BESIII_2019_I1685351);
16
17
18 /// @name Analysis methods
19 /// @{
20
21 /// Book histograms and initialise projections before the run
22 void init() {
23 // Projections
24 declare(FinalState(), "FS");
25 declare(UnstableParticles(Cuts::pid==PID::ETA), "UFS");
26 // histograms
27 for (unsigned int ix=0; ix<3; ++ix) {
28 book(_sigma[ix], 1, 1, 1+ix);
29 }
30 // central beam energy
31 string ecms = std::to_string(0.01*double(round(sqrtS()/MeV*100)));
32 const size_t idx = ecms.find(".");
33 ecms = ecms.substr(0,idx+3);
34 if(ecms[ecms.length()-1]=='0') ecms.pop_back();
35 _eCent = getOption<string>("ECENT", ecms);
36 }
37
38 void findChildren(const Particle & p,map<long,int> & nRes, int &ncount) {
39 for (const Particle &child : p.children()) {
40 if (child.children().empty()) {
41 --nRes[child.pid()];
42 --ncount;
43 }
44 else {
45 findChildren(child,nRes,ncount);
46 }
47 }
48 }
49
50 /// Perform the per-event analysis
51 void analyze(const Event& event) {
52 const FinalState& fs = apply<FinalState>(event, "FS");
53
54 map<long,int> nCount;
55 int ntotal(0);
56 for (const Particle& p : fs.particles()) {
57 nCount[p.pid()] += 1;
58 ++ntotal;
59 }
60 // mu+mu- + photons
61 if (nCount[-13]==1 && nCount[13]==1 && ntotal==2+nCount[22]) {
62 _sigma[0]->fill(_eCent);
63 }
64 else if (nCount[111]==1 && nCount[211]==2 && nCount[-211]==2 && ntotal==5+nCount[22]) {
65 _sigma[2]->fill(_eCent);
66 }
67
68 const FinalState& ufs = apply<FinalState>(event, "UFS");
69 // loop over eta mesons
70 for (const Particle& p : ufs.particles()) {
71 map<long,int> nRes = nCount;
72 int ncount = ntotal;
73 findChildren(p,nRes,ncount);
74 bool matched = true;
75 for (const auto& val : nRes) {
76 if (abs(val.first)==211) {
77 if (val.second !=1) {
78 matched = false;
79 break;
80 }
81 }
82 else if (val.first!=PID::PHOTON && val.second!=0) {
83 matched = false;
84 break;
85 }
86 }
87 if (!matched) continue;
88 _sigma[1]->fill(_eCent);
89 break;
90 }
91 }
92
93
94 /// Normalise histograms etc., after the run
95 void finalize() {
96 scale(_sigma, crossSection()/ sumOfWeights() /nanobarn);
97 }
98
99 /// @}
100
101
102 /// @name Histograms
103 /// @{
104 BinnedHistoPtr<string> _sigma[3];
105 string _eCent;
106 /// @}
107
108
109 };
110
111
112 RIVET_DECLARE_PLUGIN(BESIII_2019_I1685351);
113
114}
|