Modified Post Correspondence Problem 113 FORMAL LANGUAGES AND AUTOMATA THEORY

Modified post correspondence problem 113 formal

This preview shows page 139 - 146 out of 152 pages.

Modified Post Correspondence Problem 113
Image of page 139
FORMAL LANGUAGES AND AUTOMATA THEORY 10CS56 We have seen an undecidable problem, that is, given a Turing machine M and an input w, determine whether M will accept w (universal language problem). We will study another undecidable problem that is not related to Turing machine directly. Given two lists A and B: A = w1, w2, …, wk B = x1, x2, …, xk The problem is to determine if there is a sequence of one or more integers i1, i2, …, im such that: w1wi1wi2…wim = x1xi1xi2…xim (wi, xi) is called a corresponding pair. Example A B i w i x i 1 11 1 2 1 111 3 0111 10 4 10 0 This MPCP instance has a solution: 3, 2, 2, 4: w 1 w 3 w 2 w 2 w 4 = x 1 x 3 x 2 x 2 x 4 = 1101111110 114
Image of page 140
FORMAL LANGUAGES AND AUTOMATA THEORY 10CS56 8.2: a un decidable problem that is RE Undecidability of PCP To show that MPCP is undecidable, we will reduce the universal language problem (ULP) to MPCP: Universal A mapping MPCP Language Problem (ULP) If MPCP can be solved, ULP can also be solved. Since we have already shown that ULP is un- decidable, MPCP must also be undecidable. Mapping ULP to MPCP Mapping a universal language problem instance to an MPCP instance is not as easy. In a ULP instance, we are given a Turing machine M and an input w, we want to determine if M will accept w. To map a ULP instance to an MPCP instance success-fully, the mapped MPCP instance should have a solution if and only if M accepts w. 115
Image of page 141
FORMAL LANGUAGES AND AUTOMATA THEORY 10CS56 Mapping ULP to MPCP ULP instance MPCP instance Given: (T,w) Construct an MPCP instance Two lists: A and B If T accepts w, the two lists can be matched. Otherwise, the two lists cannot be matched. Mapping ULP to MPCP We assume that the input Turing machine T: Never prints a blank Never moves left from its initial head position. These assumptions can be made because: Theorem (p.346 in Textbook): Every language accepted by a TM M2 will also be accepted by a TM M1 with the following restrictions: (1) M1 ‟s head never moves left from its initial position. (2) M1 never writes a blank. Mapping ULP to MPCP Given T and w, the idea is to map the transition function of T to strings in the two lists in such a way that a matching of the two lists will correspond to aconcatenation of the tape contents at each time step . We will illustrate this with an example first. 116
Image of page 142
FORMAL LANGUAGES AND AUTOMATA THEORY 10CS56 Example of ULP to MPCP • Consider the following Turing machine: T = ({q 0 , q 1 },{0,1},{0,1,#}, , q 0 , #, {q 1 }) q 0 0/0, L q 1 1/0, R (q 0 ,1)=(q 0 ,0,R) (q 0 ,0)=(q 1 ,0,L) • Consider input w=110. Example of ULP to MPCP Now we will construct an MPCP instance from T and w. There are five types of strings in list A and B: Starting string (first pair ): List A List B # #q 0 110#
Image of page 143
117
Image of page 144
FORMAL LANGUAGES AND AUTOMATA THEORY 10CS56 Example of ULP to MPCP • Strings from the transition function : List A List B q 0 1 0q 0 (from (q 0 ,1)=(q 0 ,0,R)) 0q 0 0 q 1 00 (from (q 0 ,0)=(q 1 ,0,L)) 1q 0 0 q 1 10 (from (q 0 ,0)=(q 1 ,0,L)) Example of ULP to MPCP Strings for copying: List A List B # # 0 0 1 1 Example of ULP to MPCP Strings for consuming the tape symbols at the end: List A List B List A List B 0q1 q1 0q11 q1 1q1 q1 1q10 q1 q10 q1 0q10 q1 q11 q1 1q10 q1
Image of page 145
Image of page 146

You've reached the end of your free preview.

Want to read all 152 pages?

  • Winter '17
  • Shwetha CH
  • Regular expression, Automata theory, finite automata

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture