Relationship Between Basic Operation of Boolean and Basic Logic Gate

Download Report

Transcript Relationship Between Basic Operation of Boolean and Basic Logic Gate

Relationship Between Basic Operation
of Boolean and Basic Logic Gate
• The basic construction of a logical circuit is gates
• Gate is an electronic circuit that emits an output signal as a
result of a simple Boolean operation on its inputs
• Logical function is presented through the combination of
gates
• The basic gates used in digital logic is the same as the basic
Boolean algebra operations (e.g., AND, OR, NOT,…)
• The package Truth Tables and Boolean Algebra set out the basic
principles of logic.
Name
Graphic Symbol
AND
A
B
F
OR
A
B
F
NOT
NAND
NOR
A
A
B
A
B
Boolean Algebra
F =A. B
Or
F = AB
F =A+ B
_
F =A
F
____
F=A.B
Or
F = AB
F
F
_____
F=A+B
Truth Table
A
0
0
1
1
A
0
0
1
1
B
0
1
0
1
B
0
1
0
1
B
0
1
F
0
0
0
1
F
0
1
1
1
F
1
0
A B
0 0
0 1
1 0
1 1
F
0
1
1
1
A B
0 0
0 1
1 0
1 1
F
0
0
0
1
the symbols, algebra signs and the truth table for the gates
Basic Theorems of Boolean Algebra
1. Identity Elements
1.A=A
0+A=A
2. Inverse Elements
A.A=0
A+A=1
3. Idempotent Laws
A+A=A
A.A=A
4. Boundess Laws
A+1=1
A.0=0
5. Distributive Laws
A . (B + C) = A.B + A.C
A + (B . C) = (A+B) . (A+C)
6. Order Exchange Laws
A.B=B.A
A+B=B+A
7. Absorption Laws
A + (A . B) = A
A . (A + B) = A
9. Elimination Laws

A + (A . B) = A + B

A . (A + B) = A . B
8. Associative Laws
A + (B + C) = (A + B) + C
A . (B . C) = (A . B) . C
10. De Morgan Theorem
  
(A + B) = A . B
  
(A . B) = A + B
Exercise 1
• Apply De Morgan theorem to the following
equations:
F =V+A+ L
F =A+ B + C + D
• Verify the following expressions:
S.T + V.W + R.S.T = S.T + V.W
A.B + A.C + B.A = A.B + A.C
Relationship Between Boolean
Function and Logic Circuit
Boolean function  Q = AB + B
= (NOT A AND B) OR B
Logic circuit
A
A
AB
B
B
Q
= AB + B
Relationship Between Boolean
Function and Logic Circuit
• Any Boolean function can be implemented in electronic
form as a network of gates called logic circuit
A
B
A.B = AB
F = AB + C + D
C
D
C+D
G = A . (B + C + D)
A
G = A . (B + C + D)
B
C
D
B+C+D
C+D
Truth Table
A
A
AB
B
B
Produce a truth table from the logic circuit
A
B
A
AB
Q
0
0
0
1
1
1
0
1
0
1
1
0
0
0
0
1
1
0
0
1
Q
= AB + B
Exercise 2
• Build a truth table for the following
Boolean function
G = A . (B + C + D)
Karnaugh Map
• A graphical way of depicting the content of a truth table
where the adjacent expressions differ by only one variable
• For the purposes simplification, the Karnaugh map is a
convenient way of representing a Boolean function of a
small number (up to four) of variables
• The map is an array of 2n squares, representing all possible
combination of values of n binary variables
• Example: 2 variables, A and B
B
B
B
A
AB
AB
A
AB
AB
A
B
A
0
1
1
0
00
01
10
11
4 variables, A, B, C, D  24 = 16 squares
AB
CD
CD
CD
AB
0000
0001
AB
0100
AB
1100
AB
1000
CD
CD
• List combinations in
the order 00, 01, 11, 10
00
01
11
C
AB
AB
AB
AB
0 C
000
010
110
100
1 C
001
011
111
101
C
0
C
1
C
00
AB
000
001
01
AB
010
011
11
AB
110
111
10
AB
100
101
AB
AB
10
How to create Karnaugh Map
Truth Table
A
B
C
F
0
0
0
1
0
0
1
0
0
1
0
0
0
1
1
1
1
0
0
1
1
0
1
1
1
1
0
0
1
1
1
0
1. Place 1 in the corresponding
square
Karnaugh Map
BC
BC
00
A 0
1
A
A 1
1
BC
01
BC
11
1
1
BC
10
Karnaugh Maps to Represent Boolean Functions
AB
00
AB
01
AB
1
11
AB
10
AB
1
F = AB + AB
2. Group the adjacent squares:
Begin grouping square with 2n-1 for n variables
• e.g. 3 variables, A, B, and C
23-1 = 22 = 4
= 21 = 2
= 20 = 1
BC
BC
00
A 0
1
A
1
A 1
BC
BC
01
BC
11
BC
10
1
1
AB
ABC
F = BC + AB + ABC
BC
A
BC
00
BC
11
BC
10
1
A 0
A 1
BC
01
1
1
A
F = A + BC
BC
1
1
3 variables:
23-1 = 22 = 4
22-1 = 21 = 2
21-1 = 20 = 1
4 variables, A, B, C, D  24-1 = 23 = 8 (maximum); 22 = 4;
21 = 2; 20 = 1 (minimum);
AB
CD
00
00
1
01
1
11
1
10
1
F=
01
11
10
1
1
CD + BD + ABC
1
The following diagram illustrates some of the possible pairs of
values for which simplification is possible:
Karnaugh Map
Boolean Function
Logic Circuit
Exercise 3
Transform the following truth table to Karnaugh Map and
find the Boolean function