[postgis-devel] [PostGIS] #231: New distance-calculations proposal
PostGIS
trac at osgeo.org
Sat Oct 17 11:50:10 PDT 2009
#231: New distance-calculations proposal
--------------------------+-------------------------------------------------
Reporter: nicklas | Owner: robe
Type: enhancement | Status: assigned
Priority: medium | Milestone: postgis 1.5.0
Component: postgis | Version:
Resolution: | Keywords:
--------------------------+-------------------------------------------------
Comment (by nicklas):
Yes, this will never be of practical importance. But I think it was a
little bit interesting, I have never thought of that there is room for
more precision in storing the geometries closer to the origo of the
coordinate system than far away. If the "whole-unit part" of the
coordinate takes 7 positions there is only 7 more to describe the decimals
compared to 13 or maybe even 14 decimals, closer to origo than one unit.
I have played a little with the numbers and I don't see the logic how many
decimals is returned in our calculations. Sometimes it seems like the same
number is returned as inputed but not considering how many digits
representing decimals and how many representing whole units.
Sometimes I get the whole, double precision answer, even if it is not
needed. In this example this ccauses a little strange answer, I think:
{{{
select st_length('LINESTRING(10000 1,10000.1 1)'::geometry)
}}}
I get 0.100000000000364
instead of 0.1
What is deciding how many decimals should be returned? is it the planner
or the postgis functions?
/Nicklas
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/231#comment:15>
PostGIS <http://trac.osgeo.org/postgis/>
PostGIS
More information about the postgis-devel
mailing list