Re: Fixing geometic calculation

Поиск
Список
Период
Сортировка
От Paul Matthews
Тема Re: Fixing geometic calculation
Дата
Msg-id 4A7CCFDA.6060306@netspace.net.au
обсуждение исходный текст
Ответ на Re: Fixing geometic calculation  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Fixing geometic calculation  (marcin mank <marcin.mank@gmail.com>)
Список pgsql-hackers
Tom Lane wrote:
> No, I'm worried about code that supposes that it can divide by (x - y)
> after testing that FPeq(x,y) is not true.  point_sl() for instance.
>
> We could perhaps fix those specific issues by testing the difference
> explicitly instead of doing it like that.  But there's still the overall
> problem of error accumulation ...
>
>             regards, tom lane
>   
IEEE754 does not allow two number X and Y, such that X!=Y and (X-Y)==0.
And since IEEE754 has been around since the 70's or 80's I think we can
start relying on its existence and behavior by now.

I don't see why it should be is postgres job to worry about error
accumulation. And then why only worry about it in geometric
calculations. Where in normal postgres code, or in perl, python, lisp,
or any in any other general purpose tool, is it where you ask it to tell
you 1.0+1.0 it responds with 2.0 +or- 0.0000000000000001?


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Paul Matthews
Дата:
Сообщение: Re: Fixing geometic calculation
Следующее
От: Herodotos Herodotou
Дата:
Сообщение: Re: Join optimization for inheritance tables