Download presentation
Presentation is loading. Please wait.
Published byPeter Cooper Modified over 9 years ago
1
9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU1 Two Level Circuit Optimiztion An easier way to generate a minimal sum of products expression.
2
9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU2 Class 7 outline Cost Functions Map Structures Maps Two Variable Three Variable Four Variable Material from section 2-4 of text
3
Intro and Cost Function The complexity of the gates to physically implement a Boolean function is typically a 1-to-1 relationship with the Boolean expression of the function. If the expression has 3 terms ANDed together, the implementation has a 3-input AND gate. If the expression has 4 AND terms Ored together for the final output the implementation has a 4-input OR gate 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU3
4
Function representations Truth Tables Any Boolean function can be represented by a Truth Table Truth Tables have 1 line for each of the 2 n possible input combinations Are a full specification of the function Sum-of-Products There is just one maximal sum-of-products representation This is a representation where each term contain each literal of the function, i.e., specifies each line of the Truth Table where the value of the function is 1. 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU4
5
Illustration of this Consider two function 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU5
6
Cost Functions A cost function is a metric to place a value on the ‘cost’ to implement a logic function. The lowest cost will be the minimal sum-of-products or minimal product-of-sums representation. These representation of the function with have the fewest number of terms with the fewest number of literals in each term. 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU6
7
Different cost factors Literal cost – the sum of the number of literals required for expression of the function. Gate inputs – the number of inputs to gates in the implementation This is a cost function that is sometimes used today. CAD tools that automatically generate the implementation have proprietary cost functions 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU7
8
Manual minimization Usually done with Karnaugh maps K-maps are an extension of Venn Diagrams Consider a function of 2 inputs F(A, B) Have 4 regions A B AB and A’B’ Note adjacencies A adjacent to AB and A’B’ AB adjacent to A and B 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU8
9
K-map for 2 variables Karnaugh map for two variables Note adjacencies 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU9
10
For three variables 3 variables – 8 Truth Table entries – 8 variable K-map 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU10
11
4 variable K-map The 4 variable Karnaugh map 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU11
12
9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU12
13
Minimizing functions using maps Form the largest power of 2 group of adjacent 1 that you can. 1s on K-maps can be used multiple times. Example: 3 variable map Simplify F(A,B,C)=∑m(0,1,2,3,4,5) Note minterm positions Step 1 – enter 1s onto map 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU13
14
Minimizing Step 2 find larges power of 2 groupings Make sure all 1s are included (covered) F(X,Y,Z)=X’ + Y’ 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU14
15
2 variable map examples Easy to simplify if you can. 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU15
16
4 variable examples Consider the map What power of 2 groups exist? 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU16
17
First two Is there a third? Wraparound 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU17
18
Adjaceny What cells are adjacent? 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU18
19
Another Adjacency and wraparound Top 00 cells are adjacent to bottom 10 cells minimal is F=A’C + B’C’ 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU19
20
In general Map all 1s of the function to the K-map Choose the largest power of 2 groups until all the 1 of the function are covered For a 4 variable function Group 8 1s – will have 1 literal Group 4 1s – will have 2 literals Group 2 1s – will have 3 literals No group – a lone 1 – term will have all 4 literals Sometimes will have a choice on how to cover that last 1. Make the choice that results in a term with the fewest literals. Sometimes either of 2 answers are equal. 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU20
21
Simplifying functions Simplify XY+X’Z+YZ Expand to generate minterms = XY(Z+Z’) + X’Z(Y+Y’) + (X+X’)YZ = XYZ+XYZ’ + X’YZ + X’Y’Z + XYZ+X’YZ = m 7 + m 6 + m 3 + m 1 + repeat + repeat. 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU21
22
Class 7 summary assignment Covered section 2-4 Problems for hand in 2-16 2-17 Problems for practice 2-15 Reading for next class: section 2-5 9/15/09 - L7 Two Level Circuit Optimization Copyright 2009 - Joanne DeGroat, ECE, OSU22
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.