CMPSCI 401: Theory of Computation

Solutions to Second Midterm Exam, Spring 2013

David Mix Barrington

10 April 2013

Question text is in black, solutions in blue.

Directions:

  Q1: 10 points
  Q2: 10 points
  Q3: 10 points
  Q4: 10 points
  Q5: 10 points
  Q6: 25 points
  Q7: 15 points
  Q8: 30+15 points
 Total: 120+15 points

Correction in orange added 20 March 2015.

If C is any class of computers, such as DFA's, CFG's, LBA's TM, strange variant TM's, etc.:

The language DECIDER is the set {(M): M halts (either accepts or rejects) on every input}.

Recall that if A and B are two languages, A is mapping reducible to B, written A ≤m B, if there exists a function f: Σ* → Σ* such that for any string w, w ∈ A ↔ f(w) ∈ B.

A language A is Turing recognizable (TR) if it equals L(M) for some Turing machine M.

A is Turing decidable if A = L(M) for some Turing machine M that always halts.

A function f is Turing computable if there exists a Turing machine M such that for any string w, M when started on w halts with f(w) on its tape.

A stupid Turing machine (STM) has one tape which "wraps around" -- moving left from its leftmost cell takes you to its rightmost cell, and moving right from its leftmost cell takes you to its leftmost cell. It begins with the input string filling the entire tape.

A very stupid Turing machine (VSTM) is like an STM except that for some of its state-letter pairs it may replace the current cell with two cells, writing to both of them, instead of just writing to the current cell. Thus its transition function is δ (Q × Σ) ↔ (Q × (Σ ∪ (Σ × Σ)) × {L, R}).

The function S from N × N to N is defined as follows. Consider all the k-state Turing machines with tape alphabet {0, 1, blank} and consider all input strings in {0, 1}n. S(k, n) is the number of steps taken by the longest of any of the halting computations of any of these machines on any of these inputs. (This is similar to the "busy beaver function" but is not exactly the same thing.)

Last modifie 20 March 2015