Rivet analyses referenceDELPHI_1993_I356732Charmed Meson spectra at LEPIExperiment: DELPHI (LEP) Inspire ID: 356732 Status: VALIDATED Authors:
Beam energies: (45.6, 45.6) GeV Run details:
Measurement of the spectra for $D^{*\pm$} $D^0$ and $D^\pm$ measured by DELPHI. Rather than the event rates in HEPData values read from Figs6-8 in the original paper are used with the branching ratios corrected using the PDG 2020 values. Source code: DELPHI_1993_I356732.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/UnstableParticles.hh"
4
5namespace Rivet {
6
7
8 /// @brief Charm hadrons at 91 GeV
9 class DELPHI_1993_I356732 : public Analysis {
10 public:
11
12 /// Constructor
13 RIVET_DEFAULT_ANALYSIS_CTOR(DELPHI_1993_I356732);
14
15
16 /// @name Analysis methods
17 ///@{
18
19 /// Book histograms and initialise projections before the run
20 void init() {
21 declare(UnstableParticles(), "UFS");
22
23 book(_h_Xe_Ds , 1, 1, 1);
24 book(_h_Xe_D0 , 3, 1, 1);
25 book(_h_Xe_Dp , 5, 1, 1);
26 }
27
28
29 /// Perform the per-event analysis
30 void analyze(const Event& event) {
31 const UnstableParticles& ufs = apply<UnstableParticles>(event, "UFS");
32
33 // Accept all D*+- decays.
34 for (const Particle& p : ufs.particles(Cuts::abspid==PID::DSTARPLUS ||
35 Cuts::abspid==PID::DPLUS ||
36 Cuts::abspid==PID::D0)) {
37 // Scaled energy.
38 const double energy = p.E()/GeV;
39 const double scaledEnergy = 2.*energy/sqrtS();
40 if(p.abspid()==PID::DSTARPLUS)
41 _h_Xe_Ds->fill(scaledEnergy);
42 else if(p.abspid()==PID::DPLUS)
43 _h_Xe_Dp->fill(scaledEnergy);
44 else
45 _h_Xe_D0->fill(scaledEnergy);
46 }
47 }
48
49
50 /// Normalise histograms etc., after the run
51 void finalize() {
52 scale(_h_Xe_Ds , 1./sumOfWeights());
53 scale(_h_Xe_Dp , 1./sumOfWeights());
54 scale(_h_Xe_D0 , 1./sumOfWeights());
55 }
56
57 ///@}
58
59
60 /// @name Histograms
61 ///@{
62 Histo1DPtr _h_Xe_Ds,_h_Xe_D0,_h_Xe_Dp;
63 ///@}
64
65
66 };
67
68
69 RIVET_DECLARE_PLUGIN(DELPHI_1993_I356732);
70
71}
|