PDA

View Full Version : Floating Point Arithmetic



d2_s
04-04-2006, 12:40 AM
Is it possible to do floating point calculations?

I noticed that when you use the divide operator in an expression it will only caluclate a non-zero result when the left side is greater than or equal to the right side, for exmaple 55555 / 5 will yield non zero result, whereas, 45 / 100 will yield zero as its result ... implying that floating point calculations are not valid.

Is this correct? If not how can one perform floating point arithmetic?

There doesn't seem to be anything in the help files in regards to this or in regards to what is possible with equations in general.
In addition (if floating point arithmetic is possible) how is truncation, rounding handled?

Thanks again.

linder
04-04-2006, 04:09 AM
Hello,

The scripting language does not support floating point calculations. I think this is missing in the documentation.

45 / 100 returns 0

9 / 4 returns 2

Thanks,

d2_s
04-04-2006, 05:57 PM
Hello,

The scripting language does not support floating point calculations. I think this is missing in the documentation.

45 / 100 returns 0

9 / 4 returns 2

Thanks,

Thanks again Friedrich!