30#ifndef __SPH_VICINITY_H__
31#define __SPH_VICINITY_H__
33#include <siscone/vicinity.h>
38#ifdef USE_QUADTREE_FOR_STABILITY_TEST
39#include <siscone/quadtree.h>
42namespace siscone_spherical{
125#ifdef USE_QUADTREE_FOR_STABILITY_TEST
Implementation of a 2D quadtree.
a class to keep track of inclusion status in cone and in cocircular region while using minimal resour...
base class for managing the spatial part of Cmomentum (defined after)
base class for dynamic coordinates management
element in the vicinity of a parent.
double cocircular_range
amount by which the angle can be varied while maintaining this point within co-circularity margin
bool side
true if angle on the positive side, false otherwise
CSph3vector centre
direction of the centre
std::list< CSphvicinity_elm * > cocircular
list of elements co-circular with this one NB: empty list uses less mem than vector
double angle
angle with parent
CSphmomentum * v
pointer to the second borderline particle
siscone::Cvicinity_inclusion * is_inside
variable to tell if the particle is inside or outside the cone
list of element in the vicinity of a parent.
double VR
radius of the vicinity
~CSphvicinity()
default destructor
CSphvicinity_elm * ve_list
list of vicinity elements built from particle list (size=2*n)
std::vector< CSphmomentum > plist
the list of particles
double D2_R
euclidian distance (squared) corresp. to the arc R
double inv_R_2EPS_COCIRC
R / (2*EPSILON_COCIRCULAR)
std::vector< siscone::Cvicinity_inclusion > pincluded
the inclusion state of particles
CSph3vector angular_dir2
second direction to measure angles (sign)
CSph3vector angular_dir1
main direction to measure angles
CSphmomentum * parent
parent vector
void append_to_vicinity(CSphmomentum *v)
append a particle to the 'vicinity' list after having tested it and computed the angular-ordering qua...
std::vector< CSphvicinity_elm * > vicinity
list of points in parent's vicinity
CSphvicinity()
default constructor
double cosVR
cosine of the radius of the vicinity
double tan2R
squared tangent of the normal radius
void set_particle_list(std::vector< CSphmomentum > &_particle_list)
set the particle_list
int n_part
number of particles
CSph3vector parent_centre
parent centre
unsigned int vicinity_size
number of elements in vicinity
double VR2
squared radius of the vicinity
double inv_R_EPS_COCIRC
R / EPSILON_COCIRCULAR.
double R2
squared normal radius
void build(CSphmomentum *_parent, double _VR)
build the vicinity list from the list of points.
CSphvicinity(std::vector< CSphmomentum > &_particle_list)
constructor with initialisation (see set_particle_list)