Activity
A |
Fill in the rest of
the AND truth table
|
OR GATE
The
OR gate produces a 1 if at least one input is 1. Otherwise a 0 is
produced.
Have
a look...
Here
is part of a truth table for the OR gate:-
~Now
try the activity~
Activity
B |
Fill in the rest of
the OR truth table
|
NOT GATE
The
NOT gate inverts an input so a 1 becomes a 0 and a 0 becomes a 1.
Have
a look...
Here
is part of a truth table for the NOT gate:-
~Now
try the activity~
Activity
C |
Fill in the rest of
the NOT truth table
|
NAND GATE
The
NAND gate produces outputs the inverse of those for the AND gate.
Have
a look...
Here
is part of a truth table for the NAND gate:-
~Now
try the activity~
Activity
D |
Fill in the rest of
the NAND truth table
|
NOR GATE
The
NOR gate produces outputs the inverse of those for the OR gate
Have
a look...
Here
is part of a truth table for the NOR gate:-
~Now
try the activity~
Activity
E |
Fill in the rest of
the NOR truth table
|
XOR GATE
The XOR gate produces a 1
only if one input is 1. Otherwise a 0 is
produced.
Have
a look...
Here
is part of a truth table for the XOR gate:-
x
|
y
|
Q = (X.Y
+ X.Y)
|
0
|
0
|
0
|
0
|
|
|
|
|
|
|
|
|
~Now
try the activity~
Activity
F |
Fill in the rest of
the XOR truth table
|
Combinations
and Arithmetic
Combining Logic Gates
Logic
gates can be combined to form logic circuits. Consider the combination of
an OR gate and a NOT gate.
Here
is part of a truth table for this circuit:-
A
|
B
|
A + B
|
A
+ B
|
0
|
0
|
0
|
1
|
0
|
|
|
|
|
|
|
|
|
|
|
|
~Now
try the activity~
Activity
G |
-
Fill in the rest of
the truth table above.
Which
logic function does the circuit simulate - AND, OR, NOT, NAND, NOR or
XOR?
-
Draw
two logic gates that simulate a NAND gate.
|
Binary Addition
How
can we use logic gates to carry out computer arithmetic?
Let's
suppose we wish to add two binary digits X and Y. Considering the
following table:-
X
|
Y
|
Carry
|
Sum
|
0
|
0
|
0
|
0
|
0
|
1
|
0
|
1
|
1
|
0
|
0
|
1
|
1
|
1
|
1
|
0
|
When
we add two binary digits, we may get the result of 00, 01, or 10. We can
consider the left bit to be a carry bit. Now consider the 0's and 1's as
two signals. We require two input signals and two output signals.
I.e.
How
can we use gates to construct this half-adder. Consider the following circuit:-
This
circuit simulates the sum operation where the two inputs are 0 and the
output is 0.
Can
this circuit be used to simulate the other three sum operations? Try the
activity and find out.
~Now
try the activity~
Activity
H |
-
Check the circuit
above to see if it can be used to simulate the other three sum
operations.
-
Consider the inputs
to a half-adder and the carry bit produced. Which logic gate
could be used to represent this operation?
|
Exercises
Now
try the following.
Exercises:
-
Draw
a truth table for the function Q1 = X.Y.Z
+ X.Y.Z
-
Draw
a truth table for the function Q2 = A.B.C + A.B.C
+ A.B.C + A.B.C
-
Draw
a truth table for the function Q2 . Q3 where Q3
= Q1. Note:
Q2 and Q2 are defined above
-
Produce
a truth table that defines the difference between two inputs X and Y. Hint:
Consider the truth table for the sum operation. This time though we
need a difference column and a borrow column.
-
Add
a carry circuit to a sum circuit to produce a complete half-adder circuit.
Question
1
|
That's it!!