Q1: 10 points Q2: 10 points Q3: 10 points Q4: 10 points Q5: 35 points Q6: 30 points Q7: 20 points Total: 125 points
If X is a computational model, such as DFA's, CFG's, or TM's, we follow Sipser in defining the following languages:
Recall also that the Post Correspondence Problem takes as input a finite set of dominoes {D1,..., Dn}, such that each domino Di has a top string ti and a bottom string bi, each a nonempty string in &Sigma'* for some alphabet Σ. A set of dominoes is in the language PCP if there exists a nonempty sequence of dominoes that is a match, meaning that the concatenation of the top strings and the concatenation of the bottom strings form the same word.
FALSE. Since the TM can never change its behavior based on any information from the write-only tapes, it would behave the same if they did not exist. Similarly, it will always see a blank on every read-only tape except the input tape. In effect, it is a two-way DFA and thus its A-problem is decidable. (You could prove this quickly by noting that a two-way DFA can be simulated by an LBA, which is enough because ALBA is decidable. Or you can give a direct proof, that you can decide a two-way DFA with k states on an input of size n with a TM, by simulating the two-way DFA until either it halts or has run for kn+1 steps. In the latter case it must be in a loop and your TM can reject.
TRUE. (This was the hardest question on the test -- several people had the
right boolean answer but no one had a full-credit explanation.) The δ
function of such a machine is from Q × {0,1} to Q × {0,1} ×
{L,R}, that is, from a set of size 20 to a set of size 40. Up to renaming of
the states, then, there are only 4020 such machines, a finite
number. There thus exists a finite lookup table answering the
emptiness problem for each of these machines, and our TM deciding the language
E10BTTM just has to figure out which machine it has and look up the
answer.
Note that a ten-state machine with a binary alphabet can use memory beyond
its input and thus could run for an insanely long time. (Wikipedia
claims that there is a
six-state machine with a binary alphabet that halts after running for more
than 102879 steps.) But although no imaginable computation could
produce this lookup table, it exists mathematically and thus
E10BTTM is a decidable language.
FALSE. We can simulate an arbitrary machine with a ten-state machine, if we are allowed to expand the tape alphabet. If M is a single-tape ordinary TM with state set Q and tape alphabet Γ, define Γ' to be a tape alphabet Γ ∪ (Q × Γ), so a new letter is either an old letter or an old letter marked by a state of M. Our new TM M' will have fewer then ten states, q'0, a few running states q1, etc., and special states to allow it to accept or reject. It begins by changing the first letter a of its input to (q0, a), where q0 is the start state of M, and going into q1. In state q1 it starts the process of simulating a step of M. For example, if δM(q,a) = (r,b,R), M' changes a letter (q,a) to (r,b) and then uses its other running states to move the state r, bit by bit, to the cell to the right, leaving the b in place. (We might need some more letters in Γ' to record situations with the state partially copied.) This simulation gives us a reduction from ATM, which is undecidable, to A10TM.
The codebook fixed-point problem (or CFPP) is the language consisting of all codebooks for which there is some nonempty plaintext string that has a ciphertext string that is identical to the palintext. Then this language CFPP is undecidable.
TRUE. We can reduce PCP, which was proven undecidable in Sipser and in lecture, to CFPP. (Note that the opposite reduction only proves that CFPP is TR.) Given a PCP instance, we make a codebook by making each domino into a pair, making the top string the plaintext and the bottom string the ciphertext of the pair. A match in the domino set thus corresponds exactly to a plaintext string with a ciphertext string identical to it, a fixed point. So this transformation proves PCP ≤m and thus that CFPP is undecidable.
The set of triples satisfying (a) is Turing recognizable because we can start
M and N on w in parallel and wait until or unless both accept. The sets
satisfying (b) and (c) are each decidable -- we showed in lecture that an LBA,
which is among other things an always-halting Turing machine, can decide whether
an alleged computation history is valid.
So we can test (b) and (c), accept the triple if both are true, and otherwise
start the machine that recognizes the triples that satisfy (a). If (a) is true
we accept, and if not we never find out.
If (M, N) is in EQTM, we know that L(M) = L(M), and we must show
that every triple is then in LM,N. If w is in both L(M) and L(N),
then (a) is true for any triple (w,x,y) and thus these triples are in the
language. If w is in neither L(M) nor L(N), then there are no accepting
histories for either machine on w, and thus (b) and (c) will both be true for
any strings x and y. Thus any (w,x,y), for such a w, will also be in
LM,N and we have shown that the machine for LM,N is in
ALLTM.
Conversely, suppose that LM,N is not the set of all
triples, so that there exists a triple (w,x,y) such that "(a) or ((b) and (c))"
is false. By propositional calculus, this means that (a) is false and at least
one of (b) and (c) is false. For (a) to be false, this w cannot be in both
L(M) and L(N). For (b) to be false, w must be in L(M), and for (c) to be false,
w must be in L(N). So we have that w is in one of L(M) or L(N) but not the
other, and thus L(M) ≠ L(N) and (M, N) ∉ ALLTM.
The function mapping the pair (M, N) to the Turing machine recognizing LM,N is a mapping reduction proving that EQTM ≤m ALLTM. Since we proved in lecture that EQTM is neither TR nor co-TR, and both the class TR and the class co-TR are closed downward under mapping reduction, we can conclude that ALLTM is neither TR nor co-TR (and thus certainly undecidable).
We saw in Chapter 1 that if M is a DFA with i states and N is a DFA with j states, then we can construct a new DFA P such that L(P) = L(M) ∩ L(N). By the definition, (M, N) is in COMMONDFA if and only if P is not in EDFA, and we proved that the latter language is decidable. (We have only to determine whether the directed graph for P has a path from the start state to any accepting state.) A TM can carry out the construction of P and the test for a path.
We need to determine, for every string w in Σ*, whether w is in both L(M) and L(N) (where M and N are now grammars). Since ACFG is decidable, we can carry out these tests sequentially, accepting if we ever find a common w and running forever if we do not. We could also carry out these tests in parallel by dovetailing as in the answer to part (c).
COMMOMTM is TR: We run both M and N in parallel on every string w
by dovetailing. (For example, for each natural number i in order we could
run M and N on each of the first i strings for i steps each.) If we ever find
a w that is accepted by both M and N we accept. If we do not find such a w
we continue to look for one forever.
COMMONTM is not TD: My proof was to reduce from the complement
of the known undecidable language ETM, which must also be
undecidable. Given a Turing machine M, let N be a fixed machine such that
L(N) = Σ*. Then L(M) is not empty if and only if
L(M) and L(N) have a string in common.
Several people gave the following proof which I think I like better.
Reduce ATM to COMMONTM as follows. Given M and w,
construct a Turing machine N such that L(N) = {w}. ("On input x, if x = w
accept; else reject;") Then (M, w) is in ATM if and only if
(M, N) is in COMMONTM. We have reduced the known undecidable
language ATM to COMMONTM, proving that the latter is
not decidable.
Given a set of dominoes with a string in a* on the top and another string in a* on the bottom, we decide whether this set is in PCP as follows. If there is a domino with the same string on top and on bottom, accept because the sequence consisting of just this domino is a match. If there is domino with longer top string and another domino with longer bottom string, accept because we can build a match with these two. (Let the first domino have b+c a's on top and b a's on bottom, and the second domino have d a's on top and d+e on bottom. Then e copies of the first domino and c copies of the second give up a match because there are be + ce + cd a's in the top string and the bottom string.) Otherwise the dominoes in the set either all have longer top string or all have longer bottom string, and in this case we reject because a match is clearly impossible.
We only have to check every sequence of dominoes with no domino more than once -- there are 2n - 1 possible nonempty sets drawn from n dominoes, and each of these sets can be placed in at most n! orders, so the total number to check is finite. It is clear that checking whether a given sequence forms a match is decidable, so an always-halting TM can just check every possible sequence.
Last modified 2 April 2010