it’s an adder that adds 2 binary values and outputs the sum and a carry
it uses an xor and an and gate to be the sum and carry
Full adder
What is a full adder
A full adder can also be realized by cascading two half adders and using an OR gate
Si=(xi)
Ripple-Carry Adder
it’s like an adder but carries the “carry” to the input of the next in a “ripple
Unsigned integers
How to multiply in a circuit
we can just add the thing thats being multiplied by n, we can just add n times
this is not that efficient
Signed integer numbers
Signed bits give sign and magnitude representation
all leading 0/1s denote pos/neg respectively
the most significant digit is the one behind the leading integer
the least significant digit is the one that is trailing
Complement Representation
For an n-digit number, N in radix r
its r ‘s complement defined as rn−N
For an n-digit number, N in radix r
its (r-1 )complement defined as rn−1−N
Simply 1s compliment is just the inverted integers of original
2’s complement
we just get 1s compliment and add 1
Half Subtractor
What is a half subtractor
it takes 2 binary values and subtracts them, placing the “negative” number into a “barrow”, the main way since there is no negatives it uses difference, and to know if it is negative you use the borrow