[GRASS-dev] Some doubts about GRASS topology

Benjamin Ducke benjamin.ducke at oxfordarch.co.uk
Wed Sep 23 14:55:27 EDT 2009

Dear all,

in an attempt to better understand the GRASS vector and topology
model, I imported a set of 3 polygons from an ESRI Shapefile (see
attachment). The polygon in the upper left has 4 holes (called
islands for some reason by GRASS), the lower one consists of 3
parts (QGIS calls this a polygon with islands -- good to know we 
understand each other in the GIS world!). The third is a simple,
convex shape.

Displaying the imported map shows all geometries exactly as it
should. So far so good.

Now, when I run v.info on the imported map, I get:

Number of lines: 0
Number of boundaries: 9
Number of centroids: 5
Number of areas: 9
Number of islands: 9

This completely baffles me!

The GRASS documentation consistently states that an area
is a boundary + a centroid + any number of "islands".

Now, assuming that the lines around the four "islands" count
as boundaries, I understand why there are 9 boundaries
altogether. 5 centroids also check out, given that there
is no 1:1 equivalent for a shapefile multipart polygon in GRASS.

But how in the (GRASS) world can there be 9 areas if there
are only 5 centroids? And why 9 islands? It's a mystery to
me. After all those days working on v.out.ogr et al. these
sort of things leave me thinking I have not understood anything
about the GRASS vector model at all.

Could someone clarify please?



P.S.: I have also attached the simple Shapefile I used.

Files attached to this email may be in ISO 26300 format (OASIS Open Document Format). If you have difficulty opening them, please visit http://iso26300.info for more information.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: polytest.jpeg
Type: image/jpeg
Size: 21890 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20090923/fcea2ea1/polytest-0001.jpeg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: polytest.zip
Type: application/zip
Size: 2331 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20090923/fcea2ea1/polytest-0001.zip

More information about the grass-dev mailing list