ThePEG  1.8.0
MadGraphOneCut.h
1 // -*- C++ -*-
2 //
3 // MadGraphOneCut.h is a part of ThePEG - Toolkit for HEP Event Generation
4 // Copyright (C) 1999-2011 Leif Lonnblad
5 //
6 // ThePEG is licenced under version 2 of the GPL, see COPYING for details.
7 // Please respect the MCnet academic guidelines, see GUIDELINES for details.
8 //
9 #ifndef THEPEG_MadGraphOneCut_H
10 #define THEPEG_MadGraphOneCut_H
11 //
12 // This is the declaration of the MadGraphOneCut class.
13 //
14 
15 #include "ThePEG/Cuts/OneCutBase.h"
16 
17 namespace ThePEG {
18 
28 class MadGraphOneCut: public OneCutBase {
29 
30 public:
31 
35  enum CutType {
36  PT,
37  ETA,
38  XPT
40  };
41 
45  enum PType {
46  JET,
47  LEP,
48  PHO,
49  BOT
50  };
51 
52 public:
53 
60 
67  MadGraphOneCut(CutType t, PType p, double c)
68  : cutType(t), particleType(p), theCut(c) {}
70 
71 public:
72 
79  virtual Energy minKT(tcPDPtr p) const;
80 
86  virtual double minEta(tcPDPtr p) const;
87 
93  virtual double maxEta(tcPDPtr p) const;
94 
100  virtual Energy minMaxKT(tcPDPtr p) const;
101 
107  virtual bool passCuts(tcCutsPtr parent,
108  tcPDPtr ptype, LorentzMomentum p) const;
110 
111 protected:
112 
116  bool checkType(tcPDPtr p) const;
117 
118 public:
119 
126  void persistentOutput(PersistentOStream & os) const;
127 
133  void persistentInput(PersistentIStream & is, int version);
135 
142  static void Init();
143 
144 protected:
145 
152  virtual IBPtr clone() const;
153 
158  virtual IBPtr fullclone() const;
160 
161 private:
162 
167 
172 
176  double theCut;
177 
178 private:
179 
185 
191 
192 };
193 
194 }
195 
196 #include "ThePEG/Utilities/ClassTraits.h"
197 
198 namespace ThePEG {
199 
204 template <>
205 struct BaseClassTrait<MadGraphOneCut,1> {
207  typedef OneCutBase NthBase;
208 };
209 
212 template <>
214  : public ClassTraitsBase<MadGraphOneCut> {
216  static string className() { return "ThePEG::MadGraphOneCut"; }
220  static string library() { return "MadGraphReader.so"; }
221 };
222 
225 }
226 
227 #endif /* THEPEG_MadGraphOneCut_H */
PersistentIStream is used to read persistent objects from a stream where they were previously written...
Objects of the MadGraphOneCut class can be created automatically by the MadGraphReader class when sca...
The cut applies only to photons.
A concreate implementation of ClassDescriptionBase describing a concrete class with persistent data...
virtual IBPtr clone() const
Make a simple clone of this object.
The minimum transverse momentum of the particle with largest transverse momentum. ...
PersistentOStream is used to write objects persistently to a stream from which they can be read in ag...
The cut applies only to leptons.
TransientConstRCPtr is a simple wrapper around a bare const pointer which can be assigned to and from...
Definition: RCPtr.h:681
The cut applies only to bottom quarks.
This is the main namespace within which all identifiers in ThePEG are declared.
Definition: FactoryBase.h:28
The maximum (absolute value of) pseudo-rapidity of a particle.
CutType cutType
The type of this cut.
static void Init()
The standard Init function used to initialize the interfaces.
virtual double minEta(tcPDPtr p) const
Return the minimum allowed pseudo-rapidity of an outgoing parton of the given type.
QTY< 0, 1, 0 >::Type Energy
Energy.
Definition: Unitsystem.h:34
virtual Energy minMaxKT(tcPDPtr p) const
Return the minimum allowed value of the transverse momentum of the outgoing parton with the lagrest t...
PType particleType
The type of particles this cut applies to.
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
PType
Enumerate the types of particles the cut is made on.
MadGraphOneCut(CutType t, PType p, double c)
The constructor used by the MadGraphReader.
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
CutType
Enumerate the different kinds of cuts made by MadGraph.
virtual bool passCuts(tcCutsPtr parent, tcPDPtr ptype, LorentzMomentum p) const
Return true if a particle with type ptype and momentum p passes the cuts.
RCPtr is a reference counted (smart) pointer.
Definition: RCPtr.h:60
The cut applies only to coloured particles.
bool checkType(tcPDPtr p) const
Returns true if cut should be applied to a particle of type p.
The minimum transverse momentum of a particle.
static ClassDescription< MadGraphOneCut > initMadGraphOneCut
The static object used to initialize the description of this class.
double theCut
The value of the cut to be applied.
virtual double maxEta(tcPDPtr p) const
Return the maximum allowed pseudo-rapidity of an outgoing parton of the given type.
The default concrete implementation of ClassTraitsBase.
Definition: ClassTraits.h:134
MadGraphOneCut & operator=(const MadGraphOneCut &)
The assignment operator is private and must never be called.
BaseClassTraits describes the base classes of the templated class.
Definition: ClassTraits.h:156
virtual Energy minKT(tcPDPtr p) const
Return the minimum allowed value of the transverse momentum of an outgoing parton.
This class corresponds to a kinematical cut to be made on a single outgoing parton from a hard sub-pr...
Definition: OneCutBase.h:39
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
The templated ClassTraitsBase class defines a set of default information about classes used by ThePEG...
Definition: ClassTraits.h:52
MadGraphOneCut()
The default constructor.