Está en la página 1de 49

Chapter 2

Circuitos combinacionales
Adaptado de:
Digital Design and Computer Architecture, 2nd Edition
David Money Harris and Sarah L. Harris

Chapter 2 <1>

Chapter 2 :: Topics

Introduction
Boolean Equations
Boolean Algebra
From Logic to Gates
Multilevel Combinational Logic
Xs and Zs, Oh My
Karnaugh Maps
Combinational Building Blocks
Timing

Chapter 2 <2>

Introduction
A logic circuit is composed of:
Inputs
Outputs
Functional specification
Timing specification

inputs

functional spec
timing spec

outputs

Chapter 2 <3>

Circuits
Nodes
Inputs: A, B, C
Outputs: Y, Z
Internal: n1

Circuit elements

E1

n1
E3

B
E2

E1, E2, E3
Each a circuit

Chapter 2 <4>

Y
Z

Types of Logic Circuits


Combinational Logic
Memoryless
Outputs determined by current values of inputs

Sequential Logic
Has memory
Outputs determined by previous and current values
of inputs
inputs

functional spec
timing spec

outputs

Chapter 2 <5>

Rules of Combinational Composition


Every element is combinational
Every node is either an input or connects
to exactly one output
The circuit contains no cyclic paths
Example:

Chapter 2 <6>

Boolean Equations
Functional specification of outputs in terms
of inputs
Example: S = F(A, B, Cin)
Cout = F(A, B, Cin)

A
B
Cin

C
CLL

S
Cout

S
= A B Cin
Cout = AB + ACin + BCin
Chapter 2 <7>

Some Definitions
Complement: variable with a bar over it
A, B, C
Literal: variable or its complement
A, A, B, B, C, C
Implicant: product of literals
ABC, AC, BC
Minterm: product that includes all input
variables
ABC, ABC, ABC
Maxterm: sum that includes all input variables
(A+B+C), (A+B+C), (A+B+C)
Chapter 2 <8>

Sum-of-Products (SOP) Form

All equations can be written in SOP form


Each row has a minterm
A minterm is a product (AND) of literals
Each minterm is TRUE for that row (and only that row)
Form function by ORing minterms where the output is TRUE
Thus, a sum (OR) of products (AND terms)
A
0
0
1
1

B
0
1
0
1

Y
0
1
0
1

minterm
minterm name
A B
m0
m1
A B
m2
A B
m3
A B

Y = F(A, B) =
Chapter 2 <9>

Sum-of-Products (SOP) Form

All equations can be written in SOP form


Each row has a minterm
A minterm is a product (AND) of literals
Each minterm is TRUE for that row (and only that row)
Form function by ORing minterms where the output is TRUE
Thus, a sum (OR) of products (AND terms)
A
0
0
1
1

B
0
1
0
1

Y
0
1
0
1

minterm
minterm name
A B
m0
m1
A B
m2
A B
m3
A B

Y = F(A, B) =
Chapter 2 <10>

Sum-of-Products (SOP) Form

All equations can be written in SOP form


Each row has a minterm
A minterm is a product (AND) of literals
Each minterm is TRUE for that row (and only that row)
Form function by ORing minterms where the output is TRUE
Thus, a sum (OR) of products (AND terms)
A
0
0
1
1

B
0
1
0
1

Y
0
1
0
1

minterm
minterm name
A B
m0
m1
A B
m2
A B
m3
A B

Y = F(A, B) = AB + AB = (1, 3)
Chapter 2 <11>

Product-of-Sums (POS) Form

All Boolean equations can be written in POS form


Each row has a maxterm
A maxterm is a sum (OR) of literals
Each maxterm is FALSE for that row (and only that row)
Form function by ANDing the maxterms for which the
output is FALSE
Thus, a product (AND) of sums (OR terms)
A
0
0
1
1

B
0
1
0
1

Y
0
1
0
1

maxterm
maxterm name
A
A
A
A

+
+
+
+

B
B
B
B

M0
M1
M2
M3

Y = F(A, B) = (A + B)(A + B) = (0, 2)


Chapter 2 <12>

Boolean Equations Example


You are going to the cafeteria for lunch
You wont eat lunch (E)
If its not open (O) or
If they only serve corndogs (C)

Write a truth table for determining if you


will eat lunch (E).
O
0
0
1
1

C
0
1
0
1

Chapter 2 <13>

Boolean Equations Example


You are going to the cafeteria for lunch
You wont eat lunch (E)
If its not open (O) or
If they only serve corndogs (C)

Write a truth table for determining if you


will eat lunch (E).
O
0
0
1
1

C
0
1
0
1

E
0
0
1
0

Chapter 2 <14>

SOP & POS Form


SOP sum-of-products
O
0
0
1
1

C
0
1
0
1

minterm
O C
O C
O C
O C

POS product-of-sums
O
0
0
1
1

C
0
1
0
1

maxterm
O
O
O
O

+
+
+
+

C
C
C
C
Chapter 2 <15>

SOP & POS Form


SOP sum-of-products
O
0
0
1
1

C
0
1
0
1

E
0
0
1
0

minterm
O C
O C
O C
O C

Y = OC
= (2)

POS product-of-sums
O
0
0
1
1

C
0
1
0
1

E
0
0
1
0

maxterm
O
O
O
O

+
+
+
+

C
C
C
C

Y = (O + C)(O + C)(O + C)
= (0, 1, 3)

Chapter 2 <16>

Boolean Algebra
Axioms and theorems to simplify Boolean
equations
Like regular algebra, but simpler: variables
have only two values (1 or 0)
Duality in axioms and theorems:
ANDs and ORs, 0s and 1s interchanged

Chapter 2 <17>

Boolean Axioms

Chapter 2 <18>

T1: Identity Theorem


B 1=B
B+0=B

Chapter 2 <19>

T1: Identity Theorem


B 1=B
B+0=B
B
1

B
0

Chapter 2 <20>

T2: Null Element Theorem


B 0=0
B+1=1

Chapter 2 <21>

T2: Null Element Theorem


B 0=0
B+1=1
B
0

B
1

Chapter 2 <22>

T3: Idempotency Theorem


B B=B
B+B=B

Chapter 2 <23>

T3: Idempotency Theorem


B B=B
B+B=B
B
B

B
B

Chapter 2 <24>

T4: Identity Theorem


B=B

Chapter 2 <25>

T4: Identity Theorem


B=B

Chapter 2 <26>

T5: Complement Theorem


B B=0
B+B=1

Chapter 2 <27>

T5: Complement Theorem


B B=0
B+B=1
B
B

B
B

Chapter 2 <28>

Boolean Theorems Summary

Chapter 2 <29>

Boolean Theorems of Several Vars

Chapter 2 <30>

Simplifying Boolean Equations


Example 1:
Y = AB + AB

Chapter 2 <31>

Simplifying Boolean Equations


Example 1:
Y = AB + AB
= B(A + A)
= B(1)
=B

T8
T5
T1

Chapter 2 <32>

Simplifying Boolean Equations


Example 2:
Y = A(AB + ABC)

Chapter 2 <33>

Simplifying Boolean Equations


Example 2:
Y = A(AB + ABC)
= A(AB(1 + C))
= A(AB(1))
= A(AB)
= (AA)B
= AB

T8
T2
T1
T7
T3

Chapter 2 <34>

DeMorgans Theorem
Y = AB = A + B

Y=A+B=A B

A
B

A
B

A
B

A
B

Chapter 2 <35>

Bubble Pushing
Backward:
Body changes
Adds bubbles to inputs

A
B

A
B

A
B

Forward:
Body changes
Adds bubble to output

A
B

Chapter 2 <36>

Bubble Pushing
What is the Boolean expression for this
circuit?
A
B
Y
C
D

Chapter 2 <37>

Bubble Pushing
What is the Boolean expression for this
circuit?
A
B
Y
C
D

Y = AB + CD
Chapter 2 <38>

Bubble Pushing Rules


Begin at output, then work toward inputs
Push bubbles on final output back
Draw gates in a form so bubbles cancel
A
B
C

Chapter 2 <39>

Bubble Pushing Example


A
B
C

Chapter 2 <40>

Bubble Pushing Example


A
B
C

no output
bubble
Y

Chapter 2 <41>

Bubble Pushing Example


A
B

no output
bubble

A
B
C

bubble on
input and output
Y

Chapter 2 <42>

Bubble Pushing Example


no output
bubble

A
B
C

A
B

bubble on
input and output

A
B

no bubble on
input and output

D
Y = ABC + D
Chapter 2 <43>

From Logic to Gates


Two-level logic: ANDs followed by ORs
Example: Y = ABC + ABC + ABC
A

C
minterm: ABC
minterm: ABC
minterm: ABC

Chapter 2 <44>

Boole Algebra: Graphic Notation

Propiedades interesantes de la puerta NAND


Se puede utilizar la puerta NAND para obtener cualquiera de los
tres operadores lgicos bsicos (NOT, AND y OR)
Aplicando el lgebra de Boole

Tambin se puede hacer lo mismo con puertas NOR. Comprobar (ejercicio).

Boole Algebra: Work in class: Derive F


5m

Boole Algebra: Work in class: F

Boole Algebra: Work in class: F Solution

También podría gustarte