A More Effective Realization of BCD Adder by Using A New Reversible Logic BBCDC
A More Effective Realization of BCD Adder by Using A New Reversible Logic BBCDC
A More Effective Realization Of BCD Adder By Using A New Reversible Logic BBCDC
Shefali Mamataj1,Biswajit Das2,Anurima Rahaman3
1 2
Assistant Professor, Department of ECE Murshidabad College of Engineering &Technology,Berhampore, Assistant Professor, Department of CSE, Murshidabad College of Engineering &Technology,Berhampore 3 B.Tech Student, Department of AEIE, Future Institute of Engineering and Management,Sonarpur
Abstract:
Reversible logic is one of the emerging technologies having promising applications in quantum computing nanotechnology, and low power CMOS design. The main purposes of designing reversible logic are to decrease quantum cost, depth of the circuits and the number of garbage outputs. With the advent of quantum computer and reversible logic, design and implementation of all devices has received more attention. BCD digit adder is the basic unit of the more precise decimal computer arithmetic. This paper represents a new reversible logic BBCDC and also a more effective realization of BCD adder by using the proposed reversible logic. A comparative result is presented which shows that the proposed design is more effective in terms of number of gates and number of garbage outputs than the existing designs.
KEYWORDS: Reversible logic, Basic Reversible Gates, BCD adder , Reversible full adder, Constant
input, Garbage ,Quantum cost. 1. Introduction
I.
INTRODUCTION
In electronics hardware designing energy dissipation is one of the most important factor. Researchers like Landauer have shown that for irreversible logic computations, each bit of information lost, generates kTln2 joules of heat energy, where k is Boltzmanns constant and T the absolute temperat ure at which computation is performed [1]. Bennett showed that kTln2 energy dissipation would not occur, if a computation is carried out in a reversible way, since the amount of energy dissipated in a system bears a direct relationship to the number of bits erased during computation [2]. Reversible circuits are those circuits that do not lose information and reversible computation in a system can be performed only when the system comprises of reversible gates. These circuits can generate unique output vector from each input vector, and vice versa, that is, there is a one-to-one mapping between input and output vectors According to Moores law the numbers of transistors will double every 18 months. Thus energy conservative devices are the need of the day. The amount of energy dissipated in a system bears a direct relationship to the number of bits erased during computation. Reversible circuits are those circuits that do not lose information A circuit will be reversible if input vector can be specifically retrieved from output vectors and here is one to one correspondence between input and output [3]. A reversible logic circuit should have the following features [5]: Use minimum number of reversible gates. Use minimum number of garbage outputs. Use minimum constant inputs. Decimal arithmetic has found promising uses in the financial and commercial applications. This is due to the precise calculations required in these applications as oppose to binary arithmetic where some of decimal fractions cant be r epresented precisely [16].In the hardware design, binary computing is preferred over decimal computing because of ease in building hardware based on binary number system. In spite of ease in building binary hardware, most of the fractional decimal numbers such as 0.110 cannot be exactly represented in binary, thus their approximate values are used for performing computations in binary hardware. Because the financial, commercial, and Internet-based applications cannot tolerate errors generated by conversion between decimal and binary formats, the decimal arithmetic is receiving significant attention and efforts are being accelerated to build dedicated hardware based on decimal arithmetic [4].
||Issn 2250-3005 ||
||February||2014||
Page 13
A More Effective Realization Of BCD Adder II. BASIC REVERSIBLE LOGIC GATE
2.1.Reversible logic Function: It is an n-input n-output logic function in which there is a one-to-one correspondence between the inputs and the outputs. The reversible logic circuits must be constructed under two main constraints. They are Fan-out is not permitted. Loops or feedbacks are not permitted. In the proposed design these two constraints along with the other parameters are optimized effectively . The important parameters which play a major role in the design of an optimized reversible logic circuit are [1719] , Constants: This refers to the number of inputs that are to be maintained constant at either 0 or 1 in order to synthesize the given logical function. Garbage: This refers to the number of outputs which are not used in the synthesis of a given function. These are very essential without which reversibility cannot be achieved. Gate count: The number of reversible gates used to realize the function. Flexibility: This refers to the universality of a reversible logic gate in realizing more functions. Quantum cost: This refers to the cost of the circuit in terms of the cost of a primitive gate. It is calculated knowing the number of primitive reversible logic gates (1X1 or 2X2 ) required to realize the circuit. Gate levels: This refers to the number of levels in the circuit which are required to realize the given logic functions. 2.2. Basic Reversible logic Gates The important basic reversible logic gates are, Feynman gate [6] which is the only 2X2 reversible gate which is as shown in the figure.(1a )and it is used most popularly by the designers for fan-out purposes. There is also a double Feynman gate [7], Fredkin gate [8] and Toffoli gate [9],New Gate[10] , Peres gate[11] , all of which can be used to realize important combinational functions and all are 3X3 reversible gates and are as shown in the figure.(1b) to figure.(1e) .The figures also shows the switching functions for terminals.
||Issn 2250-3005 ||
||February||2014||
Page 14
Figure(1e) Peres gate 3X 3 gate There are other 4X4 gates some of which are specially designed for the realization of important combinational circuit functions in addition to some basic functions. Some of the important 4X4 gates are, TSG gate [13],MKG gate [12],HNG gate [14]etc, shown in figure(2a,2b,2c) all of which are very useful for the construction of important reversible adders.
2.3.Reversible logic DKFG gate A 4X4 reversible gate DKFG already had been proposed [20] shown in figure 2. In this gate the input vector is given by =(0,A,,C) and the corresponding output vector is =(,,,).
. Figure(3a): DKFG reversible gate We can use DKFG gate as a full-adder as shown in fig3b
||Issn 2250-3005 ||
||February||2014||
Page 15
A 5X5 reversible gate BBCDC (Binary to BCD conversion ) logic has been proposed in this paper (See Figure 4) for BCD adder circuit application. The Truth table for the corresponding gate is shown in TABLE I . A closer look at the Truth Table reveals that the input pattern corresponding to a specific output pattern can be uniquely determined and thereby maintaining that there is a one-to-one correspondence between the input vector and the output vector. In this gate the input vector is given by =(A,,C,D,E) and the corresponding output vector is=(,,,,T)
||Issn 2250-3005 ||
||February||2014||
Page 16
A More Effective Realization Of BCD Adder IV. CONVENTIONAL BCD ADDER CIRCUIT
A Binary Coded Decimal (BCD) adder is a circuit which adds two 4-bit BCD numbers in parallel and produces a 4-bit BCD result. Fig. 5 shows the block diagram of conventional BCD adder. The circuit must include the correction logic to produce valid BCD output. Two 4-bit BCD numbers A(A3A2A1A0) and B(B3 B2B1B0) along with carry input is added using conventional 4-bit parallel adder, 4-bit sum and a carry is taken out. If the carry output is set or if the result is greater than nine, binary 0110 is added to the intermediate sum output with the help of second stage 4-bit parallel adder circuit shown in figure5. In a BCD adder, the correction logic which generates the Cout is given by, Cout = S3S2 +S3S1+C4
V.
A BCD adder can be realized by using two parts, first part represents a four bit parallel adder and the second part gives us the appropriate addition result in the form of BCD number. The 4-bit parallel adder can be constructed using HNG gates or DKG gates or TSG gates or MKG gates. But we have designed the adder circuit by using DKFG reversible gate as a full adder. The proposed BCD adder circuit is shown in figure 6. Here two BCD numbers A(A3A2A1A0) and B (B3B2 B1B0) are to be added and we got the result of the BCD addition as S3 S2 S1 S0 and final carry output K from the adder circuit. The minimum value of the one bit BCD addition is 0(0000) and the maximum value should be 19(10011). The BCD sum cannot be greater than 19 because the range of a one bit BCD number is 0-9.Now if carry =1,then the maximum BCD sum will be 9+9+1=19.So in our proposed circuit we will get the maximum BCD sum (19) in binary form as S3=0 , S2=0, S1=1, S0=1 and K=1 .But this is not the correct BCD form .We will get the result in binary form(10011).So for getting the corrected form of BCD sum we have to convert this binary sum into BCD form by using appropriate logic. So for this we have used here a new BBCDC logic for this conversion. If we follow the truth table of BBCDC ,we can see that we can get the appropriate BCD form11001 instead of 10011 .So here S3S2S1S0 is the corrected form of BCD sum and the minimum value is CoutS3S2S1S0=00000 and the maximum value will be CoutS3S2S1S 0= 11001 which is the appropriate form of BCD sum.
||Issn 2250-3005 ||
||February||2014||
Page 17
Figure 6: Proposed BCD adder circuit TABLE III COMPARISON OF EXISTING BCD ADDERS AND PROPOSED BCD ADDER
Name of circuit I. Different parameters No. of No. of No. of Garbage Constant reversible output input gates 22 BCD adder[22] BCD adder[23] BCD adder[24] BCD adder[25] BCD adder[26] PROPOSED BCD adder 22 22 11 10 11 8 17 11 7 6 7 8 14 11 10 8 9 5 17 23
BCD adder[21]
VI.
CONCLUSION
We have realized BCD adder circuit by using DKFG and BBCDC reversible gates and made comparisons in TABLE II. The analysis of various implementations discussed is tabulated in TABLE II. It gives the comparisons of the different designs in terms of the important design parameters like number of reversible gates, number of garbage outputs, and number of constant inputs parameter. From the table it is observed that the present proposal uses least number of gates producing least number of garbage outputs. The efficient design of the BCD adder depends on the design methodology used for designing the reversible ripple carry adder and the reversible binary to BCD converter. Thus for future research, efficient design schemes for reversible ripple carry adder and the reversible binary to BCD converter is an interesting area to investigate. Alternate optimization methods are under investigation as a future work.
||Issn 2250-3005 ||
||February||2014||
Page 18
[19] [20]
||Issn 2250-3005 ||
||February||2014||
Page 19