[postgis-tickets] [PostGIS] #5563: Potential bug in the ST_Equals function.

PostGIS trac at osgeo.org
Thu Oct 5 14:56:46 PDT 2023


#5563: Potential bug in the ST_Equals function.
-----------------------+---------------------------
  Reporter:  Wenjing   |      Owner:  pramsey
      Type:  defect    |     Status:  new
  Priority:  critical  |  Milestone:  PostGIS 3.4.1
 Component:  postgis   |    Version:  3.4.x
Resolution:            |   Keywords:
-----------------------+---------------------------
Comment (by mdavis):

 The issue is due to the inherent inaccuracy of finite-precision floating
 point arithmetic. There's a lot of arithmetic being carried out, so the
 likelihood of 2 transformed intersecting lines NOT intersecting in 3D is
 very high.

 You can't rely on topological relationships being preserved through
 floating-point operations. This is the essence of the well-known issue of
 geometrical robustness failures. The solution is usually either to use
 exact arithmetic (often impractical) or use tolerance values (not a
 panacea, but very often works).
-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5563#comment:3>
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-tickets mailing list