Notes for Digital Logic Design (MCPC1001)
Course: Master of Computer Applications (MCA)
Karnaugh Map
The Karnaugh Map also called as K Map is a graphical representation that provides a
systematic method for simplifying the Boolean expressions.
For a Boolean expression consisting of n-variables, number of cells required in K
Map = 2n cells.
Two Variable K Map
Two variable K Map is drawn for a Boolean expression consisting of two variables.
The number of cells present in two variable K Map = 22 = 4 cells.
So, for a Boolean function consisting of two variables, we draw a 2 x 2 K Map.
Two variable K Map may be represented as
Here, A and B are the two variables of the given Boolean function.
Three Variable K Map
Three variable K Map is drawn for a Boolean expression consisting of three
variables.
The number of cells present in three variable K Map = 23 = 8 cells.
So, for a Boolean function consisting of three variables, we draw a 2 x 4 K
Map.
Prof. S. Bera MCA Department Page 1
Three variable K Map may be represented as-
Here, A, B and C are the three variables of the given Boolean function.
Four Variable K Map-
Four variable K Map is drawn for a boolean expression consisting of four variables.
4
The number of cells present in four variable K Map = 2 = 16 cells.
So, for a boolean function consisting of four variables, we draw a 4 x 4 K Map.
Prof. S. Bera MCA Department Page 2
Four variable K Map may be represented as-
Here, A, B, C and D are the four variables of the given boolean function.
Prof. S. Bera MCA Department Page 3
Karnaugh Map Simplification Rules-
To minimize the given boolean function,
We draw a K Map according to the number of variables it contains.
We fill the K Map with 0’s and 1’s according to its function.
Then, we minimize the function in accordance with the following rules.
Rule-01:
We can either group 0’s with 0’s or 1’s with 1’s but we cannot group 0’s and 1’s
together.
X representing don’t care can be grouped with 0’s as well as 1’s.
NOTE: There is no need of separately grouping X’s i.e. they can be ignored if all 0’s and
1’s are already grouped.
Rule-02:
Groups may overlap each other.
Rule-03:
We can only create a group whose number of cells can be represented in the power of
2.
n
In other words, a group can only contain 2 i.e. 1, 2, 4, 8, 16 and so on number of
cells.
Example-
Rule-04:
Groups can be only either horizontal or vertical.
We cannot create groups of diagonal or any other shape.
Prof. S. Bera MCA Department Page 4
Rule-05:
Each group should be as large as possible.
Example-
Rule-06:
Opposite grouping and corner grouping are allowed.
The example of opposite grouping is shown illustrated in Rule-05.
The example of corner grouping is shown below.
Prof. S. Bera MCA Department Page 5
Example-
Rule-07:
There should be as few groups as possible.
PROBLEMS BASED ON KARNAUGH MAP-
Problem-01:
Minimize the following boolean function-
F(A, B, C, D) = Σm(0, 1, 2, 5, 7, 8, 9, 10, 13, 15)
Solution-
Since the given boolean expression has 4 variables, so we draw a 4 x 4 K Map.
We fill the cells of K Map in accordance with the given boolean function.
Then, we form the groups in accordance with the above rules.
Then, we have
Prof. S. Bera MCA Department Page 6
Now,
F(A, B, C, D)
= (A’B + AB)(C’D + CD) + (A’B’ + A’B + AB + AB’)C’D + (A’B’ + AB’)(C’D’ + CD’)
= BD + C’D + B’D’
Thus, minimized boolean expression is-
F(A, B, C, D) = BD + C’D + B’D’
Problem-02:
Minimize the following boolean function-
F(A, B, C, D) = Σm(0, 1, 3, 5, 7, 8, 9, 11, 13, 15)
Solution-
Since the given boolean expression has 4 variables, so we draw a 4 x 4 K Map.
We fill the cells of K Map in accordance with the given boolean function.
Then, we form the groups in accordance with the above rules.
Then, we have-
Prof. S. Bera MCA Department Page 7
Now,
F (A, B, C, D)
= (A’B’ + A’B + AB + AB’)(C’D + CD) + (A’B’ + AB’)(C’D’ + C’D)
= D + B’C’
Thus, minimized boolean expression is-
F (A, B, C, D) = B’C’ + D
Prof. S. Bera MCA Department Page 8