rivet is hosted by Hepforge, IPPP Durham
Rivet  2.7.0
DISLepton.hh
1 // -*- C++ -*-
2 #ifndef RIVET_DISLepton_HH
3 #define RIVET_DISLepton_HH
4 
5 #include "Rivet/Projections/Beam.hh"
6 #include "Rivet/Projections/PromptFinalState.hh"
7 #include "Rivet/Particle.hh"
8 #include "Rivet/Event.hh"
9 
10 namespace Rivet {
11 
12 
14  class DISLepton : public Projection {
15  public:
16 
18 
19 
20  DISLepton(){
21  setName("DISLepton");
22  addProjection(Beam(), "Beam");
24  }
25 
28 
30 
31 
32  protected:
33 
35  virtual void project(const Event& e);
36 
38  virtual int compare(const Projection& p) const;
39 
40 
41  public:
42 
44  const Particle& in() const { return _incoming; }
45 
47  const Particle& out() const { return _outgoing; }
48 
50  int pzSign() const { return sign(_incoming.pz()); }
51 
52 
53  private:
54 
56  Particle _incoming;
57 
59  Particle _outgoing;
60 
61  // /// The charge sign of the DIS current
62  // double _charge;
63 
64  };
65 
66 }
67 
68 
69 #endif
void setName(const std::string &name)
Used by derived classes to set their name.
Definition: Projection.hh:133
Definition: ALICE_2010_I880049.cc:13
DEFAULT_RIVET_PROJ_CLONE(DISLepton)
Clone on the heap.
virtual int compare(const Projection &p) const
Compare with other projections.
Definition: DISLepton.cc:7
int pzSign() const
Sign of the incoming lepton pz component.
Definition: DISLepton.hh:50
Particle representation, either from a HepMC::GenEvent or reconstructed.
Definition: Particle.hh:18
Definition: Event.hh:22
virtual void project(const Event &e)
Perform the projection operation on the supplied event.
Definition: DISLepton.cc:13
const Particle & out() const
The outgoing lepton.
Definition: DISLepton.hh:47
const PROJ & addProjection(const PROJ &proj, const std::string &name)
Register a contained projection (user-facing version)
Definition: ProjectionApplier.hh:170
const Particle & in() const
The incoming lepton.
Definition: DISLepton.hh:44
Project out the incoming beams.
Definition: Beam.hh:129
Get the incoming and outgoing leptons in a DIS event.
Definition: DISLepton.hh:14
Base class for all Rivet projections.
Definition: Projection.hh:29
Find final state particles directly connected to the hard process.
Definition: PromptFinalState.hh:22
std::enable_if< std::is_arithmetic< NUM >::value, int >::type sign(NUM val)
Find the sign of a number.
Definition: MathUtils.hh:236