pg.ddx.io pgsql-bugs@postgresql.org mailing list archivehelp / color / mirror / Atom feed
BUG #6675: Box overlap with infinity edge 2+ messages / 2 participants [nested] [flat]
* BUG #6675: Box overlap with infinity edge @ 2012-06-05 07:15 jeremie.thomassey@gmail.com 0 siblings, 1 reply; 2+ messages in thread From: jeremie.thomassey@gmail.com @ 2012-06-05 07:15 UTC (permalink / raw) To: pgsql-bugs The following bug has been logged on the website: Bug reference: 6675 Logged by: Thomassey J Email address: jeremie.thomassey@gmail.com PostgreSQL version: 9.1.4 Operating system: Ubuntu 10.04.4 LTS Description: Hi, I can't understand this result : SELECT box '((1,1),(infinity, 1))' && box '((2, 1),(infinity, 1))'; ?column? --------- f Isn't it supposed to return true? The documentation doesn't really say anything about infinite edge. Thanks. ^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: BUG #6675: Box overlap with infinity edge @ 2012-06-06 04:58 Tom Lane <tgl@sss.pgh.pa.us> parent: jeremie.thomassey@gmail.com 0 siblings, 0 replies; 2+ messages in thread From: Tom Lane @ 2012-06-06 04:58 UTC (permalink / raw) To: jeremie.thomassey@gmail.com; +Cc: pgsql-bugs jeremie.thomassey@gmail.com writes: > I can't understand this result : > SELECT box '((1,1),(infinity, 1))' && box '((2, 1),(infinity, 1))'; > ?column? > --------- > f > Isn't it supposed to return true? The documentation doesn't really say > anything about infinite edge. The test for this involves FPge(box1->high.x, box2->high.x) where FPge is defined as #define FPge(A,B) ((B) - (A) <= EPSILON) When both high.x values are infinity, you have infinity minus infinity, which yields NaN in IEEE arithmetic, so the comparison to epsilon comes out false. In general I don't think we promise that geometric operations involving infinite endpoints will behave sanely. There are probably a boatload of corner cases besides this one that'd need to be fixed before we could consider that a supported case. regards, tom lane ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2012-06-06 04:58 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2012-06-05 07:15 BUG #6675: Box overlap with infinity edge jeremie.thomassey@gmail.com 2012-06-06 04:58 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox