The Gateway to Computer Science Excellence
0 votes

The following is a scheme for floating point number representation using 16 bits.

Bit Position 15 14 .... 9 8 ...... 0
  s e m
  Sign Exponent Mantissa

 Then the floating point number represented is:


                                                        (−1)s(1+m×2−9)2e−31 ,     if the exponent ≠111111


                                                             0, otherwise


What is the minimum difference between two successive real numbers representable in this system?


Any help to solve this question is appreciated.

in Digital Logic by Loyal (8.4k points) | 120 views

1 Answer

0 votes
let n1=$(-1)^{s}\ast(1+m1\ast 2^{-9})\ast 2^{e-31}$

let n2=$(-1)^{s}\ast(1+m2\ast 2^{-9})\ast 2^{e-31}$

difference=$(-1)^{s}\ast((m2-m1)\ast 2^{-9})\ast 2^{e-31}$     ...........(1)

now for consecutive m2-m1=1
so difference=$2^{e-40}$. to get minimum e=100000,so difference=$2^{-72}$
by Active (2.8k points)
edited by

How changing the exponent gives the minimum difference can you please explain? Also how are they successive..

i am corrected my answer check it now.


This  (−1)s(1+m×2−9)2e−31 is valid only if  the exponent ≠111111 and you have taken the value of e=111111.

oh,it's my mistake,i think my approach is true.
@BASANT KUMAR , minimum difference  will be there  when we take numbers very close to zero on number line.. so, here for 1st minimum , e = 0 and m = 0 and for 2nd minimum , e =0 and m =1 we have to put it in the given formula and  after subtraction , we will get the answer...
@Ankit gupta,this is true for positive number that minimum no. Is occurs close to zero,i am giving min value for negative number which is far away from zero.
@BASANT KUMAR  , Difference is an absolute(modulus) value. It can't be negative. It shows gap between two numbers. For difference of two numbers, we have to subtract small number  from a big number. When you go far away from zero either positive side or negative side, difference will be getting big. Difference will be minimum when two numbers are very closed to zero on real number line.
by putting e=0 ,difference=2^-40 and by putting e=-32 ,difference=2^-72 ,so minimum will occur at e=-32
why e = -32 ?
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,737 questions
57,317 answers
105,100 users