ClusterSequenceActiveAreaExplicitGhosts Class Reference

Class that behaves essentially like ClusterSequence except that it also provides access to the area of a jet (which will be a random quantity. More...

#include <ClusterSequenceActiveAreaExplicitGhosts.hh>

Inheritance diagram for ClusterSequenceActiveAreaExplicitGhosts:
Inheritance graph
[legend]
Collaboration diagram for ClusterSequenceActiveAreaExplicitGhosts:
Collaboration graph
[legend]

List of all members.

Public Member Functions

template<class L >
 ClusterSequenceActiveAreaExplicitGhosts (const std::vector< L > &pseudojets, const JetDefinition &jet_def, const GhostedAreaSpec &ghost_spec, const bool &writeout_combinations=false)
 constructor using a GhostedAreaSpec to specify how the area is to be measured
template<class L >
 ClusterSequenceActiveAreaExplicitGhosts (const std::vector< L > &pseudojets, const JetDefinition &jet_def, const std::vector< L > &ghosts, double ghost_area, const bool &writeout_combinations=false)
template<class L >
void _initialise (const std::vector< L > &pseudojets, const JetDefinition &jet_def, const GhostedAreaSpec *ghost_spec, const std::vector< L > *ghosts, double ghost_area, const bool &writeout_combinations)
 does the actual work of initialisation
unsigned int n_hard_particles () const
 returns the number of hard particles (i.e. those supplied by the user).
virtual double area (const PseudoJet &jet) const
 returns the area of a jet
virtual PseudoJet area_4vector (const PseudoJet &jet) const
 returns a four vector corresponding to the sum (E-scheme) of the ghost four-vectors composing the jet area, normalised such that for a small contiguous area the p_t of the extended_area jet is equal to area of the jet.
virtual bool is_pure_ghost (const PseudoJet &jet) const
 true if a jet is made exclusively of ghosts
bool is_pure_ghost (int history_index) const
 true if the entry in the history index corresponds to a ghost; if hist_ix does not correspond to an actual particle (i.e.
virtual bool has_explicit_ghosts () const
 this class does have explicit ghosts
virtual double empty_area (const RangeDefinition &range) const
 return the total area, up to |y|<maxrap, that consists of unclustered ghosts
double total_area () const
 returns the total area under study
double max_ghost_perp2 () const
 returns the largest squared transverse momentum among all ghosts
bool has_dangerous_particles () const
 returns true if there are any particles whose transverse momentum if so low that there's a risk of the ghosts having modified the clustering sequence

Private Member Functions

void _add_ghosts (const GhostedAreaSpec &ghost_spec)
 adds the "ghost" momenta, which will be used to estimate the jet area
template<class L >
void _add_ghosts (const std::vector< L > &ghosts, double ghost_area)
 another way of adding ghosts
void _post_process ()
 routine to be called after the processing is done so as to establish summary information on all the jets (areas, whether pure ghost, etc.

Private Attributes

int _n_ghosts
 get the area of the ghosts
double _ghost_area
std::vector< bool > _is_pure_ghost
std::vector< double > _areas
std::vector< PseudoJet_area_4vectors
double _max_ghost_perp2
bool _has_dangerous_particles
unsigned int _initial_hard_n

Static Private Attributes

static LimitedWarning _warnings
 handle warning messages

Detailed Description

Class that behaves essentially like ClusterSequence except that it also provides access to the area of a jet (which will be a random quantity.

.. Figure out what to do about seeds later...)

Definition at line 49 of file ClusterSequenceActiveAreaExplicitGhosts.hh.


Constructor & Destructor Documentation

template<class L >
ClusterSequenceActiveAreaExplicitGhosts::ClusterSequenceActiveAreaExplicitGhosts ( const std::vector< L > &  pseudojets,
const JetDefinition jet_def,
const GhostedAreaSpec ghost_spec,
const bool &  writeout_combinations = false 
) [inline]

constructor using a GhostedAreaSpec to specify how the area is to be measured

Definition at line 55 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _initialise().

00059            : ClusterSequenceAreaBase() {
00060            std::vector<L> * ghosts = NULL;
00061            _initialise(pseudojets,jet_def,&ghost_spec,ghosts,0.0,
00062                        writeout_combinations); }

template<class L >
ClusterSequenceActiveAreaExplicitGhosts::ClusterSequenceActiveAreaExplicitGhosts ( const std::vector< L > &  pseudojets,
const JetDefinition jet_def,
const std::vector< L > &  ghosts,
double  ghost_area,
const bool &  writeout_combinations = false 
) [inline]

Definition at line 65 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _initialise().

00070            : ClusterSequenceAreaBase() {
00071            const GhostedAreaSpec * ghost_spec = NULL;
00072            _initialise(pseudojets,jet_def,ghost_spec,&ghosts,ghost_area,
00073                        writeout_combinations); }


Member Function Documentation

template<class L >
void ClusterSequenceActiveAreaExplicitGhosts::_add_ghosts ( const std::vector< L > &  ghosts,
double  ghost_area 
) [inline, private]

another way of adding ghosts

add an explicitly specified bunch of ghosts

Definition at line 222 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _ghost_area, _is_pure_ghost, ClusterSequence::_jets, and _n_ghosts.

00224                                              {
00225 
00226   
00227   for (unsigned i = 0; i < ghosts.size(); i++) {
00228     _is_pure_ghost.push_back(true);
00229     _jets.push_back(ghosts[i]);
00230   }
00231   // and record some info about ghosts
00232   _ghost_area = ghost_area;
00233   _n_ghosts   = ghosts.size();
00234 }

void ClusterSequenceActiveAreaExplicitGhosts::_add_ghosts ( const GhostedAreaSpec ghost_spec  )  [private]

adds the "ghost" momenta, which will be used to estimate the jet area

template<class L >
void ClusterSequenceActiveAreaExplicitGhosts::_initialise ( const std::vector< L > &  pseudojets,
const JetDefinition jet_def,
const GhostedAreaSpec ghost_spec,
const std::vector< L > *  ghosts,
double  ghost_area,
const bool &  writeout_combinations 
) [inline]

does the actual work of initialisation

Definition at line 169 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by ClusterSequenceActiveAreaExplicitGhosts().

00174                                               {
00175   // don't reserve space yet -- will be done below
00176 
00177   // insert initial jets this way so that any type L that can be
00178   // converted to a pseudojet will work fine (basically PseudoJet
00179   // and any type that has [] subscript access to the momentum
00180   // components, such as CLHEP HepLorentzVector).
00181   for (unsigned int i = 0; i < pseudojets.size(); i++) {
00182     PseudoJet mom(pseudojets[i]);
00183     //mom.set_user_index(0); // for user's particles (user index now lost...)
00184     _jets.push_back(mom);
00185     _is_pure_ghost.push_back(false);
00186   }
00187 
00188   _initial_hard_n = _jets.size();
00189 
00190   if (ghost_spec != NULL) {
00191     _add_ghosts(*ghost_spec);
00192   } else {
00193     _add_ghosts(*ghosts, ghost_area);
00194   }
00195 
00196   if (writeout_combinations) {
00197     std::cout << "# Printing particles including ghosts\n";
00198     for (unsigned j = 0; j < _jets.size(); j++) {
00199       printf("%5u %20.13f %20.13f %20.13e\n",
00200                j,_jets[j].rap(),_jets[j].phi_02pi(),_jets[j].kt2());
00201     }
00202     std::cout << "# Finished printing particles including ghosts\n";
00203   }
00204 
00205   // this will ensure that we can still point to jets without
00206   // difficulties arising!
00207   _jets.reserve(_jets.size()*2);
00208 
00209   // run the clustering
00210   _initialise_and_run(jet_def,writeout_combinations);
00211 
00212   // set up all other information
00213   _post_process();
00214 }

void ClusterSequenceActiveAreaExplicitGhosts::_post_process (  )  [private]

routine to be called after the processing is done so as to establish summary information on all the jets (areas, whether pure ghost, etc.

)

virtual double ClusterSequenceActiveAreaExplicitGhosts::area ( const PseudoJet jet  )  const [virtual]

returns the area of a jet

Reimplemented from ClusterSequenceAreaBase.

virtual PseudoJet ClusterSequenceActiveAreaExplicitGhosts::area_4vector ( const PseudoJet jet  )  const [virtual]

returns a four vector corresponding to the sum (E-scheme) of the ghost four-vectors composing the jet area, normalised such that for a small contiguous area the p_t of the extended_area jet is equal to area of the jet.

Reimplemented from ClusterSequenceAreaBase.

virtual double ClusterSequenceActiveAreaExplicitGhosts::empty_area ( const RangeDefinition range  )  const [virtual]

return the total area, up to |y|<maxrap, that consists of unclustered ghosts

Reimplemented from ClusterSequenceAreaBase.

bool ClusterSequenceActiveAreaExplicitGhosts::has_dangerous_particles (  )  const [inline]

returns true if there are any particles whose transverse momentum if so low that there's a risk of the ghosts having modified the clustering sequence

Definition at line 124 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _has_dangerous_particles.

Referenced by ClusterSequenceActiveArea::_run_AA(), and ClusterSequenceActiveArea::_throw_unless_jets_have_same_perp_or_E().

00124 {return _has_dangerous_particles;}

virtual bool ClusterSequenceActiveAreaExplicitGhosts::has_explicit_ghosts (  )  const [inline, virtual]

this class does have explicit ghosts

Reimplemented from ClusterSequenceAreaBase.

Definition at line 108 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

00108 {return true;}

bool ClusterSequenceActiveAreaExplicitGhosts::is_pure_ghost ( int  history_index  )  const

true if the entry in the history index corresponds to a ghost; if hist_ix does not correspond to an actual particle (i.e.

hist_ix < 0), then the result is false.

virtual bool ClusterSequenceActiveAreaExplicitGhosts::is_pure_ghost ( const PseudoJet jet  )  const [virtual]

true if a jet is made exclusively of ghosts

Reimplemented from ClusterSequenceAreaBase.

Referenced by ClusterSequenceActiveArea::_transfer_ghost_free_history().

double ClusterSequenceActiveAreaExplicitGhosts::max_ghost_perp2 (  )  const [inline]

returns the largest squared transverse momentum among all ghosts

Definition at line 119 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _max_ghost_perp2.

00119 {return _max_ghost_perp2;}

unsigned int ClusterSequenceActiveAreaExplicitGhosts::n_hard_particles (  )  const [inline]

returns the number of hard particles (i.e. those supplied by the user).

Definition at line 217 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

References _initial_hard_n.

00217 {return _initial_hard_n;}

double ClusterSequenceActiveAreaExplicitGhosts::total_area (  )  const

returns the total area under study


Member Data Documentation

Definition at line 135 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

std::vector<double> ClusterSequenceActiveAreaExplicitGhosts::_areas [private]

Definition at line 134 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Definition at line 132 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by _add_ghosts().

Definition at line 139 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by has_dangerous_particles().

Definition at line 146 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by n_hard_particles().

Definition at line 133 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by _add_ghosts().

Definition at line 138 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by max_ghost_perp2().

get the area of the ghosts

Definition at line 131 of file ClusterSequenceActiveAreaExplicitGhosts.hh.

Referenced by _add_ghosts().

handle warning messages

allow for warnings

Reimplemented from ClusterSequenceAreaBase.

Definition at line 140 of file ClusterSequenceActiveAreaExplicitGhosts.hh.


The documentation for this class was generated from the following file:

Generated on 26 Feb 2010 for fastjet by  doxygen 1.6.1