Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-08-06 09:24:08

0001 // -*- C++ -*-
0002 //
0003 // MEvv2ss.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_MEvv2ss_H
0010 #define HERWIG_MEvv2ss_H
0011 //
0012 // This is the declaration of the MEvv2ss class.
0013 //
0014 
0015 #include "GeneralHardME.h"
0016 #include "ThePEG/Helicity/WaveFunction/VectorWaveFunction.h"
0017 #include "ThePEG/Helicity/WaveFunction/ScalarWaveFunction.h"
0018 #include "ThePEG/Helicity/Vertex/AbstractVVSVertex.h"
0019 #include "ThePEG/Helicity/Vertex/AbstractVSSVertex.h"
0020 #include "ThePEG/Helicity/Vertex/AbstractVVVVertex.h"
0021 #include "ThePEG/Helicity/Vertex/AbstractVVTVertex.h"
0022 #include "ThePEG/Helicity/Vertex/AbstractSSTVertex.h"
0023 #include "ThePEG/Helicity/Vertex/AbstractVVSSVertex.h"
0024 #include "ThePEG/Helicity/Vertex/AbstractSSSVertex.h"
0025 #include "Herwig/MatrixElement/ProductionMatrixElement.h"
0026 
0027 namespace Herwig {
0028 using namespace ThePEG;
0029 using ThePEG::Helicity::VectorWaveFunction;
0030 using ThePEG::Helicity::ScalarWaveFunction;
0031 
0032 /**
0033  * This is the implementation of the matrix element for the process
0034  * vector-vector to scalar-scalar. It inherits from GeneralHardME and
0035  * implements the required virtual functions.
0036  *
0037  * @see \ref MEff2ffInterfaces "The Interfaces"
0038  * defined for MEff2ff.
0039  * @see GeneralHardME
0040  */
0041 class MEvv2ss: public GeneralHardME {
0042 
0043 public:
0044 
0045   /** A vector of VectorWaveFunction objects*/
0046   typedef vector<VectorWaveFunction> VBVector;
0047 
0048 public:
0049 
0050   /** @name Virtual functions required by the MEBase class. */
0051   //@{
0052   /**
0053    * The matrix element for the kinematical configuration
0054    * previously provided by the last call to setKinematics(), suitably
0055    * scaled by sHat() to give a dimension-less number.
0056    * @return the matrix element scaled with sHat() to give a
0057    * dimensionless number.
0058    */
0059   virtual double me2() const;
0060   //@}
0061 
0062   /**
0063    * Set the Hardvertex for the spin correlations
0064    * @param sub
0065    */
0066   virtual void constructVertex(tSubProPtr sub);
0067 
0068 private:
0069 
0070   /**
0071    * Calculate the matrix element.
0072    * @param v1 A vector of VectorWaveFunction objects for the first boson
0073    * @param v2 A vector of VectorWaveFunction objects for the second boson
0074    * @param sca1 A ScalarWaveFunction for the first outgoing
0075    * @param sca2 A ScalarWaveFunction for the second outgoing
0076    * @param me2 The value of the spin-summed matrix element squared
0077    * (to be calculated)
0078    * @param first Whether or not first call to decide if colour decomposition etc
0079    * should be calculated
0080    */
0081   ProductionMatrixElement vv2ssME(const VBVector & v1, const VBVector & v2,
0082                   const ScalarWaveFunction & sca1, 
0083                   const ScalarWaveFunction & sca2, 
0084                   double & me2, bool first) const;
0085 protected:
0086   
0087   /**
0088    * A debugging function to test the value of me2 against an
0089    * analytic function.
0090    * @param me2 The value of the \f$ |\bar{\mathcal{M}}|^2 \f$
0091    */
0092   virtual void debug(double me2) const;
0093 
0094 public:
0095 
0096   /** @name Functions used by the persistent I/O system. */
0097   //@{
0098   /**
0099    * Function used to write out object persistently.
0100    * @param os the persistent output stream written to.
0101    */
0102   void persistentOutput(PersistentOStream & os) const;
0103 
0104   /**
0105    * Function used to read in object persistently.
0106    * @param is the persistent input stream read from.
0107    * @param version the version number of the object when written.
0108    */
0109   void persistentInput(PersistentIStream & is, int version);
0110   //@}
0111 
0112   /**
0113    * The standard Init function used to initialize the interfaces.
0114    * Called exactly once for each class by the class description system
0115    * before the main function starts or
0116    * when this class is dynamically loaded.
0117    */
0118   static void Init();
0119 
0120 
0121 protected:
0122 
0123   /** @name Standard Interfaced functions. */
0124   //@{
0125   /**
0126    * Initialize this object after the setup phase before saving an
0127    * EventGenerator to disk.
0128    * @throws InitException if object could not be initialized properly.
0129    */
0130   virtual void doinit();
0131   //@}
0132 
0133 
0134 protected:
0135 
0136   /** @name Clone Methods. */
0137   //@{
0138   /**
0139    * Make a simple clone of this object.
0140    * @return a pointer to the new object.
0141    */
0142   virtual IBPtr clone() const {return new_ptr(*this);}
0143 
0144   /** Make a clone of this object, possibly modifying the cloned object
0145    * to make it sane.
0146    * @return a pointer to the new object.
0147    */
0148   virtual IBPtr fullclone() const {return new_ptr(*this);}
0149   //@}
0150 
0151 private:
0152 
0153   /**
0154    * The assignment operator is private and must never be called.
0155    * In fact, it should not even be implemented.
0156    */
0157   MEvv2ss & operator=(const MEvv2ss &) = delete;
0158 
0159 private:
0160 
0161   /** @name The dynamically casted vertices. */
0162   //@{
0163   /**
0164    * Intermediate s-channel scalar
0165    */
0166   vector<pair<AbstractVVSVertexPtr, AbstractSSSVertexPtr> > scalar1_;
0167 
0168   /**
0169    * Intermediate t-channel scalar
0170    */
0171   vector<pair<AbstractVSSVertexPtr, AbstractVSSVertexPtr> > scalar2_;
0172 
0173   /**
0174    * Intermediate t-channel scalar
0175    */
0176   vector<pair<AbstractVVSVertexPtr, AbstractVVSVertexPtr> > scalar3_;
0177 
0178   /**
0179    * Intermediate s-channel vector
0180    */
0181   vector<pair<AbstractVVVVertexPtr, AbstractVSSVertexPtr> > vector_;
0182 
0183   /**
0184    * Intermediate s-channel tensor
0185    */
0186   vector<pair<AbstractVVTVertexPtr, AbstractSSTVertexPtr> > tensor_;
0187   
0188   /**
0189    * The contact vertex 
0190    */
0191   vector<AbstractVVSSVertexPtr> contact_;
0192   //@}
0193   
0194   
0195 };
0196 
0197 }
0198 
0199 #endif /* HERWIG_MEvv2ss_H */