"Michael B. Trausch" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
> Let's say that I want to work with the latitude 33.6907570.  In Python, 
> that number > can not be stored exactly without the aid of 
> decimal.Decimal().

> >>> 33.6907570
> 33.690756999999998
> >>>

> As you can see, it loses accuracy after the 6th decimal place.

No, it loses accuracy in the 15th decimal place, which is the 17th digit.
This is far more accurate than any measured latitude could be.
If the above is a measurement, it represents anything from 33.69075695
to 33.69075705.  The conversion error would have to be multiplied by some 
number of millions before it would be visible in the 7th decimal place 
(your last).

Any trigonometric calculations will use an *approximate* value of pi and 
polynomial *approximations* of the theoretical functions.

Perhaps you have been given impossible conditions to fulfill.

Terry Jan Reedy



-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to