rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

ALEPH_2014_I1267648

Normalised spectral functions of hadronic tau decays
Experiment: ALEPH (LEP)
Inspire ID: 1267648
Status: VALIDATED
Authors:
  • Holger Schulz
No references listed
Beams: * *
Beam energies: ANY
Run details:
  • Hadronic tau decays.

Spectral functions of pionic tau decays measured with ALEPH. The data is taken from http://aleph.web.lal.in2p3.fr/tau/specfun.html

Source code: ALEPH_2014_I1267648.cc
  1// -*- C++ -*-
  2#include "Rivet/Analysis.hh"
  3#include "Rivet/Projections/UnstableParticles.hh"
  4
  5namespace Rivet {
  6
  7
  8  /// @brief Add a short analysis description here
  9  class ALEPH_2014_I1267648 : public Analysis {
 10  public:
 11
 12    /// Constructor
 13    RIVET_DEFAULT_ANALYSIS_CTOR(ALEPH_2014_I1267648);
 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
 25      // Book histograms
 26      book(_h_pip0 , 1, 1, 1);
 27      book(_h_pi2p0, 2, 1, 1);
 28      book(_h_pi3p0, 3, 1, 1);
 29      book(_h_3pi  , 4, 1, 1);
 30      book(_h_3pip0, 5, 1, 1);
 31    }
 32
 33
 34    void findDecayProducts(const Particle &mother, unsigned int &nstable, unsigned int &npip,
 35                           unsigned int &npim, unsigned int &npi0, FourMomentum &ptot) {
 36      for (const Particle &p : mother.children()) {
 37        int id = p.pid();
 38        if (id == PID::KPLUS || id == PID::KMINUS) {
 39          ++nstable;
 40          ptot += p.momentum();
 41        }
 42        else if (id == PID::PIPLUS) {
 43          ++npip;
 44          ++nstable;
 45          ptot += p.momentum();
 46        }
 47        else if (id == PID::PIMINUS) {
 48          ++npim;
 49          ++nstable;
 50          ptot += p.momentum();
 51        }
 52        else if (id == PID::PI0) {
 53          ++nstable;
 54          ++npi0;
 55          ptot += p.momentum();
 56        }
 57        else if (id == PID::PHOTON)  continue;
 58        else if (!p.children().empty())  findDecayProducts(p, nstable, npip, npim, npi0, ptot);
 59        else  ++nstable;
 60      }
 61    }
 62
 63
 64    /// Perform the per-event analysis
 65    void analyze(const Event& event) {
 66
 67      // Loop over taus
 68      for (const Particle& tau : apply<UnstableParticles>(event, "UFS").particles(Cuts::abspid==PID::TAU)) {
 69        FourMomentum ptot;
 70        unsigned int nstable(0), npip(0), npim(0), npi0(0);
 71        findDecayProducts(tau,nstable,npip,npim,npi0,ptot);
 72        // tau -> pi pi0 nu_tau (both charges)
 73        if (npim==1 && npi0==1 && nstable==3)  _h_pip0->fill(ptot.mass2());
 74        // tau -> pi pi0 pi0 nu_tau (both charges)
 75        else if (npim==1 && npi0==2 && nstable==4)  _h_pi2p0->fill(ptot.mass2());
 76        //    tau -> pi pi0 pi0 pi0         (3,1,1)
 77        else if (npim==1 && npi0==3 && nstable==5)  _h_pi3p0->fill(ptot.mass2());
 78        //    tau -> 3 charged pions        (4,1,1)
 79        else if (npim==2 && npip==1 && nstable==4)  _h_3pi->fill(ptot.mass2());
 80        //    tau -> 3 charged pions + pi0  (5,1,1)
 81        else if (npim==2 && npip==1 && npi0==1 && nstable==5)  _h_3pip0->fill(ptot.mass2());
 82      }
 83    }
 84
 85
 86    /// Normalise histograms etc., after the run
 87    void finalize() {
 88
 89      normalize(_h_pip0);  // normalize to unity
 90      normalize(_h_pi2p0); // normalize to unity
 91      normalize(_h_pi3p0); // normalize to unity
 92      normalize(_h_3pi);   // normalize to unity
 93      normalize(_h_3pip0); // normalize to unity
 94
 95    }
 96
 97    /// @}
 98
 99
100  private:
101
102
103    /// @name Histograms
104    /// @{
105    Histo1DPtr _h_pip0;
106    Histo1DPtr _h_pi2p0;
107    Histo1DPtr _h_pi3p0;
108    Histo1DPtr _h_3pi;
109    Histo1DPtr _h_3pip0;
110    /// @}
111
112  };
113
114
115  RIVET_DECLARE_PLUGIN(ALEPH_2014_I1267648);
116
117}