How to set calculation with the highest possible accuracy?
- Eugene Lutsenko
- Posts: 1649
- Joined: Sat Feb 04, 2012 2:23 am
- Location: Russia, Southern federal district, city of Krasnodar
- Contact:
How to set calculation with the highest possible accuracy?
How to set calculation with the highest possible accuracy? I used SET DECIMALS TO 15, but I have such impression that 0.99 is perceived as 1. Please...
Re: How to set calculation with the highest possible accurac
SET DECIMALS has nothing to do with calculation precision. SET DECIMALS and SET FIXED just set the number of digits behind the comma when numbers are displayed (maybe using "? in CRT mode).
Since Xbase++ only knows the datatype "numeric", which always is a 64-bit floating number (IEEE), calculations should be almost precise for up to 16 digits behind the comma. When it comes to display numbers, a value like 0.9999999999 may show up as 1.0, depending on the format.
Since Xbase++ only knows the datatype "numeric", which always is a 64-bit floating number (IEEE), calculations should be almost precise for up to 16 digits behind the comma. When it comes to display numbers, a value like 0.9999999999 may show up as 1.0, depending on the format.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."