Professional Documents
Culture Documents
Bde Unit 3
Bde Unit 3
INTRODUCTION:
Any Boolean function can be implemented using only AND And INVERT gates since the OR
function can be generated by a combination of these two gates, as shown in Figure 2.20(a). It
follows that these two gates can implement any arbitrary Boolean function and they are said to
form a complete set.
KARNAUGH MAP:
In many digital circuits and practical problems we need to find expression with minimum
variables. We can minimize Boolean expressions of 3, 4 variables very easily using K-map
without using any Boolean algebra theorems. K-map can take two forms Sum of Product (SOP)
and Product of Sum (POS) according to the need of problem. K-map is table like representation
but it gives more information than TRUTH TABLE. We fill grid of K-map with 0’s and 1’s then
solve it by making groups.
Steps to solve expression using K-map-
SOP FORM:
1. K-map of 3 variables –
Z= ∑A, B, C (1,3,6,7)
F(P,Q,R,S)=∑(0,2,5,7,8,10,13,15)
POS FORM:
1. K-map of 3 variables –
F(A,B,C)=π(0,3,6,7)
Canonical Sop form means Canonical Sum of Products form. In this form, each product term
contains all literals. So, these product terms are nothing but the min terms. Hence, canonical SoP
form is also called as sum of min terms form.
The K-map is a systematic way of simplifying Boolean expressions. With the help of the K-map
method, we can find the simplest POS and SOP expression, which is known as the minimum
expression. The K-map provides a cookbook for simplification.
Just like the truth table, a K-map contains all the possible values of input variables and their
corresponding output values. However, in K-map, the values are stored in cells of the array. In
each cell, a binary value of each input variable is stored.
The K-map method is used for expressions containing 2, 3, 4, and 5 variables. For a higher number
of variables, there is another method used for simplification called the Quine-McClusky method.
In K-map, the number of cells is similar to the total number of variable input combinations. For
example, if the number of variables is three, the number of cells is 2 3=8, and if the number of
variables is four, the number of cells is 24. The K-map takes the SOP and POS forms. The K-map
grid is filled using 0's and 1's. The K-map is solved by making groups. There are the following
steps used to solve the expressions using K-map:
With this general idea of K-maps, let us now move on to the procedure employed in designing an
optimal (in terms of the number of logic gates used to realize the logic) digital system. We'll start
with a given problem statement.
Example 1:
Design a digital system whose output is defined as logically low if the 4-bit input binary
number is a multiple of 3; otherwise, the output will be logically high. The output is defined
if and only if the input binary number is greater than 2.
Where:
Y = "Don't Care," if the input number is less than 3 (orange entries in the truth table)
Y = 0, if the input number is an integral multiple of 3 (green entries in the truth table)
Y = 1, if the input number is not an integral multiple of 3 (blue entries in the truth table)
Note that, in addition to the input and output columns, the truth table also has a column that gives
the decimal equivalent of the input binary combination, which makes it easy for us to arrive at the
minterm or maxterm expansion for the given problem. Thus for the given example:
However, sometimes the logical expression which is to be simplified might be directly given in
terms of SOP or POS forms. In this case, the requirement for the truth table can be overlooked
provided that we express the given expression in its canonical form, from which the
corresponding minterms or maxterms can be obtained.
The process has to be initiated by grouping the bits which lie in adjacent cells such that the
group formed contains the maximum number of selected bits. This means that for an n-
variable K-map with 2n cells, try to group for 2 n cells first, then for 2 n-1 cells, next for 2n-
2
cells, and so on until the “group” contains only 2 0 cells, i.e., isolated bits (if any). Note that
the number of cells in the group must be equal to an integer power to 2, i.e., 1, 2, 4, 8. . . .
The procedure must be applied for all adjacent cells of the K-map, even when they appear to
be not adjacent—the top row is considered to be adjacent to the bottom row and the rightmost
column is considered to be adjacent to the leftmost column as if the K-map wraps around
from top to bottom and right to left. For example, Group 1 of SOP form solution in Table 2.
A bit appearing in one group can be repeated in another group provided that this leads to an
increase in the resulting group size. For example, cell 5 is repeated in both Group 3 and 4 in
the SOP form solution of Table 2 as it results in forming a group with two cells instead of a
group with just one cell.
"Don’t Care" conditions should be considered for the grouping activity if and only if they
help obtain a larger group. Otherwise, they are to be neglected. Here the "Don't Care" terms
in cells 0 and 1 are considered to create Group 2 of SOP solution form as it results in a group
with four cells instead of just two.
Table 2.
Thus, for the example considered, the K-map showing the groups can be obtained as given in
Figure 3 whose information is summarized in Table 1.
Figure 3. K-maps grouped for (a) SOP solution and (b) POS solution
Figure 4. K-map simplification technique for (a) SOP solution and (b) POS solution
Following this same process, we can obtain the logical terms corresponding to each of the groups
to finally form the logical expression for the particular output, as shown in Table 3.
Table 3.
Figure 5. Digital system corresponding to (a) SOP form of solution and (b) POS form of solution
The above expression can be implemented with three AND gates in first stage and one OR gate
in second stage as shown in figure.
If bubbles are introduced at AND gates output and OR gates inputs (the same for NOR gates), the
above circuit becomes as shown in figure.
Now replace OR gate with input bubble with the NAND gate. Now we have circuit which is fully
implemented with just NAND gates.
Any logic function can be implemented using NOR gates. To achieve this, first the logic function
has to be written in Product of Sum (POS) form. Once it is converted to POS, then it's very easy
to implement using NOR gate. In other words any logic circuit with OR gates in first level and
AND gates in second level can be converted into a NOR-NOR gate circuit.
F = (X+Y) . (Y+Z)
The above expression can be implemented with three OR gates in first stage and one AND gate in
second stage as shown in figure.
If bubble are introduced at the output of the OR gates and the inputs of AND gate, the above
circuit becomes as shown in figure.
Now replace AND gate with input bubble with the NOR gate. Now we have circuit which is fully
implemented with just NOR gates.