use crate::bounds::BoundingBox;
pub mod algo_2d_grid;
pub mod algo_3d_grid;
pub mod algo_3d_octree;
pub trait SpatialAlgorithm<const D: usize>: Send + Sync {
fn set_generators(&mut self, generators: &[f64], bounds: &BoundingBox<D>);
fn update_generator(&mut self, index: usize, old_pos: &[f64; D], new_pos: &[f64; D], bounds: &BoundingBox<D>);
fn visit_neighbors<F>(&self, generators: &[f64], index: usize, pos: [f64; D], max_dist_sq: &mut f64, visitor: F)
where
F: FnMut(usize, [f64; D], f64) -> f64;
}