Voronoi & Lloyd Relaxation illustration

Voronoi & Lloyd Relaxation

A Voronoi diagram splits the plane into cells, one per seed point, where each cell is everywhere closer to its seed than to any other. Scatter seeds by clicking or randomising and the tool paints the cells live, with the Delaunay triangulation (the dual graph joining neighbouring seeds) available as an overlay. Then run Lloyd’s relaxation: repeatedly move each seed to the centre of its own cell, and the ragged random pattern smooths step by step into an even, organic honeycomb. Drag seeds around to reshape the cells, change the distance metric, and watch tissue-like structure emerge from scattered dots.

Runs 100% in your browser — simulations are computed locally on your device.

Notes

  • Every point in a cell is closer to that cell’s seed than to any other, so the cell walls are the perpendicular bisectors between neighbouring seeds.
  • Lloyd’s relaxation moves each seed to its cell centroid and repeats; the diagram converges toward a centroidal Voronoi tessellation, an even honeycomb-like packing.
  • Voronoi and its dual Delaunay triangulation underlie mesh generation, nearest-neighbour lookup, and models of everything from cell tissue to mobile-phone coverage.
  • Runs 100% in your browser — simulations are computed locally on your device.