Consider a hypothetical computer using the number representation:
- base = 2; signed bit exists; 20 bit mantissa,
- first mantissa bit is always 1 except for representing zero;
- exponent $e$ belongs to $\Bbb Z$ (integers);
Find the smallest positive integer $n$ that does not belong to the representable numbers?
representation : signed_bit * 0.d1d2...d20 * 2^(e)
This is what I got, but could not understand it.
Between any two consecutive powers of $2$, there can be $2^{19} - 1$ equidistant numbers in this system. Therefore we need to set the gap between two successive numbers of this system to $2$ in order to satisfy the conditions of the question. This is possible when $2^{19} - 1$ equidistant numbers are positioned between $2^{p+1}$ and $2^p$ or the following is true $$(2^{p+1} - 2^p)/2^{19} = 2.$$ Solving this we obtain $p = 20$. Thus the smallest number missing from the number system of this machine is $2m + 1$.
The argument above also clearly indicates that as long as we take positive integers between $1$ and $2m$, they belong to the number system of the machine.
As the first bit of the mantissa is a one, it can represent all integer numbers between $2^{19}$ and $2^{20}-1$, scaled by $2^{-20}$ (hence between $2^{-1}$ and $1-2^{-20}$, i.e. $0.5$ to $\sim1$).
Now, as the exponent is said to belong to $\mathbb Z$, there is no upper nor lower limit ! This statement doesn't make sense for a machine representation. Assuming the minimum exponent to be $e_{\min}$, the smallest representable positive number is $2^{e_{\min}-1}$.