The universal turing machine
This presentation is the property of its rightful owner.
Sponsored Links
1 / 6

The universal Turing machine PowerPoint PPT Presentation


  • 88 Views
  • Uploaded on
  • Presentation posted in: General

CSC 4170 Theory of Computation. The universal Turing machine. Section 4.2. 4.2.a. The universal Turing machine. Let A TM = {<M,w> | M is a TM and M accepts string w} A TM is misleadingly called the “halting problem” in the textbook. . Theorem: A TM is Turing-recognizable. .

Download Presentation

The universal Turing machine

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript


The universal turing machine

CSC 4170

Theory of Computation

The universal Turing machine

Section 4.2


The universal turing machine1

4.2.a

The universal Turing machine

Let ATM = {<M,w> | M is a TM and M accepts string w}

ATM is misleadingly called the “halting problem” in the textbook.

Theorem:ATM is Turing-recognizable.

Proof idea.

The following TM U, called the universal TM, recognizes ATM:

U = “On input <M,w>, where M is a TM and w is a string:

1. Simulate M on input w.

2. If M ever enters its accept state, accept;

if M ever enters its reject state, reject.”

Does U also decide ATM?


A tm is undecidable

4.2.b.1

ATM is undecidable

Theorem 4.11:ATM is undecidable.

Proof idea. Suppose, for a contradiction, that ATM is decidable.

That is, there is a TM H that decides ATM.

Thus, that machine H behaves as follows:

accept if M accepts w

reject if M does not accept w

H(<M,w>) =

Using H as a subroutine, we can construct the following TM D:

D = “On input <M>, where M is a TM:

1. Run H on input <M,<M>>.

2. Do the opposite of what H does.

That is, if H accepts, reject, and if H rejects, accept.”

accept if M does not accept <M>

reject if M accepts <M>

Thus, D(<M>) =


A tm is undecidable1

4.2.b.2

ATM is undecidable

accept if D does not accept <D>

reject if D accepts <D>

But then D(<D>) =

Contradiction!

  • To summarize:

  • H accepts <M,w> exactly when M accepts w.

  • D rejects <M> exactly when M accepts M.

  • D rejects <D> exactly when D accepts <D>.


A turing unrecognizable language

4.2.c

Theorem 4.23:

A

is Turing-unrecognizable.

TM

A Turing-unrecognizable language

ATM = {<M,w> | M is a TM and M accepts string w}

ATM = {<M,w> | M is a TM and M does not accept string w}

Proof idea. Suppose, for a contradiction, that ATM is Turing-recognizable.

That is, there is a TM U that recognizes ATM.

  • U recognizes ATM (slide 4.2.a)

  • U recognizes ATM

Thus,

Let M = “On input w:

1. Run both U and U on input w in parallel;

2. If U accepts, accept; if U accepts, reject.”

It can bee seen that M decides ATM, which contradicts Theorem 4.11.


The language hierarchy summary

4.2.d

The language hierarchy summary

All languages

Turing-recognizable languages

Turing-decidable languages

Context-free languages

Regular languages

{anbn | n0}

ATM

ATM

{anbncn | n0}


  • Login