[metapost] Accuracy of numbersystem double

Daniel H. Luecking luecking at uark.edu
Tue Feb 11 20:06:34 CET 2014

On Tue, Feb 11, 2014 3:00 AM, <taco at elvenkind.com> wrote:
>On 10 Feb 2014, at 22:21, Daniel H. Luecking <luecking at uark.edu> wrote:
>> (1) I assume a double is stored in binary format with some fixed
>> number of significant binary places. If not, I'd be pleased to
>> know that.
>The numbersystem ‘double’ is a standard C language ‘double’. On
>all modern systems that should translate to EEE 754 double-precision
>binary floating-point format binary64.

Thank you for the appropriate search terms. If I understand the 
Wikipedia article, the answer is "yes" ...

>> (2) If so, how many binary places? It seems 52, but I'd like to know for sure.

...and again "yes".

>> (3) So: is there a way to display accurate values of variables in
>> numbersystem double?
>It would be quite straightforward to change ‘decimal’ so that it matches
>the input reader ?

I would consider that (or some other primitive like that) a big plus.


Daniel H. Luecking
Department of Mathematical Sciences
University of Arkansas
Fayetteville, Arkansas

More information about the metapost mailing list