Professional Documents
Culture Documents
4-Karnaugh Map - 5 Variables
4-Karnaugh Map - 5 Variables
Simplification Using
Karnaugh Map
Digital Design. M. Morris Mano
Prof. Imane Aly Saroit Ismail 1 Logic Design
Karnaugh Map
Var2
Var1 0 1
00 01
0 In each square:
0 1
10 11 Black values represents the binary values.
1
2 3 Red values represents the decimal values.
Example 1:
Using k-map, optimize: B
A 0 1
F(A,B)= m (1,3) 0 1
As SoP form. 1 1
F(A,B)=B
Var2 Var3
Var1 00 01 11 10
000 001 011 010
0
0 1 3 2
100 101 111 110
1
4 5 7 6
In each square:
Black values represents the binary values.
Red values represents the decimal values.
Example 2:
Using k-map, optimize: BC
A 00 01 11 10
F(A,B,C)= m (0,1,4) as PoS 0 0 0
form. 1 0 0 0
As we need F as PoS, so we
need to use maxterms. 𝑭 𝑨, 𝑩, 𝑪 = 𝑩(𝑨 + 𝑪)
F(A,B,C)= M (2,3,5,6,7)
Prof. Imane Aly Saroit Ismail 12 Logic Design
3-Variable K-map (Example 3)
Example 3:
Using k-map, optimize:
F(A,B,C)= m (0,1,7) as both SOP and PoS form.
Example 4:
Using k-map, optimize:
𝑭 𝑨, 𝑩, 𝑪 = 𝑨𝑩𝑪 + 𝑨𝑩𝑪 + 𝑨𝑩𝑪+A𝐁𝑪 + 𝑨𝑩𝑪
as both SOP and PoS form.
Example 5:
Using k-map, optimize:
𝑭 𝑿. 𝒀, 𝒁 = (𝑿 + 𝒀 + 𝒁)(𝑿 + 𝒀)
as both SOP and PoS form.
Example 6:
Using k-map, optimize:
𝑭 𝑿. 𝒀, 𝒁 = 𝑴(𝟐, 𝟑, 𝟒, 𝟕) using ANDs-OR-NOTs gates .
Var3 Var4
Var1 Var2 00 01 11 10
0000 0001 0011 0010
00
0 1 3 2 In each square:
0100 0101 0111 0110
01 Black values represents the binary values.
4 5 7 6
1100 1101 1111 1110 Red values represents the decimal values.
11
12 13 15 14
1000 1001 1011 1010
10
8 9 11 10
Example 8:
Using k-map, optimize F in an SoP form:
𝐅 𝐀, 𝐁, 𝐂, 𝐃 = 𝐀𝐂𝐃 + 𝐀𝐃 + 𝐁𝐂 + 𝐂𝐃 + 𝐀𝐁𝐃
We need to find minterms or maxterms. We can use truth
table. But an easier way can be used is by adding 1’s (in case
of SoP) or 0’s (in case of PoS) in the square(s) that met the
value of the variables. Of course do not add two 1’s (or 0’s)
in the same square.
Prof. Imane Aly Saroit Ismail 19 Logic Design
4-Variable K-map (Example 8)
• 𝐅𝐨𝐫 𝐀𝐂𝐃 add 1’s in the squares where A=0, C=0, D=0 (2)
• For 𝐀𝐃 add 1’s in the squares where A=0, D=1 (4)
• 𝐅𝐨𝐫 𝐁𝐂 add 1’s in the squares where B=0, C=1 (4)
• 𝐅𝐨𝐫 𝐂𝐃 add 1’s in the squares where C=1, D=1 (4)
• 𝐅𝐨𝐫 𝐀𝐁𝐃 add 1’s in the squares where A=1, B=0, D=0 (2)
𝐅 𝐀, 𝐁, 𝐂, 𝐃 = 𝐀𝐂𝐃 + 𝐀𝐃 + 𝐁𝐂 + 𝐂𝐃 + 𝐀𝐁𝐃
CD
AB CD
00 01 11 10
AB 00 01 11 10
00 1 1 111 1
00 1 1 1 1
01 1 1 11
01 1 1 1
11 1 11 1
10 1 11 11
10 1 1 1
𝐅 𝐀, 𝐁, 𝐂, 𝐃 = 𝐀𝐂 + 𝐂𝐃 + 𝐁𝐃
Prof. Imane Aly Saroit Ismail 21 Logic Design
4-Variable K-map (Example 8)
𝐅 𝐀, 𝐁, 𝐂, 𝐃 = 𝐀𝐂𝐃 + 𝐀𝐃 + 𝐁𝐂 + 𝐂𝐃 + 𝐀𝐁𝐃
CD
AB 00 01 11 10
00 1 1 1 1 Note that we can obtain the
01 1 1 1 minterms and maxterms directly
11 1 from the k-map.
10 1 1 1 F(A,B,C,D) =
=m (0,1,2,3,4,5,7,8,10,11,15)
=M (6,9,12,13,14)
Prof. Imane Aly Saroit Ismail 22 Logic Design
4-Variable K-map (Example 9)
𝑭 𝑨, 𝑩, 𝑪, 𝑫 = 𝒎(𝟎, 𝟏, 𝟐, 𝟓, 𝟔)