Vous êtes sur la page 1sur 3

Adder: In electronics, an adder or summer is a digital circuit that performs addition of numbers.

In many computers and other kinds of processors, adders are used not only in the arithmetic logic unit(s), but also in other parts of the processor, where they are used to calculate addresses, table indices, and similar. Although adders can be constructed for many numerical representations, such as Binary-coded decimal or excess-3, the most common adders operate on binary numbers. In cases where two's complement or one's complement is being used to represent negative numbers, it is trivial to modify an adder into an adder-subtractor. Other signed number representations require a more complex adder. Half adder:

Fig: half adder logic diagram A half adder adds two one-bit binary numbers A and B. It has two outputs, Sum(S) and Carry(C).The simplest half-adder design, incorporates an XOR gate for S and an AND gate for C.
y y y

The simplest case arises when two one bit numbers are to be added. With one bit, only the numbers 0 and 1 can be represented. All possible scenarios can be summarized by the following table: Binary/Decimal Decimal Binary Inputs Result Result A B D Y1 Y0 0 0 0 00 0 1 1 01 1 0 1 01 1 1 2 10

y y y

The least significant bit of the output, Y0, is the result of XOR-ing the inputs. The other bit, Y1, results from AND-ing A and B. The bit Y1 is called the carry bit.
B Carry = A. B

Boolean Expression of Half Adder: Sum = A

Full Adder: The main difference between the Full Adder and the previous seen Half Adder is that a full adder has three inputs, the same two single bit binary inputs A and B as before plus an additional Carry-In (C-in) input as shown below. Full Adder with Carry-In

The 1-bit Full Adder circuit shown below is basically two half adders connected together and consists of three Ex-OR gates, two AND gates and an OR gate, six logic gates in total. The truth table for the full adder includes an additional column to take into account the Carry-in input as well as the summed output and carry-output. 4-bit full adder circuits are available as standard IC packages in the form of the TTL 74LS83 or the 74LS283 which can add together two 4-bit binary numbers and generate a SUM and a CARRY output. But what if we wanted to add together two n-bit numbers, then n 1-bit full adders need to be connected together to produce what is known as the Ripple Carry Adder.

We have seen that the output of the quarter adder is HIGH when either input, but not both, is HIGH. It is only when both inputs are HIGH that the AND gate is activated and a carry is produced. The largest sum that can be obtained from a half adder is 102 (12 plus 12). FULL ADDER The full adder becomes necessary when a carry input must be added to the two binary digits to obtain the correct sum. A half adder has no input for carries from previous circuits. One method of constructing a full adder is to use two half adders and an OR gate as shown in figure. The inputs A and B are applied to gates 1 and 2. These make up one half adder. The sum output of this half adder and the carry-from a previous circuit become the inputs to the second half adder. The carry from each half adder is applied to gate 5 to produce the carry-out for the circuit. Now lets add a series of numbers and see how the circuit operates. First, lets add 1 and 0. When either A or B is HIGH, gate 1 has an output. This output is applied to gates 3 and 4. Since the carry-in is 0, only gate 3 will produce an output. The sum of 12 and 0 is 12. Now lets add 12 and

12. If A and B are both HIGH, the output of gate 1 is LOW. When the carry-in is 0 (LOW), the output of gate 3 is LOW. Gate 2 produces an output that is applied to gate 5, which produces the carry-out. The sum of 12 and 12 is 102, just as it was for the half adder. When A and B are both LOW and the carry-in is 1, only gate 3 has an output and produces a sum of 12 with no carry-out. Now, lets add A or B and a carry-in. For example, lets assume that A is HIGH and B is LOW. With these conditions, gate 1 will have an output. This output and the carry-in applied to gates 3 and 4 will produce a sum out of 0 and a carry of 1. This carry from gate 4 will cause gate 5 to produce a carry-out. The sum of A and a carry (12 plus 12) is 102.

Vous aimerez peut-être aussi