Docsity

Assignment 5 Solutions - Discrete Mathematics | EECS 203, Assignments of Discrete Mathematics

Toggle sidebar
bg1
EECS 203 Homework 5 Solutions
2.
(a) (10 pts)
Using the codes provided in the assignment, we can create the following Karnaugh maps, and
thereby obtain the equations.
A:
L\RE 00 01 11 10
0 0 1 X 0
1 1 X X X
B:
L\RE 00 01 11 10
0 0 1 X 1
1 0 X X X
(b) (10 pts)
A 1-input decoder is shown here:
=>
Therefore, using this and some AND gates, we can decode the signals as follows:
A L
R
B
E
(c) i) (10 pts)
Designs can vary.
A/000
N: 00
L: 10
R: 01
E: 11 B/001 C/100
D/010
Therefore,
A = L + E
and
B = R + E
A A
1-Input
Decoder
A
A A
A
P Q
1-Input
Decoder
Q
P Q
1-Input
Decoder
Q
pf3
pf4
pf5

Partial preview of the text

Download Assignment 5 Solutions - Discrete Mathematics | EECS 203 and more Assignments Discrete Mathematics in PDF only on Docsity!

EECS 203 Homework 5 Solutions

(a) (10 pts) Using the codes provided in the assignment, we can create the following Karnaugh maps, and thereby obtain the equations.

A: L\RE 00 01 11 10 0 0 1 X 0 1 1 X X X

B: L\RE 00 01 11 10 0 0 1 X 1 1 0 X X X

(b) (10 pts) A 1-input decoder is shown here:

Therefore, using this and some AND gates, we can decode the signals as follows:

A L

R

B

E

(c) i) (10 pts) Designs can vary.

A/ N: 00 L: 10 R: 01 E: 11 B/001 C/

D/

Therefore, A = L + E

and

B = R + E

A A 1-Input Decoder A

A A

A

P Q 1-Input Decoder Q

P Q 1-Input Decoder Q

(c) ii) (5 pts) NS Output CS i = 00 i = 01 i = 10 i = 11 pqr A A C B D 000 B A C D A 001 C A D B A 100 D A B C A 010

(c) iii) (5 pts) CS NS ( m’n’ ) Output mn i^ = 00^ i^ = 01^ i^ = 10^ i^ = 11^ pqr A (00) A (00) C (10) B (01) D (11) 000 B (01) A (00) C (10) D (11) A (00) 001 C (10) A (00) D (11) B (01) A (00) 100 D (11) A (00) B (01) C (10) A (00) 010

(c) iv) (10 pts) m’ I ( ab ) n’ i ( ab ) 00 01 11 10 00 01 11 10 00 0 1 1 0 00 0 0 1 1 01 0 1 0 1 01 0 0 0 1 CS (^11 0 0 0 1 11 0 1 0

mn

CS (

mn

Therefore, we can solve for the equations as follows

m '= mnb + mab + nab + mna b n '= mna + mab + mab + mna b p = m n q = mn r = m n

Drawing the circuits should be straightforward using these equations.

  1. (10 pts) Easy solution:

CLK

in out

1 1 0 0 1

Q

D Q D Q D Q D Q D Q

(a) (5 pts) Mealy (b) (4 pts) Current State Input Next State Output A 0 D^1 1 C 1 0 A 0 B 1 F 0 C 0 C^0 1 E 1 D 0 C^1 1 C 1 0 B 1 E (^1) E 1

F 0 A^0 1 D 1 (c) (5 pts) CS ( pqr ) Input ( i ) NS ( p’q’r’ ) Output ( z ) 0 D (011) 1 A (000) 1 C (010) 1 B (001) 0 A (000)^0 1 F (101) 0 C (010) 0 C (010)^0 1 E (100) 1 0 C (010) 1 D (011) (^1) C (010) 1

E (100) 0 B (001)^1 1 E (100) 1 F (101) 0 A (000)^0 1 D (011) 1 (d) (10 pts) p’ ri q ’ ri 00 01 11 10 00 01 11 10 00 0 0 1 0 00 1 1 0 0 01 0 1 0 0 01 1 0 1 1 11 x x x x 11 x x x x

pq

pq

r’ ri z ri 00 01 11 10 00 01 11 10 00 1 0 1 0 00 1 1 0 0 01 0 0 0 0 01 0 1 1 1 11 x x x x 11 x x x x

pq

pq

p '= qri + pri + pq ri q '= pqr + qr + qr + pri r '= qri + q ri z = qr + pi + qi + qr

(a) (5 pts) It is a Moore machine because the outputs depend on the current state, but not the inputs. Although, one output is different for a different input when the current state is A, the output is a don’t care, so we can choose it to be 0 and hence make it a Moore machine.

(b) (5 pts) CS ( pq ) Input ( i ) NS ( p’q’ ) Output ( z ) 0 A (00) A (00) 1 C (10)

0 D (11)

B (01)

1 D (11)

C (10) 0 A (00)

1 B (01)

0 D (11)

D (11)

1 C (10)

p’ q’ z p \ qi 00 01 11 10 p \ qi 00 01 11 10 p \ qi 00 01 11 10 0 0 1 1 1 0 0 0 1 1 0 0 0 0 0 1 0 0 1 1 1 0 1 0 1 1 1 1 0 0

p '= q + p i q '= pq + qi + pq i z = p q