1/22
Vocabulary flashcards covering signed-magnitude, 2's complement, and 1's complement representations, their addition rules, and example interpretations from the lecture notes.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Signed Magnitude System
A binary representation using a sign bit to indicate positive or negative, with the remaining bits encoding the magnitude.
Sign Bit
The most significant bit that denotes the sign of a signed number (0 = positive, 1 = negative).
Magnitude
The absolute value portion of a signed number, represented by the bits excluding the sign bit.
Same-Sign Addition (Signed Magnitude)
If the signs are the same, add the magnitudes and give the result the common sign.
Different-Sign Addition (Signed Magnitude)
If signs differ, subtract the smaller magnitude from the larger and give the result the sign of the larger magnitude.
Subtraction in Signed Magnitude
Performed by treating subtraction as addition with the appropriate sign changes (A − B = A + (−B)).
2's Complement System
A signed-number representation where negative numbers are formed by inverting all bits of the magnitude and adding one; addition is plain binary addition with wrap-around and any final carry is discarded.
Negative Number in 2's Complement
A negative value is represented by its two's-complement bit pattern (invert bits, add one).
2's Complement Addition
Add the two n-bit representations including sign bits; discard any final carry out.
Overflow in 2's Complement
Occurs when the true result cannot be represented in the chosen bit-width; in practice, this is detected when the sign of the result is not consistent with the inputs.
1's Complement System
A signed representation where negative numbers are the bitwise NOT of the magnitude; addition may require an end-around carry to obtain the final result.
End-Around Carry
In 1's complement addition, the final carry is added back to the least significant bit to produce the correct result.
Comparison in Signed Magnitude
First compare signs; if signs are the same, compare magnitudes; if signs differ, the larger magnitude determines the result sign.
Example: (+25) + (−37) (Signed Magnitude)
Result is −12 because larger magnitude is 37; difference is 12 with the sign of the larger magnitude.
Example: (+11) + (+17) (Signed Magnitude)
Result is +28 since signs are the same and magnitudes add.
Example: (−11) + (+17) (Signed Magnitude)
Result is +6; larger magnitude is 17 with positive sign, difference 17−11.
Example: (+6) + (−6) (2's Complement)
Sum is zero; oppostie numbers cancel to 0 in 2's complement representation.
7-Representation in Examples (8-bit 2's Complement)
−7 can be represented as 11111001 in 8-bit 2's complement (example from notes).
Rule for 2's Complement Addition (Key Concept)
For signed numbers in 2's complement, addition is performed as binary addition including sign bits; any carry out is discarded.
Zero Representation in 2's Complement
Zero is represented by all zero bits; negative results wrap around into their 2's-complement form.
5-Bit Demonstrations (notation in notes)
The notes show multiple 5-bit examples to illustrate addition/subtraction in different representations.
Signed Arithmetic in 2's Complement (Summary)
All signed numbers are represented in 2's complement; addition works directly on bit patterns with carry-out discarded.
End-Point Rule (General)
In signed arithmetic, overflow is not indicated by a separate flag in these notes; discard the final carry and interpret the result within the bit-width.