Sample Lab Report
Sample Lab Report
LAB REPORT
Course Name: Digital Logic Design
Section: 02
Experiment Number: 05
Remarks:
Title: Binary Arithmetic
Objectives:
Understand the concept of binary addition and subtraction.
Learn about half and full binary adders.
Perform binary addition and subtraction.
Understand the concept of BCD addition and implement a BCD adder.
Theory:
Arithmetic operation is one of the most common functions encountered by a digital computer.
The most basic arithmetic operation is the addition of two binary digits. There are four
possible outcomes of binary addition for four possible combinations. These are; 0+0=0,
0+1=1, 1+0=0 and 1+1=10. The first three operation produces outcome of 1 bit, while the last
operation produces an outcome of 2 bits. Among the two bits the higher significant bit is
called ‘carry’. The carry obtained from the addition of two bits is added to the next higher
order pair of significant bits.
Half Adder: The combinational circuit that performs the addition operation between two
bits is called a half adder. It produces a sum bit (S) and a carry bit (C) as output.
A B C S
0 0 0 0
0 1 0 1
1 0 0 1
1 1 1 0
Fig: Half Adder Diagram and truth table
Full Adder: The combinational circuit that performs the addition operation of three bits;
two significant bits and a previously carry bit is called a full adder.
Cin A B Cout S
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
In this experiment, at first we had to draw the half adder circuit using a XOR gate and a
AND gate connected to the XOR gate. The output of the XOR gate gives the ‘Sum’ value
and the output of the AND gate connected to the XOR gate shows the ‘Carry’ value. Then
clicking on the ‘Edit viewed circuit’s subcircuit appearance’ option we edited the
subcircuit placing its components in the right place and save the subcircuit. Then using
two half adder subcircuit we draw a full adder where the first half adder takes the binary
inputs and produces the ‘Sum’ which forwards to the second half adder as input. The
‘Carry’ value of each of the half adder are connected to an OR gate which gives out the
final ‘Carry out’ value and the second half adder gives out the final ‘Sum’ value of the
operation as outputs. Thus a full adder is produced using two half adder. Again, we edit
and save the subcircuit of the full adder the same way we did for the subcircuit of half the
adder.
With the help of a full adder subcircuit we produce a Binary Adder Subtractor. For this
we connect a NOT gate to the second input. We draw a Ripple-Through-Carry Adder
using 4 full adder to perform operation for 4 bit digit. It forms a relation between the bits
by acting as a Carry propagator. We used splitters to take 1 input of 4 bits. Using the
Ripple-Through-Carry Adder we can perform both addition and subtraction operation. In
this case, during addition operation, the Cin (Carry in) should be set to 0 whereas during
subtraction operation, we add a NOT gate with the input that is to be subtracted and the
Cin (Carry in) is set to 1. Then we draw the BCD adder using two full adders. The inputs
are connected to the first full adder which then propagates to AND and OR gates and
finally to the second half adder. Splitters are used to show the 4 bit outputs together.
Finally, we fill up the data tables by performing the arithmetic operations using different
types of Adders that we drew.
This experiment teaches how different types of Adders are built using the basic binary
addition concept in order to perform both addition and subtraction operations. The
concepts of this experiment is very important to understand the related topics of the
theory course properly. Hopefully, now it will be easier for me to understand the lectures
of the theory classes better.