herwig is hosted by Hepforge, IPPP Durham
Herwig  7.1.5
SudakovFormFactor.h
1 // -*- C++ -*-
2 //
3 // SudakovFormFactor.h is a part of Herwig - A multi-purpose Monte Carlo event generator
4 // Copyright (C) 2002-2017 The Herwig Collaboration
5 //
6 // Herwig is licenced under version 3 of the GPL, see COPYING for details.
7 // Please respect the MCnet academic guidelines, see GUIDELINES for details.
8 //
9 #ifndef HERWIG_SudakovFormFactor_H
10 #define HERWIG_SudakovFormFactor_H
11 //
12 // This is the declaration of the SudakovFormFactor class.
13 //
14 
15 #include "ThePEG/Interface/Interfaced.h"
16 #include "Herwig/Shower/Core/SplittingFunctions/SplittingFunction.h"
17 #include "Herwig/Shower/Core/Couplings/ShowerAlpha.h"
18 #include "Herwig/Shower/Core/SplittingFunctions/SplittingGenerator.fh"
19 #include "ThePEG/Repository/UseRandom.h"
20 #include "ThePEG/PDF/BeamParticleData.h"
21 #include "ThePEG/EventRecord/RhoDMatrix.h"
22 #include "ThePEG/EventRecord/SpinInfo.h"
23 #include "ShowerKinematics.fh"
24 #include "SudakovFormFactor.fh"
25 
26 namespace Herwig {
27 
28 using namespace ThePEG;
29 
33 typedef Ptr<BeamParticleData>::transient_const_pointer tcBeamPtr;
34 
127 
132  friend class SplittingGenerator;
133 
134 public:
135 
139  SudakovFormFactor() : pdfmax_(35.0), pdffactor_(0),
140  cutOffOption_(0), a_(0.3), b_(2.3), c_(0.3*GeV),
141  kinCutoffScale_( 2.3*GeV ), vgcut_(0.85*GeV),
142  vqcut_(0.85*GeV), pTmin_(1.*GeV), pT2min_(ZERO),
143  z_( 0.0 ),phi_(0.0), pT_(){}
144 
157  virtual ShoKinPtr generateNextTimeBranching(const Energy startingScale,
158  const IdList &ids,
159  const RhoDMatrix & rho,
160  double enhance, double detuning,
161  Energy2 maxQ2)=0;
162 
173  virtual ShoKinPtr generateNextDecayBranching(const Energy startingScale,
174  const Energy stoppingScale,
175  const Energy minmass,
176  const IdList &ids,
177  const RhoDMatrix & rho,
178  double enhance,
179  double detuning)=0;
180 
191  virtual ShoKinPtr generateNextSpaceBranching(const Energy startingScale,
192  const IdList &ids,double x,
193  const RhoDMatrix & rho,
194  double enhance,
195  tcBeamPtr beam,
196  double detuning)=0;
198 
205  virtual double generatePhiForward(ShowerParticle & particle,const IdList & ids,
206  ShoKinPtr kinematics,
207  const RhoDMatrix & rho)=0;
208 
215  virtual double generatePhiBackward(ShowerParticle & particle,const IdList & ids,
216  ShoKinPtr kinematics,
217  const RhoDMatrix & rho)=0;
218 
225  virtual double generatePhiDecay(ShowerParticle & particle,const IdList & ids,
226  ShoKinPtr kinematics,
227  const RhoDMatrix & rho)=0;
228 
236  tSplittingFnPtr splittingFn() const { return splittingFn_; }
237 
241  tShowerAlphaPtr alpha() const { return alpha_; }
242 
247  {return splittingFn_->interactionType();}
249 
250 public:
251 
259  double z() const { return z_; }
260 
264  double phi() const { return phi_; }
265 
269  Energy pT() const { return pT_; }
271 
275  double pdfMax() const { return pdfmax_;}
276 
281  virtual Energy calculateScale(double z, Energy pt, IdList ids,unsigned int iopt)=0;
282 
286  virtual ShoKinPtr createFinalStateBranching(Energy scale,double z,
287  double phi, Energy pt)=0;
288 
292  virtual ShoKinPtr createInitialStateBranching(Energy scale,double z,
293  double phi, Energy pt)=0;
294 
298  virtual ShoKinPtr createDecayBranching(Energy scale,double z,
299  double phi, Energy pt)=0;
300 
301 public:
302 
309  void persistentOutput(PersistentOStream & os) const;
310 
316  void persistentInput(PersistentIStream & is, int version);
318 
325  static void Init();
326 
327 protected:
328 
336  virtual void doinit();
338 
339 protected:
340 
354  double guessz (unsigned int iopt, const IdList &ids) const;
355 
367  Energy2 guesst (Energy2 t1,unsigned int iopt, const IdList &ids,
368  double enhance, bool identical, double detune) const;
369 
380  bool PDFVeto(const Energy2 t, const double x,
381  const tcPDPtr parton0, const tcPDPtr parton1,
382  tcBeamPtr beam) const;
386  double PDFVetoRatio(const Energy2 t, const double x,
387  const tcPDPtr parton0, const tcPDPtr parton1,
388  tcBeamPtr beam,double factor) const;
389 
397  bool SplittingFnVeto(const Energy2 t,
398  const IdList &ids,
399  const bool mass,
400  const RhoDMatrix & rho,
401  double detune) const {
402  return UseRandom::rnd()>SplittingFnVetoRatio(t,ids,mass,rho,detune);
403  }
404 
409  double SplittingFnVetoRatio(const Energy2 t,
410  const IdList &ids,
411  const bool mass,
412  const RhoDMatrix & rho,
413  double detune) const {
414  return splittingFn_->ratioP(z_, t, ids,mass,rho)/detune;
415  }
416 
422  bool alphaSVeto(Energy2 pt2) const;
423 
428  double alphaSVetoRatio(Energy2 pt2,double factor) const;
429 
430 
432 
440  void z(double in) { z_=in; }
441 
445  void phi(double in) { phi_=in; }
446 
450  void pT(Energy in) { pT_=in; }
452 
460  pair<double,double> zLimits() const { return zlimits_;}
461 
465  void zLimits(pair<double,double> in) { zlimits_=in; }
467 
471  void addSplitting(const IdList &);
472 
476  void removeSplitting(const IdList &);
477 
481  const vector<IdList> & particles() const { return particles_; }
482 
483 public:
484 
492  unsigned int cutOffOption() const { return cutOffOption_; }
493 
497  Energy kinScale() const {return kinCutoffScale_;}
498 
504  Energy kinematicCutOff(Energy scale, Energy mq) const
505  {return max((scale -a_*mq)/b_,c_);}
506 
510  Energy vgCut() const { return vgcut_; }
511 
515  Energy vqCut() const { return vqcut_; }
516 
520  Energy pTmin() const { return pTmin_; }
521 
525  Energy2 pT2min() const { return pT2min_; }
526 
530  const vector<Energy> & virtualMasses(const IdList & ids);
532 
536  void setPDF(tcPDFPtr pdf, Energy scale) {
537  pdf_ = pdf;
538  freeze_ = scale;
539  }
540 
541 private:
542 
547  SudakovFormFactor & operator=(const SudakovFormFactor &) = delete;
548 
549 private:
550 
554  SplittingFnPtr splittingFn_;
555 
559  ShowerAlphaPtr alpha_;
560 
564  double pdfmax_;
565 
570  vector<IdList> particles_;
571 
575  unsigned pdffactor_;
576 
577 private:
578 
582  unsigned int cutOffOption_;
583 
592  double a_;
593 
597  double b_;
598 
602  Energy c_;
603 
609 
617  Energy vgcut_;
618 
622  Energy vqcut_;
624 
632  Energy pTmin_;
633 
637  Energy2 pT2min_;
639 
640 private:
641 
650  double z_;
651 
655  double phi_;
656 
660  Energy pT_;
662 
666  pair<double,double> zlimits_;
667 
676 
680  Energy freeze_;
682 
683 
684 };
685 
686 }
687 
688 #endif /* HERWIG_SudakovFormFactor_H */
Ptr< BeamParticleData >::transient_const_pointer tcBeamPtr
A typedef for the BeamParticleData.
Definition: HwMEBase.h:22
Energy freeze_
Freezing scale.
void zLimits(pair< double, double > in)
Set the limits.
double a_
Parameters for the default Herwig cut-off option, i.e.
vector< IdList > particles_
List of the particles this Sudakov is used for to aid in setting up interpolation tables if needed...
This is the definition of the Sudakov form factor class.
ShowerInteraction
Handy header file to be included in all Shower classes.
double z_
Member variables to keep the shower kinematics information generated by a call to generateNextTimeBra...
double b_
The parameter.
Energy kinCutoffScale_
Kinematic cutoff used in the parton shower phase space.
ShowerAlphaPtr alpha_
Pointer to the coupling for this Sudakov form factor.
pair< double, double > zlimits_
The limits of in the splitting.
ThePEG::Ptr< PDFBase >::transient_const_pointer tcPDFPtr
const vector< IdList > & particles() const
Access the potential branchings.
Energy pT() const
The transverse momentum.
SudakovFormFactor()
The default constructor.
static double rnd()
pair< double, double > zLimits() const
Set/Get the limits on the energy fraction for the splitting.
Energy vgcut_
Parameters for the FORTRAN-like cut-off.
Energy vqCut() const
The virtuality cut-off for everything else.
vector< tcPDPtr > IdList
Definition of the IdList for branchings.
Definition: ShowerConfig.h:64
void z(double in)
Methods to set the kinematic variables for the branching.
bool SplittingFnVeto(const Energy2 t, const IdList &ids, const bool mass, const RhoDMatrix &rho, double detune) const
The veto on the splitting function.
unsigned int cutOffOption_
Option for the type of cut-off to be applied.
tSplittingFnPtr splittingFn() const
Methods to provide public access to the private member variables.
Energy kinScale() const
The kinematic scale.
ShowerInteraction interactionType() const
The type of interaction.
void pT(Energy in)
The transverse momentum.
Energy kinematicCutOff(Energy scale, Energy mq) const
The virtuality cut-off on the gluon .
SplittingFnPtr splittingFn_
Pointer to the splitting function for this Sudakov form factor.
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr
Energy2 pT2min_
The square of the minimum .
void setPDF(tcPDFPtr pdf, Energy scale)
Set the PDF.
double phi_
The azimuthal angle.
Energy pTmin() const
The minimum for the branching.
Energy2 pT2min() const
The square of the minimum .
This class represents a particle in the showering process.
Energy pT_
The transverse momentum.
tShowerAlphaPtr alpha() const
Return the pointer to the ShowerAlpha object.
Energy pTmin_
Parameters for the cut-off.
unsigned pdffactor_
Option for the inclusion of a factor in the PDF estimate.
Energy vqcut_
The virtuality cut-off for everything else.
-*- C++ -*-
double pdfMax() const
Access the maximum weight for the PDF veto.
double SplittingFnVetoRatio(const Energy2 t, const IdList &ids, const bool mass, const RhoDMatrix &rho, double detune) const
The Splitting function veto ratio.
double z() const
Methods to access the kinematic variables for the branching.
double phi() const
The azimuthal angle.
Energy vgCut() const
The virtualilty cut-off for gluons.
Energy c_
The parameter.
This class is responsible for creating, at the beginning of the Run, all the SplittingFunction object...
void phi(double in)
The azimuthal angle.
unsigned int cutOffOption() const
The option being used.
tcPDFPtr pdf_
Stuff for the PDFs.
constexpr ZeroUnit ZERO
double pdfmax_
Maximum value of the PDF weight.