Gap between numbers in fixed-point vs. floating point arithmetic If $r$ is a machine-representable number and $f(r)$ is the next larger machine representable number, are the following true or false?


In fixed-point arithmetic, the distance between $r$ and $f(r)$ is constant.
In floating-point arithmetic, the relative distance $|(f(r)-r)/r|$ is constant.


I believe that (1) is true, but I'm not sure about (2).  I am new to the world of numerical analysis and I'm just trying to hang on for dear life.  Could anybody point me to a resource that does a good job of explaining the basic introductory topics of machine mathematics?
Yes, the difference is constant.
It is not really constant, but approximately, yes.  With exceptions.


With binary floating point numbers, the expression $(f(r)−r)/r$ is constant within a factor of $2$.  It is between $1 \over 2^m$ and $1 \over 2^{m-1}$ where m is the number of bits in the mantissa.  For rounding error calculations, you can assume it is constant.

A note on 0:
Obviously, you cannot apply the formula when $r=0$.  But it is important to know that while $f(r)-r$ decreases when $r$ becomes small, $f(0)-0$ is much larger than, for instance, $f(f(r))-f(r)$.  There is a huge non-representable gap around $0$.