Rivet analyses referenceCLEO_1991_I29927Inclusive $B^*$ cross-section above the $\Upsilon(4S)$Experiment: CLEO (CESR) Inspire ID: 29927 Status: VALIDATED NOTREENTRY HEPDATA SINGLEWEIGHT Authors:
Beam energies: (5.3, 5.3); (5.3, 5.3); (5.3, 5.3); (5.3, 5.3); (5.3, 5.3); (5.3, 5.3); (5.3, 5.3) GeV Run details:
Measurement of the inclusive cross section for $B^*$ production at energies above the $\Upsilon(4S)$ mass. Beam energy must be specified as analysis option "ENERGY" when rivet-merging samples. Source code: CLEO_1991_I29927.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/UnstableParticles.hh"
4
5namespace Rivet {
6
7
8 class CLEO_1991_I29927 : public Analysis {
9 public:
10
11 /// Constructor
12 RIVET_DEFAULT_ANALYSIS_CTOR(CLEO_1991_I29927);
13
14
15 /// @name Analysis methods
16 /// @{
17
18 /// Book histograms and initialise projections before the run
19 void init() {
20
21 // Initialise and register projections
22 declare(UnstableParticles(), "UFS");
23
24 // Book histograms
25 book(_c_B , 1, 1, 1);
26 book(_c_Bstar, 2, 1, 1);
27 for (const string& en : _c_B.binning().edges<0>()) {
28 const double end = std::stod(en)*GeV;
29 if (isCompatibleWithSqrtS(end)) {
30 _ecms = en;
31 break;
32 }
33 }
34 if(_ecms.empty()) MSG_ERROR("Beam energy incompatible with analysis.");
35
36 }
37
38
39 /// Perform the per-event analysis
40 void analyze(const Event& event) {
41 const FinalState& ufs = apply<FinalState>(event, "UFS");
42 unsigned int nBstar(0);
43 // Get Bottom hadrons
44 const Particles bhads = select(ufs.particles(), isBottomHadron);
45 // find the Bstars
46 for (const Particle& p : bhads) {
47 if(abs(p.pid())==513 || abs(p.pid())==523) {
48 if(!p.hasDescendantWith(Cuts::pid == p.pid())) ++nBstar;
49 }
50 }
51 if(!bhads.empty())
52 _c_B->fill(_ecms);
53 if(nBstar!=0)
54 _c_Bstar->fill(_ecms,nBstar);
55 }
56
57
58 /// Normalise histograms etc., after the run
59 void finalize() {
60 double fact = crossSection()/ sumOfWeights() /picobarn;
61 scale(_c_B,fact);
62 scale(_c_Bstar,fact);
63 }
64
65 /// @}
66
67
68 /// @name Histograms
69 /// @{
70 BinnedHistoPtr<string> _c_B, _c_Bstar;
71 string _ecms;
72 /// @}
73
74
75 };
76
77
78 RIVET_DECLARE_PLUGIN(CLEO_1991_I29927);
79
80
81}
|