Some languages not Turing-recognizable I is countable Simply count - - PowerPoint PPT Presentation

some languages not turing recognizable i
SMART_READER_LITE
LIVE PREVIEW

Some languages not Turing-recognizable I is countable Simply count - - PowerPoint PPT Presentation

Some languages not Turing-recognizable I is countable Simply count w with | w | = 0 , 1 , 2 , 3 , . . . For example, if = { 0 , 1 } , then { , 0 , 1 , 00 , 01 , 10 , 11 , . . . } The set of TMs is countable Each machine can be


slide-1
SLIDE 1

Some languages not Turing-recognizable I

Σ∗ is countable Simply count w with |w| = 0, 1, 2, 3, . . . For example, if Σ = {0, 1}, then {ǫ, 0, 1, 00, 01, 10, 11, . . .} The set of TMs is countable Each machine can be represented as a finite string (think about the formal definition) Thus the set of TMs is a subset of {0, 1}∗ Let

October 28, 2020 1 / 12

slide-2
SLIDE 2

Some languages not Turing-recognizable II

L: all languages over Σ B: all infinite binary sequences For any A ∈ L there is a corresponding element in B Example: A : 0{0, 1}∗ Σ∗ = {ǫ, 0, 1, 00, 01, 10, 11, 000, 001, . . .} A = {0, 00, 01, 000, 001, . . .} χA = 010110011 . . .

October 28, 2020 2 / 12

slide-3
SLIDE 3

Some languages not Turing-recognizable III

One-to-one correspondence between B and L B is uncountable (like real numbers) Therefore, L is uncountable Each TM ⇒ handles one language in L Set of TM is countable, but L is not Thus some languages cannot be handled by TM

October 28, 2020 3 / 12

slide-4
SLIDE 4

Halting problem undecidable I

Recall the halting problem is ATM = {M, w | M : TM, accepts w} We prove it is undecidable by contradiction Assume there is an H that is a decider for ATM Then H satisfies H(M, w) =

  • accept

if M accepts w reject

  • therwise

Construct a new TM D with H as a subroutine

October 28, 2020 4 / 12

slide-5
SLIDE 5

Halting problem undecidable II

For D, the input is M, where M is a TM It runs H on M, M and outputs the opposite result of H The machine D satisfies D(M) =

  • accept

if M rejects M reject if M accepts M But we get a contradiction D(D) =

  • accept

if D rejects D reject if D accepts D

October 28, 2020 5 / 12

slide-6
SLIDE 6

Halting problem undecidable III

We said earlier that the diagonalization method is used for the proof. Is that the case? We show that indeed it is used

October 28, 2020 6 / 12

slide-7
SLIDE 7

Diagonalization in the proof I

Set of TMs is countable so we can have M1 M2 M3 M1 A A M2 A A A . . . blank entries: unknown if reject or loop But H knows the solution as it is a decider M1 M2 M3 M1 A R A M2 A A A . . .

October 28, 2020 7 / 12

slide-8
SLIDE 8

Diagonalization in the proof II

D outputs opposite of diagonal entries M1 M2 . . . D M1 R M2 R ... D ?

October 28, 2020 8 / 12

slide-9
SLIDE 9

co-Turing-recognizable Language I

Definition: a language is co-Turing-recognizable if its complement is Turing-recognizable Theorem 4.22 Decidable ⇔ Turing-recognizable and co-Turing-recognizable Why not Turing-recognizable ⇒ complement Turing-recognizable Note that “recognizable” means any

October 28, 2020 9 / 12

slide-10
SLIDE 10

co-Turing-recognizable Language II

w ∈ language is accepted by the machine in a finite number of steps That is, no infinite loop Example: ATM Turing-recognizable but not decidable w ∈ ATM ⇒ reject or loop Thus ATM is not Turing-recognizable

October 28, 2020 10 / 12

slide-11
SLIDE 11

co-Turing-recognizable Language III

What if we swap qaccept, qreject? If a / ∈ A and loop occurs then a ∈ A, but TM still loops We cannot reach the new qaccept state Proof of Theorem 4.22 “⇒” Decidable ⇒ Turing-recognizable Complement ⇒ decidable ⇒ Turing-recognizable

October 28, 2020 11 / 12

slide-12
SLIDE 12

co-Turing-recognizable Language IV

“⇐” Now A, A are Turing-recognizable by two machines M1, M2 Construct a new machine M: for any input w

1

Run M1, M2 in parallel

2

M1 accept ⇒ accept, M2 accept ⇒ reject Never infinity loop M accepts all strings in A, reject all not in A Thus A is decidable with a decider M

October 28, 2020 12 / 12