![]() |
![]()
| ![]() |
![]()
NAMEv.voronoi - Creates a Voronoi diagram constrained to the extents of the current region from an input vector map containing points or centroids. KEYWORDSvector, geometry, triangulation, skeleton SYNOPSISv.voronoi
Flags:
Parameters:
DESCRIPTIONv.voronoi creates a Voronoi diagram (Thiessen polygons) from points or centroids. The bounds of the output map are limited by the current region (see g.region). The -a flag can be used to create a Voronoi diagram for areas. The -s flag can be used to extract the center line of areas or skeletons of areas with thin >= 0. Smaller values for the thin option will preserve more detail, while negative values will extract only the center line. NOTESv.voronoi suffers from numerical instability, results can sometimes contain many artefacts. When creating Voronoi diagrams for areas or skeletons for areas, it is highly recommended to simplify the areas first with v.generalize. Voronoi diagrams may be used for nearest-neighbor flood filling. Give the centroids attributes (start with v.db.addcolumn), then optionally convert the result to a raster map with v.to.rast. The extraction of skeletons and center lines with the -s flag is a brute force approach. Faster and more accurate algorithms to extract skeletons from areas exist but are not yet implemented. In the meantime, skeletons and center lines can be simplified with the Douglas-Peucker algorithm: v.generalize method=douglas. EXAMPLEVoronoi diagram for pointsThis example uses the hospitals in the North Carolina dataset.
g.region -p raster=elev_state_500m v.voronoi input=hospitals output=hospitals_voronoi Result:
Voronoi diagram for areasThis example uses urban areas in the North Carolina dataset.
g.region -p n=162500 s=80000 w=727000 e=846000 res=500 v.voronoi input=urbanarea output=urbanarea_voronoi -a Result:
Skeletons and center lines of areasThis example uses urban areas in the North Carolina dataset.
g.region -p n=161000 s=135500 w=768500 e=805500 res=500 v.voronoi input=urbanarea output=urbanarea_centerline -s v.voronoi input=urbanarea output=urbanarea_skeleton -s thin=2000 Result:
REFERENCESSteve J. Fortune, (1987). A Sweepline Algorithm for Voronoi Diagrams, Algorithmica 2, 153-174 (DOI). SEE ALSOg.region, v.delaunay, v.hull Voronoi diagram (Wikipedia) AUTHORSJames Darrell McCauley, Purdue University
SOURCE CODEAvailable at: v.voronoi source code (history) Latest change: Tuesday Dec 17 20:17:20 2024 in commit: d962e90c026708a4815ea2b9f46c0e84c17de22d Main index | Vector index | Topics index | Keywords index | Graphical index | Full index © 2003-2025 GRASS Development Team, GRASS GIS 8.4.1 Reference Manual
|