[Python-ideas] Python Numbers as Human Concept Decimal System

Terry Reedy tjreedy at udel.edu
Sat Mar 8 07:14:46 CET 2014


On 3/7/2014 2:20 PM, Guido van Rossum wrote:


> However, for the growing contingent of scientists who use Python as a
> replacement for Matlab (not Mathematica!), it could be a big nuisance.
> They don't care about decimal issues (they actually like binary better)

One reason knowledgeable users of floating point numbers as 
approximations like binary better is that the binary floating point 
system is much 'smoother' than the decimal floating point system. For 
example, with 3 decimal digits, consider .999, 1.00, 1.01. The first 
difference is .001, the second is .01, 10 x larger.  This is one of the 
problems of working with base 10 slide rules. For binary, the largest 
ratio between differences is 2 rather than 10.

> and they write lots of C++ code that interfaces between CPython's
> internal API and various C++ libraries for numeric data processing, all
> of which use IEEE binary.

This too ;-).

-- 
Terry Jan Reedy



More information about the Python-ideas mailing list