3. The Inverter
• The inverter (NOT circuit) performs the
operation called inversion or complementation.
• Standard logic symbols:
1
1
input output input output
4. Inverter Truth Table & Logic Expression
Input Output
LOW (0) HIGH (1)
HIGH (1) LOW (0)
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0 1
1 0
A X = A
5. The AND Gate & Its Operation
• The AND gate is composed of two or more
inputs and a single output.
• For a 2-input AND gate:
– Output X is HIGH only when inputs A and B are
HIGH
– X is LOW when either A or B is LOW, or when both
A and B are LOW.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
&
A
B
X
A
B
X
6. AND Gate Truth Table
INPUTS OUTPUT
A B X
0 0 0
0 1 0
1 0 0
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The total number of possible combinations of binary inputs to a gate is
determined by:
N = 2n
• Therefore:
– 2 bits (n=2) = 4 combinations
– 3 bits = 8 combinations
– 4 bits = 16 combinations
A
B
X
7. AND Gate – Logic Expressions
• Use either:
– X = A · B ,or
– X = AB
• If there are more than 2 inputs, do as below:
A
B
X
X= ABC
X= ABCD
A
B
C
A
B
C
D
8. The OR Gate
• Like AND gate, an OR gate has two or more
inputs and one output.
• For a 2-input OR gate:
– output X is HIGH when either input A or input B is
HIGH, or when both A and B are HIGH.
– X is LOW only when both A and B are LOW.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
≥ 1
A
B
X
9. OR Gate Truth Table
INPUTS OUTPUT
A B X
0 0 0
0 1 1
1 0 1
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
10. OR Gate – Logic Expressions
• Use the operator + for OR operation
– X = A + B
– If there are more than 2 inputs, do as below:
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
X= A+B+C
X= A+B+C+D
A
B
C
A
B
C
D
11. The NAND Gate
• NAND = NOT-AND
• For a 2-input NAND gate:
– Output X is LOW only when inputs A and B are
HIGH
– X is HIGH when either A or B is LOW, or when both
A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
&
A
B
X
A
B
X
A
B
X
12. NAND Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 1
1 0 1
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input NAND gate is
X = AB
A
B
X
13. Negative-OR Equivalent Op of a NAND
• For a 2-input NAND gate performing a
negative-OR operation
– Output X is HIGH when either input A or input B is
LOW or when both A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
NAND Negative-OR
14. The NOR Gate
• NOR = NOT-OR
• For a 2-input NOR gate:
– Output X is LOW when either input A or input B is
HIGH, or when both A and B are HIGH
– X is HIGH only when both A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
A
B
X
≥ 1
A
B
X
15. NOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 0
1 0 0
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input NOR gate is
X = A+B
A
B
X
16. Negative-AND Equivalent Op of a NOR
• For a 2-input NOR gate performing a negative-
AND operation
– Output X is HIGH only when both inputs A and B
are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
NOR Negative-AND
17. The XOR and XNOR Gates
• Exclusive-OR and Exclusive-NOR gates are
formed by a combination of other gates
already discussed.
• Because of their fundamental importance in
many applications, these gates are often
treated as basic logic elements with their own
unique symbols.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
18. The XOR Gate
• For a 2-input exclusive-OR gate:
– Output X is HIGH when input A is LOW and input B
is HIGH, or when input A is HIGH and input B is
LOW
– X is LOW when A and B are both HIGH and both
LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
= 1
A
B
X
A
B
X
19. XOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 0
0 1 1
1 0 1
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input XOR gate is
X = A+B
A
B
X
20. The XNOR Gate
• For a 2-input exclusive-NOR gate:
– Output X is LOW when input A is LOW and input B
is HIGH, or when input A is HIGH and input B is
LOW
– X is HIGH when A and B are both HIGH and both
LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
= 1
A
B
X
A
B
X
21. XNOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 0
1 0 0
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input XNOR gate is
X = A+B
A
B
X
23. Introduction
• 1854: Logical algebra was published by
George Boole known today as “Boolean
Algebra”
– It’s a convenient way and systematic way of
expressing and analyzing the operation of logic
circuits.
• 1938: Claude Shannon was the first to apply
Boole’s work to the analysis and design of
logic circuits.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
24. Boolean Operations & Expressions
• Variable – a symbol used to represent a logical
quantity.
• Complement – the inverse of a variable and is
indicated by a bar over the variable.
• Literal – a variable or the complement of a
variable.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
25. Boolean Addition
• Boolean addition is equivalent to the OR operation
• A sum term is produced by an OR operation with no
AND ops involved.
– i.e.
– A sum term is equal to 1 when one or more of the literals in
the term are 1.
– A sum term is equal to 0 only if each of the literals is 0.
D
C
B
A
C
B
A
B
A
B
A
,
,
,
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0+0 = 0 0+1 = 1 1+0 = 1 1+1 = 1
26. Boolean Multiplication
• Boolean multiplication is equivalent to the AND
operation
• A product term is produced by an AND operation with
no OR ops involved.
– i.e.
– A product term is equal to 1 only if each of the literals in
the term is 1.
– A product term is equal to 0 when one or more of the
literals are 0.
D
BC
A
C
AB
B
A
AB ,
,
,
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0·0 = 0 0·1 = 0 1·0 = 0 1·1 = 1
27. Laws & Rules of Boolean Algebra
• The basic laws of Boolean algebra:
– The commutative laws (กฏการสลับที่)
– The associative laws (กฏการจัดกลุ่ม)
– The distributive laws (กฏการกระจาย)
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
28. Commutative Laws
• The commutative law of addition for two
variables is written as: A+B = B+A
• The commutative law of multiplication for
two variables is written as: AB = BA
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
A+B
B
A
B+A
A
B
AB
B
A
B+A
29. Associative Laws
• The associative law of addition for 3 variables
is written as: A+(B+C) = (A+B)+C
• The associative law of multiplication for 3
variables is written as: A(BC) = (AB)C
A
B
A+(B+C)
C
A
B
(A+B)+C
C
A
B
A(BC)
C
A
B
(AB)C
C
B+C
A+B
BC
AB
30. Distributive Laws
• The distributive law is written for 3 variables as
follows: A(B+C) = AB + AC
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
B
C
A
B+C
A
B
C
A
X
X
AB
AC
X=A(B+C) X=AB+AC
31. Rules of Boolean Algebra
1
.
6
.
5
1
.
4
0
0
.
3
1
1
.
2
0
.
1
A
A
A
A
A
A
A
A
A
A
A
BC
A
C
A
B
A
B
A
B
A
A
A
AB
A
A
A
A
A
A
A
A
)
)(
.(
12
.
11
.
10
.
9
0
.
8
.
7
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
___________________________________________________________
A, B, and C can represent a single variable or a combination of variables.
33. DeMorgan’s Theorems
• DeMorgan’s theorems provide mathematical
verification of:
– the equivalency of the NAND and negative-OR
gates
– the equivalency of the NOR and negative-AND
gates.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
34. DeMorgan’s Theorems
• The complement of two or
more ANDed variables is
equivalent to the OR of the
complements of the
individual variables.
• The complement of two or
more ORed variables is
equivalent to the AND of
the complements of the
individual variables.
Y
X
Y
X
Y
X
Y
X
NAND Negative-OR
Negative-AND
NOR
35. DeMorgan’s Theorems (Exercises)
• Apply DeMorgan’s theorems to the expressions:
Z
Y
X
W
Z
Y
X
Z
Y
X
Z
Y
X
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
36. DeMorgan’s Theorems (Exercises)
• Apply DeMorgan’s theorems to the expressions:
)
(
)
(
F
E
D
C
B
A
EF
D
C
B
A
DEF
ABC
D
C
B
A
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
37. Boolean Analysis of Logic Circuits
• Boolean algebra provides a concise way to
express the operation of a logic circuit formed
by a combination of logic gates
– so that the output can be determined for various
combinations of input values.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
38. Boolean Expression for a Logic Circuit
• To derive the Boolean expression for a given
logic circuit, begin at the left-most inputs and
work toward the final output, writing the
expression for each gate.
C
D
B
A
CD
B+CD
A(B+CD)
39. Constructing a Truth Table for a Logic
Circuit
• Once the Boolean expression for a given logic
circuit has been determined, a truth table that
shows the output for all possible values of the
input variables can be developed.
– Let’s take the previous circuit as the example:
A(B+CD)
– There are four variables, hence 16 (24)
combinations of values are possible.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
40. Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression
– To evaluate the expression A(B+CD), first find the
values of the variables that make the expression
equal to 1 (using the rules for Boolean add &
mult).
– In this case, the expression equals 1 only if A=1
and B+CD=1 because
A(B+CD) = 1·1 = 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
41. Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression (cont’)
– Now, determine when B+CD term equals 1.
– The term B+CD=1 if either B=1 or CD=1 or if both
B and CD equal 1 because
B+CD = 1+0 = 1
B+CD = 0+1 = 1
B+CD = 1+1 = 1
• The term CD=1 only if C=1 and D=1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
42. Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression (cont’)
– Summary:
– A(B+CD)=1
• When A=1 and B=1 regardless of the values of C and D
• When A=1 and C=1 and D=1 regardless of the value of B
– The expression A(B+CD)=0 for all other value
combinations of the variables.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
43. Constructing a Truth Table for a Logic
Circuit
• Putting the results in
truth table format
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1
1 1 0 0
1 1 0 1
1 1 1 0
1 1 1 1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
When A=1 and
B=1 regardless
of the values
of C and D
When A=1 and C=1
and D=1 regardless of
the value of B
A(B+CD)=1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 0
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
44. EEE - DIGITAL ELECTRONICS
•A combinational circuit has 3 inputs A, B, C and output F. F is true for
following input combinations
A is False, B is True
A is False, C is True
A, B, C are False
A, B, C are True
(i) Write the Truth table for F. Use the convention True=1 and False = 0.
(ii) Write the simplified expression for F in Sum-of-Products (SOP)
form.
(iii) Write the simplified expression for F in Product-of-Sum (POS) form.
(iv) Draw logic circuit using minimum number of 2-input NAND gates.