Rivet analyses
Cross section for e+e− → ωη and ωπ0 between 3.773 and 4.701 GeV
Experiment: BESIII (BEPC)
Inspire ID: 2047667
Status: VALIDATED
Authors: - Peter Richardson
References: - arXiv: 2203.02682
Beams: e+ e-
Beam energies: ANY
Run details: - e+ e- to hadrons
Cross section for e+e− → ωη and ωπ0 between 3.773 and 4.701 GeV measured by the BESIII collaborations
Source
code:BESIII_2022_I2047667.cc
// -*- C++ -*-
#include "Rivet/Analysis.hh"
#include "Rivet/Projections/FinalState.hh"
#include "Rivet/Projections/UnstableParticles.hh"
namespace Rivet {
/// @brief e+e- > eta omega and omega pi0
class BESIII_2022_I2047667 : public Analysis {
public:
/// Constructor
RIVET_DEFAULT_ANALYSIS_CTOR(BESIII_2022_I2047667);
/// @name Analysis methods
/// @{
/// Book histograms and initialise projections before the run
void init() {
// Initialise and register projections
declare(FinalState(), "FS");
declare(UnstableParticles(), "UFS");
for (size_t ix=0; ix<2; ++ix) {
book(_nMeson[ix], 1, 1, 1+ix);
}
for (const string& en : _nMeson[0].binning().edges<0>()) {
const double end = stod(en)*GeV;
if (isCompatibleWithSqrtS(end)) {
_sqs = en; break;
}
}
raiseBeamErrorIf(_sqs.empty());
}
void findChildren(const Particle& p, map<long,int>& nRes, int& ncount) const {
for( const Particle &child : p.children()) {
if (child.children().empty()) {
--nRes[child.pid()];
--ncount;
}
else {
findChildren(child,nRes,ncount);
}
}
}
/// Perform the per-event analysis
void analyze(const Event& event) {
const FinalState& fs = apply<FinalState>(event, "FS");
map<long,int> nCount;
int ntotal(0);
for (const Particle& p : fs.particles()) {
nCount[p.pid()] += 1;
++ntotal;
}
const UnstableParticles& ufs = apply<UnstableParticles>(event, "UFS");
for (const Particle& p : ufs.particles(Cuts::pid==223)) {
if (p.children().empty()) continue;
map<long,int> nRes = nCount;
int ncount = ntotal;
findChildren(p,nRes,ncount);
if (ncount==1) {
bool matched=true;
for (const auto& val : nRes) {
if (val.first==111 ) {
if (val.second !=1) {
matched = false;
break;
}
}
else if(val.second!=0) {
matched = false;
break;
}
}
if (matched) {
_nMeson[0]->fill(_sqs);
continue;
}
}
else {
// check for eta
for (const Particle& p2 : ufs.particles(Cuts::pid==221)) {
map<long,int> nResB = nRes;
int ncountB = ncount;
findChildren(p2,nResB,ncountB);
if (ncountB!=0) continue;
bool matched = true;
for (const auto& val : nResB) {
if (val.second!=0) {
matched = false;
break;
}
}
if(matched) {
_nMeson[1]->fill(_sqs);
break;
}
}
}
}
}
/// Normalise histograms etc., after the run
void finalize() {
scale(_nMeson, crossSection()/picobarn/sumOfWeights());
}
/// @}
/// @name Histograms
/// @{
BinnedHistoPtr<string> _nMeson[2];
string _sqs = "";
/// @}
};
RIVET_DECLARE_PLUGIN(BESIII_2022_I2047667);
}