[Prev][Next][Index][Thread]

Re: Type theory vs floating-point arithmetic



Ross Casley wrote:

> At 09:14 PM 9/2/2003 -0700, Joe Darcy wrote:
>
>> For example, the value
>> "3.0" can be written as
>>
>>  0x1.8p1
>>
>> that is "1.8" as a hex string (i.e. 1.5 decimal) times 2 to the 1.  The
>> double floating-point value next larger than 3.0 is
>>
>>  0x1.800000000001p1
>>
>> and the number next smaller is
>>
>>  0x1.7999 9999 9999p1
>
>
> Isn't it 0x1.7FFFFFFFFFFFp1 ?


Yes; I mistakenly slipped into decimal in the midst of my hex example.

-Joe

References: