[postgis-devel] [PostGIS] #240: ST_SimplifyPreserveTopology documentation unclear on intersections within a MultiPolygon

Martin Davis mbdavis at refractions.net
Mon Nov 23 15:57:39 PST 2009


Sorry, my previous reply didn't quite answer the question asked!  Here's 
another try...

The contract of SimplifyPreserveTopology is:
- it will not introduce new intersections in the portions of the 
geometry which are modifed by the simplification.
- it may or may not preserve intersections in affected portions, 
depending on the nature of the surrounding geometry.

So for the case given, if the output of SPT is {A',B',C'}then:
- B' and C' will not intersect
- A' and B' may or may not intersect.

To answer the other statement of the question, it is true that SPT 
ensures that the intersection count is no greater after than before, but 
this is a side effect of the algorithm.  SPT evaluates each intersection 
or potential intersection independently, and at no time computes the 
overall count of intersections.

PostGIS wrote:
> #240: ST_SimplifyPreserveTopology documentation unclear on intersections within a
> MultiPolygon
> ----------------------+-----------------------------------------------------
>   Reporter:  perchrh  |       Owner:  robe         
>       Type:  defect   |      Status:  new          
>   Priority:  medium   |   Milestone:  PostGIS 1.5.0
>  Component:  postgis  |     Version:               
> Resolution:           |    Keywords:               
> ----------------------+-----------------------------------------------------
> Comment (by perchrh):
>
>  In the ESRI shapefile standard, a Record with shapetype Polygon is a
>  collection of zero or more Rings (in other terms: a MultiPolygon
>  containing multiple Polygons). The rings may intersect each other and
>  cannot self-intersect.
>
>  It is clear that ST_SimplifyPreserveTopology doesn't introduce self-
>  intersections and doesn't introduce intersections between Polygons if
>  there were none in the input.
>
>  My question, that I didn't manage to get answered by a quick look at the
>  code is, is the processing of these valid MultiPolygons with intersecting
>  Polygons guaranteed to result in a MultiPolygon with no new intersections?
>  Or does it just guarantee that the intersection count will not be higher
>  than in the input? To put it another way, if I have a MultiPolygon with
>  three polygons, two of them intersecting each other (A and B), is it
>  possible that B and C will intersect after ST_SimplifyPreserveTopology?
>
>   

-- 
Martin Davis
Senior Technical Architect
Refractions Research, Inc.
(250) 383-3022




More information about the postgis-devel mailing list