Re:1/0 = 0 (2018)
by MereInterest on Monday December 02, 2024 @06:40AM
(#42295220)
Technically, it is possible for floating-point Inf to stop propagating prior to the final result, depending on the operation. For example, 1/Inf produces zero, as does exp(-Inf).
But those are cases where the larger a value is, the less is contributes to the final value.
I don't think so, because getting 0 in a larger expression might yield a result that looks plausible, leading to hidden bugs. Inf and NaN both are good because they necessarily propagate all the way up to the end result, making it obvious that something went wrong.