Please create an account to participate in the Slashdot moderation system


Forgot your password?
For the out-of-band Slashdot experience (mostly headlines), follow us on Twitter, or Facebook. ×

Comment: Re:x/0 does not equal 0. (Score 1) 1064 1064

Well, I am sorry, but you are factually wrong about this. Your "proofs" show that division by zero may be undefined for some cases, which does not change the fact that it is quite well defined for some other cases. IEEE 754 is quite clear on that too. You may wish to eduacte yourself beyond pre-calc before sounding off.

Comment: Re:Sounds like a plan! (Score 1) 1064 1064

Well, no, I did not. If the result Inf occurs in computations that must be passed to control mechanisms, it must be caught at this point, and not where it occured. Throwing exception on arithmetic operation is bad idea that seems good if you do not think about it carefully. Which authors of IEEE754 did, and produced a very good standard.

Comment: Re:I want my division by zero errors to be errors (Score 1) 1064 1064

Fortunately, your vote did not count when IEEE754 was created by the top numerical experts. Unfortunately, far too many programmers are voefully ignorant about proper FP math.

> And how many times exactly have you been happy to get "Infinity" as a result?
> Pretty much every time I've gotten that there has been an error in my logic.

I believe you that there're lots of errors in your logic. One of them is ignoring mathematical fact that 1/0=Inf as per IEEE standard implemented in hardware by (virtually) all modern processors

Comment: Re:Sounds like a plan! (Score 1) 1064 1064

The code that generated an exception was not useful by the time rocket left the launch pad. Yet because the designers, like you, incorrectly thought that division by zero must throw an exception, the flight controller crashed, and with it, the rocket.

Comment: Re:Sounds like a plan! (Score 1) 1064 1064

No, you are wrong that the error was in the code handling flight trajectory computations. It was in the part of software that was needed before the launch, and not at all during the flight. The results of that computation were not needed for guidance, and yet unhandled exception caused the controller to crash.

Secondly, you are wrong when you assume that the division by zero is necessarily an error. There are valid and useful numerical algorithms that rely on division by zero being well-defined operation.

Comment: Re:I want my division by zero errors to be errors (Score 1) 1064 1064

Wrong wrong wrong misguided and wrong again. division of non-zero by zero is quite meaningful and is defined by IEEE standard for floating point arithmetic to return infinity (wtih appropriate sign depending on the signs of the zero and numerator).

In the rare cases when exception is needed IEEE compliant fp math implementation provides mechanism for it

Gravity brings me down.