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"
38FASTJET_BEGIN_NAMESPACE
66 _bge(bge), _rho(-1.0) { set_defaults(); }
77 Subtractor() : _bge(0), _rho(_invalid_rho) { set_defaults(); }
108 if (_bge == 0 && _rho_m < 0) {
109 throw Error(
"Subtractor: rho_m support works only for Subtractors constructed with a background estimator or an explicit rho_m value");
111 _use_rho_m=use_rho_m_in;
159 const Selector &sel_leading_vertex){
160 _sel_known_vertex = sel_known_vertex;
161 _sel_leading_vertex = sel_leading_vertex;
177 virtual std::string description()
const;
Abstract base class that provides the basic interface for classes that estimate levels of background ...
base class corresponding to errors that can be thrown by FastJet
class to provide facilities for giving warnings up to some maximum number of times and to provide glo...
Class to contain pseudojets, including minimal information of use to jet-clustering routines.
Class that encodes information about cuts and other selection criteria that can be applied to PseudoJ...
Class that helps perform jet background subtraction.
bool use_rho_m() const
returns whether or not the rho_m component is used
Subtractor(const BackgroundEstimatorBase *bge)
define a subtractor based on a BackgroundEstimator
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
virtual ~Subtractor()
default dtor
Subtractor()
default constructor
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.
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
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...
bool safe_mass() const
returns whether or not safety tests on the mass are included
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...
const BackgroundEstimatorBase * _bge
the tool used to estimate the background if has to be mutable in case its underlying selector takes a...
bool _use_rho_m
include the rho_m correction
Selector _sel_leading_vertex
amongst the particles with a known vertex origin, select those coming from the leading vertex
Selector _sel_known_vertex
selects the particles with a known vertex origin