[postgis-devel] [PostGIS] #503: ST_Area on small polygons in EPSG:31467 gives incorrect results depending on 32-/64-system-architecture
PostGIS
trac at osgeo.org
Thu Apr 15 12:35:49 PDT 2010
#503: ST_Area on small polygons in EPSG:31467 gives incorrect results depending
on 32-/64-system-architecture
----------------------+-----------------------------------------------------
Reporter: mjansen | Owner: pramsey
Type: defect | Status: new
Priority: medium | Milestone: PostGIS 1.5.2
Component: postgis | Version: 1.5.X
Resolution: | Keywords:
----------------------+-----------------------------------------------------
Comment (by pramsey):
Some of the polygons are very "not polygon like". They are extremely flat
triangles. Which is why I suspected failures due to precision issues (the
vertices being snapped to a regular lattice imposed by the precision of
the representation) However, the triangle in my example
{{{
'POLYGON ((3498246.2563 5815493.2389, 3498246.2472 5815493.1259,
3498246.2094 5815493.1202, 3498246.2563 5815493.2389))'
}}}
has a normal shape. See what your manual routine returns for it? With a
double we have 52 bits of precision, which is enough space to store 15
digits of information, which is more than we have here... The reason I
wonder if we're being coerced into single precision is that there are only
23 bits of precision there, so a max untruncated number of 8388608, so
most of the digits after the decimal point in these examples would be
lost. This also fits with the idea that even large polygons are showing
similar quantization effects -- if the vertices are being pushed into a
single precision grid.
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/503#comment:9>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-devel
mailing list