From: Brian Drummond <brian_drummond@btconnect.com>
Subject: Re: loop problem with exit condition
Date: Tue, 26 Oct 2010 13:38:46 +0100
Date: 2010-10-26T13:38:46+01:00 [thread overview]
Message-ID: <hqidc6p2d9rhntem6d0cmsttqsh4jnem6j@4ax.com> (raw)
In-Reply-To: op.vk5w9gtdule2fv@garhos
On Tue, 26 Oct 2010 04:59:30 +0200, Yannick Duch�ne (Hibou57)
<yannick_duchene@yahoo.fr> wrote:
>Le Sun, 26 Sep 2010 11:10:24 +0200, Dmitry A. Kazakov
><mailbox@dmitry-kazakov.de> a �crit:
>> in your case the simplest way to remove bias would be to multiply the
>> step:
>> [�]
>> Inner := Inner_Start + Inner_Step * Long_Float (J - 1);
>
>I did not knew that. Why is an iterative addition less accurate than a
>multiplication ? Does it have something to deal with adjustment of the
>exponent ? (the one of the float's internal representation)
An iterative addition and a multiplication both have rounding error bounded by
epsilon.
N iterative additions versus one multiplication, however...
- Brian
prev parent reply other threads:[~2010-10-26 12:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-26 8:14 loop problem with exit condition Ada novice
2010-09-26 8:16 ` Ada novice
2010-09-26 9:10 ` Dmitry A. Kazakov
2010-09-26 10:19 ` Ada novice
2010-10-26 2:59 ` Yannick Duchêne (Hibou57)
2010-10-26 7:02 ` Niklas Holsti
2010-10-26 8:24 ` Dmitry A. Kazakov
2010-10-26 12:38 ` Brian Drummond [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox