Rivet analyses referenceBELLE_2009_I810744Pion Mass Spectrum in $\Upsilon(4S)\to\Upsilon(1S)\pi^+\pi^-$Experiment: BELLE (KEKB) Inspire ID: 810744 Status: VALIDATED Authors:
Beam energies: ANY Run details:
Measurement of the $\pi^+\pi^-$ mass Spectrum in $\Upsilon(4S)\to\Upsilon(1S)\pi^+\pi^-$ decays. Source code: BELLE_2009_I810744.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/UnstableParticles.hh"
4
5namespace Rivet {
6
7
8 /// @brief Upsilon(4S) -> Upsilon(1S) pi+pi-
9 class BELLE_2009_I810744 : public Analysis {
10 public:
11
12 /// Constructor
13 RIVET_DEFAULT_ANALYSIS_CTOR(BELLE_2009_I810744);
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 book(_hist, 1, 1, 1);
25
26 }
27
28 void findDecayProducts(const Particle & mother,
29 unsigned int & nstable,
30 Particles& pip, Particles& pim,
31 Particles & onium) {
32 for(const Particle & p : mother.children()) {
33 int id = p.pid();
34 if ( id == PID::PIMINUS) {
35 pim.push_back(p);
36 ++nstable;
37 }
38 else if (id == PID::PIPLUS) {
39 pip.push_back(p);
40 ++nstable;
41 }
42 else if (id == PID::PI0) {
43 ++nstable;
44 }
45 else if (id==553) {
46 onium.push_back(p);
47 ++nstable;
48 }
49 else if ( !p.children().empty() ) {
50 findDecayProducts(p,nstable,pip,pim,onium);
51 }
52 else
53 ++nstable;
54 }
55 }
56
57 /// Perform the per-event analysis
58 void analyze(const Event& event) {
59 // loop over unstable particles
60 for(const Particle& ups : apply<UnstableParticles>(event, "UFS").particles(Cuts::pid==300553)) {
61 unsigned int nstable(0);
62 Particles pip, pim, onium;
63 findDecayProducts(ups,nstable,pip,pim,onium);
64 // check for onium
65 if(onium.size() !=1 || nstable !=3) continue;
66 // check for pipi
67 if( ! (pip.size()==1 && pim.size() ==1) ) continue;
68 FourMomentum q = pip[0].momentum()+pim[0].momentum();
69 _hist->fill(q.mass());
70 }
71 }
72
73
74 /// Normalise histograms etc., after the run
75 void finalize() {
76 normalize(_hist);
77 }
78
79 /// @}
80
81
82 /// @name Histograms
83 /// @{
84 Histo1DPtr _hist;
85 /// @}
86
87
88 };
89
90
91 RIVET_DECLARE_PLUGIN(BELLE_2009_I810744);
92
93}
|