1. Nov 22, 2015

### DiamondV

I don't understand the second row of the truth table. If A is 0 and B is also 0 how is there a carry of 1 and a sum of 1. 0+0=0

2. Nov 22, 2015

### Staff: Mentor

There are three inputs to that table, not two. They are A, B, and C-in.

3. Nov 22, 2015

### DiamondV

Where does the 1 of carry in come from? The carry in is created from the previous binary addition isn't it? If the carry out of the first addition is 0, how can there be a carry in to the second one?

4. Nov 22, 2015

### Staff: Mentor

It comes from the previous digit. Each binary digit when added creates a carry bit to the next most significant digit.

5. Nov 22, 2015

### DiamondV

Isn't that when only 1+1 is added? Like if I add 0+1. Ill get a sum of 1 and no carry as the resulting sum is a binary digit and isnt over 1.

6. Nov 22, 2015

### Staff: Mentor

First digit 1+1 yields sum 0 carry 1.
Second digit 1+0+carry = 1+0+1 yields sum 0 carry 1.
Third digit 0+0+carry = 0+0+1 yields sum 1 carry 0
Fourth digit 0+0+carry = 0+0+0 yields sum 0 carry 0

Total sum 0100.

Does that help?

7. Nov 22, 2015

### DiamondV

Not really. I understand what your doing here with binary addition. But for some reason im not understand where the carry in of 1 exactly came from. Like in the example you gave, since the first addition is 1+1 which in binary results in 10(from the rules that ive learnt), you write down the 0 as a sum and the 1 becomes a carry for the next addition, in which you're gonna add the next two digits but also the carry from the last one. In the truth table above, the first addition is 0+0+0 which is 0 sum and 0 carry out. Since the carry out for the first addition is 0, how is there a carry in of 1 for the second addition

EDIT: Or wait? Is each row independant of other rows? So the carry in of 1 in the second row is just a value given to us, threres no reasoning behind it, is it just to show all possible values of each input A, B and carry in?

8. Nov 22, 2015

### Staff: Mentor

You are reading the table wrong. Each row in the table represents one of the eight possible combinations of A, B, and carry for a single binary digit. Each row is not the result of the row above.

To add 0011+0001 you must apply the entire table four times.

9. Nov 22, 2015

### DiamondV

Ah. so for the first addition of your example of 1+1, I go to the A=1 and B=1 in the table and get the sum from there and also then use the carry out of that addition as the carry in of the next addition of 1+0 +carryin of 1

10. Nov 22, 2015

Yes