Professional Documents
Culture Documents
Solution of Homework#03
Solution of Homework#03
Homework#03 2005/2
Solution of Homework#03
(1) Use the theorems of switching algebra to simplify each of the following logic
functions:
(a) F = W·X·Y·Z· (W·X·Y·Z′ + W·X′·Y·Z + W′·X·Y·Z + W·X·Y′·Z)
F = W·X·Y·Z·W·X·Y·Z′ + W·X·Y·Z·W·X′·Y·Z + W·X·Y·Z·W′·X·Y·Z +
W·X·Y·Z·W·X·Y′·Z (according to T8)
= W·X·Y·0 + W·X·Y·Z·W·X′·Y·Z + W·X·Y·Z·W′·X·Y·Z +
W·X·Y·Z·W·X·Y′·Z (according to T5′)
=0+0+0+0 (according to T2′)
=0 (according to A4′)
(2) Prove each of the following algebraically. Identify the axioms or theorems used at
each step
(a) A·B+A·B′ = A
A·B+A·B′ = A·(B+B′) (according to T8)
= A·(1) (according to T5)
= A (according to T1′)
(b) A + A·B = A
A + A·B = A·(1+B) (according to T8 and T5)
= A·1 (according to T2)
= A (according to T1′)
(c) A′ +A·B = A′ + B
A′ +A·B = A′ + ((A·B)′)′ (according to T4)
= A′ + (A′ + B′)′ (according to T13)
= (A·(A′ + B′))′ (according to T13)
= (A·A′ + A·B′)′ (according to T8)
= (0 + A·B′)′ (according to T5′)
= (A·B′)′ (according to T1)
= A′+(B′)′ (according to T13)
= A′+B (according to T4)
(3) Write the truth table for each of the following logic functions:
(a) F = X′·Y + X′·Y′·Z
Row X Y Z F
0 0 0 0 0
1 0 0 1 1
2 0 1 0 1
3 0 1 1 1
4 1 0 0 0
5 1 0 1 0
6 1 1 0 0
7 1 1 1 0
Row W X Y Z F
0 0 0 0 0 1
1 0 0 0 1 1
2 0 0 1 0 0
3 0 0 1 1 1
4 0 1 0 0 1
5 0 1 0 1 1
6 0 1 1 0 1
7 0 1 1 1 1
8 1 0 0 0 1
9 1 0 0 1 1
10 1 0 1 0 0
11 1 0 1 1 1
12 1 1 0 0 1
13 1 1 0 1 0
14 1 1 1 0 0
15 1 1 1 1 0
(c) F = (((A+B)′+C′)′+D)′
Row A B C D F
0 0 0 0 0 1
1 0 0 0 1 0
2 0 0 1 0 1
3 0 0 1 1 0
4 0 1 0 0 1
5 0 1 0 1 0
6 0 1 1 0 0
7 0 1 1 1 0
8 1 0 0 0 1
9 1 0 0 1 0
10 1 0 1 0 0
11 1 0 1 1 0
12 1 1 0 0 1
13 1 1 0 1 0
14 1 1 1 0 0
15 1 1 1 1 0
(5) Write the canonical sum and product for each of the following logic functions:
(a) F = ΣX,Y(1,2)
Canonical sum = X′·Y + X·Y′
Canonical product = (X+Y)·(X′+Y′)
(b) F = ΠA,B(0,1,2)
Canonical sum = A·B
Canonical product = (A+B)·(A′+B)·(A+B′)
(e) F = X + Y′·Z′
Canonical sum = X′·Y′·Z′ + X·Y′·Z′ + X·Y′·Z + X·Y·Z′ + X·Y·Z
Canonical product
= (X+Y+Z′)·(X+Y′+Z)·(X+Y′+Z′)
(6) Given the function P(A, B, C) = ΣA, B, C(0, 1+x, 3+x, 4+x) where x = y mod 4 and
y = sum of all digits in your telephone number
(a) Express P in canonical forms
My telephone number = 012830195
y = 0+1+2+8+3+0+1+9+5 = 29
x = y mod 4 = 29 mod 4 = 1
P(A, B, C) = ΣA, B, C(0, 2, 4, 5)
Canonical sum = A′·B′·C′+A′·B·C′+A·B′·C′+ A·B′·C
Canonical product = (A+B+C′)·(A+B′+C′)·(A′+B′+C)·(A′+B′+C′)
(7) An Exclusive OR (XOR) gate is a 2-input gate whose output is 1 if and only if
exactly one of its inputs is 1. Write the truth table, sum-of-products expression, and
corresponding AND-OR circuit for the Exclusive OR function
X Y F F = X′·Y + X·Y′
0 0 0
0 1 1
X
1 0 1
1 1 0
Y
(8) Any set of logic-gate types that can realize any logic function is called a complete
set of logic gates. For example, 2-input AND gates, 2-input OR gates, and inverters
are a complete set, because any logic function can be expressed as a sum of products
of variables and their complements, and AND and OR gates with any number of
inputs can be made from 2-input gates. Do 2-input NAND gates form a complete set
of logic gates? Prove your answer.
Yes, 2-input NAND gates form a complete set of logic gates because 2-
input AND gates, 2-input OR gates, and inverters are a complete set and we can
derive logic function AND, OR, and NOT (inverter) from 2-input NAND gates.
Panupong Sornkhom Department of Electrical and Faculty of Engineering,
Computer Engineering Naresuan University
Solution of Digital Circuit and Logic Design 1 Page 6/6
Homework#03 2005/2
(9) Draw a truth table to show the function of an odd number detection circuit. That
is, the output of the circuit will be one only if the decimal value of the binary input is
odd. Assume three inputs. Derive a simplified circuit