rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

BESIII_2018_I1651451

Cross Section for $e^+e^-\to\phi\pi^+\pi^-$ and $\phi\pi^0\pi^0$ at 2.125 GeV
Experiment: BESIII (BEPC)
Inspire ID: 1651451
Status: VALIDATED NOHEPDATA
Authors:
  • Peter Richardson
References:
  • Phys.Rev.D 99 (2019) 1, 011101
Beams: e+ e-
Beam energies: (1.1, 1.1) GeV
Run details:
  • e+e- to hadrons

Measurement of the cross section for $e^+e^-\to\phi\pi^+\pi^-$ and $\phi\pi^0\pi^0$ at 2.125 GeV.

Source code: BESIII_2018_I1651451.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  e+e- -> phi pi+ pi- and phi pi0 pi0
 10  class BESIII_2018_I1651451 : public Analysis {
 11  public:
 12
 13    /// Constructor
 14    RIVET_DEFAULT_ANALYSIS_CTOR(BESIII_2018_I1651451);
 15
 16
 17    /// @name Analysis methods
 18    /// @{
 19
 20    /// Book histograms and initialise projections before the run
 21    void init() {
 22
 23      // Initialise and register projections
 24      declare(FinalState(), "FS");
 25      declare(UnstableParticles(), "UFS");
 26      // histograms
 27      for (unsigned int ix=0; ix<2; ++ix) {
 28        book(_h[ix],1,1,ix+1);
 29      }
 30    }
 31
 32    void findChildren(const Particle & p,map<long,int>& nRes, int &ncount) {
 33      for (const Particle &child : p.children()) {
 34        if (child.children().empty()) {
 35          nRes[child.pid()]-=1;
 36          --ncount;
 37        }
 38        else {
 39          findChildren(child,nRes,ncount);
 40        }
 41      }
 42    }
 43
 44    /// Perform the per-event analysis
 45    void analyze(const Event& event) {
 46      const FinalState& fs = apply<FinalState>(event, "FS");
 47
 48      map<long,int> nCount;
 49      int ntotal(0);
 50      for (const Particle& p : fs.particles()) {
 51        nCount[p.pid()] += 1;
 52        ++ntotal;
 53      }
 54      const FinalState& ufs = apply<FinalState>(event, "UFS");
 55      for (const Particle& p : ufs.particles(Cuts::pid==PID::PHI)) {
 56        if (p.children().empty()) continue;
 57        map<long,int> nRes=nCount;
 58        int ncount = ntotal;
 59        findChildren(p,nRes,ncount);
 60        // phi pi+pi-
 61        if (ncount==2) {
 62          bool matched = true;
 63          for (const auto& val : nRes) {
 64            if (abs(val.first)==211) {
 65              if (val.second!=1) {
 66                matched = false;
 67                break;
 68              }
 69            }
 70            else if (val.second!=0) {
 71              matched = false;
 72              break;
 73            }
 74          }
 75          if (matched) {
 76            _h[0]->fill("2.125"s);
 77            break;
 78          }
 79          matched = true;
 80          for (const auto& val : nRes) {
 81            if (abs(val.first)==111) {
 82              if (val.second!=2) {
 83                matched = false;
 84                break;
 85              }
 86            }
 87            else if(val.second!=0) {
 88              matched = false;
 89              break;
 90            }
 91          }
 92          if (matched) {
 93            _h[1]->fill("2.125"s);
 94            break;
 95          }
 96        }
 97      }
 98    }
 99
100
101    /// Normalise histograms etc., after the run
102    void finalize() {
103      scale(_h, crossSection()/ sumOfWeights() /picobarn);
104    }
105
106    /// @}
107
108
109    /// @name Histograms
110    /// @{
111    BinnedHistoPtr<string> _h[2];
112    /// @}
113
114
115  };
116
117
118  RIVET_DECLARE_PLUGIN(BESIII_2018_I1651451);
119
120}