rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

BESIII_2018_I1627871

Cross section for $e^+e^-\to\Lambda\bar{\Lambda}$ between threshold and 3.08 GeV
Experiment: BESIII (BEPC II)
Inspire ID: 1627871
Status: VALIDATED
Authors:
  • Peter Richardson
References:
  • Phys.Rev. D97 (2018) no.3, 032013
Beams: e+ e-
Beam energies: ANY
Run details:
  • e+e- to hadrons

Measurement of the cross section for $e^+e^-\to\Lambda\bar{\Lambda}$ between threshold and 3.08 GeV.

Source code: BESIII_2018_I1627871.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 Lambda Lambdabar cross section
 10  class BESIII_2018_I1627871 : public Analysis {
 11  public:
 12
 13    /// Constructor
 14    RIVET_DEFAULT_ANALYSIS_CTOR(BESIII_2018_I1627871);
 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      book(_nLambda, "/TMP/nLambda" );
 26    }
 27
 28    void findChildren(const Particle & p,map<long,int> & nRes, int &ncount) {
 29      for (const Particle &child : p.children()) {
 30	if(child.children().empty()) {
 31	  nRes[child.pid()]-=1;
 32	  --ncount;
 33	}
 34	else
 35	  findChildren(child,nRes,ncount);
 36      }
 37    }
 38
 39    /// Perform the per-event analysis
 40    void analyze(const Event& event) {
 41      const FinalState& fs = apply<FinalState>(event, "FS");
 42      // total hadronic and muonic cross sections
 43      map<long,int> nCount;
 44      int ntotal(0);
 45      for (const Particle& p : fs.particles()) {
 46	nCount[p.pid()] += 1;
 47	++ntotal;
 48      }
 49      // find the Lambdas
 50      const FinalState& ufs = apply<UnstableParticles>(event, "UFS");
 51      for(unsigned int ix=0;ix<ufs.particles().size();++ix) {
 52	const Particle& p1 = ufs.particles()[ix];
 53	if(abs(p1.pid())!=3122) continue;
 54	bool matched = false;
 55	// check fs
 56	bool fs = true;
 57	for (const Particle & child : p1.children()) {
 58	  if(child.pid()==p1.pid()) {
 59	    fs = false;
 60	    break;
 61	  }
 62	}
 63	if(!fs) continue;
 64	// find the children
 65	map<long,int> nRes = nCount;
 66	int ncount = ntotal;
 67	findChildren(p1,nRes,ncount);
 68	for(unsigned int iy=ix+1;iy<ufs.particles().size();++iy) {
 69	  const Particle& p2 = ufs.particles()[iy];
 70	  if(abs(p2.pid())!=3122) continue;
 71	  // check fs
 72	  bool fs = true;
 73	  for (const Particle & child : p2.children()) {
 74	    if(child.pid()==p2.pid()) {
 75	      fs = false;
 76	      break;
 77	    }
 78	  }
 79	  if(!fs) continue;
 80	  map<long,int> nRes2 = nRes;
 81	  int ncount2 = ncount;
 82	  findChildren(p2,nRes2,ncount2);
 83	  if(ncount2!=0) continue;
 84	  matched=true;
 85	  for(auto const & val : nRes2) {
 86	    if(val.second!=0) {
 87	      matched = false;
 88	      break;
 89	    }
 90	  }
 91	  if(matched) {
 92	    _nLambda->fill();
 93	    break;
 94	  }
 95	}
 96	if(matched) break;
 97      }
 98    }
 99
100
101    /// Normalise histograms etc., after the run
102    void finalize() {
103      double sigma = _nLambda->val();
104      double error = _nLambda->err();
105      sigma *= crossSection()/ sumOfWeights() /picobarn;
106      error *= crossSection()/ sumOfWeights() /picobarn; 
107      Scatter2D temphisto(refData(1, 1, 1));
108      Scatter2DPtr  mult;
109      book(mult, 1, 1, 1);
110      for (size_t b = 0; b < temphisto.numPoints(); b++) {
111	const double x  = temphisto.point(b).x();
112	pair<double,double> ex = temphisto.point(b).xErrs();
113	pair<double,double> ex2 = ex;
114	if(ex2.first ==0.) ex2. first=0.0001;
115	if(ex2.second==0.) ex2.second=0.0001;
116	if (inRange(sqrtS()/GeV, x-ex2.first, x+ex2.second)) {
117	  mult->addPoint(x, sigma, ex, make_pair(error,error));
118	}
119	else {
120	  mult->addPoint(x, 0., ex, make_pair(0.,.0));
121	}
122      }
123    }
124    //@}
125
126    /// @name Histograms
127    //@{
128    CounterPtr _nLambda;
129    //@}
130  };
131
132
133  // The hook for the plugin system
134  RIVET_DECLARE_PLUGIN(BESIII_2018_I1627871);
135
136
137}