1.090516455488E9 / 1000000.000 ???
Tim Roberts
timr at probo.com
Wed Mar 29 02:31:12 EST 2006
"Math" <mathweijzen at home.nl> wrote:
>
>Thanks this does the job
>And yes, I really need this accuracy..
Then you need to understand that you don't really HAVE this accuracy. You
are fooling yourself. 1090.516455488 cannot be represented exactly in
binary, just like 1/3 cannot be represented exactly in decimal. Further,
the more arithmetic you do, the less precise is your result.
Floating point is a very tricky world of approximation.
--
- Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the Python-list
mailing list