Thank you for all the answers.<div><br></div><div>I did not try the topology, as I need to study its implementation a little better.<br><div><br></div><div>I did not found the st_cleanpolygon function and using (St_Buffer, 0) did not worked:</div>
<div><br></div><div>The dilate\erode visually corrects the problem, but of course introduce a small rounding in the angle introducing a small overlaping with other adjacent polygons...</div><div><br></div><div>I guess that the tolerance with the GEOS PrecisionModel would be nice, I think that is the method used by ArcGIS products to "insure" geometry "topology" after aggregation operations.</div>
<div><br></div><div>Any more ideas?</div><div><br></div><div>Alexandre Neto</div><div><br></div><div><br></div><div><br><div><br></div><div><br><br><div class="gmail_quote">On Fri, Oct 26, 2012 at 8:40 AM, Dave Potts <span dir="ltr"><<a href="mailto:dave.potts@pinan.co.uk" target="_blank">dave.potts@pinan.co.uk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Have you considered curve smoothing or apply a small buffer around the<br>
orginal data/<br>
<div><div class="h5"><br>
Sandro Santilli wrote:<br>
> It will be _very_ slow.<br>
> So much that you may prefer to make the topology persistent.<br>
><br>
> Another approach I'd like to see implemented would be to expose a<br>
> tolerance<br>
> to the GEOS implemented functions. Basically exposing the GEOS<br>
> PrecisionModel. By doing that you could specify a tolerance in the overlay<br>
> operations and the result should never have gaps bigger than the given<br>
> tolerance.<br>
><br>
> --strk;<br>
><br>
> On Thu, Oct 25, 2012 at 10:28:19AM -0700, <a href="mailto:pcreso@pcreso.com">pcreso@pcreso.com</a> wrote:<br>
>> My impression is that working topologies is slow, especially with large<br>
>> datasets - lots of computation involved.<br>
>><br>
>> How effective would this be with hundreds of thousands or millions or<br>
>> small polygons?<br>
>><br>
>> Just running ST_Union() takes hours to days.<br>
>><br>
>> Thanks<br>
>><br>
>> Brent Wood<br>
>><br>
>> --- On Fri, 10/26/12, Sandro Santilli <<a href="mailto:strk@keybit.net">strk@keybit.net</a>> wrote:<br>
>><br>
>> From: Sandro Santilli <<a href="mailto:strk@keybit.net">strk@keybit.net</a>><br>
>> Subject: Re: [postgis-users] How to eliminate small gaps produced by<br>
>> ST_union?<br>
>> To: "PostGIS Users Discussion" <<a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a>><br>
>> Date: Friday, October 26, 2012, 6:04 AM<br>
>><br>
>> You may try to construct a topology within PostGIS-2.0, using<br>
>> a small tolerance, and then get the geometries back.<br>
>><br>
>> --strk;<br>
>><br>
>> On Thu, Oct 25, 2012 at 05:54:05PM +0100, Alexandre Neto wrote:<br>
>> > I'm trying to Aggregate\Dissolve a set of adjacent, but not touching<br>
>> > polygons in Postgis. The geometries were created editing the Postgis<br>
>> table<br>
>> > in QGIS created, with snapping and avoid overlap in the layer.<br>
>> ><br>
>> > I used ST_Union like this:<br>
>> ><br>
>> > SELECT ST_Union(the_geom)<br>
>> > FROM table;<br>
>> ><br>
>> > Small gaps similar to lines appear in the result. This happens when<br>
>> the<br>
>> > adjacent polygons do not share the exact same vertices.<br>
>> ><br>
>> > [image: Inline image 2]<br>
>> > Is there a way to eliminate this "gaps" or "small angles" within<br>
>> Postgis?<br>
>> ><br>
>> > I know that v.clean in GRASS can eliminate small angles, and correct<br>
>> > topology, but that would mean I needed to copy the features to GRASS,<br>
>> > correct them and copy it back to Postgis.<br>
>> ><br>
>> > Thanks in advance,<br>
>> ><br>
>> > Alexandre Neto<br>
>><br>
>><br>
>> _______________________________________________<br>
>> postgis-users mailing list<br>
>> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
>> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
><br>
>> _______________________________________________<br>
>> postgis-users mailing list<br>
>> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
>> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
><br>
><br>
> --<br>
><br>
>  <a href="http://www.cartodb.com" target="_blank">http://www.cartodb.com</a> - Map, analyze and build applications with your<br>
> data<br>
><br>
>                                        ~~ <a href="http://strk.keybit.net" target="_blank">http://strk.keybit.net</a><br>
><br>
> _______________________________________________<br>
> postgis-users mailing list<br>
> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
><br>
<br>
<br>
</div></div>--<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
<a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
</div></div></blockquote></div><br></div></div></div>