GATE / CS ARCHIVE

GATE CSE 2001 / QUESTION 2.7

Whether a computation visits a designated state

Theory of Computation · Decidability & Computability · Full GATE CSE 2001 paper

GATE 2001, Q2.7 2 marks · MCQ
Report issue

Decidability & Computability

Question 2.7, GATE 2001: Given a Turing machine M, input w, and state q, ask whether M’s computation on w ever visits q. Is this decidable, undecidable but partially decidable, not even partially decidable, or not a decision problem?
Tap to enlarge
Your answer
Answer & solution

Answer: B (no official key was published)

Step 1: Simulate M on w and accept as soon as q is visited. Every yes instance is eventually accepted; a no instance may run forever. This proves partial decidability.

Step 2: Reduce the halting problem: construct a simulator that enters a fresh designated state q exactly when the simulated machine halts. A decider for state visitation would decide halting, impossible.

Hence X is undecidable but partially decidable, B. It is a decision problem because the required answer is yes/no, regardless of whether an algorithm always produces that answer.

Original paper, page 4