Gates and Circuits
Three Main Gates
AND OR NOT
NAND Gates
NOT AND
TFF
TTF
TFT
FTT
A NAND BBA
Gate Diagrams
Example: MR + S
Gate Diagrams
Example:
Gate Diagrams
Example: (MR + S) (RS)’
Gate Diagrams
Exercise:
Truth Table (to Expression) to Gates
First, build the Boolean algebra expression that gives Z Z = AB + A’B’
TFF
FTF
FFT
TTT
ZBA
Truth Table to Gates
Z = AB + A’B’ Next, build the
circuit that goes with the Boolean algebra expression Z
TFF
FTF
FFT
TTT
ZBA
Boolean Expression to Gates
Exercise: (A + B’) A
Boolean Expression to Gates
Exercise: (A + B’) A
Multi-input AND and OR
What circuit corresponds to ABC? A+B+C?
Binary Addition
The first step in building our computer…
Binary Addition
TrueFalseFalseFalse
FalseTrueTrueFalse
10110
+ 1+ 0+ 1+ 0
1100
Sum
Carry
Binary Addition
000
010
001
111
CarryBA
000
110
101
011
SumBA
Sum Circuit
000
110
101
011
SumBA
Sum = AB’ + A’B
Carry Circuit
000
010
001
111
CarryBA
Carry = AB
Half Adder - Sum and Carry
4 Bit Adder
Computers represent numbers in parallel.
Exercises
Give Boolean expressions and construct circuits with the following properties (using AND, OR or NOT gates):
Exercises
A) B)
100
110
101
011
ZBA
0000
1100
1010
0110
1001
0101
0011
1111
ZCBA
Exercises
2 - Fill in a truth table and give a Boolean expression for the following circuit.