Unit - 2
Combinational Digital Circuits
Q1) What is a Multiplexer? Explain 2:1 Mux in detail.
A1)
- It is a special type of combinational circuit.
- It has n-data inputs, one output and m inputs select lines with 2m = n.
- It selects one of the n data inputs and routes it to the output.
- The selection of one of the inputs is done by the select lines.
- Depending on the code applied at the inputs, one of the n data sources is selected and transmitted to the single output Y.
- E is the enable input which is useful for cascading purpose.
- It is an active low terminal hence performs the required operation when it is low.
Block diagram of multiplexer
Multiplexers come in multiple variations
- 2: 1 multiplexer
- 4: 1 multiplexer
- 16: 1 multiplexer
- 32: 1 multiplexer
Block Diagram of 2:1 MUX
Truth Table of 2:1 MUX
Where x is don’t care.
Q2) Draw and explain Full adder.
A2)
- It is developed to overcome the drawback of Half Adder circuit.
- It can add two one-bit numbers A and B and a carry C.
- It is a three input and two output combinational circuit.
Block diagram
Full adder
Truth Table
Circuit Diagram
Full adder
Q3) Draw and explain Full Subtractor.
A3)
It is a combinational circuit which has three inputs A,B,C and two output D and C'.
A is the 'minuend', B is 'subtrahend', C is the 'borrow' which is produced by the previous stage, difference output D and C' is the borrow output.
Truth Table
Circuit Diagram
Full subtractor
Q4) Do BCD addition of 0101 with 0110.
A4)
Q5) Explain digital comparator with its applications.
A5)
- It performs comparison operation with more than four bits by cascading two or more 4-bit comparators.
- When two comparators are to be cascaded, the outputs of the lower-order comparator is connected to corresponding input of the higher-order comparator.
Digital comparator
Applications of Comparators –
- They are used in central processing units (CPUs) and microcontrollers (MCUs).
- They are used in control applications where the binary numbers represents physical variables such as temperature, position, etc. and are compared with a reference value.
- They are also used as process controllers and Servo motor controllers.
- They are used in password verification and biometric applications too.
Q6) Explain even parity generator with example.
A6)
A 3-bit message is transmitted with an even parity bit. Hence assuming, the three inputs W,X and Y that are applied to the circuits and output bit is the parity bit P. The total number of 1s must be even, to generate the even parity bit P.
3- bit message | Even Parity | ||
W | X | Y | P |
0 | 0 | 0 | 0 |
0 | 0 | 1 | 1 |
0 | 1 | 0 | 1 |
0 | 1 | 1 | 0 |
1 | 0 | 0 | 1 |
1 | 0 | 1 | 0 |
1 | 1 | 0 | 0 |
1 | 1 | 1 | 1 |
The K-map simplification for 3-bit message even parity generator is
From the above K-Map, the expression is:
P=W′X′Y+W′XY′+WX′Y′+WXY
P=W′(X′Y+XY′)+W(X′Y′+XY)
P=W′(X⊕Y)+W(X⊕Y)′=W⊕X⊕Y
Q7) Explain even parity checker with example.
A7)
Assume a 3-bit binary input, W, X and Y is transmitted along with an even parity bit, P. So, the resultant data contains 4 bits, that is received as the input of even parity checker.
It generates an even parity bit, E. This bit is zero, if the received data contains an even number of ones, which indicates that there is no error in the received data and vice versa.
The Truth table of an even parity checker is:
4-bit Received Data WXYP | Even Parity Check bit E |
0000 | 0 |
0001 | 1 |
0010 | 1 |
0011 | 0 |
0100 | 1 |
0101 | 0 |
0110 | 0 |
0111 | 1 |
1000 | 1 |
1001 | 0 |
1010 | 0 |
1011 | 1 |
1100 | 0 |
1101 | 1 |
1110 | 1 |
1111 | 0 |
The Boolean function of even parity check bit as
E = W xor X xor Y xor P
The following figure shows the circuit diagram of even parity checker.
Q8) Convert Gray code To Binary Code.
A8)
Then the K-maps:
And B3 = G3
The realization of Gray-to-Binary converter is
Q9) Implement 3:8 Decoder.
A9)
D0 is high when X = 0, Y = 0 and Z = 0. Hence,
D0 = X’ Y’ Z’
Similarly,
D1 = X’ Y’ Z
D2 = X’ Y Z’
D3 = X’ Y Z
D4 = X Y’ Z’
D5 = X Y’ Z
D6 = X Y Z’
D7 = X Y Z
Hence,
Decoder
Q10) Explain K-map representation upto 4 variables.
A10)
- Karnaugh map method or K-map method is the pictorial representation of the Boolean equations and Boolean manipulations are used to reduce the complexity in solving them. These can be considered as a special or extended version of the ‘Truth table’.
- Karnaugh map can be explained as “An array containing 2k cells in a grid like format, where k is the number of variables in the Boolean expression that is to be reduced or optimized”. As it is evaluated from the truth table method, each cell in the K-map will represent a single row of the truth table and a cell is represented by a square.
- The cells in the k-map are arranged in such a way that there are conjunctions, which differ in a single variable, are assigned in adjacent rows. The K-map method supports the elimination of potential race conditions and permits the rapid identification.
- By using Karnaugh map technique, we can reduce the Boolean expression containing any number of variables, such as 2-variable Boolean expression, 3-variable Boolean expression, 4-variable Boolean expression and even 7-variable Boolean expressions, which are complex to solve by using regular Boolean theorems and laws.
Minimization with Karnaugh Maps and advantages of K-map:
- K-maps are used to convert the truth table of a Boolean equation into minimized SOP form.
- Easy and simple basic rules for the simplification.
- The K-map method is faster and more efficient than other simplification techniques of Boolean algebra.
- All rows in the K-map are represented by using square shaped cells, in which each square in that will represent a minterms.
- It is easy to convert a truth table to k-map and k-map to Sum of Products form equation.
Grouping of K-map variables
- There are some rules to follow while we are grouping the variables in K-maps. They are
- The square that contains ‘1’ should be taken in simplifying, at least once.
- The square that contains ‘1’ can be considered as many times as the grouping is possible with it.
- Group shouldn’t include any zeros (0).
- A group should be the as large as possible.
- Groups can be horizontal or vertical. Grouping of variables in diagonal manner is not allowed.
- If the square containing ‘1’ has no possibility to be placed in a group, then it should be added to the final expression.
- Groups can overlap.
- The number of squares in a group must be equal to powers of 2, such as 1, 2, 4, 8 etc.
- Groups can wrap around. As the K-map is considered as spherical or folded, the squares at the corners (which are at the end of the column or row) should be considered as they adjacent squares.
- The grouping of K-map variables can be done in many ways, so they obtained simplified equation need not to be unique always.
- The Boolean equation must be in must be in canonical form, in order to draw a K-map.
2 variable K-maps
There are 4 cells (22) in the 2-variable k-map. It will look like (see below image)
The possible min terms with 2 variables (A and B) are A.B, A.B’, A’. B and A’. B’. The conjunctions of the variables (A, B) and (A’, B) are represented in the cells of the top row and (A, B’) and (A’, B’) in cells of the bottom row. The following table shows the positions of all the possible outputs of 2-variable Boolean function on a K-map.
A general representation of a 2 variable K-map plot is shown below.
When we are simplifying a Boolean equation using Karnaugh map, we represent each cell of K-map containing the conjunction term with 1. After that, we group the adjacent cells with possible sizes as 2 or 4. In case of larger k-maps, we can group the variables in larger sizes like 8 or 16.
The groups of variables should be in rectangular shape that means the groups must be formed by combining adjacent cells either vertically or horizontally. Diagonal shaped or L-shaped groups are not allowed. The following example demonstrates a K-map simplification of a 2-variable Boolean equation.
Example
Simplify the given 2-variable Boolean equation by using K-map.
F = X Y’ + X’ Y + X’Y’
First, let’s construct the truth table for the given equation,
We put 1 at the output terms given in equation.
In this K-map, we can create 2 groups by following the rules for grouping, one is by combining (X’, Y) and (X’, Y’) terms and the other is by combining (X, Y’) and (X’, Y’) terms. Here the lower right cell is used in both groups.
After grouping the variables, the next step is determining the minimized expression.
By reducing each group, we obtain a conjunction of the minimized expression such as by taking out the common terms from two groups, i.e., X’ and Y’. So, the reduced equation will be X’ +Y’.
3 variable K-maps
For a 3-variable Boolean function, there is a possibility of 8 output min terms. The general representation of all the min terms using 3-variables is shown below.
A typical plot of a 3-variable K-map is shown below. It can be observed that the positions of columns 10 and 11 are interchanged so that there is only change in one variable across adjacent cells. This modification will allow in minimizing the logic.
Up to 8 cells can be grouped in case of a 3-variable K-map with other possibilities being 1, 2 and 4.
Example
Simplify the given 3-variable Boolean equation by using k-map.
F = X’ Y Z + X’ Y’ Z + X Y Z’ + X’ Y’ Z’ + X Y Z + X Y’ Z’
First, let’s construct the truth table for the given equation,
We put 1 at the output terms given in equation.
There are 8 cells (23) in the 3-variable k-map. It will look like (see below image).
The largest group size will be 8 but we can also form the groups of size 4 and size 2, by possibility. In the 3 variable Karnaugh map, we consider the left most column of the k-map as the adjacent column of rightmost column. So, the size 4 group is formed as shown below.
And in both the terms, we have ‘Y’ in common. So, the group of size 4 is reduced as the conjunction Y. To consume every cell which has 1 in it, we group the rest of cells to form size 2 group, as shown below.
The 2-size group has no common variables, so they are written with their variables and its conjugates. So, the reduced equation will be X Z’ + Y’ + X’ Z. In this equation, no further minimization is possible.
4 variable K-maps
There are 16 possible min terms in case of a 4-variable Boolean function. The general representation of minterms using 4 variables is shown below.
A typical 4-variable K-map plot is shown below. It can be observed that both the columns and rows of 10 and 11 are interchanged.
The possible numbers of cells that can be grouped together are 1, 2, 4, 8 and 16.
Example
Simplify the given 4-variable Boolean equation by using k-map. F (W, X, Y, Z) = (1, 5, 12, 13)
Sol: F (W, X, Y, Z) = (1, 5, 12, 13)
By preparing k-map, we can minimize the given Boolean equation as
F = W Y’ Z + W ‘Y’ Z