Sunday, 16 October 2016

Floating Point Questions

A normailised floating point representation uses a 7-bit mantissa and a 5 bit exponent, both stored using two's compliment format.

a) In binary, write the most negative number that can be represented using this normalised floating point system in the boxes below:
1.000000 10000

b) This is a floating point representation of a number:
1.010100 00110

calculate the denary equivalent  of the number. show you have arrived at your answer.

00110 = 6 

1010100 = -44

c) write the normalised floating point representation of the denary value 416 in the boxes below. show you have arrived at your answer.
416
110100000
0.110100 01001

d) write the normalised floating representation of the negative denary -12.5 in the boxes below. show you have arrived at your answer.
-12.5
100111
4 places
1.001110 00100

e) the table below lists three calculations that might cause an error to occur in a floating point system.

complete the table below by stating the name of the type of error that may occur for each calculation. you should not give the same answer more than once
overflow
underflow
cancellation error.

2) a normalised floating point representation uses an 8-bit mantissa and a 4-bit exponent, both stored using two's complement format

a) in binary, write the largest positive number that can be represented using this normalised floating point system in the boxes below.

0.1111111 0111

b) this is a floating point representation of a number.
1.0101000 0011

calculate the denary of the number, showing how you have arrived at your answer.
0011 = 3
1010.1000
-8+2+0.5 = -5.5

c) write the normalised floating point representation of denary value 13.625 in the boxes below
01101101
0.1101101 0100

d) write the normalised floating point representation of the denary value 0.3475 in the boxes.
0.01011
0.10111000 1111

e) Explain what overflow is give an example of a situation which might cause overflow to occur

An overflow occurs when both values of the same bits cause a new value 1 more bits.

3) the binary pattern 1001 1000 0100 can represented is a number of different ways.

a) convert the binary pattern to hexadecimal
1001-9 1000-8 0100-4

b) what is the decimal value if the binary pattern represents BCD?
B-1011 C-1100 D-1101

c) the above binary pattern represents a normalised two's compliment floating point number with an eight bit mantissa followed a 4 exponent.

i) state the value in denary
-13

ii) Give One reason for storing floating point numbers in normalised form.
it is more precise

ii) how does the above binary pattern indicate that the floating point number is normalised
0.1111111 0111

4) the decimal number 57 is entered on a keyboard in the form ASCII characters 5 and 7 these are stored in the computer's memory
00110101
00110111
a) express these binary values as hexadecimal
35/37
b) express these binary values in denary
54/55
c) show how the decimal value 57 could be stored as a signed integer using two's compliment in 8 bits.
00111001
d) show 57 in a normalised floating point.
0.1110010 00000110




  

No comments:

Post a Comment