Hacker News new | ask | show | jobs
by jlgustafson 3986 days ago
First of all, a correction: the 4-bit unums can represent any of

-inf, (-inf, -2), -2, (-2, -1), (-1, 0), 0, (0, 1), (1, 2), 2, (2, inf), inf, and both quiet and signaling NaN. They do not represent ±1/2 or use ±1/2 as an endpoint.

If you add, say, 1 to (1,2), you get (2, inf). The open interval means it does not CONTAIN infinity, but ends at a finite value too large to represent. If the largest positive real you can represent is 2, then (2, inf) is a mathematically correct answer.

2 comments

D'oh, missed the NaNs and wrote out a list without referring to the book... then checked the length of the list to make sure it had 8 things. Silly me!
Your list should include -1 and 1 as well, shouldn’t it?

Edit: here was the slide http://i.imgur.com/0eQvvK1.png

Those would be among the 3-bit unums.