rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

CRYSTAL_BALL_1986_I238081

Measurement of $R$ and $D^*$ production for energies between 3.67 and 4.5 GeV.
Experiment: CRYSTAL_BALL (Spear)
Inspire ID: 238081
Status: VALIDATED
Authors:
  • Peter Richardson
References:
  • https://doi.org/10.17182/hepdata.18759
Beams: e- e+
Beam energies: ANY
Run details:
  • e+ e- to hadrons and e+ e- to mu+ mu- (for normalization)

Measurement of $R$ in $e^+e^-$ collisions by the Crystal Ball experiment for energies between 3.67 and 4.5 GeV. The cross section for $D^*$ production is also measured. The individual hadronic and muonic cross sections are also outputted to the yoda file so that ratio $R$ can be recalcuated if runs are combined.

Source code: CRYSTAL_BALL_1986_I238081.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 Add a short analysis description here
 10  class CRYSTAL_BALL_1986_I238081 : public Analysis {
 11  public:
 12
 13    /// Constructor
 14    RIVET_DEFAULT_ANALYSIS_CTOR(CRYSTAL_BALL_1986_I238081);
 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
 26      // Book histograms
 27      book(_c_hadrons, "/TMP/sigma_hadrons");
 28      book(_c_muons, "/TMP/sigma_muons");
 29      book(_c_D_star, "/TMP/sigma_D_star");
 30    }
 31
 32
 33    /// Perform the per-event analysis
 34    void analyze(const Event& event) {
 35      const FinalState& fs = apply<FinalState>(event, "FS");
 36
 37      map<long,int> nCount;
 38      int ntotal(0);
 39      for (const Particle& p : fs.particles()) {
 40	nCount[p.pid()] += 1;
 41	++ntotal;
 42      }
 43      // mu+mu- + photons
 44      if(nCount[-13]==1 and nCount[13]==1 &&
 45	 ntotal==2+nCount[22])
 46	_c_muons->fill();
 47      // everything else
 48      else
 49	_c_hadrons->fill();
 50
 51      const FinalState& ufs = apply<UnstableParticles>(event, "UFS");
 52      bool found = false;
 53      for (const Particle & p : ufs.particles()) {
 54	if(abs(p.pid())!=413 && abs(p.pid())!=423) continue;
 55	bool fs = true;
 56	for (const Particle & child : p.children()) {
 57	  if(child.pid()==p.pid()) {
 58	    fs = false;
 59	    break;
 60	  }
 61	}
 62	if(fs) {
 63	  found = true;
 64	  break;
 65	}
 66      }
 67      if(found) 
 68	_c_D_star->fill();
 69    }
 70
 71
 72    /// Normalise histograms etc., after the run
 73    void finalize() {
 74      // R
 75      Scatter1D R = *_c_hadrons/ *_c_muons;
 76      double              rval = R.point(0).x();
 77      pair<double,double> rerr = R.point(0).xErrs();
 78      double fact = crossSection()/ sumOfWeights() /picobarn;
 79      double sig_h = _c_hadrons->val()*fact;
 80      double err_h = _c_hadrons->err()*fact;
 81      double sig_m = _c_muons  ->val()*fact;
 82      double err_m = _c_muons  ->err()*fact;
 83      Scatter2D temphisto(refData(1, 1, 1));
 84      Scatter2DPtr hadrons;
 85      book(hadrons, "sigma_hadrons");
 86      Scatter2DPtr muons;
 87      book(muons, "sigma_muons"  );
 88      Scatter2DPtr mult;
 89      book(mult, 1, 1, 1);
 90      for (size_t b = 0; b < temphisto.numPoints(); b++) {
 91	const double x  = temphisto.point(b).x();
 92	pair<double,double> ex = temphisto.point(b).xErrs();
 93	pair<double,double> ex2 = ex;
 94	if(ex2.first ==0.) ex2. first=0.0001;
 95	if(ex2.second==0.) ex2.second=0.0001;
 96	if (inRange(sqrtS()/GeV, x-ex2.first, x+ex2.second)) {
 97	  mult   ->addPoint(x, rval, ex, rerr);
 98	  hadrons->addPoint(x, sig_h, ex, make_pair(err_h,err_h));
 99	  muons  ->addPoint(x, sig_m, ex, make_pair(err_m,err_m));
100	}
101	else {
102	  mult   ->addPoint(x, 0., ex, make_pair(0.,.0));
103	  hadrons->addPoint(x, 0., ex, make_pair(0.,.0));
104	  muons  ->addPoint(x, 0., ex, make_pair(0.,.0));
105	}
106      }
107      // D*
108      fact = crossSection()/ sumOfWeights() /nanobarn;
109      double sigma = _c_D_star->val()*fact;
110      double error = _c_D_star->err()*fact;
111      Scatter2D temphisto2(refData(2, 1, 1));
112      Scatter2DPtr mult2;
113      book(mult2, 2, 1, 1);
114      for (size_t b = 0; b < temphisto2.numPoints(); b++) {
115      	const double x  = temphisto2.point(b).x();
116      	pair<double,double> ex = temphisto2.point(b).xErrs();
117      	pair<double,double> ex2 = ex;
118      	if(ex2.first ==0.) ex2. first=0.0001;
119      	if(ex2.second==0.) ex2.second=0.0001;
120      	if (inRange(sqrtS()/GeV, x-ex2.first, x+ex2.second)) {
121      	  mult2   ->addPoint(x, sigma, ex, make_pair(error,error));
122      	}
123      	else {
124      	  mult2   ->addPoint(x, 0., ex, make_pair(0.,.0));
125      	}
126      }
127    }
128
129    //@}
130
131
132    /// @name Histograms
133    //@{
134    CounterPtr _c_hadrons, _c_muons,_c_D_star;
135    //@}
136
137
138  };
139
140
141  // The hook for the plugin system
142  RIVET_DECLARE_PLUGIN(CRYSTAL_BALL_1986_I238081);
143
144
145}