Flip Flops |
Next, let's address the third entry in the truth table. In that situation,
X = 1, and Y = 0.
-
If Y = 0, then Q = 1.
We know that if either input to a NAND gate is 0, the output is 1.
That's the same as before. However, this time, we take advantage
of knowing that Y = 0. Before, it was X that was equal to zero, but
X = 1 here and it doesn't help us get started.
-
Now. try to take advantage
of the knowledge that Q = 1. If Q = 1 AND X = 1, then P = 0.
-
That gives us the third
entry in the truth table above. Here's the truth table with what
we have figured out so far.
X
|
Y
|
P
|
Q
|
0
|
0
|
1
|
1
|
0
|
1
|
1
|
0
|
1
|
0
|
0
|
1
|
1
|
1
|
|
|
Finally, we have the case where X = 1 and Y = 1.
-
If X = 1, then we need
to know Q to determine P.
-
If Y = 1, then we need
to know P to determine Q.
-
We are stuck! There
is no obvious way to proceed!
There
is one way to proceed. We could just assume that P = 1, for example.
Let's try that.
-
If Y = 1, and P = 1, then
we know that Q = 0.
-
If we know that Q = 0,
it is an input to the top NAND gate, so the output there is 1.
Thus, P = 1. That's what we assumed to start with, so we don't get
a contradiction.
-
All is copasetic!
Or is it?
-
Here is the truth table.
X
|
Y
|
P
|
Q
|
0
|
0
|
1
|
1
|
0
|
1
|
1
|
0
|
1
|
0
|
0
|
1
|
1
|
1
|
1
|
0
|
|