I'm not the math uncle, but a real one told me this:
"use fixed point instead of floating
point to do multiplication, division,
summation, trigonometry and
integration"
So instead of using double or float data types, what shall I do? Does anyone have a handy snippet or link that shows the difference for non-math-uncles?
Jhaliya - Praveen Sharma :
Check the below for link for fixed point, I'm sure will be useful for you ...\n\nhttp://cnx.org/content/m11054/latest/\n\nhttp://www.digitalsignallabs.com/fp.pdf",
2011-04-01T09:23:22
Lindydancer :
The language itself does not support anything except integers and floating-point values. However, you can easily simulate fix-point values by integers. If you, for example, decide that you want a fix-point value with three decimals, you can use, for example 12345 to represent 12.345. Addition is straight forward, and you can surely work out how to express the other basic operations.\n\nHowever, there is no support for doing trigonometry etc.",
2011-04-01T09:21:34