From: Georg Bauhaus <rm.dash-bauhaus@futureapps.de>
Subject: Re: Float conversion
Date: Thu, 29 Jul 2010 16:56:47 +0200
Date: 2010-07-29T16:56:47+02:00 [thread overview]
Message-ID: <4c5196af$0$6878$9b4e6d93@newsspool2.arcor-online.net> (raw)
In-Reply-To: <9e669a3b-1013-4bd1-b372-5f7dfa46d083@f42g2000yqn.googlegroups.com>
On 29.07.10 14:23, Henrique wrote:
> package Float_Text_IO is new Ada.Text_IO.Float_IO (Long_Float);
(Any reason you didn't instantiate with My_Float?)
For illustration, inserting Put(Var3, Aft => 15) and
Put(Var4, Aft => 15), I get
$ ./test_fpt
var3: 9.999000244140625E+02=
var4: 9.999000854492188E+02>
Choosing 15 digits instead of 6 in the type definition, I get
$ ./test_fpt
var3: 9.999000000000000E+02=
var4: 9.999000000000001E+02>
There is always a FPT computation that isn't giving the exact
result, since there aren't enough bits for doing real math on
any computer, if you try hard enough.
Georg
next prev parent reply other threads:[~2010-07-29 14:56 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-29 12:23 Float conversion Henrique
2010-07-29 12:44 ` Jacob Sparre Andersen
2010-07-29 12:46 ` Dmitry A. Kazakov
2010-07-29 15:08 ` Georg Bauhaus
2010-07-29 15:10 ` Georg Bauhaus
2010-07-29 15:35 ` Dmitry A. Kazakov
2010-07-29 18:21 ` Henrique
2010-07-29 19:08 ` Jeffrey R. Carter
2010-07-29 19:15 ` Dmitry A. Kazakov
2010-07-30 1:30 ` Phil Clayton
2010-07-30 8:43 ` Dmitry A. Kazakov
2010-07-30 13:14 ` Phil Clayton
2010-07-30 14:34 ` Dmitry A. Kazakov
2010-07-31 15:12 ` Stephen Leake
2010-08-03 1:07 ` Phil Clayton
2010-08-03 3:31 ` Shark8
2010-08-03 10:38 ` Georg Bauhaus
2010-08-04 7:27 ` Stephen Leake
2010-08-04 16:15 ` Georg Bauhaus
2010-08-04 16:32 ` Phil Clayton
2010-08-04 7:26 ` Stephen Leake
2010-08-04 12:52 ` Robert A Duff
2010-08-04 14:32 ` Dmitry A. Kazakov
2010-08-04 19:36 ` Simon Wright
2010-08-04 19:46 ` Dmitry A. Kazakov
2010-08-04 20:29 ` Georg Bauhaus
2010-08-05 12:05 ` Stephen Leake
2010-08-07 5:54 ` Shark8
2010-08-07 8:56 ` Georg Bauhaus
2010-08-07 13:49 ` Shark8
2010-08-05 10:20 ` Phil Clayton
2010-07-30 13:16 ` Henrique
2010-07-29 15:37 ` Warren
2010-07-29 14:56 ` Georg Bauhaus [this message]
2010-07-29 17:56 ` Jeffrey R. Carter
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox