Rivet Analyses Reference

BABAR_2017_I1498564

Electron spectrum inclusive semi-leptonic in B decays
Experiment: BABAR (PEP-II)
Inspire ID: 1498564
Status: VALIDATED NOHEPDATA
Authors:
  • Peter Richardson
References:
  • Phys.Rev. D95 (2017) no.7, 072001
Beams: * *
Beam energies: ANY
Run details:
  • bottom mesons produced at the Upsilon(4S)

Measurement of the electron spectrum inclusive semi-leptonic in $B$ decays, including but the total and the charmless. N.B. The spectum is obtained in the rest frame of the decaying $\Upsilon(4S)$ which produces the decaying $B$ mesons

Source code: BABAR_2017_I1498564.cc
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
// -*- C++ -*-
#include "Rivet/Analysis.hh"
#include "Rivet/Projections/UnstableParticles.hh"

namespace Rivet {


  /// @brief Electron spectrum in B decays
  class BABAR_2017_I1498564 : public Analysis {
  public:

    /// Constructor
    RIVET_DEFAULT_ANALYSIS_CTOR(BABAR_2017_I1498564);


    /// @name Analysis methods
    //@{

    /// Book histograms and initialise projections before the run
    void init() {
      // projections
      declare(UnstableParticles(),"UFS");
      // Book histograms
      // specify custom binning
      book(_h_light, 1,1,1);
      book(_h_all  , 1,1,2);
      book(_nB,"/TMP/nB");
    }


    void findDecayProducts(Particle parent, Particles & em, Particles & ep,
			   Particles & nue, Particles & nueBar, bool & charm) {
      for(const Particle & p : parent.children()) {
	if(PID::isCharmHadron(p.pid())) {
	  charm=true;
	}
	else if(p.pid() == PID::EMINUS) {
	  em.push_back(p);
	}
	else if(p.pid() == PID::EPLUS) {
	  ep.push_back(p);
	}
	else if(p.pid() == PID::NU_E) {
	  nue.push_back(p);
	}
	else if(p.pid() == PID::NU_EBAR) {
	  nueBar.push_back(p);
	}
	else if(PID::isBottomHadron(p.pid())) {
	  findDecayProducts(p,em,ep,nue,nueBar,charm);
	}
	else if(!PID::isHadron(p.pid())) {
	  findDecayProducts(p,em,ep,nue,nueBar,charm);
	}
      }
    }


    /// Perform the per-event analysis
    void analyze(const Event& event) {
      // find and loop over Upslion(4S)
      const UnstableParticles& ufs = apply<UnstableParticles>(event, "UFS");
      for (const Particle& p : ufs.particles(Cuts::pid==300553)) {
      	// boost to rest frame
      	LorentzTransform cms_boost;
      	if (p.p3().mod() > 1*MeV)
      	  cms_boost = LorentzTransform::mkFrameTransformFromBeta(p.momentum().betaVec());
      	// loop over decay products
      	for(const Particle & p2 : p.children()) {
      	  if(p2.abspid()==511 || p2.abspid()==521) {
	    _nB->fill();
	    bool charm = false;
      	    Particles em,ep,nue,nueBar;
	    findDecayProducts(p2,em,ep,nue,nueBar,charm);
	    if(em.size()==1 && nueBar.size()==1) {
	      double pmod = cms_boost.transform(em[0].momentum()).p3().mod();
	      _h_all->fill(pmod);
	      if(!charm) _h_light->fill(pmod);
	    }
	    else if(ep.size()==1 && nue.size()==1) {
	      double pmod = cms_boost.transform(ep[0].momentum()).p3().mod();
	      _h_all->fill(pmod);
	      if(!charm) _h_light->fill(pmod);
	    }
      	  }
      	}
      }
    }


    /// Normalise histograms etc., after the run
    void finalize() {

      // normalize to number of B decays
      scale(_h_all, 1./ *_nB);
      scale(_h_light, 1./ *_nB);
    }

    //@}


    /// @name Histograms
    //@{
    Histo1DPtr _h_light,_h_all;
    CounterPtr _nB;
    //@}


  };


  RIVET_DECLARE_PLUGIN(BABAR_2017_I1498564);

}