GATE Computer ScienceVery hardGATE CS (PYQ pattern)
A sequence detector must output 1 whenever the last four input bits are 1011, with overlapping occurrences allowed. What are the minimum numbers of states needed in a Mealy machine and in a Moore machine for this detector?
- A. Mealy 4, Moore 5
- B. Mealy 4, Moore 4
- C. Mealy 5, Moore 5
- D. Mealy 3, Moore 4
Correct answer: A. Mealy 4, Moore 5
Mealy states record the longest useful suffix: none, 1, 10, 101; the output 1 is produced on the transition 101 --1--> 1, so 4 states suffice. A Moore machine needs one more state (1011) whose own output is 1, giving 5.
More Digital Logic questions
- An 8-bit ALU adds the two's complement numbers A = 10110110 and B = 11001101. What are the carry-out C and the signed-overflow flag V of…
- A 4:1 multiplexer has A as the MSB select and B as the LSB select. To realise f(A,B,C) = Σm(0, 3, 5, 6, 7), the data inputs (I0, I1, I2…
- A 4-bit shift register Q3 Q2 Q1 Q0 shifts left on every clock: Q3 ← Q2, Q2 ← Q1, Q1 ← Q0 and Q0 ← Q3 ⊕ Q1 (the feedback taps correspond to…
- A 4-bit left-shifting register uses XNOR feedback: Q0 ← XNOR(Q3, Q2), with Q3 ← Q2, Q2 ← Q1, Q1 ← Q0. Starting at 0000, after how many…
- A 4-bit shift-right register Q3 Q2 Q1 Q0 has Q2 ← Q3, Q1 ← Q2, Q0 ← Q1 and Q3 ← NOR(Q3, Q2, Q1). Its state diagram has the single 4-state…
- A 5-bit Johnson (twisted-ring) counter shifts right with Q4 ← NOT Q0 (and Q3 ← Q4, Q2 ← Q3, Q1 ← Q2, Q0 ← Q1) and has no self-correction…