herwig is hosted by Hepforge, IPPP Durham
Herwig 7.3.0
Hw64Decayer.h
1// -*- C++ -*-
2//
3// Hw64Decayer.h is a part of Herwig - A multi-purpose Monte Carlo event generator
4// Copyright (C) 2002-2019 The Herwig Collaboration
5//
6// Herwig is licenced under version 3 of the GPL, see COPYING for details.
7// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8//
9#ifndef HERWIG_Hw64Decayer_H
10#define HERWIG_Hw64Decayer_H
11//
12// This is the declaration of the Hw64Decayer class.
13//
15#include <HwDecayerBase.h>
16#include <ThePEG/Interface/Interfaced.h>
17#include <ThePEG/PDT/DecayMode.h>
18#include <ThePEG/Repository/Strategy.fh>
19#include <fstream>
20
21namespace Herwig {
22
23using namespace ThePEG;
24
45
46public:
47
52
57 virtual bool accept(tcPDPtr parent, const tPDVector & children) const;
58
63 virtual ParticleVector decay(const Particle & parent,
64 const tPDVector & children) const;
65
71 virtual void dataBaseOutput(ofstream & os,bool header) const;
72
73public:
74
78 static void Init();
79
87
93 void persistentInput(PersistentIStream & is, int version);
95
96protected:
97
104 virtual IBPtr clone() const {return new_ptr(*this);}
105
110 virtual IBPtr fullclone() const {return new_ptr(*this);}
112
113private:
114
118 static double VAWt(Energy2 t0, Energy2 t1, Energy2 t2, InvEnergy4 t3);
119
126 void setParticleMomentum(ParticleVector & out, const cPDVector & particles,
127 const vector<Lorentz5Momentum> & moms) const {
128 unsigned int numProds = particles.size();
129 for(unsigned int ix=0;ix<numProds;++ix)
130 out.push_back(particles[ix]->produceParticle(moms[ix]));
131 }
132
133private:
134
138 const Hw64Decayer & operator=(const Hw64Decayer &) = delete;
139
140private:
141
146
150 unsigned int _masstry;
151};
152
153}
154
155#endif /* HERWIG_Hw64Decayer_H */
Hw64Decayer is a class that defines all the general routines used in HERWIG++ to imitate the HERWIG 6...
Definition: Hw64Decayer.h:44
unsigned int _masstry
Maximum number of attempts to generate the off-shell masses.
Definition: Hw64Decayer.h:150
virtual void dataBaseOutput(ofstream &os, bool header) const
Output the setup information for the particle database.
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
Definition: Hw64Decayer.h:110
Hw64Decayer()
Default constructor.
Definition: Hw64Decayer.h:51
virtual bool accept(tcPDPtr parent, const tPDVector &children) const
return true if this decayer can perfom the decay specified by the given decay mode.
virtual ParticleVector decay(const Particle &parent, const tPDVector &children) const
for a given decay mode and a given particle instance, perform the decay and return the decay products...
static double VAWt(Energy2 t0, Energy2 t1, Energy2 t2, InvEnergy4 t3)
Weighting of phase space for V-A matrix elements.
static void Init()
Standard Init function used to initialize the interface.
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
int MECode
The code for the matrix element being used.
Definition: Hw64Decayer.h:145
const Hw64Decayer & operator=(const Hw64Decayer &)=delete
Private and non-existent assignment operator.
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
virtual IBPtr clone() const
Make a simple clone of this object.
Definition: Hw64Decayer.h:104
void setParticleMomentum(ParticleVector &out, const cPDVector &particles, const vector< Lorentz5Momentum > &moms) const
Take an array of momenta and set the momentum member of the particles.
Definition: Hw64Decayer.h:126
The HwDecayerBase class is the base class for Decayers in Herwig.
Definition: HwDecayerBase.h:37
-*- C++ -*-
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
vector< tPDPtr > tPDVector
vector< PPtr > ParticleVector
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr
vector< cPDPtr > cPDVector