This demo implements the Lloyd algorithm in periodic space using the CGAL 3D periodic triangulations. The algorithm can be run either on randomly generated point sets or on input point sets provided in a file.
The Lloyd algorithm computes the Voronoi diagram and replaces in each step the input point set by the centroids of their respective Voronoi cells.
For more information on 3D periodic triangulations see the CGAL Periodic Triangulation package manual.