Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Logic Gates, Truth Tables, and Realization of Boolean Formulas, Study notes of Logic

The concepts of logic gates, truth tables, and the realization of boolean formulas using sum-of-products (sop) and product-of-sums (pos) forms. It includes examples of logic gates, minimizing boolean expressions, and designing a binary full adder.

What you will learn

  • What are the different types of logic gates and how do they function?
  • How do you write Boolean expressions from truth tables?
  • What is the difference between sum-of-products (SOP) and product-of-sums (POS) forms?
  • How do you minimize Boolean expressions?
  • What is a binary full adder and how is it designed?

Typology: Study notes

2021/2022

Uploaded on 09/27/2022

ubimaiorminorcessat
ubimaiorminorcessat 🇺🇸

4.4

(17)

225 documents

1 / 4

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
Lecture 4
Logic gates and truth tables
Implementing logic functions
Canonical forms
Sum-of-products
Product-of-sums
2
Logic gates and truth tables
AND X•Y XY
OR X + Y
NOT X' X
X
YZ
X Y Z
0 0 0
0 1 0
1 0 0
1 1 1
X
YZ
XY
_
X Y Z
0 0 0
0 1 1
1 0 1
1 1 1
X Y
0 1
1 0
3
Logic gates and truth tables
NAND
NOR
X
Y
XY
X Y Z
0 0 1
0 1 1
1 0 1
1 1 0
X Y Z
0 0 1
0 1 0
1 0 0
1 1 0
X
Y
+
X
YZ
Z
X
Y
4
Logic gates and truth tables
XOR
XNOR
X
YZ
Z
X
Y
X Y Z
0 0 0
0 1 1
1 0 1
1 1 0
X Y Z
0 0 1
0 1 0
1 0 0
1 1 1
X
Y
X
Y
5
Realizing Boolean formulas
F = (A•B)’ + C•D
F = C•(A+B)’
F
A
B
C
D
A
B
CF
6
Realizing truth tables
Given a truth table
1. Write the Boolean expression
2. Minimize the Boolean expression
3. Draw as gates
pf3
pf4

Partial preview of the text

Download Logic Gates, Truth Tables, and Realization of Boolean Formulas and more Study notes Logic in PDF only on Docsity!

1

Lecture 4

 Logic gates and truth tables

 Implementing logic functions

 Canonical forms

 Sum-of-products

 Product-of-sums

2

Logic gates and truth tables

 AND X•Y XY

 OR X + Y

 NOT X' X

X Y Z

X Y Z 0 0 0 0 1 0 1 0 0 1 1 1

X Y

Z

X (^) Y

_

X Y Z 0 0 0 0 1 1 1 0 1 1 1 1

X Y 0 1 1 0

3

Logic gates and truth tables

 NAND

 NOR

X • Y XY X^ Y^ Z

0 0 1 0 1 1 1 0 1 1 1 0

X Y Z 0 0 1 0 1 0 1 0 0 1 1 0

X +Y

X Y Z

Z

X Y

4

Logic gates and truth tables

 XOR

 XNOR

X Y Z

Z

X Y

X Y Z 0 0 0 0 1 1 1 0 1 1 1 0

X Y Z 0 0 1 0 1 0 1 0 0 1 1 1

X ⊕Y

X ⊕Y

Realizing Boolean formulas

 F = (A•B)’ + C•D  F = C•(A+B)’

F

A B

C D

A B C

F

Realizing truth tables

 Given a truth table

1. Write the Boolean expression

2. Minimize the Boolean expression

3. Draw as gates

7

Example

A B C F

F = A’BC’+A’BC+AB’C+ABC

= A’B(C’+C)+AC(B’+B)

= A’B+AC

8

Example: Binary full adder

 1-bit binary adder

 Inputs: A, B, Carry-in

 Outputs: Sum, Carry-out

A

B

Cin Cout

Sum Adder

A B Cin Cout Sum 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1

Cout = A'BCin + AB'Cin + ABCin' + ABCin

Both Sum and Cout can be minimized.

Sum = A'B'Cin + A'BCin' + AB'Cin' + ABCin

9

Full adder: Sum

Before Boolean minimization Sum = A'B'Cin + A'BCin'

  • AB'Cin' + ABCin

After Boolean minimization Sum = (A⊕B) ⊕ Cin

10

Full adder: Carry-out

Before Boolean minimization Cout = A'BCin + AB'Cin

  • ABCin' + ABCin

After Boolean minimization Cout = BCin + ACin + AB

Preview: 2-bit ripple-carry adder

A 1 B 1

Cin Cout

Sum 1

A 2 B 2

Sum 2

0 Cin Cout

Overflow

A

Sum

Cin Cout

B

1-Bit Adder

Many possible mappings

 Many ways to map expressions to

gates

 Example: Z = A•B•(C+D) = A•(B•(C+D))

_ _ _ _

19

Maxterms

 Variables appear exactly once in each

maxterm in true or inverted form (but

not both)

A B C maxterms 0 0 0 A+B+C M 0 0 1 A+B+C' M 0 1 0 A+B'+C M 0 1 1 A+B'+C' M 1 0 0 A'+B+C M 1 0 1 A'+B+C' M 1 1 0 A'+B'+C M 1 1 1 A'+B'+C' M

short-hand notation

F in canonical form: F(A,B,C) = ΠM(0,2,4) = M0 • M2 • M = (A+B+C)(A+B'+C)(A'+B+C)

20

Example: F = AB+C

21

From SOP to POS and back

 Minterm to maxterm

 Use maxterms that aren’t in minterm

expansion

 F(A,B,C) = ∑m(1,3,5,6,7) = ∏M(0,2,4)

 Maxterm to minterm

 Use minterms that aren’t in maxterm

expansion

 F(A,B,C) = ∏M(0,2,4) = ∑m(1,3,5,6,7)

22

From SOP to POS and back

 Minterm of F to minterm of F'

 Use minterms that don’t appear

 F(A,B,C) = ∑m(1,3,5,6,7) F' = ∑m(0,2,4)

 Maxterm of F to maxterm of F'

 Use maxterms that don’t appear

 F(A,B,C) = ∏M(0,2,4) F' = ∏M(1,3,5,6,7)

SOP, POS, and DeMorgan's

 Sum-of-products

 F' = A'B'C' + A'BC' + AB'C'

 Apply DeMorgan's to get POS

 (F')' = (A'B'C' + A'BC' + AB'C')'

 F = (A+B+C)(A+B'+C)(A'+B+C)

SOP, POS, and DeMorgan's

 Product-of-sums

 F' = (A+B+C')(A+B'+C')(A'+B+C')(A'+B'+C')

 Apply DeMorgan's to get SOP

 (F')' = ((A+B+C')(A+B'+C')(A'+B+C')(A'+B'+C'))'

 F = A'B'C + A'BC + AB'C + ABC