31 #ifndef __FASTJET_TOOLS_SUBTRACTOR_HH__
32 #define __FASTJET_TOOLS_SUBTRACTOR_HH__
34 #include "fastjet/internal/base.hh"
35 #include "fastjet/tools/Transformer.hh"
36 #include "fastjet/tools/BackgroundEstimatorBase.hh"
38 FASTJET_BEGIN_NAMESPACE
66 _bge(bge), _rho(-1.0) { set_defaults(); }
77 Subtractor() : _bge(0), _rho(_invalid_rho) { set_defaults(); }
103 if (_bge == 0 && _rho_m < 0) {
104 throw Error(
"Subtractor: rho_m support works only for Subtractors constructed with a background estimator or an explicit rho_m value");
106 _use_rho_m=use_rho_m_in;
154 const Selector &sel_leading_vertex){
155 _sel_known_vertex = sel_known_vertex;
156 _sel_leading_vertex = sel_leading_vertex;
172 virtual std::string description()
const;
208 FASTJET_END_NAMESPACE
210 #endif // __FASTJET_TOOLS_SUBTRACTOR_HH__
bool _use_rho_m
include the rho_m correction
void set_use_rho_m(bool use_rho_m_in=true)
when 'use_rho_m' is true, include in the subtraction the correction from rho_m, the purely longitudin...
void set_known_selectors(const Selector &sel_known_vertex, const Selector &sel_leading_vertex)
This is mostly intended for cherge-hadron-subtracted type of events where we wich to use vertex infor...
virtual ~Subtractor()
default dtor
Subtractor()
default constructor
void set_safe_mass(bool safe_mass_in=true)
when 'safe_mass' is true, ensure that the mass of the subtracted 4-vector remain positive
bool safe_mass() const
returns whether or not safety tests on the mass are included
Selector _sel_leading_vertex
amongst the particles with a known vertex origin, select those coming from the leading vertex
BackgroundEstimatorBase * _bge
the tool used to estimate the background if has to be mutable in case its underlying selector takes a...
Selector _sel_known_vertex
selects the particles with a known vertex origin
bool use_rho_m() const
returns whether or not the rho_m component is used
static const double _invalid_rho
a value of rho that is used as a default to label that the stored rho is not valid for subtraction.
Subtractor(BackgroundEstimatorBase *bge)
define a subtractor based on a BackgroundEstimator
double _rho
the fixed value of rho and/or rho_m to use if the user has selected that option
bool _safe_mass
ensures that the subtracted mass is +ve