K Maps in higher dimensions, Elements of Sequential Circuits - - PowerPoint PPT Presentation

k maps in higher dimensions elements of sequential
SMART_READER_LITE
LIVE PREVIEW

K Maps in higher dimensions, Elements of Sequential Circuits - - PowerPoint PPT Presentation

K Maps in higher dimensions, Elements of Sequential Circuits (Latches) CSE 140: Components and Design Techniques for Digital Systems Diba Mirza Dept. of Computer Science and Engineering University of California, San Diego 1 Review Some


slide-1
SLIDE 1

K Maps in higher dimensions, Elements of Sequential Circuits (Latches)

CSE 140: Components and Design Techniques for Digital Systems

Diba Mirza

  • Dept. of Computer Science and Engineering

University of California, San Diego

1

slide-2
SLIDE 2

Review 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

  • Implicate: sum of literals

(A+B+C), (A+C), (B+C)

  • 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)

2

slide-3
SLIDE 3

Minimum Product of Sum

3

Given f (a,b,c) = Σm (3, 5) + Σd (0, 4)

0 2 6 4 1 3 7 5

X 0 0 X 0 1 0 1

ab c 00 01 11 10 1 Prime Implicates: Essential Primes Implicates: Min exp: f(a,b,c) =

slide-4
SLIDE 4

Minimum Product of Sum

4

Given f (a,b,c) = Σm (3, 5) + Σd(0, 4)

0 2 6 4 1 3 7 5

X 0 0 X 0 1 0 1

ab c 00 01 11 10 1 Prime Implicates: ΠM (0, 1), ΠM (0, 2, 4, 6), ΠM (6, 7) Essential Primes Implicates: ΠM (0, 1), ΠM (0, 2, 4, 6), ΠM(6, 7) Min exp: f(a,b,c) = (a+b)(c )(a’+b’)

slide-5
SLIDE 5

Corresponding Circuit

a b a’ b’ c f(a,b,c,d)

5

Min exp: f(a,b,c) = (a+b)(c )(a’+b’)

slide-6
SLIDE 6

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10

1 0 0 1 1 0 0 X 0 0 0 0 1 0 1 X

6

ab cd 00 01 00 01 11 10 11 10

  • Reduce the following to a POS form
  • First find the essential prime implicates

Minimum product of sum: Ex 2

slide-7
SLIDE 7

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10

1 0 0 1 1 0 0 X 0 0 0 0 1 0 1 X

7

ab cd 00 01 00 01 11 10 11 10

  • Reduce the following to a POS form
  • First find the essential prime implicates

Minimum product of sum: Ex2

slide-8
SLIDE 8

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10

1 0 0 1 1 0 0 X 0 0 0 0 1 0 1 X

8

ab cd 00 01 00 01 11 10 11 10

  • Reduce the following to a POS form
  • First find the essential prime implicates

Minimum product of sum: Ex 2

slide-9
SLIDE 9

Min product of sums: Ex3

Given f(a,b,c,d) = ΠM(3, 11, 12, 13, 14). ΠD(4, 8, 10)

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10 9

ab cd 00 01 11 10 00 01 11 10

K-map

slide-10
SLIDE 10

Min product of sums: Ex3

10

a d

1 X 0 X 1 1 0 1 0 1 1 0 1 1 0 X

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10

ab 00 01 11 10 cd 00 01 11 10 Given f(a,b,c,d) = ΠM(3, 11, 12, 13, 14). ΠD(4, 8, 10)

slide-11
SLIDE 11

Prime Implicates: ΠM (3,11), ΠM (12,13), ΠM(10,11), ΠM (4,12), ΠM (8,10,12,14) PI Q: Which of the following is a non-essential prime implicate?

  • A. ΠM(3,11)
  • B. ΠM(12,13)
  • C. ΠM(10,11)
  • D. ΠM(8,10,12,14)

11

a d

1 X 0 X 1 1 0 1 0 1 1 0 1 1 0 X

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10

ab 00 01 11 10 cd 00 01 11 10

slide-12
SLIDE 12

12 0 2 6 4 1 3 7 5

X 0 1 0 1 0 0 X

ab c 00 01 11 10 1

(V) (25pts) (Karnaugh Map) Use Karnaugh map to simplify function f (a, b, c) = Σ m(1, 6) +Σ d(0, 5). List all possible minimal product of sums expres-

  • sions. Show the Boolean expressions. No need for the logic diagram.
slide-13
SLIDE 13

13 0 2 6 4 1 3 7 5

X 0 1 0 1 0 0 X

ab c 00 01 11 10 1

slide-14
SLIDE 14

Five variable K-map

0 4 12 8

c d b e

1 5 13 9 3 7 15 11 2 6 14 10 16 20 28 24

c d b e a

17 21 29 25 19 23 31 27 18 22 30 26

Neighbors of m5 are: minterms 1, 4, 7, 13, and 21 Neighbors of m10 are: minterms 2, 8, 11, 14, and 26

14

a=0 a=1 bc de 00 01 11 10 00 01 11 10 00 01 11 10

slide-15
SLIDE 15

Reading a Five variable K-map

0 4 12 8

c d b e

1 5 13 9 3 7 15 11 2 6 14 10 16 20 28 24

c d b e a

17 21 29 25 19 23 31 27 18 22 30 26 15

a=0 a=1 bc de 00 01 11 10 00 01 11 10 00 01 11 10 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

slide-16
SLIDE 16

Six variable K-map

d e c f d e c d e c f

48 52 60 56

d e c b

49 53 61 57 51 55 63 59 50 54 62 58

a

32 36 44 40 33 37 45 41 35 39 47 43 34 38 46 42

f f

0 4 12 8 1 5 13 9 3 7 15 11 2 6 14 10 16 20 28 24 17 21 29 25 19 23 31 27 18 22 30 26 16

bc de ab=(0,0) ab=(0,1) ab=(1,0) ab=(1,1)

slide-17
SLIDE 17

17

we'll need a 4-variable Karnaugh map for each of the 3 output functions

Design example: two-bit comparator

block diagram LT EQ GT A B < C D A B = C D A B > C D A B C D N1 N2 A B C D LT EQ GT 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 and truth table

slide-18
SLIDE 18

18

A' B' D + A' C + B' C D B C' D' + A C' + A B D' LT = EQ = GT = K-map for EQ K-map for LT K-map for GT

Design example: two-bit comparator (cont’d)

1

D A

1 1 1 1 1

B C

1 1

D A

1 1

B C

1 1 1 1 1

D A

1

B C

= (A xnor C) • (B xnor D) LT and GT are similar (flip A/C and B/D) A' B' C' D' + A' B C' D + A B C D + A B' C D’ Source: Rosing

slide-19
SLIDE 19

19

block diagram and truth table 4-variable K-map for each of the 4

  • utput functions

A2 A1 B2 B1 P8 P4 P2 P1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

Design example: 2x2-bit multiplier

P1 P2 P4 P8 A1 A2 B1 B2

slide-20
SLIDE 20

20

K-map for P8 K-map for P4 K-map for P2 K-map for P1

Design example: 2x2-bit multiplier (cont’d)

B1 A2

1 1 1

A1 B2

1 1

B1 A2

1 1

A1 B2

1 1

B1 A2

1 1 1 1

A1 B2 B1 A2

1

A1 B2

slide-21
SLIDE 21

What is a sequential circuit?

21

“A circuit whose output depends on current inputs and past outputs” “A circuit with memory”

Memory / Time steps Clock

xi yi si yi=fi(St,X) si

t+1=gi(St,X)

slide-22
SLIDE 22

Why do we need circuits with ‘memory’?

22

  • Circuits with memory can be used to store data
  • Complex systems often consist of circuits that

perform a sequence of tasks

slide-23
SLIDE 23

Memory Hierarchy

23

Hard disk Main Memory Cache Registers

  • What are registers made of?
slide-24
SLIDE 24

To the flip-flop!

24

  • The most basic memory element:

The capacitive load

Q Q Q Q I1 I2 I2 I1

slide-25
SLIDE 25

Fundamental Memory Mechanism

Q Q Q Q I1 I2 I2 I1

25

How is this circuit different from a combinational circuit?

  • A. Two outputs: Q, Q’
  • B. Feedback loop
  • C. No external inputs
  • D. Both B and C
  • E. None of the above
slide-26
SLIDE 26

Does this circuit really remember?

26

Q Q I1 I2 1 1

– Q = 0: then Q’ = 1 and Q = 0

Q Q I1 I2 1 1

– Q = 1: then

slide-27
SLIDE 27

Bi-stable circuit

Q Q I1 I2 1 1

  • Bistable circuit stores 1 bit of

state in the state variable, Q (or Q’ )

  • But there are no inputs to

control the state

Q Q I1 I2 1 1

27

slide-28
SLIDE 28

SR (Set/Reset) Latch

R S Q Q N1 N2

  • SR Latch
  • Consider the four possible cases:

§ S = 1, R = 0: set output to ‘1’ § S = 0, R = 1: (reset) output to ‘0’ § S = 0, R = 0: store – output should be unchanged § S = 1, R = 1: Trouble!

28

(S+Q)’

slide-29
SLIDE 29

SR Latch Analysis

§ S = 1, R = 0: § S = 0, R = 1:

R S Q Q N1 N2 1

R S Q Q N1 N2 1

29

slide-30
SLIDE 30

SR Latch Analysis

§ S = 0, R = 0:

30

R S Q Q N1 N2

slide-31
SLIDE 31

SR Latch Analysis

§ S = 0, R = 0:

31

R S Q Q N1 N2

What happens if Qprev=0 and Q’prev=0? A. The output Q toggles B. The output Q remains 0 and Q’ changes to 1 C. The output Q becomes 1 and Q’ remains 0

slide-32
SLIDE 32

SR Latch Analysis

– S = 1, R = 1:

R S Q Q N1 N2 1 1

32