Click here to Skip to main content
15,888,454 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello
I have a question about number systems and i am just a begginer who is learning different field of signal/image processing the wuestion is
(􀀀1)s  (1 + f )  2^(e-eb) :
The format has a word length of q bits, the length of the significand part representing
f is k bits, and the bias is eb (emax above is the maximum integer representable
with the bits allocated to the exponent).1
Let q=12 k=5 and eb=15, and determine the
word length p and the fraction length n of a fixed-point format (binary point scaling)
which can represent all values representable in the specified floating-point
format.?

I am not even sure if this is the right place to ask but anyways i am trying . If some has time to explain it to me or show me how to convert it i mean theoretically than i might code it.
Regards
Thank you so much
Posted

1 solution

Do you have a text book or any scripts from your lecture?
Lookup the terms there first, then understand the context of the formula, ask your teacher if you have any unclear items.

Check the internet for floating point standards, e.g. http://en.wikipedia.org/wiki/IEEE_floating_point[^].
Check what a fixed-point number is, e.g. http://en.wikipedia.org/wiki/Fixed-point_arithmetic[^]. See also floating point: http://en.wikipedia.org/wiki/Floating_point[^].
Cheers
Andi

PS: As a hint: the fixed-point number must be capable to store all values that the floating-point number can store. Find out first, what the maximum floating-point number is. Then the minimum (most negative value if it is about positive *and* negative numbers). Then find the number closest to zero (the smallest, the one with the highest negative exponent and taking in consideration the k bits that are even below that number).

I get roughly calculating something like 70 bits and the fixed point somewhere shy above 50.
 
Share this answer
 
v2
Comments
Sergey Alexandrovich Kryukov 22-Sep-13 20:38pm    
5ed.
—SA
Andreas Gieriet 23-Sep-13 0:49am    
Hello Sergey,
thanks for your 5!
Cheers
Andi
loraloper_22 22-Sep-13 23:17pm    
Well first thanks for at least directing me. I had a look so what i get is that i have an sign,exponent,and significand so in the above mentioned case my exponont is 6 bit since 1 bit is reserved for sign etc and 5 bits for significand now the number i can represent is 2^6 i-e 64 bit is this right approach? and now hhow should i proceed in fixed point format?
Andreas Gieriet 23-Sep-13 1:34am    
What is the largest positive, what is the largest negative, what is the smallest (closest to zero but different to zero) value of the floating point representation?
Once you have these values, decide how many bits you need to represent them. Fixed-point means, that you decide at which bit position is 2^0.

Now to your example: since your bias is 15, I must assume that your exponent range goes from -14 to 15, which means, you only have 5 bits for the exponent (see also http://en.wikipedia.org/wiki/Exponent_bias). With the other numbers given, you have 6 bits for the significand.
Cheers
Andi

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900