Re: [Fwd: Re: ruleutils with pretty-print option]
От
Manfred Koizar
Тема
Re: [Fwd: Re: ruleutils with pretty-print option]
Дата
Msg-id
5vdiivkpp59flilu0hvlc9nec31fe07ipr@4ax.com
Ответ на
Re: [Fwd: Re: ruleutils with pretty-print option] (Andreas Pflug)
Список
Дерево обсуждения
[Fwd: Re: ruleutils with pretty-print option] Andreas Pflug <pgadmin@pse-consulting.de>
Re: [Fwd: Re: ruleutils with pretty-print option] Tom Lane <tgl@sss.pgh.pa.us>
Re: [Fwd: Re: ruleutils with pretty-print option] Andreas Pflug <pgadmin@pse-consulting.de>
Re: [Fwd: Re: ruleutils with pretty-print option] Tom Lane <tgl@sss.pgh.pa.us>
Re: [Fwd: Re: ruleutils with pretty-print option] Andreas Pflug <pgadmin@pse-consulting.de>
Re: [Fwd: Re: ruleutils with pretty-print option] Manfred Koizar <mkoi-pg@aon.at>
On Thu, 31 Jul 2003 16:30:17 +0200, Andreas Pflug
wrote:
>Well, to me it's not well-known that floating-point addition is not
>associative
This is a case of theory vs. practice mismatch: In theory addition is
associative, in practice there is only limited storage available for a
floating-point number. Let's do an example with 3 significant decimal
digits:
a = 1000 internal representation: 1.00e3
b = 1 internal representation: 1.00e0
a + b = 1.001e3
which cannot be represented in our system, so it is rounded to 1.00e3
and we get
a + b = 1000
a + b + b + b + b + b + b + b + b + b + b = 1000
when evaluated left to right, but
a + (b + b + b + b + b + b + b + b + b + b) =
1.00e3 + 1.00e1 = 1.01e3 = 1001
Servus
Manfred
В списке pgsql-patches по дате отправления