Rivet analyses referenceCUSB_1991_I325661Inclusive $B^*$ cross-section above the $\Upsilon(4S)$Experiment: CUSB (CESR) Inspire ID: 325661 Status: VALIDATED Authors:
Beam energies: (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. Source code: CUSB_1991_I325661.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/UnstableParticles.hh"
4
5namespace Rivet {
6
7
8 /// @brief Add a short analysis description here
9 class CUSB_1991_I325661 : public Analysis {
10 public:
11
12 /// Constructor
13 RIVET_DEFAULT_ANALYSIS_CTOR(CUSB_1991_I325661);
14
15
16 /// @name Analysis methods
17 /// @{
18
19 /// Book histograms and initialise projections before the run
20 void init() {
21
22 // Initialise and register projections
23 declare(UnstableParticles(), "UFS");
24
25 // Book histograms
26 book(_c_Bstar, "/TMP/sigma_Bstar");
27 }
28
29
30 /// Perform the per-event analysis
31 void analyze(const Event& event) {
32 const FinalState& ufs = apply<FinalState>(event, "UFS");
33 unsigned int nBstar(0);
34 // Get Bottom hadrons
35 const Particles bhads = ufs.particles(Cuts::abspid==513 or Cuts::abspid==523);
36 // find the Bstars
37 for (const Particle& p : bhads) {
38 if(abs(p.pid())==513 || abs(p.pid())==523) {
39 if(!p.hasDescendantWith(Cuts::pid == p.pid())) ++nBstar;
40 }
41 }
42 if(nBstar!=0)
43 _c_Bstar->fill(nBstar);
44 }
45
46
47 /// Normalise histograms etc., after the run
48 void finalize() {
49 double fact = crossSection()/ sumOfWeights() /nanobarn;
50 double sig = _c_Bstar->val()*fact;
51 double err = _c_Bstar->err()*fact;
52 Estimate1DPtr mult;
53 book(mult, 1, 1, 1);
54 for (auto& b : mult->bins()) {
55 if (inRange(sqrtS()/GeV, b.xMin(), b.xMax())) {
56 b.set(sig, err);
57 }
58 }
59 }
60
61 /// @}
62
63
64 /// @name Histograms
65 /// @{
66 CounterPtr _c_Bstar;
67 /// @}
68
69
70 };
71
72
73 RIVET_DECLARE_PLUGIN(CUSB_1991_I325661);
74
75
76}
|