herwig is hosted by Hepforge, IPPP Durham
Herwig 7.3.0
TwoBodyAllOnCalculator.h
1// -*- C++ -*-
2//
3// TwoBodyAllOnCalculator.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_TwoBodyAllOnCalculator_H
10#define HERWIG_TwoBodyAllOnCalculator_H
11// This is the declaration of the TwoBodyAllOnCalculator class.
12
13#include "WidthCalculatorBase.h"
14#include "TwoBodyAllOnCalculator.fh"
15#include "GenericWidthGenerator.h"
16
17namespace Herwig {
18using namespace ThePEG;
19
31
32public:
33
39
40public:
41
49 TwoBodyAllOnCalculator(tGenericWidthGeneratorPtr inwidth,int imode,
50 Energy m1,Energy m2)
51 : _mode(imode),_mass1(m1),_mass2(m2),_widthgen(inwidth)
52 {}
53
59 Energy partialWidth(Energy2 scale) const;
60
68 void resetMass(int imass,Energy mass) {
69 if(imass==1) _mass1=mass;
70 else if(imass==2) _mass2=mass;
71 else throw Exception() << "Unknown particle in "
72 << "TwoBodyAllOnCalculator::resetMass()"
74 }
75
82 Energy getMass(const int imass) const {
83 if(imass==1) return _mass1;
84 else if(imass==2) return _mass2;
85 else throw Exception() << "Unknown particle in "
86 << "TwoBodyAllOnCalculator::getMass()"
88 }
89
96 Energy otherMass(const int imass) const {
97 if(imass==1) return _mass2;
98 else if(imass==2) return _mass1;
99 else throw Exception() << "Unknown particle in "
100 << "TwoBodyAllOnCalculator::otherMass()"
102 }
103
104private:
105
110
111private:
112
116 int _mode;
117
121 Energy _mass1;
122
126 Energy _mass2;
127
131 GenericWidthGeneratorPtr _widthgen;
132
133};
134
135}
136
137#endif /* HERWIG_TwoBodyAllOnCalculator_H */
The GenericWidthGenerator class is designed to automatically calculate the running width for a given ...
The TwoBodyAllOnCalculator class is a wrapped around the the simple two body decay matrix elements in...
Energy _mass1
Mass of the first particle.
Energy partialWidth(Energy2 scale) const
member to calculate the partial width.
Energy otherMass(const int imass) const
Get the masses of all bar the one specified.
TwoBodyAllOnCalculator(tGenericWidthGeneratorPtr inwidth, int imode, Energy m1, Energy m2)
Constructor.
GenericWidthGeneratorPtr _widthgen
the width generator
Energy getMass(const int imass) const
Get the mass of one of the decay products.
void resetMass(int imass, Energy mass)
Get the mass of one of the decay products.
TwoBodyAllOnCalculator & operator=(const TwoBodyAllOnCalculator &)=delete
Private and non-existent assignment operator.
Energy _mass2
Mass of the second particle.
The WidthCalculatorBase class is a base class to be used by classes which calculate partial widths fo...
-*- C++ -*-