Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-04-19 09:10:08

0001 #ifndef PHASIC_Channels_Channel_Elements_H
0002 #define PHASIC_Channels_Channel_Elements_H
0003 
0004 #include "ATOOLS/Math/Vector.H"
0005 #include "ATOOLS/Org/Info_Key.H"
0006 
0007 namespace PHASIC {
0008 
0009   double SqLam(double,double,double);
0010   double PeakedDist(double,double,double,double,int,double);
0011   double PeakedWeight(double,double,double,double,double,int,double&);
0012   double ExponentialDist(double ca,double cxm,double cxp,double ran);
0013   double ExponentialWeight(double ca,double cxm,double cxp);
0014   double BoundaryPeakedDist(double cxm,double cxp,double ran);
0015   double BoundaryPeakedWeight(double cxm,double cxp,double res,double &ran);
0016   double Tj1(double,double,double,double);
0017   double Hj1(double,double,double);
0018 
0019   class Channel_Elements {
0020   private:
0021 
0022     void QcdAntenna(ATOOLS::Vec4D* &,int,double, double);
0023     void BasicAntenna(ATOOLS::Vec4D,ATOOLS::Vec4D,ATOOLS::Vec4D &, double*, double);
0024     void PermP(int,int* &);
0025     void Polytope(int,double* &);
0026     void CheckMasses(const double & s1,ATOOLS::Vec4D & p1,
0027              const double & s2,ATOOLS::Vec4D & p2) const;
0028   public:
0029 
0030     double Isotropic2Weight(const ATOOLS::Vec4D&,const ATOOLS::Vec4D&,double&,double&,double=-1.0,double=1.0,
0031                 const ATOOLS::Vec4D &x=ATOOLS::Vec4D(1.,1.,0.,0.));
0032     void Isotropic2Momenta(ATOOLS::Vec4D,double,double,
0033                ATOOLS::Vec4D&,ATOOLS::Vec4D&,double,double,double=-1.0,double=1.0,
0034                const ATOOLS::Vec4D &x=ATOOLS::Vec4D(1.,1.,0.,0.));
0035 
0036     double Anisotropic2Weight(const ATOOLS::Vec4D&,const ATOOLS::Vec4D&,
0037                   double&,double&,double,double=-1.0,double=1.0,
0038                   const ATOOLS::Vec4D &x=ATOOLS::Vec4D(1.,1.,0.,0.));
0039     void Anisotropic2Momenta(ATOOLS::Vec4D,double,double,
0040                  ATOOLS::Vec4D&,ATOOLS::Vec4D&,double,double,
0041                  double,double=-1.0,double=1.0,
0042                  const ATOOLS::Vec4D &x=ATOOLS::Vec4D(1.,1.,0.,0.));
0043 
0044     double TChannelWeight(const ATOOLS::Vec4D&,const ATOOLS::Vec4D&,
0045               const ATOOLS::Vec4D&,const ATOOLS::Vec4D&,
0046               double,double,double,double,double&,double&);
0047     void TChannelMomenta(ATOOLS::Vec4D,ATOOLS::Vec4D,ATOOLS::Vec4D&,ATOOLS::Vec4D&,
0048             double,double,double,double,double,double,double,double);
0049 
0050     double BremsstrahlungWeight(double,double,double,
0051                 const ATOOLS::Vec4D&,const ATOOLS::Vec4D&);
0052     void BremsstrahlungMomenta(ATOOLS::Vec4D&,const double,const double,const double,
0053                    const double,const double,const double,
0054                    ATOOLS::Vec4D &, ATOOLS::Vec4D &,const double,const double);
0055 
0056     double MasslessPropMomenta(double,double,double,double);
0057     double MasslessPropWeight(double,double,double,double,double&);
0058     double MasslessPropMomenta(double,double,double,double,double);
0059     double MasslessPropWeight(double,double,double,double,double,double&);
0060 
0061     double ExponentialMomenta(double,double,double,double[],double);
0062     double ExponentialWeight(double,double,double,double[],double,double&);
0063 
0064     double AntennaWeight(double amin,double amax,const double a,double &ran);
0065     double AntennaMomenta(double amin,double amax,double ran);
0066 
0067     double MassivePropWeight(double,double,double,double,double,double&);
0068     double MassivePropMomenta(double,double,double,double,double);
0069 
0070     double QCDAPWeight(ATOOLS::Vec4D*,int,double);
0071     void QCDAPMomenta(ATOOLS::Vec4D*,ATOOLS::Vec4D,int,double);
0072 
0073     double LLPropWeight(double,double,double,double,double,double&);
0074     double LLPropMomenta(double,double,double,double,double);
0075 
0076     double ThresholdMomenta(double,double,double,double,double);
0077     double ThresholdWeight(double,double,double,double,double,double&);
0078 
0079     double GenerateDMRapidityUniform(const double masses[], const ATOOLS::Double_Container &spinfo,
0080       ATOOLS::Double_Container &xinfo, const double cosxi, const double ran, const int mode);
0081     double GenerateDMAngleUniform(const double ran, const int mode) const;
0082     double GenerateYUniform(const double tau,const ATOOLS::Double_Container &xinfo,
0083             const ATOOLS::Double_Container &yinfo,const double ran,const int mode) const;
0084     double WeightYUniform(const double tau,const ATOOLS::Double_Container &xinfo,
0085               const ATOOLS::Double_Container &yinfo,double&,const int mode) const;
0086     double GenerateYCentral(const double tau,const ATOOLS::Double_Container &xinfo,
0087             const ATOOLS::Double_Container &yinfo,const double ran,const int mode) const;
0088     double WeightYCentral(const double tau,const ATOOLS::Double_Container &xinfo,
0089               const ATOOLS::Double_Container &yinfo,double&,const int mode) const;
0090     double GenerateYForward(const double yexponent,const double tau,
0091             const ATOOLS::Double_Container &xinfo,
0092             const ATOOLS::Double_Container &yinfo,const double ran,const int mode) const;
0093     double WeightYForward(const double yexponent,const double tau,
0094               const ATOOLS::Double_Container &xinfo,
0095               const ATOOLS::Double_Container &yinfo,double&,const int mode) const;
0096     double GenerateYBackward(const double yexponent,const double tau,
0097              const ATOOLS::Double_Container &xinfo,
0098              const ATOOLS::Double_Container &yinfo,const double ran,const int mode) const;
0099     double WeightYBackward(const double yexponent,const double tau,
0100                const ATOOLS::Double_Container &xinfo,
0101                const ATOOLS::Double_Container &yinfo,double&,const int mode) const;
0102 
0103   };// end of class Channel_Elements
0104 
0105   extern Channel_Elements CE;
0106 
0107   /*!
0108     Weights and momenta for isotropic two-body decays.
0109     The idea for the gbeneration of the momenta is to boost the
0110     decaying vector into its rest frame, select the orientation of
0111     the two decay products with given masses 4-pi isotropically and
0112     to boost back. The weight is just a constant.
0113   */
0114 
0115   /*!
0116     Weights and momenta for anisotropic two-body decays as they occur
0117     in splittings involving one outgoing massless vector boson.
0118     The idea here is to use a peaked distribution for the polar angle
0119     of one decay product (not the "vector boson") along the original direction
0120     of the decaying particle.
0121   */
0122 
0123   /*!
0124     Weights and momenta for a Tchannel process. Again, there is a strong peak in
0125     the forward direction in order to minimize the mass of the propagator.
0126   */
0127 
0128   /*!
0129      Decay p -> q + p1, q is space-like with energy Eq given from outside
0130      cos(pq) is constrained by ctmin and ctmax.
0131   */
0132 
0133   /*!
0134     Scale and weight for a massless propagator. It is distributed
0135     according to a simple pole structure peaking at 0 (or the minimal
0136     scale that is kinematically allowed).
0137   */
0138 
0139   /*!
0140     Scale and weight for a massive propagator. It is distributed
0141     according to a physical Breit-Wigner distribution with given
0142     mass and width.
0143   */
0144 
0145   /*!
0146     Scale and weight for a typical electron initial state radiation
0147     event. It is distributed according to a simple pole structure peaking
0148     at the maximal scale that is kinematically allowed.
0149   */
0150 
0151 }// end of namespace PHASIC
0152 
0153 #endif