A different type of IEEE single format

41 Views Asked by At

To practice with different kinds of IEEE single format types, I am trying a format where the width of the exponent field is $4$ instead of $8$ and the width of the fraction field is $4$ instead of $23$.

I realize that the exponent bias for this system will be $2^{4-1}-1=7$ and the machine epsilon will be $2^{-4}$. Through this, I realize that the smallest positive normal floating point number in this system will be $\left(1.0000..\right)_2\cdot 2^{-6}$ and the largest positive normal floating point number in this system will be $\left(1.1111..\right)_2\cdot 2^7$.

Firstly, I just want to make sure whether what I have done above is correct?

Secondly, I want to see if all integer numbers between the smallest and largest positive normal floating point numbers above can be stored exactly in this floating point system (in other words, they do not need to be rounded). If so, I want to prove it, and if not, I want to find a counterexample.

And thirdly, I want to see what the largest floating point number smaller than $2$ is in this system.

Unfortunately, I am encountering some problems with the last two steps. I understand the foundations that come beforehand but am struggling to put it together.

I would greatly appreciate any advice!