comp.lang.ada
 help / color / mirror / Atom feed
From: murphy@beatnix.UUCP (Michael Murphy)
Subject: Re: Ada decimal elaboration, further experimentation.
Date: 5 Jul 88 23:39:35 GMT	[thread overview]
Message-ID: <835@elxsi.UUCP> (raw)
In-Reply-To: 7576@boring.cwi.nl

The more serious problem here which is what *really* causes the bad
numbers is that most (all?) Ada compilers only support fixed point numbers
that are a power of two.  So despite the type declaration with a
delta of 0.01, the actual delta used is 0.0078125 (2e-7).  This makes
decimal arithmetic using fixed point unworkable.

-- Michael Murphy

P.S.  The VADS 5.5 compiler for the ELXSI prints out 0.10 for all
my_dime calculations (constant or not) because they are all done with 
universal arithmetic, but your_dime is 0.08 for the above reason.

  reply	other threads:[~1988-07-05 23:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1988-07-03 18:49 Ada decimal elaboration, further experimentation CONTR47
1988-07-03 23:36 ` Dik T. Winter
1988-07-05 23:39   ` Michael Murphy [this message]
1988-07-09 19:22     ` Ada decimal elaboration, furthe stt
replies disabled

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