54
Digital Electronics
Case 2
• Let us subtract +24 from +14.
• The 2’s complement representation of +14 = 00001110.
• The 2’s complement representation of +24 = 00011000.
• The 2’s complement of the subtrahend (i.e. +24) = 11101000.
• Therefore, +14 − (+24) is given by
00001110
+ 11101000
11110110
• The decimal equivalent of (11110110) 2 , which is of course in 2’s complement form, is −10 which
is the correct answer.
Case 3
• Let us subtract −14 from +24.
• The 2’s complement representation of +24 = 00011000 = minuend.
• The 2’s complement representation of −14 = 11110010 = subtrahend.
• The 2’s complement of the subtrahend (i.e. −14) = 00001110.
• Therefore, +24 − (−14) is performed as follows:
00011000
+ 00001110
00100110
• The decimal equivalent of (00100110) 2 is +38, which is the correct answer.
Case 4
• Let us subtract −24 from +14.
• The 2’s complement representation of +14 = 00001110 = minuend.
• The 2’s complement representation of −24 = 11101000 = subtrahend.
• The 2’s complement of the subtrahend (i.e. −24) = 00011000.
• Therefore, +14 − (−24) is performed as follows:
00001110
+ 00011000
00100110
• The decimal equivalent of (00100110) 2 is +38, which is the correct answer.
Case 5
• Let us subtract −14 from −24.
• The 2’s complement representation of −24 = 11101000 = minuend.
Précédent

- 75/741

Suivant