Here is some code to manipulate Voronoi cells in 2D.

https://github.com/jlapeyre/VoronoiCells.jl

I am developing these recent packages more or less just enough to get some 
research done. When things cool down (i.e. baby is grown and I get an 
endowed chair of free creativity) I plan to make them proper packages. I'm 
putting them out in case someone happens to have the same need I did, (or 
wants to contribute or comment).  If you do use something and have a 
question, or want something specific documented, let me know. Of course, 
this should eventually be integrated into the Julia geometry packages.

This code uses VoronoiDelaunay.jl to generate a tesselation. Then the 
objects representing cells are built from the triangles. There are a lot of 
choices about what to store and what to compute. The current choice is 
driven by my current need. The cell containing a random (as in access) 
point can be retrieved quickly using a standard bucket scheme. The cell 
stores the generator and the vertices.  A simpler (undocumented) structure 
is provided if you don't need to lookup by random point. A few features 
such as area of cells are provided.

John

Reply via email to