[amibroker] IEEE 754 Standard

 

Tomasz

 

I one of the previous conversations you had mentioned AB uses floats and that all integers upto 2^24 are represented accurately in floats. Is there a way around this issue (using mathematical tricks)? The following sum produces 268,460,128. The correct calculation is 268,460,113.

 

ic1 = 1;
ic4 = 16;
ic6 = 64;
ic13 = 8192;
ic14 = 16384;
ic28 = 268435456;
alliCs = ic1 + ic4 + ic6 + ic13 + ic14 + ic28;
_TRACE("alliCs: " + NumToStr(alliCs, 1.0));

__._,_.___

Posted by: "TA" <tagroups@sbcglobal.net>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)
**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/


.

__,_._,___


EmoticonEmoticon