Questions tagged [number-systems]
5 questions
2
votes
1 answer
Verilog signed numbers representation
I am confused as to when the '-' sign is used and when 's' is used. This post is somewhat helping, although not entirely.
Please correct if I am wrong:
For example, to interpret 8'sd244, we write 244 in binary = 11110100. Now it is signed, so the…

SM32
- 366
- 2
- 12
1
vote
2 answers
Problem with the smallest negative number using Signed-2's-Complement
I have a problem figuring out why the smallest negative number we can represent in 3 bits, using Signed-2's-Complement is -4.
I understand that in S2C format, we can create numbers from 2x-1-1 (Highest Positive Number) to -2x-1 (Smallest Negative…

Ali A
- 11
- 1
1
vote
2 answers
Subtraction using 2's complement, why 4, 8 or 16 bit are required
During subtraction using 2's complement, why it is important to decide on the number of bits we are going to use, (e.g. 4 bit, 8 bit, 16 bit etc) and use the same number of bits to write each number.
For example:
Question: (-2-5) base 10
…

TapasX
- 405
- 3
- 17
0
votes
1 answer
Bits are toggled in step 1 or 9's complement is done using subtraction?
In base 2, I want to subtract x-y using adder. Where, x = (1011)2 and y = (0101)2
[For verification, in decimal x=(11)10, y = (5)10. So, we are seeking (6)10 as the answer ]
In base 2 using adder we are looking for (1011)2-(0101)2 = (?)2
Or,…

Ubi.B
- 135
- 5
-2
votes
1 answer
Why do we write the integer part from top to bottom and not the other way?
While converting the fractional part of a decimal number to another number system, why do we write the integer part from top to bottom and not the other way?
Since the fractional part is 0, the multiplication is stopped. Writing the integer part…

Anshul Gupta
- 385
- 3
- 12