Problem
Problem
controls a light in the room. It has to be possible to turn the light on or off by
changing the state of any one of the switches. Design a logic network that realizes
this scenario.
• Light ON if exactly any 1 switch closed & OFF is a second switch also closed.
• But if a 3rd switch also closed then light is ON.
• Let x1, x2, x3 represents the input variable that denote the state of each switch.
And f(x1, x2, x3) represents the state of the light.
SOP realization
Sum
Carry
Y
x
• In 2nd row, both of the cells are identified by x2 = 1, but x1 = 0 for the left cell and
x1 = 1 for the right cell.
• Similarly, f = 1 for both cells in the first column. These cells are identified by x1 =
0 leading to the product term 𝑥ഥ1.
• Since this takes care of all instances where f = 1, it follows that the minimum-cost
realization of the function is :
𝑓 = 𝒙𝟐 + 𝒙𝟏
• To find a minimum-cost implementation of a given function, it is necessary to find
the smallest number of product terms that produce a value of 1 for all cases where
f = 1.
• Moreover, the cost of these product terms should be as low as possible.
Stephen Brown, Zvonko Vranesic, “Fundamentals of
Digital logic with Verilog Design”, Tata McGraw Hill 13
Publishing
3 variable map
YZ
Gray code X
• Then there are the implicants that correspond to all possible pairs of minterms
that can be combined (5 nos).
• Finally, there is one implicant that covers a group of four minterms
Stephen Brown, Zvonko Vranesic, “Fundamentals of Digital
18
logic with Verilog Design”, Tata McGraw Hill Publishing
Contd..
Prime Implicant
• An implicant is called a prime implicant if it cannot be combined into another
implicant that has fewer literals
Cover
• A collection of implicants that account for all valuations for which a given
function is equal to 1 is called a cover of that function
• Eg : set of all minterms, set of prime implicants etc.
• A cover also defines a particular implementation of the function. For e.g.
• From the K-map a cover consisting of minterms leads to the expression
1 1
1 1 1
1 1 1 1