29 #ifndef __FASTJET_JETDEFINITION_HH__
30 #define __FASTJET_JETDEFINITION_HH__
33 #include "fastjet/internal/numconsts.hh"
34 #include "fastjet/PseudoJet.hh"
38 FASTJET_BEGIN_NAMESPACE
163 class ClusterSequence;
194 *
this =
JetDefinition(jet_algorithm_in, R_in, strategy_in, recomb_scheme_in, 1);
203 *
this =
JetDefinition(jet_algorithm_in, dummyR, strategy_in, recomb_scheme_in, 0);
210 double xtra_param_in,
213 *
this =
JetDefinition(jet_algorithm_in, R_in, strategy_in, recomb_scheme_in, 2);
214 set_extra_param(xtra_param_in);
226 _recombiner = recombiner_in;
236 _recombiner = recombiner_in;
243 double xtra_param_in,
247 _recombiner = recombiner_in;
248 set_extra_param(xtra_param_in);
270 _Rparam = _plugin->R();
285 int nparameters_in = 1);
300 if (_recombiner_shared()) _recombiner_shared.reset(recomb);
301 _recombiner = recomb;
307 void delete_recombiner_when_unused();
314 void delete_plugin_when_unused();
320 double R ()
const {
return _Rparam ;}
323 double extra_param ()
const {
return _extra_param ;}
324 Strategy strategy ()
const {
return _strategy ;}
326 return _default_recombiner.scheme();}
346 return _recombiner == 0 ? & _default_recombiner : _recombiner;}
350 bool has_same_recombiner(
const JetDefinition &other_jd)
const;
353 std::string description()
const;
366 virtual std::string description()
const = 0;
386 recombine(pa,pb,pres);
405 _recomb_scheme(recomb_scheme) {}
407 virtual std::string description()
const;
413 virtual void preprocess(
PseudoJet & p)
const;
435 virtual std::string description()
const = 0;
445 virtual double R()
const = 0;
456 virtual void set_ghost_separation_scale(
double scale)
const;
457 virtual double ghost_separation_scale()
const {
return 0.0;}
473 double _extra_param ;
476 const Plugin * _plugin;
481 DefaultRecombiner _default_recombiner;
482 const Recombiner * _recombiner;
499 PseudoJet join(
const std::vector<PseudoJet> & pieces,
const JetDefinition::Recombiner & recombiner);
502 PseudoJet join(
const PseudoJet & j1,
503 const JetDefinition::Recombiner & recombiner);
506 PseudoJet join(
const PseudoJet & j1,
const PseudoJet & j2,
507 const JetDefinition::Recombiner & recombiner);
510 PseudoJet join(
const PseudoJet & j1,
const PseudoJet & j2,
const PseudoJet & j3,
511 const JetDefinition::Recombiner & recombiner);
514 PseudoJet join(
const PseudoJet & j1,
const PseudoJet & j2,
const PseudoJet & j3,
const PseudoJet & j4,
515 const JetDefinition::Recombiner & recombiner);
521 FASTJET_END_NAMESPACE
523 #endif // __FASTJET_JETDEFINITION_HH__
@ genkt_for_passive_algorithm
a version of genkt with a special distance measure for particles whose pt is < extra_param() [relevan...
const Recombiner * recombiner() const
return a pointer to the currently defined recombiner.
@ BIpt_scheme
pt weighted recombination of y,phi (and summing of pt's), with no preprocessing
@ BIpt2_scheme
pt^2 weighted recombination of y,phi (and summing of pt's) no preprocessing
@ N2Tiled
fastest from about 50..500
@ NlnNCam2pi2R
Chan's closest pair method (in a variant with 2pi+2R coverage), for use exclusively with the Cambridg...
@ Best
automatic selection of the best (based on N)
virtual ~Recombiner()
a destructor to be replaced if necessary in derived classes...
@ Et_scheme
pt weighted recombination of y,phi (and summing of pt's) with preprocessing to make things massless b...
@ N2MinHeapTiled
fastest form about 500..10^4
static const double max_allowable_R
R values larger than max_allowable_R are not allowed.
@ E_scheme
summing the 4-momenta
virtual bool exclusive_sequence_meaningful() const
if this returns false then a warning will be given whenever the user requests "exclusive" jets from t...
void set_recombiner(const Recombiner *recomb)
set the recombiner class to the one provided
JetDefinition(JetAlgorithm jet_algorithm_in, RecombinationScheme recomb_scheme_in=E_scheme, Strategy strategy_in=Best)
constructor for algorithms that have no free parameters (e.g.
JetDefinition(JetAlgorithm jet_algorithm_in, double R_in, double xtra_param_in, RecombinationScheme recomb_scheme_in=E_scheme, Strategy strategy_in=Best)
constructor for algorithms that require R + one extra parameter to be set (the gen-kt series for exam...
virtual ~Plugin()
a destructor to be replaced if necessary in derived classes...
@ cambridge_algorithm
the longitudinally invariant variant of the cambridge algorithm (aka Aachen algoithm).
@ NlnNCam4pi
Chan's closest pair method (in a variant with 4pi coverage), for use exclusively with the Cambridge a...
JetDefinition(JetAlgorithm jet_algorithm_in, double R_in, double xtra_param_in, const Recombiner *recombiner_in, Strategy strategy_in=Best)
constructor allowing the extra parameter to be set and a pointer to a recombiner
JetDefinition(JetAlgorithm jet_algorithm_in, double R_in, RecombinationScheme recomb_scheme_in=E_scheme, Strategy strategy_in=Best)
constructor with alternative ordering or arguments – note that we have not provided a default jet fin...
@ pt2_scheme
pt^2 weighted recombination of y,phi (and summing of pt's) with preprocessing to make things massless...
string fastjet_version_string()
return a string containing information about the release
void plus_equal(PseudoJet &pa, const PseudoJet &pb) const
pa += pb in the given recombination scheme.
JetAlgorithm jet_algorithm() const
return information about the definition...
@ NlnN
best of the NlnN variants – best overall for N>10^4.
JetDefinition(JetAlgorithm jet_algorithm_in, double R_in, const Recombiner *recombiner_in, Strategy strategy_in=Best)
constructor in a form that allows the user to provide a pointer to an external recombiner class (whic...
RecombinationScheme scheme() const
return the index of the recombination scheme
@ genkt_algorithm
like the k_t but with distance measures dij = min(kti^{2p},ktj^{2p}) Delta R_{ij}^2 / R^2 diB = 1/kti...
void set_extra_param(double xtra_param)
(re)set the general purpose extra parameter
@ antikt_algorithm
like the k_t but with distance measures dij = min(1/kti^2,1/ktj^2) Delta R_{ij}^2 / R^2 diB = 1/kti^2
@ ee_genkt_algorithm
the e+e- genkt algorithm (R > 2 and p=1 gives ee_kt)
virtual void preprocess(PseudoJet &) const
routine called to preprocess each input jet (to make all input jets compatible with the scheme requir...
@ NlnN4pi
legacy N ln N using 4pi coverage of cylinder
const JetAlgorithm aachen_algorithm
provide other possible names for the Cambridge/Aachen algorithm
@ NlnN3pi
legacy N ln N using 3pi coverage of cylinder.
@ external_scheme
for the user's external scheme
void set_jet_algorithm(JetAlgorithm njf)
(re)set the jet finder
JetDefinition(JetAlgorithm jet_algorithm_in, const Recombiner *recombiner_in, Strategy strategy_in=Best)
constructor for case with 0 parameters (ee_kt_algorithm) and and external recombiner
Strategy
the various options for the algorithmic strategy to adopt in clustering events with kt and cambridge ...
@ Et2_scheme
pt^2 weighted recombination of y,phi (and summing of pt's) with preprocessing to make things massless...
virtual bool supports_ghosted_passive_areas() const
return true if there is specific support for the measurement of passive areas, in the sense that area...
@ NlnNCam
Chan's closest pair method (in a variant with 2pi+minimal extra variant), for use exclusively with th...
JetDefinition(const Plugin *plugin_in)
constructor based on a pointer to a user's plugin; the object pointed to must remain valid for the wh...
RecombinationScheme
the various recombination schemes
@ undefined_jet_algorithm
the value for the jet algorithm in a JetDefinition for which no algorithm has yet been defined
@ plugin_strategy
the plugin has been used...
JetAlgorithm jet_finder() const
same as above for backward compatibility
@ N2Plain
fastest below 50
@ N3Dumb
worse even than the usual N^3 algorithms
@ plugin_algorithm
any plugin algorithm supplied by the user
const Plugin * plugin() const
return a pointer to the plugin
@ pt_scheme
pt weighted recombination of y,phi (and summing of pt's) with preprocessing to make things massless b...
JetDefinition()
a default constructor which creates a jet definition that is in a well-defined internal state,...
@ ee_kt_algorithm
the e+e- kt algorithm
void set_jet_finder(JetAlgorithm njf)
same as above for backward compatibility
@ cambridge_for_passive_algorithm
a version of cambridge with a special distance measure for particles whose pt is < extra_param()
@ kt_algorithm
the longitudinally invariant kt algorithm