|
|
|||
File indexing completed on 2026-08-06 09:24:21
0001 // -*- C++ -*- 0002 // 0003 // PomeronPDF.h is a part of Herwig - A multi-purpose Monte Carlo event generator 0004 // Copyright (C) 2002-2019 The Herwig Collaboration 0005 // 0006 // Herwig is licenced under version 3 of the GPL, see COPYING for details. 0007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 0008 // 0009 #ifndef HERWIG_PomeronPDF_H 0010 #define HERWIG_PomeronPDF_H 0011 0012 #include <ThePEG/PDF/PDFBase.h> 0013 #include <iostream> 0014 #include <fstream> 0015 #include <string> 0016 #include <cmath> 0017 0018 namespace Herwig { 0019 0020 using namespace ThePEG; 0021 0022 /** \ingroup PDF 0023 * 0024 * Implementation of the PomeronPDF PDFs 0025 * 0026 * @see \ref PomeronPDFInterfaces "The interfaces" 0027 * defined for PomeronPDF. 0028 */ 0029 class PomeronPDF : public PDFBase { 0030 public: 0031 0032 /** @name Standard constructors and destructors. */ 0033 //@{ 0034 /** 0035 * Default constructor. 0036 */ 0037 PomeronPDF(); 0038 0039 0040 /** @name Virtual functions from PDFBase */ 0041 //@{ 0042 /** 0043 * Return true if this PDF can handle the extraction of parton from the 0044 * given particle ie. if the particle is a proton or neutron. 0045 * @param particle The particle 0046 */ 0047 virtual bool canHandleParticle(tcPDPtr particle) const; 0048 0049 /** 0050 * Return the parton types which are described by these parton 0051 * densities. 0052 * @param p The particle 0053 */ 0054 virtual cPDVector partons(tcPDPtr p) const; 0055 0056 /** 0057 * Return x times the pdf for the given parameters 0058 * @param particle The beam particle 0059 * @param parton The parton for which to return the PDF. 0060 * @param partonScale The scale at which to evaluate the PDF. 0061 * @param x The momentum fraction 0062 * @param eps ??? an unknown parameter from ThePEG. 0063 * @param particleScale The scale for the particle 0064 */ 0065 virtual double xfx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, 0066 double x, double eps = 0.0, 0067 Energy2 particleScale = ZERO) const; 0068 0069 /** 0070 * Return x times the valence pdf for the given parameters 0071 * @param particle The beam particle 0072 * @param parton The parton for which to return the PDF. 0073 * @param partonScale The scale at which to evaluate the PDF. 0074 * @param x The momentum fraction 0075 * @param eps ??? an unknown parameter from ThePEG. 0076 * @param particleScale The scale for the particle 0077 */ 0078 virtual double xfvx(tcPDPtr particle, tcPDPtr parton, Energy2 partonScale, 0079 double x, double eps = 0.0, 0080 Energy2 particleScale = ZERO) const; 0081 //@} 0082 0083 public: 0084 0085 /** @name Functions used by the persistent I/O system. */ 0086 //@{ 0087 /** 0088 * Function used to write out object persistently. 0089 * @param os the persistent output stream written to. 0090 */ 0091 void persistentOutput(PersistentOStream & os) const; 0092 0093 /** 0094 * Function used to read in object persistently. 0095 * @param is the persistent input stream read from. 0096 * @param version the version number of the object when written. 0097 */ 0098 void persistentInput(PersistentIStream & is, int version); 0099 //@} 0100 0101 /** 0102 * The standard Init function used to initialize the interfaces. 0103 * Called exactly once for each class by the class description system 0104 * before the main function starts or 0105 * when this class is dynamically loaded. 0106 */ 0107 static void Init(); 0108 0109 0110 protected: 0111 0112 /** @name Standard Interfaced functions. */ 0113 //@{ 0114 /** 0115 * Initialize this object after the setup phase before saving an 0116 * EventGenerator to disk. 0117 * @throws InitException if object could not be initialized properly. 0118 */ 0119 virtual void doinit(); 0120 0121 protected: 0122 0123 /** @name Clone Methods. */ 0124 //@{ 0125 /** 0126 * Make a simple clone of this object. 0127 * @return a pointer to the new object. 0128 */ 0129 virtual IBPtr clone() const; 0130 0131 /** Make a clone of this object, possibly modifying the cloned object 0132 * to make it sane. 0133 * @return a pointer to the new object. 0134 */ 0135 virtual IBPtr fullclone() const; 0136 //@} 0137 0138 0139 private: 0140 /** 0141 * Enumeration to storage the types of partons 0142 */ 0143 enum PDFFlavour {charm, gluon, singlet}; 0144 0145 /** 0146 * The assignment operator is private and must never be called. 0147 * In fact, it should not even be implemented. 0148 */ 0149 PomeronPDF & operator=(const PomeronPDF &) = delete; 0150 0151 private: 0152 0153 /** 0154 * This function calculates the PDF value for the given particles and a given x and q 0155 * @param flPDF Flavour of the PDF function 0156 * @param x The x of the pomeron 0157 * @param qq The scale 0158 * 0159 */ 0160 double getPDFValue(PDFFlavour flPDF, double x, Energy2 qq) const; 0161 0162 /** 0163 * Load the PDF tables from file to the vectors. 0164 */ 0165 void loadTables() const; 0166 0167 private: 0168 0169 /** 0170 * Number of PDF flavours 0171 */ 0172 static const int nPDFFlavour_; 0173 0174 0175 /** 0176 * Vector of matrixes of PDF functions for different flavours: 0177 * pdfTable [Flavours][Q^2][log x] 0178 */ 0179 mutable vector<vector<vector<double> > > pdfTable_; 0180 0181 /** 0182 * Vector of grid with log x values: lxGrid [Flavours] [log x] 0183 */ 0184 mutable vector<vector<double> > lxGrid_; 0185 0186 /** 0187 * Vector of grid with log qq values: lxGrid [Flavours] [log qq] 0188 */ 0189 mutable vector<vector<double> > lqqGrid_; 0190 0191 /** 0192 * Vector of names of PDF data files for each flavour 0193 */ 0194 vector<string> fileName_; 0195 0196 /** 0197 * Base of the filename 0198 */ 0199 string rootName_; 0200 0201 /** 0202 * Number of ln x points 0203 */ 0204 int nxPoints_; 0205 0206 /** 0207 * Number of qq flavours 0208 */ 0209 int nqPoints_; 0210 0211 /** 0212 * Switch between different PDF fits. Possible values: 0 fit 2007, 1 fit A 2006, 2 fit B 2006 0213 */ 0214 int PDFFit_; 0215 0216 /** 0217 * Switch between different aproaches when the values are out of PDF range: 0 Extrapolate, 1 Freeze 0218 */ 0219 int boundary_; 0220 0221 0222 }; 0223 0224 } 0225 0226 #endif
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|