Anybody know why this is, and more importantly, what the most practical
workaround?
Arbitrary fractional exponents were not defined for Rexx or NetRexx
because all the arithmetic operators are correctly rounded, and at the time Rexx
and NetRexx were written no algorithm for a correctly rounded power
operator was known. Recently it has been proven it is possible to
correctly round the operation but no upper bound on execution time has been
proven.
Hence I'd still say that it's best to use a function which can then
be defined as 'usually correctly rounded' and improve it later
perhaps.
Since you cannot guarantee an exact/precise result in this case you
may as well convert to doubles and use Java's Math.pow
method.
(If the fractional part is only 1 or 2 digits always I think there's
a workaround where you multiply it by (say) 100 to make it an integer, raise to
the integer power and then take the 100th root. Or something like that ...
it's a long time since I looked at this.)
Mike
_______________________________________________
Ibm-netrexx mailing list
[hidden email]
Online Archive :
http://ibm-netrexx.215625.n3.nabble.com/