Full Adder Using Multiplexer
Full Adder Using Multiplexer
Full Adder Using Multiplexer
The multiplexer is one of the basic building blocks of any digital design system. What it does is it
takes a number of inputs and multiplexes them onto a single output line. That is, it selects one of
the input lines, and passes its state to the output line.
Figure 1: A Multiplexer
This section discusses the basics of digital addition. Here is a block diagram of a binary adder:
Fall 2005,alnz@v1.1 1
ECE238 laboratory lecture notes – University of New Mexico
Instead of using the 8-to-1 MUX introduced in Part 1, the 4-to-1 MUX will be used to implement
the binary adder. The following is the logic diagram of the 4-to-1 MUX.
Design process
Using the truth table shown in figure 3, generate two K-maps; one K-map for the Sum, and one
for the Carry Out.
Let's take a few moments to inspect this Karnaugh map. Note that the Sum is A when B and K
are both true and false. The Sum is the complement of A when B or K is true, but not both.
Fall 2005,alnz@v1.1 2
ECE238 laboratory lecture notes – University of New Mexico
Now, how can we use this knowledge to Figure 6 shows a block diagram for the sum
create the Sum from a 4-to-1 MUX? Recall implemented using 4x1 MUX.
that the output is either A or the complement
of A. This makes things easier. Also, notice
how the 4-to-1 MUX has two control lines, A
S1, and S2. Recall that the value on the
control lines determines which input line is A
Data Selector /
passed to the output. Sum
A Multiplexor
Here is the solution:
A
S1 S2
If we tie B to S1 and K to S2, then we can tie
A to input lines 0 and 3 (00 and 11). Then
we must tie the complement of A to input B
lines 1 and 2 (01 and 10). This allows us to K
use a 4-to-1 MUX to produce the Sum.
Figure 6. Block diagram for SUM
Now, inspect the K-map shown in figure 7 for a moment. Think of how we could use this K-map to
produce the Carry-Out using a 4-to-1 MUX.
If you want to add bigger numbers, you can cascade several binary adders together to produce
the sum.
Fall 2005,alnz@v1.1 3
ECE238 laboratory lecture notes – University of New Mexico
This section discusses the basics of digital subtraction. Here is a block diagram of a binary
subtractor.
This subtractor will work on two one-bit numbers X and Y. Figure 9 shows the truth table for the
subtractor.
Fall 2005,alnz@v1.1 4