# Help: Floating Point Exam Question

Watch
Announcements
#1
I got part b of this question wrong in my test. I didn't know how to work it out so I guessed. Can anyone explain how to get the right answer?
I feel like it's meant to be 00000001 in the mantissa and 1000 in the exponent. I don't have a method tbh. I just tried to get the most negative exponent and the smallest number in the mantissa. Am I on the right track?
Last edited by niclawrence01; 1 year ago
0
1 year ago
#2
The exponent in floating-point arithmetic doesn't use two's complement, instead, the exponent is already negative-biased. Therefore unlike two's complement, the smallest possible negative exponent is represented by all-zeroes in binary.

So the smallest possible value that can be stored using a 4-bit exponent would be represented by decimal -7 which is binary 0000

There's not really any method to answering that question though - it's just a matter of whether or not you understand that the exponent is negative-biased.

However, you're right that the mantissa would be binary 00000001 which is a decimal value of 2^(-8).

(and together, those would give you a decimal value of 2^(-8) * 2^(-7) which of course is equal to 2^(-15).)
0
#3
(Original post by winterscoming)
The exponent in floating-point arithmetic doesn't use two's complement, instead, the exponent is already negative-biased. Therefore unlike two's complement, the smallest possible negative exponent is represented by all-zeroes in binary.

So the smallest possible value that can be stored using a 4-bit exponent would be represented by decimal -7 which is binary 0000

There's not really any method to answering that question though - it's just a matter of whether or not you understand that the exponent is negative-biased.

However, you're right that the mantissa would be binary 00000001 which is a decimal value of 2^(-8).

(and together, those would give you a decimal value of 2^(-8) * 2^(-7) which of course is equal to 2^(-15).)
Can you explain how 0000 is - 7 please?
0
1 year ago
#4
(Original post by niclawrence01)
Can you explain how 0000 is - 7 please?
It's negative-biased, and based on the smallest possible number which can be represented with a signed 4-bit exponent which is -7

I.e. instead of using binary to count from zero upwards, binary is used to count from -7 upwards.

So:
0000 is -7.
0001 is -6
0010 is -5
0011 is -4
etc.
Last edited by winterscoming; 1 year ago
0
#5
OK thanks for the help
0
X

new posts Back
to top
Latest
My Feed

### Oops, nobody has postedin the last few hours.

Why not re-start the conversation?

see more

### See more of what you like onThe Student Room

You can personalise what you see on TSR. Tell us a little about yourself to get started.

### Poll

Join the discussion

#### With no certainty that exams next year will take place, how does this make you feel?

More motivated (88)
30.88%
Less motivated (197)
69.12%