fastjet 2.4.3
Public Member Functions | Private Member Functions | Private Attributes

Dnn4piCylinder Class Reference

class derived from DynamicNearestNeighbours that provides an implementation for the surface of cylinder (using two copies of DnnPlane, one running from 0--2pi, the other from pi--3pi). More...

#include <Dnn4piCylinder.hh>

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

List of all members.

Public Member Functions

 Dnn4piCylinder ()
 empty initaliser
 Dnn4piCylinder (const std::vector< EtaPhi > &, const bool &verbose=false)
 Initialiser from a set of points on an Eta-Phi plane, where eta can have an arbitrary ranges and phi must be in range 0 <= phi < 2pi.
int NearestNeighbourIndex (const int &ii) const
 Returns the index of the nearest neighbour of point labelled by ii (assumes ii is valid)
double NearestNeighbourDistance (const int &ii) const
 Returns the distance to the nearest neighbour of point labelled by index ii (assumes ii is valid)
bool Valid (const int &index) const
 Returns true iff the given index corresponds to a point that exists in the DNN structure (meaning that it has been added, and not removed in the meantime)
void RemoveAndAddPoints (const std::vector< int > &indices_to_remove, const std::vector< EtaPhi > &points_to_add, std::vector< int > &indices_added, std::vector< int > &indices_of_updated_neighbours)
 remove the points labelled by the std::vector indices_to_remove, and add the points specified by the std::vector points_to_add (corresponding indices will be calculated automatically); the idea behind this routine is that the points to be added will somehow be close to the one or other of the points being removed and this can be used by the implementation to provide hints for inserting the new points in whatever structure it is using.
 ~Dnn4piCylinder ()

Private Member Functions

EtaPhi _remap_phi (const EtaPhi &point)
 given a phi value in the 0--2pi range return one in the pi--3pi range.

Private Attributes

bool _verbose
DnnPlane_DNN1
DnnPlane_DNN2

Detailed Description

class derived from DynamicNearestNeighbours that provides an implementation for the surface of cylinder (using two copies of DnnPlane, one running from 0--2pi, the other from pi--3pi).

Definition at line 45 of file Dnn4piCylinder.hh.


Constructor & Destructor Documentation

Dnn4piCylinder::Dnn4piCylinder ( ) [inline]

empty initaliser

Definition at line 48 of file Dnn4piCylinder.hh.

{}
Dnn4piCylinder::Dnn4piCylinder ( const std::vector< EtaPhi > &  ,
const bool &  verbose = false 
)

Initialiser from a set of points on an Eta-Phi plane, where eta can have an arbitrary ranges and phi must be in range 0 <= phi < 2pi.

Dnn4piCylinder::~Dnn4piCylinder ( ) [inline]

Definition at line 117 of file Dnn4piCylinder.hh.

References _DNN1, and _DNN2.

                                       {
  delete _DNN1; 
  delete _DNN2;
}

Member Function Documentation

EtaPhi Dnn4piCylinder::_remap_phi ( const EtaPhi point) [inline, private]

given a phi value in the 0--2pi range return one in the pi--3pi range.

Definition at line 87 of file Dnn4piCylinder.hh.

References EtaPhi::first, d0::inline_maths::phi(), fastjet::pi, EtaPhi::second, and twopi.

                                                 {
    double phi = point.second;
    if (phi < pi) { phi += twopi ;}
    return EtaPhi(point.first, phi);}
double Dnn4piCylinder::NearestNeighbourDistance ( const int &  ii) const [inline, virtual]

Returns the distance to the nearest neighbour of point labelled by index ii (assumes ii is valid)

Implements DynamicNearestNeighbours.

Definition at line 105 of file Dnn4piCylinder.hh.

References _DNN1, _DNN2, and DnnPlane::NearestNeighbourDistance().

int Dnn4piCylinder::NearestNeighbourIndex ( const int &  ii) const [inline, virtual]

Returns the index of the nearest neighbour of point labelled by ii (assumes ii is valid)

Implements DynamicNearestNeighbours.

Definition at line 98 of file Dnn4piCylinder.hh.

References _DNN1, _DNN2, DnnPlane::NearestNeighbourDistance(), and DnnPlane::NearestNeighbourIndex().

void Dnn4piCylinder::RemoveAndAddPoints ( const std::vector< int > &  indices_to_remove,
const std::vector< EtaPhi > &  points_to_add,
std::vector< int > &  indices_added,
std::vector< int > &  indices_of_updated_neighbours 
) [virtual]

remove the points labelled by the std::vector indices_to_remove, and add the points specified by the std::vector points_to_add (corresponding indices will be calculated automatically); the idea behind this routine is that the points to be added will somehow be close to the one or other of the points being removed and this can be used by the implementation to provide hints for inserting the new points in whatever structure it is using.

remove the points labelled by the vector indices_to_remove, and add the points specified by the vector points_to_add (corresponding indices will be calculated automatically); the idea behind this routine is that the points to be added will somehow be close to the one or other of the points being removed and this can be used by the implementation to provide hints for inserting the new points in whatever structure it is using.

insertion and removal of points

In a kt-algorithm the points being added will be a result of a combination of the points to be removed -- hence the proximity is (more or less) guaranteed.

Implements DynamicNearestNeighbours.

bool Dnn4piCylinder::Valid ( const int &  index) const [inline, virtual]

Returns true iff the given index corresponds to a point that exists in the DNN structure (meaning that it has been added, and not removed in the meantime)

Implements DynamicNearestNeighbours.

Definition at line 112 of file Dnn4piCylinder.hh.

References _DNN1, _DNN2, and DnnPlane::Valid().

                                                         {
  return (_DNN1->Valid(index) && _DNN2->Valid(index));
}

Member Data Documentation

bool Dnn4piCylinder::_verbose [private]

Definition at line 77 of file Dnn4piCylinder.hh.


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