Dark Mode

17,649 views

44 votes

Consider the following floating-point number representation.$$\begin{array}{c|c}

\begin{array}{cc}31\;\;\hspace{15pt}&\hspace{15pt}24\end{array} & \begin{array}{cc}23\hspace{15pt}&\hspace{15pt}0\end{array} \\\hline

\text{Exponent}&\text{Mantissa}\\ \hline

\end{array}$$The exponent is in $2’s$ complement representation and the mantissa is in the sign-magnitude representation. The range of the magnitude of the normalized numbers in this representation is

- $0$ to $1$
- $0.5$ to $1$
- $2^{-23}$ to $0.5$
- $0.5$ to $\left(1-2^{-23}\right)$

53 votes

Best answer

Here, we are asked "magnitude" - so we just need to consider the mantissa bits.

Also, we are told "normalized representation"- so most significant bit of mantissa is always 1 (this is different from IEEE 754 normalized representation where this 1 is omitted in representation, but here it seems to be added on the right of decimal point as seen from options).

So, the maximum value of mantissa will be 23 1's where a decimal point is assumed before first 1. So, this value will be $1-2^{-23}$.

Due to the 1 in normalized representation, the smallest positive number will be 1 followed by 23 0's which will be $2^{-1} = 0.5.$

So ans d.

the maximum value of mantissa will be 23 1's where a decimal point is assumed before first 1. So, this value will be 1−2−23.

The Mantissa field is of 24 bits. So it should be : $ .111...1 (24 \ 1’s) = 1-2^{-24}$.

Hence range must be from $ 0.5 \ to \ 1-2^{-24}$ (a/c to this selected answer where we have taken normalized rep and not IEEE rep).

Please correct me if I am wrong.

0

24 votes

Given that mantissa is sign magnitude representation so 1 bit for sign and remaining 23 bits for mantissa

and we have to find the range of mantissa in normalized form ....

so smallest will be = .100.....0(normalize form) which is 2^(-1) = .5

and for largest will be .111....1 which is 1-2^(-23) .

so range will be .5 to (1-2^(-23))

and we have to find the range of mantissa in normalized form ....

so smallest will be = .100.....0(normalize form) which is 2^(-1) = .5

and for largest will be .111....1 which is 1-2^(-23) .

so range will be .5 to (1-2^(-23))

0