Seven years ago, after studying what Prof. Kahan of UC Berkeley was writing (he’s the father of the IEEE FP Standard), I strove very hard to make sure that NML would be IEEE FP Compliant. I took great care to recognize the difference bewteen -0.0 and +0.0.
Prof. Kahan used a conformal mapping problem solving the hypersonic fluid flow from an orifice, called the Borda problem, to illustrate the shortcomings of MatLab, c.a., 1999. I don’t know if MatLab still has this ``problem’’ or not, but NML doesn’t.
Here is the NML code for the Borda problem, and here is the result of the calculation:
That red curve at the bottom is the problem contour for non-IEEE Compliant languages. In those languages, that flow line crosses upward across the other flow lines -- something that is physically impossible.
At first I was elated that all my painstaking care had paid off, until Xavier Leroy, who is the father of OCaml, pointed out that there were other cases on other Riemann surfaces that would still be computed incorrectly.
Indeed, branch cuts in the complex plane can be placed arbitrarily, according to one’s best interests, and those defined by the IEEE FP Standard are as arbitrary as any others.
So in the end, it really isn’t any big deal unless your problem demands proper behavior along the IEEE FP-defined branch cuts. In that case, you should take care to program around them, just like you should take care with NaN’s and infinities, if they matter to you.