Digital Circuits and Logic Design: Lecture6-2
Digital Circuits and Logic Design: Lecture6-2
ci
si
xi
yi
ci + 1
c1
cn FA cn ” 1 c2 FA FA c0
sn – 1 s1 s0
Add ⁄ Sub
control
xn – 1 x1 x0
cn n-bit adder c0
sn – 1 s1 s0
1 = 1 + d
Carry-Out =1 if (g=1)
112341 Digital Circuits and Logic Design 2010 (KTS)
Carry-lookahead adder
1 = d+ 1
c1 = g0 + p0c0
Now, we write it for c2.
c2 = g1 + p1c1
c2 = g1 + p1(g0 + p0c0)
= g1 + p1g0 + p1p0c0
112341 Digital Circuits and Logic Design 2010 (KTS)
Carry-lookahead adder
Let's go one more step further:
c3 = g2 + p2c2
= g2 + p2(g1 + p1g0 + p1p0c0)
= g2 + p2g1 + p2p1g0 + p2p1p0c0
Already, you should be able to detect a pattern.
By following the same pattern, you'd expect:
c4 = g3 + p3g2 + p3p2g1 + p3p2p1g0 + p3p2p1p0c0
n-bit Adder
112341 Digital Circuits and Logic Design 2010 (KTS)
Ripple-Carry adder
g1 p1 g0 p0
c0
c2
c1
s1 s0