Rivet analyses referenceBELLE_2022_I2169621Exclusive semileptonic $B$ to $D$ decays.Experiment: BELLE (KEKB) Inspire ID: 2169621 Status: VALIDATED NOHEPDATA Authors:
Beam energies: ANY Run details:
Measurement of the differential partial width with respect to $w$ for $B$ to $D$ semi-leptonic decays. Source code: BELLE_2022_I2169621.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/UnstableParticles.hh"
4
5namespace Rivet {
6
7
8 /// @brief B -> D semileptonic
9 class BELLE_2022_I2169621 : public Analysis {
10 public:
11
12 /// Constructor
13 RIVET_DEFAULT_ANALYSIS_CTOR(BELLE_2022_I2169621);
14
15
16 /// @name Analysis methods
17 /// @{
18
19 /// Book histograms and initialise projections before the run
20 void init() {
21 // projection
22 declare(UnstableParticles(Cuts::pid==511 or
23 Cuts::pid==521), "UFS");
24 // histograms
25 for(unsigned int ix=0;ix<4;++ix)
26 book(_h[ix],1,1,1+ix);
27 for(unsigned int ix=0;ix<2;++ix)
28 book(_nB[ix],"TMP/nB_"+toString(ix));
29 }
30
31 // Check for explicit decay into pdgids
32 bool isSemileptonicDecay(const Particle& mother, vector<int> ids) {
33 // Trivial check to ignore any other decays but the one in question modulo photons
34 const Particles children = mother.children(Cuts::pid!=PID::PHOTON);
35 if (children.size()!=ids.size()) return false;
36 // Check for the explicit decay
37 return all(ids, [&](int i){return count(children, hasPID(i))==1;});
38 }
39
40 // Calculate the recoil w using mother and daugher meson
41 double recoilW(const Particle& B, int mesonID) {
42 // TODO why does that not work with const?
43 Particle D = select(B.children(), Cuts::pid==mesonID)[0];
44 FourMomentum q = B.mom() - D.mom();
45 return (B.mom()*B.mom() + D.mom()*D.mom() - q*q )/ (2. * sqrt(B.mom()*B.mom()) * sqrt(D.mom()*D.mom()) );
46 }
47
48 /// Perform the per-event analysis
49 void analyze(const Event& event) {
50 for(const Particle & p : apply<UnstableParticles>(event, "UFS").particles()) {
51 if(p.children().size()<=1) continue;
52 if(p.pid()==PID::BPLUS) {
53 _nB[0]->fill();
54 if (isSemileptonicDecay(p, {PID::D0BAR,PID::POSITRON,PID::NU_E})) _h[0]->fill(recoilW(p, PID::D0BAR));
55 if (isSemileptonicDecay(p, {PID::D0BAR,PID::ANTIMUON,PID::NU_MU})) _h[1]->fill(recoilW(p, PID::D0BAR));
56 }
57 else if(p.pid()==PID::B0) {
58 _nB[1]->fill();
59 if (isSemileptonicDecay(p, {PID::DMINUS,PID::POSITRON,PID::NU_E})) _h[2]->fill(recoilW(p, PID::DMINUS));
60 if (isSemileptonicDecay(p, {PID::DMINUS,PID::ANTIMUON,PID::NU_MU})) _h[3]->fill(recoilW(p, PID::DMINUS));
61 }
62 }
63 }
64
65
66 /// Normalise histograms etc., after the run
67 void finalize() {
68 double tau[2] = {1638e-15,1519e-15};
69 double hbar = 6.582119569e-10;
70 for(unsigned int ix=0;ix<4;++ix) {
71 double fact = ix<2 ? hbar/tau[0] : hbar/tau[1];
72 CounterPtr c = ix<2 ? _nB[0] : _nB[1];
73 scale(_h[ix],fact/ *c);
74 }
75 }
76
77 /// @}
78
79
80 /// @name Histograms
81 /// @{
82 Histo1DPtr _h[4];
83 CounterPtr _nB[2];
84 /// @}
85
86
87 };
88
89
90 RIVET_DECLARE_PLUGIN(BELLE_2022_I2169621);
91
92}
|