Presentation is loading. Please wait.

Presentation is loading. Please wait.

Logic Design CS221 1 st Term 2009-2010 K-Map Cairo University Faculty of Computers and Information.

Similar presentations


Presentation on theme: "Logic Design CS221 1 st Term 2009-2010 K-Map Cairo University Faculty of Computers and Information."— Presentation transcript:

1 Logic Design CS221 1 st Term 2009-2010 K-Map Cairo University Faculty of Computers and Information

2 13/10/2009 cs221 – sherif khattab 2 Administrivia imagine cup (imaginecup.com): tutorial session, Wednesday @3pm in seminar room bonus winners (correct answer + explanation)‏  Mostafa Ahmed Sayed - 20080311  Mostafa Mohamed Mostafa - 20070434  Mido Talaat, Aya Elkady - 20080088  Mohamed Mahmoud Sayed - 20080272  Ahmed Emad Samy Yossef - 20080020 lab 2 is significantly longer than lab 1 email subject must include the word CS221 project groups: GA and GB http://www.fci.cu.edu.eg/~skhattab/cs221/project.php

3 13/10/2009 cs221 – sherif khattab 3 boolean functions input -> output binary variables (and constants) and logic operations defined by a truth table for two variables, only 16 boolean functions possible. why?  how many possible truth tables? for n variables, 2 2 n boolean functions

4 13/10/2009 cs221 – sherif khattab 4 gate-level minimization Boolean function representation  truth table: one way  algebraic form (and logic circuit): many ways  simplest and cheapest circuit minimum # terms -> min. # gates minimum # literals per term -> min. # inputs to each gate not unique gate-level minimization  automatic (logic synthesis software)‏  manual algebraic: awkward map method: simple, straightforward (Karnaugh map or K-map)‏

5 13/10/2009 cs221 – sherif khattab 5 map diagram of squares each square represents one minterm (one row in truth table)‏ For 2 variables:  4 minterms  x'y', x'y, xy', xy columns in which x = 1

6 13/10/2009 cs221 – sherif khattab 6 two-variable map Example: F = xy

7 13/10/2009 cs221 – sherif khattab 7 two-variable map Example: F = x + y = x (y + y') + y (x + x') = xy + xy' + x'y

8 13/10/2009 cs221 – sherif khattab 8 Gray code only one bit changes from number to next:  7 -> 0100  8 -> 1100 2-bit Gray code  00, 01, 11, 10

9 13/10/2009 cs221 – sherif khattab 9 three-variable map 8 minterms column sequence in Gray code row 1 and column 01 -> 1 01 = 5 -> m 5 row x and column y'z -> x y'z

10 13/10/2009 cs221 – sherif khattab 10 2 adjacent cells each two adjacent cells differ in how many variables (bits)? sum (OR) of two adjacent cells -> one AND  e.g., m 5 + m 7 = xy'z + xyz = xz (y + y') = xz  e.g., m 1 + m 5 = x'y'z + xy'z = y'z (x + x') = y'z

11 13/10/2009 cs221 – sherif khattab 11 2 adjacent cells m 0, m 1 adjacent? m 0, m 5 adjacent? m 0, m 2 adjacent? m 4, m 6 adjacent?

12 13/10/2009 cs221 – sherif khattab 12 4 adjacent cells sum (OR) of four adjacent cells -> one literal  e.g., m 1 + m 3 + m 5 + m 7 001 011 101 111 = x'y'z + x'yz + xy'z + xyz = x'z (y + y') + xz (y + y') = x'z + xz = z (x + x') = z

13 13/10/2009 cs221 – sherif khattab 13 4 adjacent cells

14 13/10/2009 cs221 – sherif khattab 14 3-variable map simplification 1 cell -> three literals (e.g., xyz)‏ 2 adjacent cells -> two literals (e.g., xy)‏ 4 adjacent cells -> one literal (e.g., z)‏ 8 adjacent cells -> ??

15 13/10/2009 cs221 – sherif khattab 15 example 1 F = ∑(2,3,4,5)‏ = (010, 011, 100, 101) = xy' + x'y

16 13/10/2009 cs221 – sherif khattab 16 example 2 F = ∑(3,4,6,7)‏ = yz + xz'

17 13/10/2009 cs221 – sherif khattab 17 example 3 F = ∑(0,2,4,5,6)‏ = z' + xy'

18 13/10/2009 cs221 – sherif khattab 18 example 4 F = A'C + A'B + AB'C + BC (what form?)‏ =

19 13/10/2009 cs221 – sherif khattab 19 four-variable map ?? minterms column sequence in Gray code row 01 and column 01 -> 01 01 = 5 -> m 5 row w'x and column y'z -> w'x y'z

20 13/10/2009 cs221 – sherif khattab 20 4-variable map simplification 1 cell -> four literals (e.g., wxyz)‏ 2 adjacent cells -> three literals (e.g., w'xy)‏ 4 adjacent cells -> two literals (e.g., wz)‏ 8 adjacent cells -> one literal (e.g., x)‏ 16 adjacent cells -> 1 adjacent?

21 13/10/2009 cs221 – sherif khattab 21 example 1 F = ∑(0,1,2,4,5,6,8,9,12,13,14)‏ =

22 13/10/2009 cs221 – sherif khattab 22 example 2 F = A'B'C' + B'CD' + A'BCD' + AB'C' =

23 13/10/2009 cs221 – sherif khattab 23 5-variable map ?? minterms the two 4-variable maps on top of each other

24 13/10/2009 cs221 – sherif khattab 24 5-variable map simplification

25 13/10/2009 cs221 – sherif khattab 25 example F = ∑(0,2,4,6,9,13,21,23,25,29,31)‏


Download ppt "Logic Design CS221 1 st Term 2009-2010 K-Map Cairo University Faculty of Computers and Information."

Similar presentations


Ads by Google