I’m assuming the best answer to this question requires using `VoronoiDelaunay.jl`

, but I’m also open to other packages/approaches.

If I have a set of points in 2D (or 3D? Though not I’m not sure this is possible with the package `VoronoiDelaunay.jl`

), what is the fastest way to get each of their nearest neighbors in a Voronoi-tesselation sense (e.g the neighbors within the ‘first Voronoi shell’)? I am also not really confident on the mathematics behind this or how it relates to Delaunay triangulation.

The data structure doesn’t matter too much to me, but let’s just assume the data is stored in a 2D array of type `Array{Float64,2}`

called `my_points`

, whose size is `(nDims, nPoints),`

and `nDims`

is 2 or 3, and `nPoints`

is the number of points. Let’s say I want to have the output be an edge list of some kind, e.g. array of arrays called `edge_list`

(`Array{Array{Int64,1}}`

) where each element `i`

of `edge_list`

gives me the indices of those points that are Voronoi neighbors of the focal point `i`

(whose coordinates are stored in `my_points[:,i]`

).