herwig is hosted by Hepforge, IPPP Durham
Herwig 7.3.0
SMHiggsMassGenerator.h
1// -*- C++ -*-
2//
3// SMHiggsMassGenerator.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_SMHiggsMassGenerator_H
10#define HERWIG_SMHiggsMassGenerator_H
11//
12// This is the declaration of the SMHiggsMassGenerator class.
13//
14
15#include "GenericMassGenerator.h"
16#include "GenericWidthGenerator.h"
17
18namespace Herwig {
19
20using namespace ThePEG;
21
30
31public:
32
37
44 virtual double weight(Energy q, int shape) const {
45 Energy2 q2 = sqr(q);
46 Energy2 mass2 = sqr(nominalMass());
47 Energy2 mwidth= nominalMass()*nominalWidth();
48 return BreitWignerWeight(q,shape)*(sqr(mass2-q2)+sqr(mwidth))/mwidth;
49 }
50
56 bool accept(const ParticleData & part) const;
57
61 virtual void dataBaseOutput(ofstream &,bool);
62
70
76 void persistentInput(PersistentIStream & is, int version);
78
85 static void Init();
86
87protected:
88
95 virtual InvEnergy2 BreitWignerWeight(Energy q,int shape) const {
96 useMe();
97 pair<Energy,Energy> widths = shape!=2 ? _hwidth->width(q,*particle()) :
98 make_pair(nominalWidth(),nominalWidth());
99 Energy2 q2 = sqr(q);
100 Energy4 sq=sqr(q2-sqr(nominalMass()));
101 Energy2 num = widths.first*q;
102 double fact = 1.;
103 if(_shape==1) fact *= pow<4,1>(nominalMass()/q);
104 if( shape==3) num=GeV2;
105 return num*fact/Constants::pi/(sq+sqr(widths.second*q)*fact);
106 }
107
108protected:
109
116 virtual IBPtr clone() const { return new_ptr(*this); }
117
122 virtual IBPtr fullclone() const { return new_ptr(*this); }
124
125protected:
126
134 virtual void doinit();
136
137private:
138
144
145private:
146
150 unsigned int _shape;
151
155 GenericWidthGeneratorPtr _hwidth;
156
157};
158
159}
160
161#endif /* HERWIG_SMHiggsMassGenerator_H */
The GenericMassGenerator class is a simple class for the generation of particle masses in Herwig.
Energy nominalMass() const
Default mass.
Energy nominalWidth() const
Default Width.
tcPDPtr particle() const
Accesss to the particle.
The SMHiggsMassGenerator class implements the generation of the Higgs boson mass according to the pre...
virtual double weight(Energy q, int shape) const
Weight for the factor for an off-shell mass.
SMHiggsMassGenerator()
The default constructor.
virtual void doinit()
Initialize this object after the setup phase before saving and EventGenerator to disk.
virtual IBPtr clone() const
Make a simple clone of this object.
SMHiggsMassGenerator & operator=(const SMHiggsMassGenerator &)=delete
The assignment operator is private and must never be called.
static void Init()
The standard Init function used to initialize the interfaces.
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
bool accept(const ParticleData &part) const
Return true if this mass generator can handle the given particle type.
unsigned int _shape
Option for the line-shape.
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
GenericWidthGeneratorPtr _hwidth
The width generator.
virtual void dataBaseOutput(ofstream &, bool)
output for the database
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
virtual InvEnergy2 BreitWignerWeight(Energy q, int shape) const
Weight for the factor for an off-shell mass.
void useMe() const
-*- C++ -*-
constexpr double pi
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
constexpr auto sqr(const T &x) -> decltype(x *x)