[postgis-users] Is there a better way for Finding Gaps/Sliver Holes?

Martin Davis mtnclimb at gmail.com
Mon May 2 11:54:33 PDT 2022


Yes, that technique only applies to polygonal coverages.

Your use case is not clear to me.  An example dataset might make that more
clear.

On Mon, May 2, 2022 at 11:40 AM Shaozhong SHI <shishaozhong at gmail.com>
wrote:

>
>
> On Mon, 2 May 2022 at 19:05, Martin Davis <mtnclimb at gmail.com> wrote:
>
>> That blog post does provide useful queries for finding polygon overlaps
>> and gaps.
>>
>> Overlaps are found via testing if polygon interiors intersect, using the
>> DE-9IM relate mask 2********.
>>
>> Gaps are found by identifying holes in the union of the set of polygons.
>> One issue with this is that computing the union of large datasets can be
>> slow.  Lars' solution provides some ideas for dealing with this.
>>
>>
>> I think that matters are rather more complex than this.
>
> For instance, I found 2 lines meet with each other at both ends.  In this
> case, 2 intersections are both a point.  One will find two lines form an
> enclosed area.
>
> When 2 lines intersect or meet/touch more than 2 times, intersection will
> return more than 2 points.   For instance, when two lines meet at 3 points,
> one would get 2 gap polygons.
>
> Given 2 zigzagging lines, how to write a function to return overlaps and
> gaps is an interesting matter.
>
> Regards,
>
> David
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/postgis-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20220502/ead29b21/attachment.htm>


More information about the postgis-users mailing list