4-bit binary full adder

bst_16.gif (2262 bytes)

Technology: CMOS

Power supply: 3-15 V

16-pin DIL


Pin connections Basic operation
Introducing adder circuits LINKS . . .

contents Back to Contents   beastie zone Back to Beastie Zone

Pin connections

4008 pin connections

The 4008 is a 4-bit binary full adder with two
4-bit data inputs
(A0 to A3, B0 to B3), a carry
(CIN), four sum outputs (S0 to S3), and
a carry output

The outputs give the sum of the two 4-bit
binary numbers.


Introducing adder circuits

Adder circuits are essential inside microprocessors as part of the ALU, or arithmetic logic unit, where the processing and manipulation of binary numbers takes place.

How does binary addition work? The simplest addition you can do is to add together two 1-bit binary numbers. Suppose the numbers are called A and B. Each of these numbers can take the values 0 or 1. There are four possible additions:

rules of binary addition

As you can see, in binary addition, 0+0=0, 0+1=1, 1+0=1 and 1+1=10. For each of these additions, you can identify a SUM digit and a CARRY digit. The truth table below shows these additions in a different form:

input B input A


0 0 0 0
0 1 0 1
1 0 0 1
1 1 1 0

What do you notice about the values in the CARRY digit and the SUM digit columns? The CARRY digit follows the truth table for an AND gate, while the SUM digit follows the truth table for an EXOR gate.

In other words, 1-bit binary addition can be carried out by a circuit which looks like this:

half adder circuit

click for simulation Click the button for a Crocodile Technology simulation of this circuit.

This circuit is called a half adder because, although it can generate a CARRY OUT, it cannot accept a CARRY IN. To see why a CARRY IN is needed, think about what happens when 2-bit, 3-bit or longer binary numbers are added:

adding 3-bit binary numbers

Use the diagram to follow the stages involved in the addition of the binary numbers A=011 and B=110. In the LSB, or least significant bit, column, there is no CARRY IN. However, the second and subsequent columns must accept a CARRY IN and generate a CARRY OUT. The final CARRY OUT provides the MSB, or most significant bit, of the answer to the addition operation. (All of this is almost identical to the addition of decimal numbers.)

In each column to the left of the LSB, there are eight possible input combinations depending on the numbers being added:

binary addition with CARRY IN

The equivalent truth table is:

input B input A


0 0 0 0 0
0 0 1 0 1
0 1 0 0 1
0 1 1 1 0
1 0 0 0 1
1 0 1 1 0
1 1 0 1 0
1 1 1 1 1

A circuit which obeys this truth table is called a full adder. You can make a full adder by linking together two half adder circuits:

using two half adders to make a full adder

click for simulation Click the button for a Crocodile Technology simulation of this circuit.

A simpler representation of a full adder is as follows:

full adder symbol

The 4008 contains four full adders which are linked to allow the addition of two 4-bit binary numbers:

4008 4-bit full adder subsystems

The addition of the high speed parallel carry subsystem speeds up the overall operation of the circuit.


Basic operation

To investigate the 4008, you need to provide binary inputs which are easily changed. In the prototype circuit shown below the A0-A3 and B0-B3 values are set by a special variety of switches, called DIL switches. DIL stands for dual-in-line. The pins of the switch are arranged in two rows on a 0.1 in matrix and fit conveniently across the central gap of the prototype board. The switches are operated with the aid of a small screwdriver. Moving the slider to the right, into the ON position, closes the switch and connects the corresponding input to a HIGH voltage. In the OFF position, the switch is open and the input becomes LOW. This is the effect of the 10 kW pull down resistor.

click for pins! 4008

4008 4-bit binary full adder test circuit

As you can see, the S0-S3 SUM outputs and the CARRY OUT pins are connected to the indicators on the lower prototype board.

What outputs would you expect when A=0 1 1 0 and B=1 1 0 0?

4008 adders can be cascaded to allow the addition of 8-bit, or longer, binary numbers.



Cross references in the Beastie Zone:


contents Back to Contents   beastie zone Back to Beastie Zone