rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

BESIII_2023_I2645388

Cross section for $e^+e^-\to D^{*0}D^{*-}\pi^+$+c.c. for $\sqrt{s}=4.189\to4.951$ GeV
Experiment: BESIII (BEPC)
Inspire ID: 2645388
Status: VALIDATED NOHEPDATA
Authors:
  • Peter Richardson
References: Beams: e+ e-
Beam energies: (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.1, 2.1); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.2, 2.2); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.3, 2.3); (2.4, 2.4); (2.4, 2.4); (2.4, 2.4); (2.4, 2.4); (2.5, 2.5); (2.5, 2.5) GeV
Run details:
  • e+ e- > hadrons

Cross section for $e^+e^-\to D^{*0}D^{*-}\pi^+$+c.c. for $\sqrt{s}=4.189\to4.951$ GeV. Beam energy must be specified as analysis option "ENERGY" when rivet-merging samples.

Source code: BESIII_2023_I2645388.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 Cross section for D*0 D*- pi+ + c.c.
 10  class BESIII_2023_I2645388 : public Analysis {
 11  public:
 12
 13    /// Constructor
 14    RIVET_DEFAULT_ANALYSIS_CTOR(BESIII_2023_I2645388);
 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(), "UFS");
 25      for(unsigned int ix=0;ix<2;++ix) {
 26        book(_sigma[ix], 1+ix, 1, 1);
 27        for (const string& en : _sigma[ix].binning().edges<0>()) {
 28          const double end = std::stod(en)*GeV;
 29          if (isCompatibleWithSqrtS(end)) {
 30            _ecms[ix] = en;
 31            break;
 32          }
 33        }
 34      }
 35      if (_ecms[0].empty() && _ecms[1].empty()) {
 36        MSG_ERROR("Beam energy incompatible with analysis.");
 37      }
 38    }
 39
 40    void findChildren(const Particle & p,map<long,int> & nRes, int &ncount) {
 41      for (const Particle &child : p.children()) {
 42        if(child.children().empty()) {
 43          nRes[child.pid()]-=1;
 44          --ncount;
 45        }
 46        else {
 47          findChildren(child,nRes,ncount);
 48        }
 49      }
 50    }
 51
 52    /// Perform the per-event analysis
 53    void analyze(const Event& event) {
 54      const FinalState& fs = apply<FinalState>(event, "FS");
 55
 56      map<long,int> nCount;
 57      int ntotal(0);
 58      for (const Particle& p : fs.particles()) {
 59        nCount[p.pid()] += 1;
 60        ++ntotal;
 61      }
 62      const FinalState& ufs = apply<FinalState>(event, "UFS");
 63      for (const Particle & p1 : ufs.particles(Cuts::abspid==423)) {
 64        map<long,int> nRes = nCount;
 65        int ncount = ntotal;
 66        findChildren(p1,nRes,ncount);
 67        bool matched=false;
 68      	int id2 = p1.pid()>0 ? -413 :  413;
 69      	int ipi = p1.pid()>0 ?  211 : -211;
 70       	for (const Particle & p2 : ufs.particles(Cuts::pid==id2)) {
 71          map<long,int> nRes2 = nRes;
 72          int ncount2 = ncount;
 73          findChildren(p2,nRes2,ncount2);
 74          if (ncount2!=1) continue;
 75          matched=true;
 76          for (const auto& val : nRes2) {
 77            if (val.first==ipi) {
 78              if (val.second!=1) {
 79                matched = false;
 80                break;
 81      	      }
 82      	    }
 83      	    else if (val.second!=0) {
 84      	      matched = false;
 85      	      break;
 86      	    }
 87      	  }
 88      	  if (matched) break;
 89      	}
 90      	if (matched) {
 91          for (unsigned int ix=0; ix<2; ++ix) {
 92            if (!_ecms[ix].empty()) _sigma[ix]->fill(_ecms[ix]);
 93          }
 94        }
 95      }
 96    }
 97
 98
 99    /// Normalise histograms etc., after the run
100    void finalize() {
101      scale(_sigma,crossSection()/ sumOfWeights() /picobarn);
102    }
103
104    /// @}
105
106
107    /// @name Histograms
108    /// @{
109    BinnedHistoPtr<string> _sigma[2];
110    string _ecms[2];
111    /// @}
112
113
114  };
115
116
117  RIVET_DECLARE_PLUGIN(BESIII_2023_I2645388);
118
119}