thepeg is hosted by Hepforge, IPPP Durham
ThePEG 2.3.0
PDFBase.h
1// -*- C++ -*-
2//
3// PDFBase.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_PDFBase_H
10#define ThePEG_PDFBase_H
11// This is the declaration of the PDFBase class.
12
14#include "ThePEG/Handlers/HandlerBase.h"
15#include "ThePEG/PDF/PDFCuts.h"
16#include "PDFBase.xh"
17
18namespace ThePEG {
19
40class PDFBase: public HandlerBase {
41
42public:
43
50
54 PDFBase(const PDFBase &);
55
59 virtual ~PDFBase();
61
62public:
63
70 virtual bool canHandleParticle(tcPDPtr particle) const = 0;
71
77 virtual bool canHandle(tcPDPtr particle) const;
78
84 virtual bool hasPoleIn1(tcPDPtr particle, tcPDPtr parton) const;
85
90 virtual cPDVector partons(tcPDPtr particle) const = 0;
91
98 virtual double xfl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
99 double l, Energy2 particleScale = ZERO) const;
100
107 virtual double xfx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
108 double x, double eps = 0.0,
109 Energy2 particleScale = ZERO) const;
110
121 virtual double xfvl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
122 double l, Energy2 particleScale = ZERO) const;
123
133 virtual double xfvx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
134 double x, double eps = 0.0,
135 Energy2 particleScale = ZERO) const;
136
146 virtual double xfsl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
147 double l, Energy2 particleScale = ZERO) const;
148
158 virtual double xfsx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale,
159 double x, double eps = 0.0,
160 Energy2 particleScale = ZERO) const;
161
172 virtual double flattenL(tcPDPtr particle, tcPDPtr parton, const PDFCuts &cut,
173 double z, double & jacobian) const;
174
187 virtual double flattenScale(tcPDPtr particle, tcPDPtr parton,
188 const PDFCuts & cut, double l, double z,
189 double & jacobian) const;
191
197
198
199public:
200
208
214 void persistentInput(PersistentIStream & is, int version);
216
220 static void Init();
221
222protected:
223
231 virtual void doinit();
232
233protected:
234
240
241protected:
242
247 rangeFreeze,
250 };
251
257
258private:
259
260
266
270 PDFBase & operator=(const PDFBase &) = delete;
271
272};
273
274ThePEG_DECLARE_CLASS_TRAITS(PDFBase,HandlerBase);
275
276}
277
278#endif /* ThePEG_PDFBase_H */
This is the main config header file for ThePEG.
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
PDFBase is the base class for implementing parton density functions for particles with sub-structure.
Definition: PDFBase.h:40
virtual bool hasPoleIn1(tcPDPtr particle, tcPDPtr parton) const
Return true if this PDF has a pole at $x=1$ for the given particle and parton.
virtual ~PDFBase()
Destructor.
PDFBase(const PDFBase &)
Copy-constructor.
virtual double xfsx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double x, double eps=0.0, Energy2 particleScale=ZERO) const
The sea density.
virtual double xfvx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double x, double eps=0.0, Energy2 particleScale=ZERO) const
The valence density.
virtual cPDVector partons(tcPDPtr particle) const =0
Return the partons which this PDF may extract from the given particle.
virtual bool canHandleParticle(tcPDPtr particle) const =0
Return true if this PDF can handle the extraction of partons from the given particle.
static AbstractClassDescription< PDFBase > initPDFBase
The static object used to initialize the description of this class.
Definition: PDFBase.h:265
static void Init()
Standard Init function used to initialize the interface.
tcRemHPtr remnantHandler() const
Pointer to the remnant handler to handle remnant when extracting partons according to these densities...
Definition: PDFBase.h:196
virtual double flattenScale(tcPDPtr particle, tcPDPtr parton, const PDFCuts &cut, double l, double z, double &jacobian) const
Generate scale (as a fraction of the maximum scale).
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
PDFBase()
Default constructor.
PDFBase & operator=(const PDFBase &)=delete
Private and non-existent assignment operator.
virtual void doinit()
Initialize this object after the setup phase before saving an EventGenerator to disk.
RangeException
Indicate how to deal with x and Q2 which are out of range.
Definition: PDFBase.h:246
@ rangeZero
‍Freeze the value of the PDF outside the limits.
Definition: PDFBase.h:248
@ rangeThrow
‍Set the PDF to zero outside the limits.
Definition: PDFBase.h:249
virtual bool canHandle(tcPDPtr particle) const
Return true if canHandleParticle() and if the corresponding method for remnantHandler() returns true ...
virtual double flattenL(tcPDPtr particle, tcPDPtr parton, const PDFCuts &cut, double z, double &jacobian) const
Generate a momentum fraction.
RangeException rangeException
Indicate to subclasses how to deal with x and Q2 which are out of range.
Definition: PDFBase.h:256
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
virtual double xfvl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double l, Energy2 particleScale=ZERO) const
The valence density.
virtual double xfsl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double l, Energy2 particleScale=ZERO) const
The sea density.
virtual double xfl(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double l, Energy2 particleScale=ZERO) const
The density.
virtual double xfx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, double x, double eps=0.0, Energy2 particleScale=ZERO) const
The density.
RemHPtr theRemnantHandler
A remnant handler which can generate remnants for the parton extracted withfor this PDF.
Definition: PDFBase.h:239
The PDFCuts class is used to specify cuts on scale and momentum fractions for which a PDFBase object ...
Definition: PDFCuts.h:27
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...
RCPtr is a reference counted (smart) pointer.
Definition: RCPtr.h:60
TransientConstRCPtr is a simple wrapper around a bare const pointer which can be assigned to and from...
Definition: RCPtr.h:696
This is the main namespace within which all identifiers in ThePEG are declared.
Definition: FactoryBase.h:28
constexpr ZeroUnit ZERO
ZERO can be used as zero for any unitful quantity.
Definition: PhysicalQty.h:35
vector< cPDPtr > cPDVector
A vector of pointers to const ParticleData objects.
Definition: Containers.h:36