How can a NAND gate be used as a NOT gate?

12 replies · 4K views · last reply
moenste
Messages
711
Reaction score
12

Homework Statement


(a)

Logic symbol of a NAND gate with inputs labelled T1 (top) and T2 (bottom), a box marked with an ampersand, a bubble on the output, and output labelled X.


Truth table with columns T1, T2 and X; rows for inputs 00, 01, 10, 11 with X = 1 in the first row only and the remaining X entries blank.


The diagram represents a NAND gate with two inputs, T1 and T2, and an output X. Copy the truth table above and complete it.

Show how a NAND gate can become a NOT gate.

(b)

Logic circuit: inputs T1 and T2 feed a NAND gate at top, T2 also feeds a second NAND gate below with both inputs tied together; both NAND outputs feed a final NAND gate whose output is X.


Draw up a truth table for the combination of NAND gates shown above.

2. The attempt at a solution
(a) The truth table:

Truth table with columns T1, T2 and X showing rows 0 0 1, 0 1 1, 1 0 1, 1 1 0, the NAND gate outputs.


A NAND gate is an AND and a NOT gate:

Logic circuit with inputs A and B feeding an AND gate, whose output C goes into a NOT gate giving output Q, which together form a NAND gate.


(b) First of all, I shall add letters to the graph:

Logic circuit: inputs T1 and T2 feed a NAND gate giving P; T2 also feeds a second NAND gate with both inputs tied, giving O; P and O feed a final NAND gate with output X.


I got two truth tables and not sure which one is correct.

Two side-by-side truth tables with columns T1, T2, T2, P, O, X; the left table has rows 0 0 0 1 1 0, 1 0 0 1 1 0, 0 1 1 1 0 1, 1 1 1 0 0 1; the right table has rows 0 0 0 1 1 0, 0 1 1 1 0 1, 1 0 0 1 1 0, 1 1 1 0 0 1.


Are they both correct in this situation (so the problem has two solutions)? Looks like the answer depends on what combination does one put in the first two columns: 00 10 01 11 or 00 01 10 11 (specifically 10 01 or 01 10).
 
Your truth tables are identical.

I don't see any reason for duplicating column T2. One entry for T2 should suffice.
 
  • Like
Likes   Reactions: moenste
NascentOxygen said:
Your truth tables are identical.

I don't see any reason for duplicating column T2. One entry for T2 should suffice.
Are you sure? In the left one the output is 0011 and in the second 0101. Maybe I miss something? This doesn't look identical...

(I assume the (a) part is correct, right? Since you didn't mention it.)
 
You have swapped 2 rows, that's all.
 
  • Like
Likes   Reactions: moenste
NascentOxygen said:
You have swapped 2 rows, that's all.
But the output X is different, or it is acceptable?

In other words both solutions are correct?
 
moenste said:
But the output X is different, or it is acceptable?

In other words both solutions are correct?
There is only one solution; you have written it out twice.

For each input combination there can be only one output. There are 4 possible input combinations, the order in which you document them in a table does not matter.
 
  • Like
Likes   Reactions: moenste
withdrawn
 
Last edited:
  • Like
Likes   Reactions: moenste
NascentOxygen said:
There is only one solution; you have written it out twice.

For each input combination there can be only one output. There are 4 possible input combinations, the order in which you document them in a table does not matter.
TomHart said:
I think you may be making this problem harder than it needs to be.
Well, the output in X is different in the tables, so I thought I got it wrong somewhere.
 
withdrawn
 
Last edited:
  • Like
Likes   Reactions: moenste
TomHart said:
How many inputs and outputs does a NOT have?
One input and one output? It's an inverter.
 
moenste said:
Well, the output in X is different in the tables, so I thought I got it wrong somewhere.
Your outputs are listed in a different order only because the inputs have been listed in a different order.
 
  • Like
Likes   Reactions: moenste
NascentOxygen said:
Your outputs are listed in a different order only because the inputs have been listed in a different order.
So in sum: both tables are correct and both solutions are acceptable?
 
There is only one solution: the set of 4 outputs for 4 unique input combinations. Whatever way you tabulate these 4 lines is correct.
 
  • Like
Likes   Reactions: moenste