# Nand and Nor as Universal Gates

In this tutorial, you will learn about universal gates. You will see the implementation of NAND and NOR as universal gates by using them to create AND, OR & NOT operations.

Contents:

## Universal Gates

A logic gate or a digital electronic block is said to be universal if it can implement any Boolean function using just itself and no other kind of gates. In general, if a gate can implement AND, OR & NOT function, it is considered as a universal gate.

The NAND & NOR gates are two such universal gates as they can implement the basic functions of AND, OR & NOT. A few more examples of universal gates apart from NAND & NOR are: –

• Inhibition gates, f = A.B’ and f = A’. B are known as inhibition gates.
• Implication gates, f = A’ + B and f = B’ + A are known as implication gates.

## Properties of NAND and NOR Gate

Here are the properties of NAND and NOR listed: –

• Both are commutative.
(A.B)’ = (B.A)’ and (A + B)’ = (B + A)’
• Both are not associative. (A.(B.C)’)’ is not equal to ((AB)’C)’. Similarly, (A+(B+C)’)’ is not equal to ((A+B)’+C)’.
• The enable input for NAND is 1 and its disable input is 0.
• The enable input for NOR gate is 0 and disable input is 1.
• NAND operation is also equivalent to bubbled OR operation which means inverted inputs to the OR gate as (A.B)’ = A’ + B’ from De Morgan’s law.
• NOR operation is also equivalent to bubbled AND operation which means inverted inputs to the AND gate as (A+B)’ = B’.A’ from De Morgan’s law.

## NAND Gate as NOT Gate

As we know, the NOT operation gives the complemented form of any input. If we give the same input to a NAND gate, then we will get, (A.A)’ which is equal to A’, thus we can create a NOT gate using just one NAND gate.

Here is the figure which shows this implementation.

As shown in the figure, only 1 NAND gate is used to make NOT gate.

## NAND Gate as AND Gate

As we know, the NAND operation is the complement of AND operation. If we first obtain the NAND operation and then perform complement on it, we should get back the AND operation as applying complement twice gives us the same result back.
((A.B)’)’ = AB

Thus, we will need only two NAND gates to implement the AND gate. Here is a figure which shows this implementation.

As shown in the figure, two NAND gates are required to make an AND gate.

## NAND Gate as OR Gate

From De-Morgan’s law, we know that (A.B)’ = A’ + B’ which means the NAND operation gets converted into bubbled OR operation. If we apply complemented inputs to the NAND gate, then by De Morgan’s law, we should get back an equivalent OR operation.
(A’. B’)’ = (A’)’ + (B’)’ = A’ + B’

To implement this, we will need three NAND gates, first two to complement the inputs and a third NAND gate to perform the NAND operation on it. Here is the figure which shows this implementation.

As shown in the figure, three NAND gates are used to make an OR gate.

## NOR Gate as NOT Gate

The NOR gate can be used to implement the NOT gate the same way as we used NAND to implement NOT. If we use the same variable as the input to a NOR gate, we will get (A + A)’ = A’ as from Boolean algebra, we get A + A = A.

Thus, we can implement the NOT gate using 1 NOR gate. Here is a figure which shows this implementation.

As shown in the figure, only one NOR gate is required to make a NOT gate.

## NOR Gate as OR Gate

The OR operation is the complemented form of NOR operation, thus we can obtain it by complementing the output of a NOR gate as ((A+B)’)’ = A + B. The OR function thus can be implemented using 2 NOR gates.

Here is a figure which shows this implementation.

As shown in the figure, two NOR gates are required to make an OR gate.

## NOR Gate as AND Gate

The AND gate can be implemented using NOR gate by applying De-Morgan’s law. As we know, (A+B)’ = A’. B’, so if we use complemented inputs to the NOR gate, we will get (A’ + B’)’ = (A’)’. (B’)’ = A.B.

Thus, we can obtain AND gate from NOR gate by first using two NOR gates to complement the input and then use the NOR function on it by using the third gate. Here is a figure which shows this implementation.

As shown in the figure, three NOR gates are required to make an AND gate.

## Key Points to Remember

Here are the key points to remember in “NAND and NOR as Universal Gates”.

• Universal Gates are those which can implement any Boolean function using only one kind of gate.
• Any digital component which can implement AND, OR & NOT logic is a universal gate.
• NAND gate and NOR gate are the most widely used universal gates.
• Both NAND & NOR gates are commutative but not associative.
• One NAND, two NAND, and three NAND gates are required to convert into NOT, AND & OR functions respectively.
• One NOR, two NOR, and three NOR gates are required to convert into NOT, OR & AND functions respectively.

If you find any mistake above, kindly email to [email protected]