comp.lang.ada
 help / color / mirror / Atom feed
From: Adam Beneschan <adam@irvine.com>
Subject: Re: ObjectAda and Long_Long_Float
Date: Wed, 5 Dec 2007 08:17:15 -0800 (PST)
Date: 2007-12-05T08:17:15-08:00	[thread overview]
Message-ID: <dc8feff8-112c-496c-8094-fc6bb4b9b138@s12g2000prg.googlegroups.com> (raw)
In-Reply-To: cdea5ea6-92e0-4ceb-9fe0-6491c95a0132@e23g2000prf.googlegroups.com

On Dec 5, 5:12 am, axtens <Bruce.Axt...@gmail.com> wrote:
> G'day everyone,
>
> In Dmitry Kazakov's Intervals package, he was a file,
> Float_Intervals.ads which contains:
>
> with Intervals.Floats;
> package Float_Intervals is new Intervals.Floats (Float);
>
> Today I put Long_Float in between the parentheses instead of Float,
> tweaked a few things in my project and now I've got better precision.
> If I want to increase the precision, what else can in put in there?
> "digits 36"?

That's going to depend on the processor.  Generally, assuming that a
processor supports floating-point instructions, then your Ada compiler
will probably support whatever floating-point formats are natively
supported by that processor---but no others.  So if a processor has
support for 32-bit and 64-bit IEEE-754 floats, most likely you'll be
able to define floating-point types that will result in one of those
two floating-point formats---but you won't be able to get a better-
precision float just by asking for a whole bunch of "digits".  (Maybe
there are Ada compilers that support higher-precision floats than the
processor supports.  I don't know.)

                                  -- Adam





  parent reply	other threads:[~2007-12-05 16:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-05 11:39 ObjectAda and Long_Long_Float Grein, Christoph (Fa. ESG)
2007-12-05 13:12 ` axtens
2007-12-05 13:51   ` Georg Bauhaus
2007-12-05 16:17   ` Adam Beneschan [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-12-05 11:15 Grein, Christoph (Fa. ESG)
2007-12-05  9:27 axtens
2007-12-05 11:24 ` Martin Krischik
2007-12-05 11:30 ` petter_fryklund
2007-12-07  6:45   ` Simon Wright
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox