[comp.arch] Division by zero

bruceh@sgi.com (Bruce R. Holloway) (12/01/90)

In article <KHB.90Nov26115431@chiba.Eng.Sun.COM> khb@chiba.Eng.Sun.COM (Keith Bierman fpgroup) writes:
>
>In article <AGLEW.90Nov26130207@cobra.crhc.uiuc.edu> aglew@crhc.uiuc.edu (Andy Glew) writes:
>
>   Hmmm.... what should a spreadsheet do when the user has said to
>   divide by 0?
>
>If memory serves, the solution is already published,

in the IEEE spec, right?

>                  +Inf      x is positive
>	x/0 ==      NaN      x is zero
>                  -Inf      x is negative

This is a little disappointing, and would disappoint your calculus teacher,
since you don't know whether the denominator approached zero from the right
or from the left.  It is reassuring to note that dividing by -0 produces

>                  -Inf      x is positive
>	x/-0 ==     NaN      x is zero
>                  +Inf      x is negative

Regards, bruceh