A NAND gate is a logic gate used to build digital logic circuits. It is a combination of an AND and NOT gate. The name refers to this. The NAND gate is a “universal gate”, that means all other types of logic gates can be obtained by wiring exclusively one or more NAND gates in a particular manner.
Behavior[change | change source]
Given two inputs, A and B, A NAND B will be true if at most one of A and B is true. In other words, A NAND B is false if both A and B are true, and true otherwise.
|A||B||A ⊼ B|
Symbols[change | change source]
There are three symbols for drawing NAND gates in electrical circuit schematics: the "distinctive shape" symbol, the “military” symbol, and the “rectangular” symbol. For more information see logic gate symbols.
“Distinctive shape” NAND symbol, also that used by US ANSI
“Military” NAND symbol, also that used by DIN
“Rectangular” NAND symbol, used by IEC
Application[change | change source]
Since a NAND gate is a universal gate, microprocessors can be built using this type of gate only. For example:
- the negation can be represented by ¬A ≡ A ⊼ A
- and the disjunction can be obtained by A ∨ B ≡ (A ⊼ A) ⊼ (B ⊼ B)