Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Prove that the NAND gate is universal by showing how to build the AND, OR, and NOT functions using a two-input NAND gate.

Short Answer

Expert verified

According to DeMorgan’s law, the complement of the OR of two values is equal to the AND of their complements and the complement of the AND of two values is equal to the OR of their complements.

Using this law, the AND function for two values X and Y can be built asXY=X·Y¯¯

The OR function can be built asX+Y=X¯·Y¯¯.

The NOT function can be built asX¯=X·X¯.

Step by step solution

01

DeMorgan’s theorem is a set of rules for boolean expressions for AND, OR, NOT functions

According to DeMorgan’s theorem,

A·B¯=A¯+B¯A+B¯=A¯·B¯

02

Build AND function using two-input NAND gate

To build AND function using NAND gate, two NAND gates are required. The value X and Y is passed to the first NAND gate and the output of the first gate is passed to both inputs of the second NAND gate.

03

Build OR function using a two-input NAND gate

To build OR function using NOR gate, two NOR gates are required. The same value X is passed to the both inputs of the first NAND gate and Y to the inputs of both inputs to the second NAND gate. The output of these two NAND gates is passed to the third NOR gate. The output of the third NOR gate is equal to the OR function.

04

Build NOT function using two-input NAND gate

To build a NOT function using a NAND gate, one NAND gate is required. The input to the NAND gate is a tie of the two inputs together.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

See all solutions

Recommended explanations on Computer Science Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free