rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

BABAR_2011_I897848

Mass distributions in $B^0\to K^+\pi^-\pi^0$ decays
Experiment: BABAR (PEP-II)
Inspire ID: 897848
Status: VALIDATED NOHEPDATA
Authors:
  • Peter Richardson
References:
  • Phys.Rev.D 83 (2011) 112010
Beams: * *
Beam energies: ANY
Run details:
  • Any process producing B0 mesons, originally e+e- at Upsilon(4S)

Measurements of mass distributions in $B^0\to K^+\pi^-\pi^0$ decays. The data were read from the plots in the paper and the backgrounds given subtracted.

Source code: BABAR_2011_I897848.cc
 1// -*- C++ -*-
 2#include "Rivet/Analysis.hh"
 3#include "Rivet/Projections/UnstableParticles.hh"
 4#include "Rivet/Projections/DecayedParticles.hh"
 5
 6namespace Rivet {
 7
 8
 9  /// @brief B0 -> K+ pi- pi0
10  class BABAR_2011_I897848 : public Analysis {
11  public:
12
13    /// Constructor
14    RIVET_DEFAULT_ANALYSIS_CTOR(BABAR_2011_I897848);
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      UnstableParticles ufs = UnstableParticles(Cuts::abspid==511);
24      declare(ufs, "UFS");
25      DecayedParticles B0(ufs);
26      B0.addStable(PID::PI0);
27      declare(B0, "B0");
28      // histograms
29      for(unsigned int ix=0;ix<3;++ix) {
30	for(unsigned int iy=0;iy<2;++iy) {
31	  book(_h[ix][iy],1+ix,1,1+iy);
32	}
33      }
34    }
35
36
37    /// Perform the per-event analysis
38    void analyze(const Event& event) {
39      static const map<PdgId,unsigned int> & mode   = { { 321,1},{-211,1}, { 111,1}};
40      static const map<PdgId,unsigned int> & modeCC = { {-321,1},{ 211,1}, { 111,1}};
41      DecayedParticles B0 = apply<DecayedParticles>(event, "B0");
42      // loop over particles
43      for(unsigned int ix=0;ix<B0.decaying().size();++ix) {
44      	int sign = 1;
45      	if (B0.decaying()[ix].pid()>0 && B0.modeMatches(ix,3,mode)) {
46      	  sign=1;
47      	}
48      	else if  (B0.decaying()[ix].pid()<0 && B0.modeMatches(ix,3,modeCC)) {
49      	  sign=-1;
50      	}
51      	else
52      	  continue;
53	const Particle & Kp  = B0.decayProducts()[ix].at( sign*321)[0];
54	const Particle & pim = B0.decayProducts()[ix].at(-sign*211)[0];
55	const Particle & pi0 = B0.decayProducts()[ix].at(      111)[0];
56	double mpipi = (pim.momentum()+pi0.momentum()).mass();
57	_h[0][0]->fill(mpipi);
58	if(mpipi<1.8) _h[0][1]->fill(mpipi);
59	double mKpi  = (Kp.momentum()+pi0.momentum()).mass();
60	_h[1][0]->fill(mKpi);
61	if(mKpi<1.8) _h[1][1]->fill(mKpi);
62	mKpi  = (Kp.momentum()+pim.momentum()).mass();
63	_h[2][0]->fill(mKpi);
64	if(mKpi<1.8) _h[2][1]->fill(mKpi);
65      }
66    }
67
68
69    /// Normalise histograms etc., after the run
70    void finalize() {
71      for(unsigned int ix=0;ix<3;++ix) {
72	for(unsigned int iy=0;iy<2;++iy) {
73	  normalize(_h[ix][iy],1.,false);
74	}
75      }
76    }
77
78    /// @}
79
80
81    /// @name Histograms
82    /// @{
83    Histo1DPtr _h[3][2];
84    /// @}
85
86
87  };
88
89
90  RIVET_DECLARE_PLUGIN(BABAR_2011_I897848);
91
92}