Combinational Circuits
By : Ali Mustafa
Multiplexer
Also called Data selector
A digital circuit which selects one of the n data
inputs and route it to the single output.
Select lines (n) and Input lines are (2n)
Multiplexer
E is enable input
Useful for cascading
Its a active low terminal
It will perform the required operation when it is
low
Multiplexer acts like a multiple way switch
The output get connected to only one of the n
data inputs at given instant of time
Necessity of Multiplexer
In most of the digital circuits, data is available
on more than 1 line
It is essential to route this data over a single
line
It reduces the number of wires,complexity,cost
Classification of Multiplexer
2:1 multiplexer
4:1 multiplexer
8:1 multiplexer
16:1 multiplexer
2 : 1 Multiplexer
Data inputs are 2 (D0,D1)
Select input is 1 (S) Enable S Output
0 X
S S D1 D0 1 0 D0 ESD0
1 1 D1 ESD1
AND
SD0
OR AND OUTPUT
AND SD1
E
4 : 1 Multiplexer
Data inputs are 4 (I0 - I3)
Select input are 2 (S1 , S2)
8 : 1 Multiplexer
Data inputs are 8 (D0 D7)
Select input are 3 (S1 , S2 ,S3)
Make Truth Table
S1S2S3D0 - S1S2S3D7
D0
8:1
MUX Output
D7
E
S1 S2 S3
16 : 1 Multiplexer
Home Task
Cascading of Multiplexers
Obtain 8:1 MUX using 4:1 MUXES
D0
4:1
MUX
D3
S1 S2 Output
E
D4
4:1
MUX
D7
Cascading of Multiplexers
Obtain 16:1 MUX using 8:1 MUXES
Obtain 4:1 MUX using 2:1 MUXES
Home Task
Obtain 16:1 MUX using 4:1 MUXES
Making Connections
Direct point-to-point connections between gates
Wires we've seen so far
Route one of many inputs to a single output --- multiplexer
Route a single input to one of many outputs --- demultiplexer
control control
multiplexer demultiplexer 4x4 switch
NAND Gate Implementation of Muxes
2:1 mux
4:1 mux
Multiplexers as General-purpose Logic
2n:1 multiplexer implements any function of n
variables
With the variables used as control inputs and
Data inputs tied to 0 or 1 1 0
0 1
In essence, a lookup table 1
0
2
3
Example: 0 4 8:1 MUX F
0 5
1 6
F(A,B,C) = m0 + m2 + m6 + m7 1 7
S2 S1 S0
= A'B'C' + A'BC' + ABC' + ABC
= A'B'(C') + A'B(C') + AB'(0) + AB(1) A B C
Multiplexers as General-purpose Logic
2n-1:1 mux can implement any function of n variables
With n-1 variables used as control inputs and
Data inputs tied to the last variable or its complement
Example:
F(A,B,C) = m0 + m2 + m6 + m7
= A'B'C' + A'BC' + ABC' + ABC
1 0
= A'B'(C') + A'B(C') + AB'(0) + AB(1)
0 1 A B C F
1 2 0 0 0 1 C'
0 0 1 0 C' 0
0 3 F
F 0 1 0 1 C' 1 4:1 MUX
0 4 8:1 MUX C' 0 2
0 5 0 1 1 0
1 0 0 0 1 3 S1 S0
1 6 0
1 7 1 0 1 0
S2 S1 S0 1 1 0 1 1 A B
1 1 1 1
A B C
Example
Implement the following expression using 8:1
MUX
F (a,b,c) = m (0,2,4,6)
Logic 1
2
8:1
4 MUX Output
Logic 0
a b c
Self Task
Implement the following expression
using 8:1 MUX
F (a,b,c) = m (1,3,4,6)
F (a,b,c) = m (1,3,4,6) + d (2)
Decrementation in MUX
D0 D1 D2 D3
8 Inputs 16 Inputs
a 0 1 2 3 reduces to 4. reduces to 8.
8:1 4:1 16:1 8:1
a 4 5 6 7
a a 1 0
D0 D1 D2 D3 D4 D5 D6 D7
a 0 1 2 3 4 5 6 7
a 8 9 10 11 12 13 14 15
a 1 0 a a 0 1 a
Example
Implement the logic function using 4:1 MUX
F (a,b,c) = m (1,3,4,6)
Logic 1
D0 D1 D2 D3
0 a 0 1 2 3
2 a 4 5 6 7
Output a a a a
8:1
4 a a
MUX
6
4:1 Output
MUX
Logic 0
c b a
c b
Solve This
F(a,b,c) = m0 + m2 + m6 + m7 using 4:1 MUX
F (a,b,c,d) = m (2,4,5,7,10,14) using 8:1 MUX
F (a,b,c,d,e) = m (2,4,5,7,10,14,15,17,25,26,30,31)
using 16:1 MUX