Chapter 2 Logic Gates

Page 1

Chapter 2 Logic Gates


Logic Gates

• The basic building block of a digital circuit is a logic gate. • OR, AND and NOT gates are the most basic logic gates. • NOR, NAND, XOR and XNOR gates are constructed using these three basic gates. • Logic gates operate with binary numbers.

10/9/2012

Binary 0

• LOW voltage • +0 volt

Binary 1

• HIGH voltage • +5 volt RA/Sept2012-Jan2013

2


Logic Gates

NOT AND

XNOR

Basic Gates

XOR

NOR

10/9/2012

OR

NAND

RA/Sept2012-Jan2013

3


NOT Gate (Inverter)

Description

• Inverter is a logic circuit that inverts or complements its output. • If the input is 0, the output will be 1 and vice-versa.

Symbol

Logic Expression

• Y=A

Truth table

10/9/2012

A

Y

A (Input)

Y (Output)

0

1

1

0

RA/Sept2012-Jan2013

4


AND Gate

Description

• An AND gate can have two or more inputs and performs a logical multiplication. • It produces HIGH output only when all of the inputs are HIGH. • In other words, the output of an AND gate is 1 if all of the inputs are 1.

Symbol

• •

Logic Expression

• Y = AB

Truth table

10/9/2012

A B

Y

A

B

Y

0

0

0

0

1

0

1

0

0

1

1

1 RA/Sept2012-Jan2013

Serial Circuit A

B Y

Lamp Y will light when both of the input switches are closed. 5


OR Gate

Description

• An OR gate can have two or more inputs and performs a logical addition. • It produces HIGH output when one or more inputs are HIGH. • In other words, the output of an OR gate is 1 if any of the inputs are 1.

Symbol

• A • B

Logic Expression

• Y=A

+B

Truth table

A

B

Y

0

0

0

0

1

1

1

0

1

1

1

1

10/9/2012

Y

RA/Sept2012-Jan2013

Parallel circuit A B Y

Lamp Y will light when either or both of 6 the input switches are closed.


NAND Gate

Description

• NAND gate is an AND gate followed by an inverter. • It produces LOW output only when all the inputs are HIGH. • In other words, the output of an AND gate is inverted to form a NAND gate.

Symbol

• •

Logic Expression

• Y = A.B

Truth table

10/9/2012

A B

Y

A

B

Y

0

0

1

0

1

1

1

0

1

1

1

0 RA/Sept2012-Jan2013

7


NOR Gate

Description

• NOR gate is an OR gate followed by an inverter. • It produces LOW output when one or more of the inputs are HIGH. • The output of an OR gate is inverted to form a NOR gate.

Symbol

• A • B

Logic Expression

• Y=A

Truth table

10/9/2012

Y

+B

A

B

Y

0

0

1

0

1

0

1

0

0

1

1

0 RA/Sept2012-Jan2013

8


Exclusive-OR (XOR) Gate

Description

• A logic gates that produces a HIGH output only when an odd number of 1s appear at the inputs.

Symbol

• •

Logic Expression

• Y=A

Truth table

10/9/2012

A B

Y

+B

A

B

Y

0

0

0

0

1

1

1

0

1

1

1

0

RA/Sept2012-Jan2013

9


Exclusive-NOR (XNOR) Gate

Description

• A logic gates that produces a LOW output only when an odd number of 1s appear at the inputs. • In other words, the output of an XNOR gate is the complement of the XOR gate.

Symbol

• A • B

Logic Expression

• Y=A

Truth table

10/9/2012

Y

+B

A

B

Y

0

0

1

0

1

0

1

0

0

1

1

1 RA/Sept2012-Jan2013

10


Test Yourself

1. Derive the truth table and draw the logic circuit for the following Boolean expressions. Y  A B C

a)

b)

Y  A  B  AC

2. Write the Boolean expression for Y. a)

b) A

A Y

B

B Y C

C

D D

10/9/2012

RA/Sept2012-Jan2013

11


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.