Top Banner
Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1
21

Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Dec 21, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

Basic Logic Gates

Module M1.1

Section 3.1

Page 2: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

Basic Logic Gates

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

Page 3: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

X Y

Y = !X

NOT

NOT Gate -- Inverter

X Y

01

10

Page 4: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NOT

• Y = !X

• Y = X’

• Y = X

• Y = X

Page 5: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NOT

X !X !!X = X

X !X !!X0 1 01 0 1

Page 6: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

AND GateAND

X

Y

Z

Z = X & Y

X Y Z0 0 00 1 01 0 01 1 1

Page 7: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

AND

• X & Y• X Y• X Y• X * Y• XY

U

V

Page 8: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

OR Gate

OR

X

YZ

Z = X # Y

X Y Z0 0 00 1 11 0 11 1 1

Page 9: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

OR

• X # Y• X + Y• X V Y• X U Y

Page 10: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NAND GateNAND

X

Y

Z

Z = !(X & Y)

X Y Z0 0 10 1 11 0 11 1 0

Page 11: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NAND Gate

NOT-AND

X

Y

Z

W = X & Y

Z = !W = !(X & Y)

X Y W Z0 0 0 10 1 0 11 0 0 11 1 1 0

W

Page 12: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NOR Gate

NOR

X

YZ

Z = !(X # Y)

X Y Z0 0 10 1 01 0 01 1 0

Page 13: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NOR Gate

NOT-OR

X

Y

W = X # Y

Z = !W = !(X # Y)

X Y W Z0 0 0 10 1 1 01 0 1 01 1 1 0

ZW

Page 14: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NAND Gate

X

Y

X

Y

Z Z

Z = !(X & Y) Z = !X # !Y

=

X Y W Z0 0 0 10 1 0 11 0 0 11 1 1 0

X Y !X !Y Z0 0 1 1 10 1 1 0 11 0 0 1 11 1 0 0 0

Page 15: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

De Morgan’s Theorem-1

!(X & Y) = !X # !Y

• NOT all variables• Change & to # and # to &• NOT the result

Page 16: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

NOR Gate

X

YZ

Z = !(X # Y)

X Y Z0 0 10 1 01 0 01 1 0

X

YZ

Z = !X & !Y

X Y !X !Y Z0 0 1 1 10 1 1 0 01 0 0 1 01 1 0 0 0

Page 17: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

De Morgan’s Theorem-2

!(X # Y) = !X & !Y

• NOT all variables• Change & to # and # to &• NOT the result

Page 18: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

De Morgan’s Theorem

• NOT all variables

• Change & to # and # to &

• NOT the result

• --------------------------------------------

• !X # !Y = !(!!X & !!Y) = !(X & Y)

• !(X & Y) = !!(!X # !Y) = !X # !Y

• !X & !Y = !(!!X # !!Y) = !(X # Y)

• !(X # Y) = !!(!X & !Y) = !X & !Y

Page 19: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

Exclusive-OR Gate

X Y ZXOR

XY

Z

Z = X $ Y

0 0 00 1 11 0 11 1 0

Page 20: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

X Y

X !X Y !Y

Exclusive-OR Gate

0 0 1 1 0 0 00 1 1 0 1 0 11 0 0 1 0 1 11 1 0 0 0 0 0

X Y !X !Y !X&Y X&!Y Z

Page 21: Introduction to Computer Engineering by Richard E. Haskell Basic Logic Gates Module M1.1 Section 3.1.

Introduction to Computer Engineering by Richard E. Haskell

ProblemX Y

X !X Y !Y

Z

Write the logic equation for Z in terms of X and Y