00001 // -*- C++ -*- 00002 // 00003 // GaussianPtGenerator.h is a part of ThePEG - Toolkit for HEP Event Generation 00004 // Copyright (C) 1999-2007 Leif Lonnblad 00005 // 00006 // ThePEG is licenced under version 2 of the GPL, see COPYING for details. 00007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 00008 // 00009 #ifndef THEPEG_GaussianPtGenerator_H 00010 #define THEPEG_GaussianPtGenerator_H 00011 // This is the declaration of the GaussianPtGenerator class. 00012 00013 #include "ThePEG/Handlers/PtGenerator.h" 00014 00015 namespace ThePEG { 00016 00025 class GaussianPtGenerator: public PtGenerator { 00026 00027 public: 00028 00034 GaussianPtGenerator() : theSigma(1.0*GeV), theUpperCut(5.0*GeV) {} 00035 00039 virtual ~GaussianPtGenerator(); 00041 00042 public: 00043 00053 virtual TransverseMomentum generate() const; 00055 00056 public: 00057 00064 void persistentOutput(PersistentOStream & os) const; 00065 00071 void persistentInput(PersistentIStream & is, int version); 00073 00077 static void Init(); 00078 00079 protected: 00080 00087 virtual IBPtr clone() const; 00088 00093 virtual IBPtr fullclone() const; 00095 00096 private: 00097 00102 Energy theSigma; 00103 00107 Energy theUpperCut; 00108 00109 private: 00110 00114 static ClassDescription<GaussianPtGenerator> initGaussianPtGenerator; 00115 00119 GaussianPtGenerator & operator=(const GaussianPtGenerator &); 00120 00121 }; 00122 00123 } 00124 00125 00126 #include "ThePEG/Utilities/ClassTraits.h" 00127 00128 namespace ThePEG { 00129 00136 template <> 00137 struct BaseClassTrait<GaussianPtGenerator,1>: public ClassTraitsType { 00139 typedef PtGenerator NthBase; 00140 }; 00141 00147 template <> 00148 struct ClassTraits<GaussianPtGenerator> 00149 : public ClassTraitsBase<GaussianPtGenerator> { 00151 static string className() { return "ThePEG::GaussianPtGenerator"; } 00155 static string library() { return "GaussianPtGenerator.so"; } 00156 00157 }; 00158 00161 } 00162 00163 #endif /* THEPEG_GaussianPtGenerator_H */