thepeg is hosted by Hepforge, IPPP Durham
ThePEG 2.3.0
RemnantHandler.h
1// -*- C++ -*-
2//
3// RemnantHandler.h is a part of ThePEG - Toolkit for HEP Event Generation
4// Copyright (C) 1999-2019 Leif Lonnblad
5//
6// ThePEG 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 ThePEG_RemnantHandler_H
10#define ThePEG_RemnantHandler_H
11// This is the declaration of the RemnantHandler class.
12
13#include "ThePEG/Handlers/HandlerBase.h"
14#include "ThePEG/PDF/PartonBin.h"
15#include "ThePEG/PDF/PartonBinInstance.h"
16#include "ThePEG/Vectors/Transverse.h"
17#include "RemnantHandler.xh"
18
19namespace ThePEG {
20
32
33public:
34
41 RemnantHandler(bool multi = false);
43
44public:
45
52 virtual bool canHandle(tcPDPtr particle,
53 const cPDVector & partons) const = 0;
54
65 virtual int nDim(const PartonBin & pb, bool doScale) const;
66
79 virtual Lorentz5Momentum generate(PartonBinInstance & pb, const double * r,
80 Energy2 scale,
81 const LorentzMomentum & parent,
82 bool fixedPartonMomentum = false) const = 0;
83
98 virtual Lorentz5Momentum generate(PartonBinInstance & pb, const double * r,
99 Energy2 scale, Energy2 shat,
100 const LorentzMomentum & parent,
101 bool fixedPartonMomentum = false) const = 0;
102
107 virtual void boostRemnants(PartonBinInstance & pb) const;
108
117 virtual bool recreateRemnants(PartonBinInstance & pb, tPPtr oldp, tPPtr newp,
118 double newl, Energy2 scale,
119 const LorentzMomentum & p,
120 const PVector & prev = PVector()) const;
133 virtual bool recreateRemnants(PartonBinInstance & pb, tPPtr oldp, tPPtr newp,
134 double newl, Energy2 scale,
135 Energy2 shat, const LorentzMomentum & p,
136 const PVector & prev = PVector()) const;
138
143 bool multiCapable() const { return isMultiCapable; }
144
145public:
146
154
160 void persistentInput(PersistentIStream & is, int version);
162
166 static void Init();
167
168protected:
169
175
176private:
177
183
188
189};
190
195template <>
198 typedef HandlerBase NthBase;
199};
200
203template <>
204struct ClassTraits<RemnantHandler>: public ClassTraitsBase<RemnantHandler> {
206 static string className() { return "ThePEG::RemnantHandler"; }
207};
208
211}
212
213#endif /* ThePEG_RemnantHandler_H */
A concreate implementation of ClassDescriptionBase describing an abstract class with persistent data.
HandlerBase is an abstract base class derived from the Interfaced class via the HandlerBaseT class ad...
Definition: HandlerBase.h:151
PartonBinInstance is used to store information about the generation of a given parton extraction for ...
The PartonBin class is used by the PartonExtractor class to store information about the extraction of...
Definition: PartonBin.h:38
PersistentIStream is used to read persistent objects from a stream where they were previously written...
PersistentOStream is used to write objects persistently to a stream from which they can be read in ag...
TransientConstRCPtr is a simple wrapper around a bare const pointer which can be assigned to and from...
Definition: RCPtr.h:696
TransientRCPtr is a simple wrapper around a bare pointer which can be assigned to and from an RCPtr a...
Definition: RCPtr.h:519
RemnantHandler is an abstract base class for implementing classes used to generate remnants when part...
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
virtual Lorentz5Momentum generate(PartonBinInstance &pb, const double *r, Energy2 scale, const LorentzMomentum &parent, bool fixedPartonMomentum=false) const =0
Generate the momentum of the extracted parton with the parent momentum given by the last argument.
virtual bool recreateRemnants(PartonBinInstance &pb, tPPtr oldp, tPPtr newp, double newl, Energy2 scale, const LorentzMomentum &p, const PVector &prev=PVector()) const
Redo the remnant generation for the given particle bin, pb.
static void Init()
Standard Init function used to initialize the interface.
virtual Lorentz5Momentum generate(PartonBinInstance &pb, const double *r, Energy2 scale, Energy2 shat, const LorentzMomentum &parent, bool fixedPartonMomentum=false) const =0
Generate the momentum of the extracted parton with the parent momentum given by the last argument.
bool isMultiCapable
True if this handler can generate remnants also if several partons have been extracted.
static AbstractClassDescription< RemnantHandler > initRemnantHandler
The static object used to initialize the description of this class.
bool multiCapable() const
Return true if this remnant handler is able to handle multiple extractions of partons from the same p...
RemnantHandler & operator=(const RemnantHandler &)=delete
Private and non-existent assignment operator.
virtual int nDim(const PartonBin &pb, bool doScale) const
If the generation of remnants is expected to influence the actual cross section of the hard sub proce...
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
virtual bool canHandle(tcPDPtr particle, const cPDVector &partons) const =0
Return true if this remnant handler can handle extracting all specified partons from the given partic...
RemnantHandler(bool multi=false)
Default constructor.
virtual void boostRemnants(PartonBinInstance &pb) const
Boost the generated remnants to the proper momentum given the information in the parton bin,...
virtual bool recreateRemnants(PartonBinInstance &pb, tPPtr oldp, tPPtr newp, double newl, Energy2 scale, Energy2 shat, const LorentzMomentum &p, const PVector &prev=PVector()) const
Redo the remnant generation for the given particle bin, pb.
This is the main namespace within which all identifiers in ThePEG are declared.
Definition: FactoryBase.h:28
vector< PPtr > PVector
A vector of pointers to Particle objects.
Definition: Containers.h:76
vector< cPDPtr > cPDVector
A vector of pointers to const ParticleData objects.
Definition: Containers.h:36
BaseClassTraits describes the base classes of the templated class.
Definition: ClassTraits.h:156
int NthBase
The type of the BaseN'th base class (int means there are no further base classes).
Definition: ClassTraits.h:161
static string className()
Return the name of class T.
Definition: ClassTraits.h:66
ClassTraitsType is an empty, non-polymorphic, base class.
Definition: ClassTraits.h:30