comp.lang.ada
 help / color / mirror / Atom feed
From: Bryan@SIERRA.STANFORD.EDU (Doug Bryan)
Subject: Re: The AFT Attribute
Date: Wed, 24-Sep-86 01:11:16 EDT	[thread overview]
Date: Wed Sep 24 01:11:16 1986
Message-ID: <12241395032.15.BRYAN@Sierra.Stanford.EDU> (raw)
In-Reply-To: 350@cullvax.UUCP


Dale brings up a few more interesting points concerning 'Aft.  Consider:

	type Fix is delta 1.0 / 3.0 range 0.0 .. 1.0;

Given the definition of Aft, Fix'Aft must return 1.  As Dale points out,
there is no way to exactly represent Fix'Delta in any finite number of digits.
It is interesting to note that Aft is defined in terms of delta, not small.
Thus Aft may not reflect the precision of the actual model numbers of the
type. (?)

Perhaps our question can more precisely be stated as follows:

        What was the rationale for defining Aft to return the smallest 
	positive integer N such that (10 ** N) * T'Delta >= 1?

Why was T'Small not used?  Surely T'Aft is not enough digits to precisely
display the decimal form of a model number of T. (We need
not even consider representation clauses.)  Is Aft sufficient digits
to display the model numbers of T such that one does not display the
same value more than once?

	type T is delta 1.0/16 range 0.0 .. 1.0;
	T'Aft = 2

let us look at some model numbers...

	0.0625	0.125	0.1875	0.25
	
If one were to print these model numbers using 
Put (X, Fore => 2, Aft => T'Aft, Exp => 0), we would see:

	0.06	0.12	0.18	0.25

No values are repeated.  Is this the intended use for 'Aft? 

Has anybody ever used 'Aft?  How  (campers) ?

doug and geoff
-------

  reply	other threads:[~1986-09-24  5:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1986-09-16  0:32 The AFT Attribute Geoff Mendal
1986-09-22 20:38 ` Dale Worley
1986-09-24  5:11   ` Doug Bryan [this message]
     [not found] <20@<12239247219>
1986-09-22 12:44 ` stt
1986-09-24 15:13 ` 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