SlideShare a Scribd company logo
1 of 18
Download to read offline
SYED HASAN SAEED
hasansaeedcontrol@gmail.com
https://shasansaeed.yolasite.com
1
Syed Hasan Saeed, Integral University,
Lucknow
DECIMAL ADDER
2
Syed Hasan Saeed, Integral University,
Lucknow
BCD ADDER:
A BCD adder should perform the following
• Add two 4-bit BCD number using straight Binary Addition.
• If the sum of two numbers is equal to or less than 9, then the sum is
valid BCD number and no correction is required.
• If the sum of two numbers is greater than 9 or carry is generated
from the sum, then the sum is not valid BCD number. Then add
0110 (6) to the sum, the result will be valid BCD number. If further
a carry is generated then add 0110 to the result.
Syed Hasan Saeed, Integral University,
Lucknow
3
Assume that two 4-bit BCD numbers are being added. In BCD
addition, there are three different cases. Let us consider one by one.
CASE 1: Sum equal to or less than 9 with carry 0
DECIMAL BCD
2 0 0 1 0
+ 3 0 0 1 1
Carry 1
SUM 5 0 0 1 0 1
Syed Hasan Saeed, Integral University,
Lucknow
4
Valid BCD NumberFinal Carry
If the sum of two numbers is less than or equal to 9 with final carry zero,
then the sum is valid BCD number and no correction is required.
Consider second case
Syed Hasan Saeed, Integral University,
Lucknow
5
CASE 2: Sum greater than 9 with carry 0
DECIMAL BCD
5 0 1 0 1
+ 7 0 1 1 1
Carry 1 1
SUM 12 0 1 1 0 0
0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
5
Invalid BCD Number
Carry
Add 6 for correction
1 0 0 1 0
0 0 1 00 0 0 1
Final Carry
1 2
Final result
Valid BCD number with
carry 1
If the sum of two numbers is greater than 9 with carry zero , and the sum is
invalid BCD number, then correction is required. Add 0 1 1 0 (6) for correction.
Final result will be the valid BCD number.
Syed Hasan Saeed, Integral University,
Lucknow
6
Syed Hasan Saeed, Integral University,
Lucknow
6
CASE 3: Sum is equal to or less than 9 with carry 1
DECIMAL BCD
8 1 0 0 0
+ 8 1 0 0 0
Carry 1
SUM 16 1 0 0 0 0
0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
6
Invalid BCD Number
Add 6 for correction
0 1 1 0
0 1 1 00 0 0 1
Final Carry
1 6
Final result Valid BCD number with
carry 1
If the sum of two numbers is equal to or less than than 9 with carry 1 , and the
sum is invalid BCD number, then correction is required. Add 0 1 1 0 (6) for
correction. Final result will be the valid BCD number.
1
DESIGN:
• In fig. 1 B3B2B1B0 and A3A2A1A0 are the BCD inputs. S3S2S1S0 and
Cout is the output of Adder 1.
• Checked the output of Adder 1, whether it is greater than or less
than 9.
• If the sum of Adder 1 is greater than 9 then the output of
combinational circuit should be 1 (i.e Cout should be high ) and
correction is required.
• Write the truth table and K-Map for combinational circuit.
• The Boolean Expression from K-Map Y= S3S2+S3S1
• The output of combinational circuit Y2 is connected to B2B1 of
Adder 2 and B3B0 are connected to the ground. Therefore B3=B0=0
• The output sum of Adder 1 is connected to Adder 2. the output of
Adder 2 is the final result of BCD addition with Carry which can be
ignored if any.
Syed Hasan Saeed, Integral University,
Lucknow
7
INPUTS OUTPUT
S
S3 S2 S1 S0 Y1
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 1
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
Syed Hasan Saeed, Integral University, Lucknow
8
SumisvalidBCDnumber.Therefore
Y=0
SumisvalidBCD
number.Therefore
Y=1
TRUTHTABLE K-Map
INPUTS OUTPUT
S
S3 S2 S1 S0 Y1
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 1
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
Syed Hasan Saeed, Integral University, Lucknow
9
SumisvalidBCDnumber.Therefore
Y=0
SumisvalidBCD
number.Therefore
Y=1
TRUTHTABLE
0 0 0 0
0 0 0 0
1 1 1 1
0 0 1 1
K-Map
S3S2
S1S0
00 01 11 10
10
11
01
00
INPUTS OUTPUT
S
S3 S2 S1 S0 Y1
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 1
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
Syed Hasan Saeed, Integral University, Lucknow
10
SumisvalidBCDnumber.Therefore
Y=0
SumisvalidBCD
number.Therefore
Y=1
TRUTHTABLE
0 0 0 0
0 0 0 0
1 1 1 1
0 0 1 1
K-Map
S3S2
S1S0
00 01 11 10
10
11
01
00
Y1=S3S2+S3S1
Syed Hasan Saeed, Integral University,
Lucknow
11
0
Output Carry
Cout
Cout
A1 AOA3 A2BO
B1B2B3
SOS1S2S3
SOS1S2S3
Cin
Cin
4-Bit Binary Adder 1
4-Bit Binary Adder 2
S3S1
S3S2
Final Sum Output
Combinational
Circuit
Not To Be Used
Fig.1:BLOCKDIAGRAMOFBCDADDER
Y1
Y2
M3 M2 M1 M0
CASE 1: Sum equal to or less than 9 with carry 0
DECIMAL BCD
2 0 0 1 0
+ 1 0 0 0 1
Carry 0
SUM 3 0 0 0 1 1
Syed Hasan Saeed, Integral University,
Lucknow
12
Valid BCD NumberFinal Carry
Output of combinational circuit Y2= 0, M3 M2 M1 M0 = 0
Output of Adder 2 is same as the output of Adder 1
Syed Hasan Saeed, Integral University,
Lucknow
13
0
Output Carry
Cout
Cout
A1 AOA3 A2BO
B1B2B3
SOS1S2S3
SOS1S2S3
Cin
Cin
4-Bit Binary Adder 1
4-Bit Binary Adder 2
S3S1
S3S2
Final Sum Output
Combinational
Circuit
Not To Be Used
Fig.1:BLOCKDIAGRAMOFBCDADDER
Y1
Y2
0 0 0 10 0 1 0
0
0
0
0
0
0 0 0 0 0 0 1 1
0 0 1 1
M3 M2 M1 M0
Consider second case
Syed Hasan Saeed, Integral University,
Lucknow
14
CASE 2: Sum greater than 9 with carry 0
DECIMAL BCD
5 0 1 0 1
+ 7 0 1 1 1
Carry 1 1
SUM 12 0 1 1 0 0
0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
14
Invalid BCD Number
Carry
Add 6 for correction
1 0 0 1 0
0 0 1 00 0 0 1
Final Carry
1 2
Final result
Valid BCD number with
carry 1
Output of combinational circuit Y2= 0, M3 M2 M1 M0 = 0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
15
0
Output Carry
Cout
Cout
A1 AOA3 A2BO
B1B2B3
SOS1S2S3
SOS1S2S3
Cin
Cin
4-Bit Binary Adder 1
4-Bit Binary Adder 2
S3S1
S3S2
Final Sum Output
Combinational
Circuit
Not To Be Used
Fig.1:BLOCKDIAGRAMOFBCDADDER
Y1
Y2
0 00 1 1111
1 1 0 0
1 1
1
1
0
0
1
1
0
1 1 000
00 01
2
1000
1
M3 M2 M1 M0
0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
16
Syed Hasan Saeed, Integral University,
Lucknow
16
CASE 3: Sum is equal to or less than 9 with carry 1
DECIMAL BCD
8 1 0 0 0
+ 8 1 0 0 0
Carry 1
SUM 16 1 0 0 0 0
0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
16
Invalid BCD Number
Add 6 for correction
0 1 1 0
0 1 1 00 0 0 1
Final Carry
1 6
Final result Valid BCD number with
carry 1
1
Output of combinational circuit Y2= 1, M3 M2 M1 M0 = 0 1 1 0
Syed Hasan Saeed, Integral University,
Lucknow
17
0
Output Carry
Cout
Cout
A1 AOA3 A2BO
B1B2B3
SOS1S2S3
SOS1S2S3
Cin
Cin
4-Bit Binary Adder 1
4-Bit Binary Adder 2
S3S1
S3S2
Final Sum Output
Combinational
Circuit
Not To Be Used
Fig.1:BLOCKDIAGRAMOFBCDADDER
Y1
Y2
1 1
1
0 0 0 000
0000
0
0
0
1
1 10 0 00 0 0
1 1 10 0
0 0 0 1
0 1 1 0 61
M3 M2 M1 M0
THANK YOU
Syed Hasan Saeed, Integral University,
Lucknow
18

More Related Content

What's hot

Decoders
DecodersDecoders
Decoders
Re Man
 

What's hot (20)

Combinational Circuits & Sequential Circuits
Combinational Circuits & Sequential CircuitsCombinational Circuits & Sequential Circuits
Combinational Circuits & Sequential Circuits
 
Binary parallel adder
Binary parallel adderBinary parallel adder
Binary parallel adder
 
Multiplexers & Demultiplexers
Multiplexers & DemultiplexersMultiplexers & Demultiplexers
Multiplexers & Demultiplexers
 
Digital logic gates and Boolean algebra
Digital logic gates and Boolean algebraDigital logic gates and Boolean algebra
Digital logic gates and Boolean algebra
 
Latches and flip flop
Latches and flip flopLatches and flip flop
Latches and flip flop
 
Combinational circuits
Combinational circuits Combinational circuits
Combinational circuits
 
Chapter 5The proessor status and the FLAGS registers
Chapter 5The proessor status and the FLAGS registersChapter 5The proessor status and the FLAGS registers
Chapter 5The proessor status and the FLAGS registers
 
carry look ahead adder
carry look ahead addercarry look ahead adder
carry look ahead adder
 
Two’s complement
Two’s complementTwo’s complement
Two’s complement
 
Karnaugh map
Karnaugh mapKarnaugh map
Karnaugh map
 
Logic gates presentation
Logic gates presentationLogic gates presentation
Logic gates presentation
 
D and T Flip Flop
D and T Flip FlopD and T Flip Flop
D and T Flip Flop
 
Sequential circuits in Digital Electronics
Sequential circuits in Digital ElectronicsSequential circuits in Digital Electronics
Sequential circuits in Digital Electronics
 
Binary codes
Binary codesBinary codes
Binary codes
 
quine mc cluskey method
 quine mc cluskey method quine mc cluskey method
quine mc cluskey method
 
Logical and shift micro operations
Logical and shift micro operationsLogical and shift micro operations
Logical and shift micro operations
 
Decoders
DecodersDecoders
Decoders
 
latches
 latches latches
latches
 
BOOLEAN ALGEBRA AND LOGIC GATE
BOOLEAN ALGEBRA AND LOGIC GATE BOOLEAN ALGEBRA AND LOGIC GATE
BOOLEAN ALGEBRA AND LOGIC GATE
 
chapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructionschapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructions
 

Similar to Decimal adder

Binary code decimal Adder
Binary code decimal AdderBinary code decimal Adder
Binary code decimal Adder
Haya Butt
 
magnitude comparator.pdf
magnitude comparator.pdfmagnitude comparator.pdf
magnitude comparator.pdf
ShayanRoy10
 
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdfLecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
UmerKhan147799
 

Similar to Decimal adder (20)

Bcd adder
Bcd adderBcd adder
Bcd adder
 
PPT 2 - CA unit II 22 7-2020
PPT 2 - CA unit II 22 7-2020PPT 2 - CA unit II 22 7-2020
PPT 2 - CA unit II 22 7-2020
 
Presentation on bcd adder
Presentation on bcd adderPresentation on bcd adder
Presentation on bcd adder
 
Magnitude comparator
Magnitude comparatorMagnitude comparator
Magnitude comparator
 
Binary code decimal Adder
Binary code decimal AdderBinary code decimal Adder
Binary code decimal Adder
 
Chapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSIChapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSI
 
magnitude comparator.pdf
magnitude comparator.pdfmagnitude comparator.pdf
magnitude comparator.pdf
 
encoderdecoder.pptx
encoderdecoder.pptxencoderdecoder.pptx
encoderdecoder.pptx
 
Tirgul7
Tirgul7Tirgul7
Tirgul7
 
Binary Coded Decimal.pptx
Binary Coded Decimal.pptxBinary Coded Decimal.pptx
Binary Coded Decimal.pptx
 
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdfLecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
Lecture5 Chapter4- Design Decimal Adder and Binary Multiplier Circuits.pdf
 
Unit 2.pptx
Unit 2.pptxUnit 2.pptx
Unit 2.pptx
 
Binary coded decimal r004
Binary coded decimal   r004Binary coded decimal   r004
Binary coded decimal r004
 
DESIGN OF COMBINATIONAL LOGIC
DESIGN OF COMBINATIONAL LOGICDESIGN OF COMBINATIONAL LOGIC
DESIGN OF COMBINATIONAL LOGIC
 
combinational-circuit (1).ppt
combinational-circuit (1).pptcombinational-circuit (1).ppt
combinational-circuit (1).ppt
 
Number codes
Number codesNumber codes
Number codes
 
De boolean algebra
De boolean algebraDe boolean algebra
De boolean algebra
 
Lecture 18 M - Copy.pptx
Lecture 18 M - Copy.pptxLecture 18 M - Copy.pptx
Lecture 18 M - Copy.pptx
 
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic CircuitsFYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
 
GCD of n Numbers
GCD of n NumbersGCD of n Numbers
GCD of n Numbers
 

More from Syed Saeed

Time domain definition 6
Time domain definition 6Time domain definition 6
Time domain definition 6
Syed Saeed
 
Time domain definition 6
Time domain definition 6Time domain definition 6
Time domain definition 6
Syed Saeed
 

More from Syed Saeed (20)

Laplace transform of periodic functions
Laplace transform of periodic functionsLaplace transform of periodic functions
Laplace transform of periodic functions
 
Maximum power transfer theorem for ac network
Maximum power transfer theorem for ac networkMaximum power transfer theorem for ac network
Maximum power transfer theorem for ac network
 
Thevenin's theorem for ac network
Thevenin's theorem for ac network Thevenin's theorem for ac network
Thevenin's theorem for ac network
 
Tellegen's theorem
Tellegen's theoremTellegen's theorem
Tellegen's theorem
 
Millman's theorem
Millman's theoremMillman's theorem
Millman's theorem
 
Subsitution theorem
Subsitution theoremSubsitution theorem
Subsitution theorem
 
Max. power transfer theorem dc network (Revised)
Max. power transfer theorem dc network (Revised)Max. power transfer theorem dc network (Revised)
Max. power transfer theorem dc network (Revised)
 
Norton's theorem
Norton's theoremNorton's theorem
Norton's theorem
 
Circuit theory thevenin theorem
Circuit theory thevenin theoremCircuit theory thevenin theorem
Circuit theory thevenin theorem
 
Basic definitions & laws revised
Basic definitions & laws revisedBasic definitions & laws revised
Basic definitions & laws revised
 
Read only memory(rom)
Read only memory(rom)Read only memory(rom)
Read only memory(rom)
 
Prom
PromProm
Prom
 
FPGA
FPGAFPGA
FPGA
 
PAL
PALPAL
PAL
 
PLA
PLAPLA
PLA
 
Subtractor
SubtractorSubtractor
Subtractor
 
Quine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) methodQuine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) method
 
Time domain definition 6
Time domain definition 6Time domain definition 6
Time domain definition 6
 
Time domain definition 6
Time domain definition 6Time domain definition 6
Time domain definition 6
 
Sfg 5
Sfg 5Sfg 5
Sfg 5
 

Recently uploaded

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ssuser89054b
 
Digital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptxDigital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptx
pritamlangde
 

Recently uploaded (20)

HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
 
UNIT 4 PTRP final Convergence in probability.pptx
UNIT 4 PTRP final Convergence in probability.pptxUNIT 4 PTRP final Convergence in probability.pptx
UNIT 4 PTRP final Convergence in probability.pptx
 
Ground Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth ReinforcementGround Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth Reinforcement
 
fitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .pptfitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .ppt
 
Introduction to Artificial Intelligence ( AI)
Introduction to Artificial Intelligence ( AI)Introduction to Artificial Intelligence ( AI)
Introduction to Artificial Intelligence ( AI)
 
Introduction to Geographic Information Systems
Introduction to Geographic Information SystemsIntroduction to Geographic Information Systems
Introduction to Geographic Information Systems
 
Electromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptxElectromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptx
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
Online electricity billing project report..pdf
Online electricity billing project report..pdfOnline electricity billing project report..pdf
Online electricity billing project report..pdf
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
 
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxHOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
 
Digital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptxDigital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptx
 
Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...
 
Memory Interfacing of 8086 with DMA 8257
Memory Interfacing of 8086 with DMA 8257Memory Interfacing of 8086 with DMA 8257
Memory Interfacing of 8086 with DMA 8257
 
Computer Graphics Introduction To Curves
Computer Graphics Introduction To CurvesComputer Graphics Introduction To Curves
Computer Graphics Introduction To Curves
 
Design For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the startDesign For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the start
 
Employee leave management system project.
Employee leave management system project.Employee leave management system project.
Employee leave management system project.
 
Introduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaIntroduction to Serverless with AWS Lambda
Introduction to Serverless with AWS Lambda
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptx
 
Worksharing and 3D Modeling with Revit.pptx
Worksharing and 3D Modeling with Revit.pptxWorksharing and 3D Modeling with Revit.pptx
Worksharing and 3D Modeling with Revit.pptx
 

Decimal adder

  • 2. DECIMAL ADDER 2 Syed Hasan Saeed, Integral University, Lucknow
  • 3. BCD ADDER: A BCD adder should perform the following • Add two 4-bit BCD number using straight Binary Addition. • If the sum of two numbers is equal to or less than 9, then the sum is valid BCD number and no correction is required. • If the sum of two numbers is greater than 9 or carry is generated from the sum, then the sum is not valid BCD number. Then add 0110 (6) to the sum, the result will be valid BCD number. If further a carry is generated then add 0110 to the result. Syed Hasan Saeed, Integral University, Lucknow 3
  • 4. Assume that two 4-bit BCD numbers are being added. In BCD addition, there are three different cases. Let us consider one by one. CASE 1: Sum equal to or less than 9 with carry 0 DECIMAL BCD 2 0 0 1 0 + 3 0 0 1 1 Carry 1 SUM 5 0 0 1 0 1 Syed Hasan Saeed, Integral University, Lucknow 4 Valid BCD NumberFinal Carry If the sum of two numbers is less than or equal to 9 with final carry zero, then the sum is valid BCD number and no correction is required.
  • 5. Consider second case Syed Hasan Saeed, Integral University, Lucknow 5 CASE 2: Sum greater than 9 with carry 0 DECIMAL BCD 5 0 1 0 1 + 7 0 1 1 1 Carry 1 1 SUM 12 0 1 1 0 0 0 1 1 0 Syed Hasan Saeed, Integral University, Lucknow 5 Invalid BCD Number Carry Add 6 for correction 1 0 0 1 0 0 0 1 00 0 0 1 Final Carry 1 2 Final result Valid BCD number with carry 1 If the sum of two numbers is greater than 9 with carry zero , and the sum is invalid BCD number, then correction is required. Add 0 1 1 0 (6) for correction. Final result will be the valid BCD number.
  • 6. Syed Hasan Saeed, Integral University, Lucknow 6 Syed Hasan Saeed, Integral University, Lucknow 6 CASE 3: Sum is equal to or less than 9 with carry 1 DECIMAL BCD 8 1 0 0 0 + 8 1 0 0 0 Carry 1 SUM 16 1 0 0 0 0 0 1 1 0 Syed Hasan Saeed, Integral University, Lucknow 6 Invalid BCD Number Add 6 for correction 0 1 1 0 0 1 1 00 0 0 1 Final Carry 1 6 Final result Valid BCD number with carry 1 If the sum of two numbers is equal to or less than than 9 with carry 1 , and the sum is invalid BCD number, then correction is required. Add 0 1 1 0 (6) for correction. Final result will be the valid BCD number. 1
  • 7. DESIGN: • In fig. 1 B3B2B1B0 and A3A2A1A0 are the BCD inputs. S3S2S1S0 and Cout is the output of Adder 1. • Checked the output of Adder 1, whether it is greater than or less than 9. • If the sum of Adder 1 is greater than 9 then the output of combinational circuit should be 1 (i.e Cout should be high ) and correction is required. • Write the truth table and K-Map for combinational circuit. • The Boolean Expression from K-Map Y= S3S2+S3S1 • The output of combinational circuit Y2 is connected to B2B1 of Adder 2 and B3B0 are connected to the ground. Therefore B3=B0=0 • The output sum of Adder 1 is connected to Adder 2. the output of Adder 2 is the final result of BCD addition with Carry which can be ignored if any. Syed Hasan Saeed, Integral University, Lucknow 7
  • 8. INPUTS OUTPUT S S3 S2 S1 S0 Y1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 1 1 0 0 1 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 1 0 1 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 Syed Hasan Saeed, Integral University, Lucknow 8 SumisvalidBCDnumber.Therefore Y=0 SumisvalidBCD number.Therefore Y=1 TRUTHTABLE K-Map
  • 9. INPUTS OUTPUT S S3 S2 S1 S0 Y1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 1 1 0 0 1 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 1 0 1 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 Syed Hasan Saeed, Integral University, Lucknow 9 SumisvalidBCDnumber.Therefore Y=0 SumisvalidBCD number.Therefore Y=1 TRUTHTABLE 0 0 0 0 0 0 0 0 1 1 1 1 0 0 1 1 K-Map S3S2 S1S0 00 01 11 10 10 11 01 00
  • 10. INPUTS OUTPUT S S3 S2 S1 S0 Y1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 1 1 0 0 1 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 1 0 1 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 Syed Hasan Saeed, Integral University, Lucknow 10 SumisvalidBCDnumber.Therefore Y=0 SumisvalidBCD number.Therefore Y=1 TRUTHTABLE 0 0 0 0 0 0 0 0 1 1 1 1 0 0 1 1 K-Map S3S2 S1S0 00 01 11 10 10 11 01 00 Y1=S3S2+S3S1
  • 11. Syed Hasan Saeed, Integral University, Lucknow 11 0 Output Carry Cout Cout A1 AOA3 A2BO B1B2B3 SOS1S2S3 SOS1S2S3 Cin Cin 4-Bit Binary Adder 1 4-Bit Binary Adder 2 S3S1 S3S2 Final Sum Output Combinational Circuit Not To Be Used Fig.1:BLOCKDIAGRAMOFBCDADDER Y1 Y2 M3 M2 M1 M0
  • 12. CASE 1: Sum equal to or less than 9 with carry 0 DECIMAL BCD 2 0 0 1 0 + 1 0 0 0 1 Carry 0 SUM 3 0 0 0 1 1 Syed Hasan Saeed, Integral University, Lucknow 12 Valid BCD NumberFinal Carry Output of combinational circuit Y2= 0, M3 M2 M1 M0 = 0 Output of Adder 2 is same as the output of Adder 1
  • 13. Syed Hasan Saeed, Integral University, Lucknow 13 0 Output Carry Cout Cout A1 AOA3 A2BO B1B2B3 SOS1S2S3 SOS1S2S3 Cin Cin 4-Bit Binary Adder 1 4-Bit Binary Adder 2 S3S1 S3S2 Final Sum Output Combinational Circuit Not To Be Used Fig.1:BLOCKDIAGRAMOFBCDADDER Y1 Y2 0 0 0 10 0 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 1 1 M3 M2 M1 M0
  • 14. Consider second case Syed Hasan Saeed, Integral University, Lucknow 14 CASE 2: Sum greater than 9 with carry 0 DECIMAL BCD 5 0 1 0 1 + 7 0 1 1 1 Carry 1 1 SUM 12 0 1 1 0 0 0 1 1 0 Syed Hasan Saeed, Integral University, Lucknow 14 Invalid BCD Number Carry Add 6 for correction 1 0 0 1 0 0 0 1 00 0 0 1 Final Carry 1 2 Final result Valid BCD number with carry 1 Output of combinational circuit Y2= 0, M3 M2 M1 M0 = 0 1 1 0
  • 15. Syed Hasan Saeed, Integral University, Lucknow 15 0 Output Carry Cout Cout A1 AOA3 A2BO B1B2B3 SOS1S2S3 SOS1S2S3 Cin Cin 4-Bit Binary Adder 1 4-Bit Binary Adder 2 S3S1 S3S2 Final Sum Output Combinational Circuit Not To Be Used Fig.1:BLOCKDIAGRAMOFBCDADDER Y1 Y2 0 00 1 1111 1 1 0 0 1 1 1 1 0 0 1 1 0 1 1 000 00 01 2 1000 1 M3 M2 M1 M0 0 1 1 0
  • 16. Syed Hasan Saeed, Integral University, Lucknow 16 Syed Hasan Saeed, Integral University, Lucknow 16 CASE 3: Sum is equal to or less than 9 with carry 1 DECIMAL BCD 8 1 0 0 0 + 8 1 0 0 0 Carry 1 SUM 16 1 0 0 0 0 0 1 1 0 Syed Hasan Saeed, Integral University, Lucknow 16 Invalid BCD Number Add 6 for correction 0 1 1 0 0 1 1 00 0 0 1 Final Carry 1 6 Final result Valid BCD number with carry 1 1 Output of combinational circuit Y2= 1, M3 M2 M1 M0 = 0 1 1 0
  • 17. Syed Hasan Saeed, Integral University, Lucknow 17 0 Output Carry Cout Cout A1 AOA3 A2BO B1B2B3 SOS1S2S3 SOS1S2S3 Cin Cin 4-Bit Binary Adder 1 4-Bit Binary Adder 2 S3S1 S3S2 Final Sum Output Combinational Circuit Not To Be Used Fig.1:BLOCKDIAGRAMOFBCDADDER Y1 Y2 1 1 1 0 0 0 000 0000 0 0 0 1 1 10 0 00 0 0 1 1 10 0 0 0 0 1 0 1 1 0 61 M3 M2 M1 M0
  • 18. THANK YOU Syed Hasan Saeed, Integral University, Lucknow 18