|
|
|||
File indexing completed on 2026-08-06 09:24:14
0001 // -*- C++ -*- 0002 // 0003 // PhasespaceCouplings.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_PhasespaceCouplings_H 0010 #define Herwig_PhasespaceCouplings_H 0011 // 0012 // This is the declaration of the PhasespaceCouplings class. 0013 // 0014 0015 #include "ThePEG/Handlers/HandlerBase.h" 0016 #include "ThePEG/Persistency/PersistentOStream.h" 0017 #include "ThePEG/Persistency/PersistentIStream.h" 0018 0019 namespace Herwig { 0020 0021 using namespace ThePEG; 0022 0023 typedef std::tuple<long,long,long> LTriple; 0024 0025 inline PersistentOStream& operator<<(PersistentOStream& os, const LTriple& t) { 0026 os << std::get<0>(t) << std::get<1>(t) << std::get<2>(t); 0027 return os; 0028 } 0029 0030 inline PersistentIStream& operator>>(PersistentIStream& is, LTriple& t) { 0031 is >> std::get<0>(t) >> std::get<1>(t) >> std::get<2>(t); 0032 return is; 0033 } 0034 0035 /** 0036 * 0037 * \ingroup Matchbox 0038 * \author Simon Platzer 0039 * 0040 * \brief Store couplings for the phase space generator. 0041 * 0042 * @see \ref PhasespaceCouplingsInterfaces "The interfaces" 0043 * defined for PhasespaceCouplings. 0044 */ 0045 class PhasespaceCouplings: public HandlerBase { 0046 0047 public: 0048 0049 /** 0050 * Couplings to be used in diagram weighting 0051 */ 0052 map<LTriple,double>& couplings() { return theCouplings; } 0053 0054 /** 0055 * Couplings to be used in diagram weighting 0056 */ 0057 const map<LTriple,double>& couplings() const { return theCouplings; } 0058 0059 public: 0060 0061 /** @name Functions used by the persistent I/O system. */ 0062 //@{ 0063 /** 0064 * Function used to write out object persistently. 0065 * @param os the persistent output stream written to. 0066 */ 0067 void persistentOutput(PersistentOStream & os) const; 0068 0069 /** 0070 * Function used to read in object persistently. 0071 * @param is the persistent input stream read from. 0072 * @param version the version number of the object when written. 0073 */ 0074 void persistentInput(PersistentIStream & is, int version); 0075 //@} 0076 0077 /** 0078 * The standard Init function used to initialize the interfaces. 0079 * Called exactly once for each class by the class description system 0080 * before the main function starts or 0081 * when this class is dynamically loaded. 0082 */ 0083 static void Init(); 0084 0085 protected: 0086 0087 /** @name Clone Methods. */ 0088 //@{ 0089 /** 0090 * Make a simple clone of this object. 0091 * @return a pointer to the new object. 0092 */ 0093 virtual IBPtr clone() const; 0094 0095 /** Make a clone of this object, possibly modifying the cloned object 0096 * to make it sane. 0097 * @return a pointer to the new object. 0098 */ 0099 virtual IBPtr fullclone() const; 0100 //@} 0101 0102 0103 // If needed, insert declarations of virtual function defined in the 0104 // InterfacedBase class here (using ThePEG-interfaced-decl in Emacs). 0105 0106 0107 private: 0108 0109 /** 0110 * Couplings to be used in diagram weighting 0111 */ 0112 map<LTriple,double> theCouplings; 0113 0114 /** 0115 * The assignment operator is private and must never be called. 0116 * In fact, it should not even be implemented. 0117 */ 0118 PhasespaceCouplings & operator=(const PhasespaceCouplings &) = delete; 0119 0120 }; 0121 0122 } 0123 0124 #endif /* Herwig_PhasespaceCouplings_H */
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|