stablejet is hosted by Hepforge, IPPP Durham
StableJet
DiffusionDistFastJet.h
1 #ifndef DiffusionDistFastJet_h
2 #define DiffusionDistFastJet_h
3 
8 
9 #include <string>
10 #include <sstream>
11 
12 #include "diffusionFactor2.h"
13 
14 #include "fastjet/JetDefinition.hh"
15 #include "fastjet/PseudoJet.hh"
16 #include "fastjet/ClusterSequence.hh"
17 
18 using namespace fastjet;
19 
20 namespace stab {
21 
22 
23 class DiffusionDistFastJet: public JetDefinition::Plugin {
24 
25 public:
26  inline DiffusionDistFastJet(const double R): JetDefinition::Plugin()
27  ,m_R(R)
28  { }
29 
30  inline virtual ~DiffusionDistFastJet() { }
31 
32  // returns a textual description of the jet algorithm
33  inline virtual std::string description() const {
34 
35  std::stringstream desc;
36  desc << "Diffusion Distance (Fast Jet Plugin) Description:\n";
37  desc << "The diffusion distance is defined as the minimum width Gaussian filter\n";
38  desc << "for which only one energy deposit is observed from the original two.\n";
39  desc << "It is analogous to the sqrt(t) at which two drops of honey\n";
40  desc << "diffuse into a one.";
41 
42  return desc.str();
43  }
44 
45  inline virtual double R() const { return m_R; }
46 
47  // run the clustering
48  virtual void run_clustering(ClusterSequence &) const;
49 
50 
51 private:
52 
53  // how the DiffusionDist class calculates the distance
54  //inline double operator()(const jet &a, const jet &b ) const
55  //{
56  // double pT1 = a.pt();
57  // double pT2 = b.pt();
58  // double ratio = (pT1 < pT2 ? pT1 : pT2 )/(pT1 < pT2 ? pT2 : pT1 );
59  // return geom3::deltaR(a, b) * diffusionFactor2(ratio);
60  //}
61 
62  double m_R;
63 
64 };
65 
66 
67 
68 } // end stab namespace
69 
70 
71 #endif