Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
DESIGN, VOLUME I
DIGITAL SYSTEMS
DESIGN, VOLUME I
Numbering Systems and Logical
Operations
LARRY MASSENGALE
Digital Systems Design, Volume I: Numbering Systems and Logical
Operations
10 9 8 7 6 5 4 3 2 1
KEYWORDS
List of Figures xi
List of Tables xv
Acknowledgments xvii
Figure 3.24. Logic symbol for NAND gate with inverter input 99
Figure 3.25. Truth table for NAND gate with inverter on input 99
Figure 3.26. Associative property for addition 100
Figure 3.27. Associative property for multiplication 101
Figure 3.28. Commutative property for addition and
multiplication 102
Figure 3.29. Distributive property of multiplication over addition 103
Figure 3.30. Boolean algebra properties 104
Figure 3.31. DeMorgan’s theorem − (A + B)′ = A′B′ 107
Figure 3.32. DeMorgan’s theorem − (AB)′ = A′ + B′ 107
Figure 3.33. Inverse use of DeMorgan’s theorems 108
Figure 3.34. Implementation of A + AB expression 109
Figure 3.35. Implementation of A + A′B expression 110
Figure 3.36. Implementation of A′ + AB expression 110
Figure 3.37. Implementation of A + A′B′ expression 111
Figure 3.38. Implementation of A′ + AB′ expression 112
Figure 3.39. Implementation of A′ + A′B′ expression 113
Figure 3.40. Sum of products configuration 114
Figure 3.41. Simplified sum of products configuration 114
Figure 3.42. Sum of products configuration 116
Figure 3.43. Simplified sum of products configuration 116
Figure 3.44. Low output expression 117
Figure 3.45. High output expression configuration 118
Figure 3.46. Low output expression with high output equivalent 118
Figure 3.47. Truth table for sum of products 119
Figure 3.48. Logic gate configuration for sum of products 119
Figure 3.49. Truth table for product of sums 119
Figure 3.50. Logic gate configuration for product of sums 120
Figure 3.51. Truth table for product of sums 120
Figure 3.52. Sum of products Logic Gate Configuration 121
Figure 3.53. Product of sums Logic Gate Configuration 122
Figure 3.54. Three-variable minterm and maxterm expansions 124
Figure 3.55. Four-variable minterm and maxterm expansions 124
Figure 3.56. Finding the minterms and maxterms 125
Figure 3.57. Identified truth table minterms and maxterms 125
List of Tables
I would like to thank my wife for providing inspiration and motivation while
writing this book. My children Michael and Holly were very instrumental
in keeping me on track to finish the text. Robert Solis, Bob Valencia, Sean
Tijerina, Mike Ormonde, Ming Ho, and Anthony Vernon, all engineers
who are employed by various organizations, provided excitement in get-
ting me started with this project. Two people get my overwhelming thanks
for coaching me on. One is a brilliant engineer who works with cyber
operations, Christy Vera, and the other is my long-time professor friend,
Dr. Wei-Ming Lin, who reviewed the book with his insightful comments
as always. Additionally, Dr. Margaret Wesner has been one of my greatest
supporters, giving me clarity, encouragement, and compassion when times
were rough for me during the writing of this book. Most of all, I give the
Lord Jesus Christ thanks for giving me the ability and knowledge to com-
prehend engineering subject matters.
CHAPTER 1
Numbering Systems
and Codes
1.1. INTRODUCTION
By comparing the decimal and binary numbers in Table 1.3, one can
count in binary. Adding up the sum of weights as follows will provide the
binary count.
24 23 22 21 20 ?
1 0 1 1 1 ?
(1 × 24) + (0 × 23) + (1 × 22) + (1 × 21) + (1 × 20) =
(1 × 16) + (0 × 8) + (1 × 4) + (1 × 2) + (1 × 1) =
16 + 0 + 4 + 2 + 1 = 23
000
001
010
011
100
101
110
111
24 23 22 21 20 ?
1 1 0 1 1 ?
(1 × 24) + (1 × 23) + (0 × 22) + (1 × 21) + (1 × 20) =
(1 × 16) + (1 × 8) + (0 × 4) + (1 × 2) + (1 × 1) =
16 8 + 0 + 2 + 1 = 27
Step 1: Start at the most significant bit (MSB) of the binary number to be
converted.
Step 2: Add 0 to the MSB.
Step 3: Multiply the sum by 2.
Step 4: Add the product to the next lesser significant bit.
Step 5: Continue repeating this process from Step 3 until the least signifi-
cant bit (LSB) is reached.
Note: Do not multiple by 2 after the product is added to the LSB. This last
addition produces the decimal equivalent of the binary number.
The sum of weights and radix division will need to be used when con-
verting binary fractions into decimal weights. Table 1.4 shows the negative
powers of binary and the positional weight for each binary bit listed.
0.1101(2) =
(1 × 2−1) + (1 × 2−2) + (0 × 2−3) + (1 × 2−4) =
(1 × 0.5) + (1 × 0.25) + (0 × 0.125) + (1 × 0.0625) =
0.5 + 0.25 + 0 + 0.0625 = 0.8125
6 • DIGITAL SYSTEMS DESIGN, VOLUME I
For example, we have the decimal number 12(10) and we want to find
the binary conversion. Using the aforementioned procedures we derive the
base-2 number as follows:
Numbering Systems and Codes • 7
Radix division uses the whole integer of the decimal number to con-
vert it into a binary number. What if we have a decimal fraction being
converted into a binary number? We would use radix multiplication. The
decimal fraction would be repeatedly multiplied by 2 until a product of 1
is obtained. This is the LSB of the binary number obtained. We will use
this method in converting 0.8125(10) into binary number 0.1101(2) in the
following procedure:
0.8125 0.1101(2)
×2
MSB 1.6250
×2
1.2500
×2
0.5000
×2
LSB 1.0000
We can use the sum of weights method again to convert the octal number
into the decimal number. From Table 1.6 we can see that 33(8) is converted
into 27(10). By the sum of weights method we can verify this is true as
shown in the following procedure:
8(1) 8(0)
3 3(8)
(3 × 8(1)) + (3 × 8(0)) =
(3 × 8) + (3 × 1) =
24 + 3 = 27(10)
Note: Do not multiple by 8 after the product is added to the LSB. This last
addition produces the decimal equivalent of the octal number.
For the octal fraction part of an octal number radix division can be
used. Let’s convert 0.788(8) into a decimal number: Table 1.7 provides the
octal fractions for some negative powers of 8.
As with the decimal to binary conversion, octal also uses radix division. The
following procedure explains how to convert the decimal integer into octal.
10 • DIGITAL SYSTEMS DESIGN, VOLUME I
135(10) =
135(10) = 207(8)
When converting an octal number into a binary number, the binary number
will be represented in three digits, as shown in the following procedure:
Numbering Systems and Codes • 11
Both the octal and binary numbers can be converted back into dec-
imal. We should get the same decimal number for the octal and binary
numbers if we performed the aforementioned operation correctly. Let’s
check:
11101110.11(2) =
011 101 110 . 110(2) =
3 5 6 . 6(8)
Both the sum of weights and radix multiplication can be used when
converting hexadecimal into decimal. Let’s convert 1CBE(16) into decimal
using both methods:
563(10) = 233(16)
0.75(10)
×16
12.00 = C
0.75(10) = 0.C(16)
Group into groups of three bits on each side of the hex point.
The following procedure identifies how to convert gray code into binary:
1110(G) = 1011(2)
The following procedure identifies how to convert binary into gray code:
1110(2) = 1001(G)
Two special codes will be mentioned: Excess-3 Code and American Stan-
dard Code for Information Interchange.
9 6
+3 +3
12 9
1100 1001(EX3)
96(10) = 1100 1001(EX3)
4 7 8
+3 +3 +3
7 10 11
0111 1010 1011(EX3)
478(10) = 0111 1010 1011(EX3)
0101 1001 1010(EX3)
5 9 10
−3 −3 −3
2 6 7(10)
0101 1001 1010(EX3) = 267(10)
Numbering Systems and Codes • 21
(continued )
22 • DIGITAL SYSTEMS DESIGN, VOLUME I
Table 1.14. (Continued )
Numbering Systems and Codes • 23
Table 1.14. (Continued )
(continued )
24 • DIGITAL SYSTEMS DESIGN, VOLUME I
Table 1.14. (Continued )
When adding alike base numbers, if a maximum count is achieved per col-
umn, a carry will be generated for the next column. This will be shown in
the following additions of numbers. We can use other numbering systems
to check our answers.
When subtracting alike base numbers, a borrow may be necessary from the
adjacent higher digit column. This will be shown in the following subtrac-
tions of numbers. We can use other numbering systems to check our answers.
a. 111(2)
Sum of Weights:
b. 1111(2)
Sum of Weights:
c. 1011.11(2)
Sum of Weights:
(1 × 23) + (0 × 22) + (1 × 21) + (1 × 20) + (1 × 2-1) + (1 × 2-2) =
8 + 0 + 2 + 1 + 0.5 + 0.25 = 11.75(10)
Radix Multiplication:
Numbering Systems and Codes • 31
Now we add in the fractional part of the binary number with the
whole part to get our final solution.
d. 111010(2)
Sum of Weights:
25 24 23 22 21 20
1 1 1 0 1 . 0
(1 × 24) + (1 × 24) + (1 × 23) + (0 × 22) + (1 × 21) + (0 × 20) =
(1 × 32) + (1 × 16) + (1 × 8) + (0 × 4) + (1 × 2) + (0 × 1) =
32 + 16 + 8 + 0 + 2 + 0 = 58(10)
Radix Multiplication:
e. 25(8)
Sum of Weights:
8(1) 8(0)
2 5(8)
(2 × 8(1)) + (5 × 8(0)) =
(2 × 8) + (5 × 1) =
16 + 5 = 21(10)
Radix Multiplication:
32 • DIGITAL SYSTEMS DESIGN, VOLUME I
f. 37(8)
Sum of Weights:
8(1) 8(0)
3 7(8)
(3 × 8(1)) + (7 × 8(0)) =
(3 × 8) + (7 × 1) =
24 + 7 = 31(10)
Radix Multiplication:
g. 63(8)
Sum of Weights:
8(1) 8(0)
6 3(8)
(6 × 8(1)) + (3 × 8(0)) =
(6 × 8) + (3 × 1) =
48 + 3 = 51(10)
Radix Multiplication:
h. 127.32(8)
Sum of Weights:
Radix Multiplication:
Now we add in the fractional part of the octal number with the
whole part to get our final solution.
i. AF(16)
Sum of Weights:
16(1) 16(0)
A F(16)
(A × 16(1)) + (F × 16(0)) =
(A × 16) + (F × 1) =
160 + 15 = 175(10)
Radix Multiplication:
j. 4A(16)
Sum of Weights:
16(1) 16(0)
4 A(16)
(4 × 16(1)) + (A × 16(0)) =
(4 × 16) + (A × 1) =
64 + 10 = 74(10)
34 • DIGITAL SYSTEMS DESIGN, VOLUME I
Radix Multiplication:
k. 7C.BE(16)
Sum of Weights:
16(1) 16(0) 16(-1) 16(-2)
7 C B E(16)
(7 × 16(1)) + (C × 16(0)) + (B × 16(−1)) + (E × 16(−2)) =
(7 × 16) + (C × 1) + (B × 0.0625) + (E × 0.0039063) =
112 + 12 + 0.6875 + 0.0546882 = 124.742(10)
Radix Multiplication:
l. 5FB(16)
Sum of Weights:
Radix Multiplication:
m. 1101001(2)
Sum of Weights:
26 25 24 23 .
22 21 20
1 1 0 1 0 0 1
(1 × 26) + (1 × 25) + (0 × 24) + (1 × 23) + (0 × 22) + (0 × 21) + (1 × 20) =
(1 × 64) + (1 × 32) + (0 × 16) + (1 × 8) + (0 × 4) + (0 × 2) + (1 × 1) =
64 + 32 + 0 + 8 + 0 + 0 + 1 = 105(10)
Radix Multiplication:
n. 1110000(2)
Sum of Weights:
26 25 24 23 22 21 20
1 1 1 0 0 0 0
(1 × 26) + (1 × 25) + (1 × 24) + (0 × 23) + (0 × 22) + (0 × 21) + (0 × 20) =
(1 × 64) + (1 × 32) + (1 × 16) + (0 × 8) + (0 × 4) + (0 × 2) + (0 × 1) =
64 + 32 + 16 + 0 + 0 + 0 + 0 = 112(10)
Radix Multiplication:
36 • DIGITAL SYSTEMS DESIGN, VOLUME I
o. 1101010(2)
Sum of Weights:
26 25 24 23 22 21 20
1 0 1 0 1 0
(1 × 26) + (1 × 25) + (1 × 24) + (0 × 23) + (0 × 22) + (0 × 21) + (0 × 20) =
(1 × 64) + (1 × 32) + (0 × 16) + (1 × 8) + (0 × 4) + (1 × 2) + (0 × 1) =
64 + 32 + 0 + 1 + 0 + 1 + 0 = 106(10)
Radix Multiplication:
p. 1010.111(2)
Sum of Weights:
(1 × 23) + (0 × 22) + (1 × 21) + (0 × 20) + (1 × 2−1) + (1 × 2−2) + (1 × 2−3) =
8 + 0 + 2 + 0 + 0.5 + 0.25 + 0.125 = 10.875(10)
Radix Multiplication:
Now we add in the fractional part of the binary number with the
whole part to get our final solution.
Numbering Systems and Codes • 37
q. 154(8)
Sum of Weights:
r. 632(8)
Sum of Weights:
s. 173.4(8)
Sum of Weights:
Radix Multiplication:
Now we add in the fractional part of the octal number with the
whole part to get our final solution.
t. 247(8)
Sum of Weights:
u. 3E(16)
Sum of Weights:
16(1) 16(0)
3 E(16)
(3 × 16(1)) + (E × 16(0)) =
(3 × 16) + (E × 1) =
48 + 14 = 62(10)
Radix Multiplication:
v. FAE.DB(16)
Sum of Weights:
16(2) 16(1) 16(0) 16(−1) 16(−2)
F A E D B(16)
(F × 16(2)) + (A × 16(1)) + (E × 16(0)) + (D × 16(−1)) + (B × 16(−2)) =
(F × 256) + (A × 16) + (E × 1) + (D × 0.0625) + (B × 0.0039063) =
3840 + 160 + 14 + 0.8125 + 0.0439693 = 4014.855(10)
Radix Multiplication:
40 • DIGITAL SYSTEMS DESIGN, VOLUME I
w. 2ED(16)
Sum of Weights:
x. 88EB(16)
Sum of Weights:
16(3) 16(2) 16(1) 16(0)
8 8 E B(16)
(8 × 16(3)) + (2 × 16(2)) + (E × 16(1)) + (B × 16(0)) =
(8 × 4096) + (8 × 256) + (E × 16) + (B × 1) =
32768 + 2048 + 224 + 11 = 35051(10)
Numbering Systems and Codes • 41
Radix Multiplication:
a. 12(10)
42 • DIGITAL SYSTEMS DESIGN, VOLUME I
b. 24(10)
c. 326(10)
Numbering Systems and Codes • 43
d. 46.8125(10)
44 • DIGITAL SYSTEMS DESIGN, VOLUME I
e. 254(10)
f. 124(10)
g. 348(10)
Numbering Systems and Codes • 45
h. 33.625(10)
a. 11111010(2)
Binary to Octal:
11111010(2) = 011 111 010(2)
3 7 2(8) = 372(8)
Binary to Hexadecimal:
11111010(2) = 1111 1010(2)
F A(16) = FA(16)
b. 101111011(2)
Binary to Octal:
101111011(2) = 101 111 011(2)
5 7 3(8) = 573(8)
Binary to Hexadecimal:
101111011(2) = 0001 0111 1011(2)
1 7 B(16 ) = 17B(16 )
c. 1111110011(2)
Binary to Octal:
Binary to Hexadecimal:
a. 777(8)
7 7 7(8)
111 111 111(2) = 111111111(2)
4 6 5(8)
100 110 101(2) = 100110101(2)
h. 202(8)
b. FFED(16)
e. BC23(16)
1011 1100 0010 0011(2) = 1011110000100011(2)
a. 0101(G)
0101(G) = 0110(2)
52 • DIGITAL SYSTEMS DESIGN, VOLUME I
b. 1001(G)
1001(G) = 1110(2)
c. 0110(G)
0110(G) = 0100(2)
d. 0011(G)
0011(G) = 0010(2)
e. 1100(G)
1100(G) = 1000(2)
f. 0010(G)
0010(G) = 0011(2)
Numbering Systems and Codes • 53
g. 1000(G)
1000(G) = 1111(2)
h. 0100(G)
0100(G) = 0111(2)
10. Convert the following binary numbers into gray code:
Note: The following procedure identifies how to convert binary
into gray code:
Step 1: Bring down the MSB.
Step 2: Add the MSB to the adjacent bit.
Step 3: Place the sum below the adjacent bit. Note: If a carry is
generated, discard it.
Step 4: Add the second pair of bits.
Step 5: Place the sum below the last bit added.
Step 6: Add the third pair of bits.
Step 7: Place the sum below the last bit added.
a. 0101(2) e. 1100(2)
b. 1001(2) f. 0010(2)
c. 0110(2) g. 1000(2)
d. 0011(2) h. 0100(2)
a. 0101(2)
0101(2) = 0111(G)
54 • DIGITAL SYSTEMS DESIGN, VOLUME I
b. 1001(2)
1001(2) = 1101(G)
c. 0110(2)
0110(2) = 0101(G)
d. 0011(2)
0011(2) = 0010(G)
e. 1100(2)
1100(2) = 1010(G)
f. 0010(2)
0010(2) = 0011(G)
Numbering Systems and Codes • 55
g. 1000(2)
1000(2) = 1100(G)
h. 0100(2)
0100(2) = 0110(G)
11. Convert the following decimal numbers into EX3:
a. 33(10) e. 666(10)
b. 53(10) f. 345(10)
c. 37(10) g. 269(10)
d. 776(10) h. 487(10)
a. 33(10)
3 3
+3 +3
6 6
0110 0110(EX3)
33(10) = 0110 0110(EX3)
b. 53(10)
5 3
+3 +3
8 6
1000 0110(EX3)
53(10) = 1000 0110(EX3)
56 • DIGITAL SYSTEMS DESIGN, VOLUME I
c. 37(10)
3 7
+3 +3
6 A
0110 1010(EX3)
37(10) = 0110 1010(EX3)
d. 776(10)
7 7 6
+3 +3 +3
A A 9
1010 1010 1001(EX3)
776(10) = 1010 1010 1001(EX3)
e. 666(10)
6 6 6
+3 +3 +3
9 9 9
1001 1001 1001(EX3)
666(10) = 1001 1001 1001(EX3)
f. 345(10)
3 4 5
+3 +3 +3
6 7 8
0110 0111 1000(EX3)
345(10) = 0110 0111 1000(EX3)
g. 269(10)
2 6 9
+3 +3 +3
5 9 C
0101 1001 1100(EX3)
269(10) = 0101 1001 1100(EX3)
Numbering Systems and Codes • 57
h. C
4 8 7
+3 +3 +3
7 B A
0111 1011 1010(EX3)
487(10) = 0111 1011 1010(EX3)
12. Convert the following EX3 numbers into decimal:
a. 0110 0110(EX3) e. 1001 0011(EX3)
b. 1000 1000(EX3) f. 1000 0111 0011(EX3)
c. 1100 1100(EX3) g. 1011 0111 0100(EX3)
d. 1000 1100 0100(EX3) h. 1010 0110 0110(EX3)
a. 0110 0110(EX3)
0110 0110(EX3)
6 6
−3 −3
3 3(10)
0110 0110(EX3) = 33(10)
b. 1000 1000(EX3)
1000 1000(EX3)
8 8
−3 −3
5 5(10)
1000 1000(EX3) = 55(10)
c. 1100 1100(EX3)
1100 1100(EX3)
C C
−3 −3
9 9(10)
1100 1100(EX3) = 99(10)
58 • DIGITAL SYSTEMS DESIGN, VOLUME I
13. Perform addition and subtraction on the following binary, octal, and
hexadecimal numbers:
a. 111000(2) d. 101111(2)
−000111(2) + 111010(2)
b. 725(8) e. 765(8)
−257(8) +245(8)
c. F21(16) f. FAB(16)
−97A(16) + FBE(16)
a. 111000(2)
−000111(2)
b. 725(8)
−257(8)
c. F21(16)
−97A(16)
d. 101111
+111010
60 • DIGITAL SYSTEMS DESIGN, VOLUME I
e. 765(8)
+ 245(8)
f. FAB(16)
+FBE(16)
Index
A Binary
Addition, of binary, octal, and addition, 24
hexadecimal numbers, 24–25 to decimal conversion, 4–6
American National Standards to gray code conversion, 18–19
Institute (ANSI) Symbol to hexadecimal conversion, 15
AND gate operator, 65 to octal conversion, 11
NAND gate circuits, 75 subtraction, 25
NOT gate operator, 68 Binary coded decimal (BCD), 16
OR gate operator, 63 to decimal conversion, 17
American standard code for decimal to BCD conversion, 17
information interchange Binary numbering system, 2–4
(ASCII), 21–24 binary to decimal conversion,
Analysis and Laws, 89 4–6
AND decimal to binary conversion, 6–7
gate operator, 65–68 Boolean Algebra
logic gate, 91–93 basic logic operations
ASCII. See American standard AND logic, 91–93
code for information NAND logic, 98–99
interchange NOR logic, 96–98
Associative property NOT logic, 95–96
of addition, 100–101 OR logic, 93–95
of multiplication, 101 circuit and developing truth ta-
ble, 108–113
B DeMorgan’s theorems, 106–108
B747-400 Flight Management interpreting truth tables, 113
Computers, 65, 68 product of sums configuration,
Base-8 numbering system. See 119–120
Octal numbering system sum of products and product of
Basic logic gate operators, 63 sums equality, 120–123
AND gate operator, 65–68 sum of products configuration,
NOT gate operator, 68–70 117–119
OR gate operator, 63–65 three-input truth table, 115–117
BCD. See Binary coded decimal two-input truth table, 114–115
154 • Index
R T
Radix division, 6–7 Three-input truth table, 115–117
Radix multiplication method, 4–5, Truth table
8, 13 used in Boolean Algebra, 61–62
Real numbers, properties of circuit and developing, 108–113
associative property interpreting. See Interpreting
of addition, 100–101 truth tables
of multiplication, 101 Two-input truth table, 114–115
commutative properties of addi-
tion and multiplication, V
101–102 Variables, 61
OTHER TITLE FROM OUR ENGINEERING
TECHNOLOGY COLLECTION
Kenneth Reid, Editor
• A Simple Guide to Understanding Compressors by James M. Watterson
FORTHCOMING TITLES
• Rotating Equipment: Maintenance and Troubleshooting by James M. Watterson
• Tribology: A Simple Guide To The Study of Friction by James M. Watterson
• Digital Systems Design, Volume II: Developmental Methods and Combinational
Logic Circuits by Larry Massengale
• Digital Systems Design, Volume III: Latch–Flip-Flop Circuits and Characteristics
of Digital Circuits by Larry Massengale
Momentum Press is one of the leading book publishers in the field of engineering,
mathematics, health, and applied sciences. Momentum Press offers over 30 collections,
including Aerospace, Biomedical, Civil, Environmental, Nanomaterials, Geotechnical,
and many others.
Momentum Press is actively seeking collection editors as well as authors. For more
information about becoming an MP author or collection editor, please visit
http://www.momentumpress.net/contact
The Momentum Press digital library is very affordable, with no obligation to buy in future years.