Lecture 2: Uncomputability and the Haling Problem

Similar documents
Computability and computational complexity

Lecture 14: Randomized Computation (cont.)

Lecture 11: Pseudorandom functions

Lecture 9: Hierarchy Theorems

CS151 Complexity Theory

The Growth of Functions. Theoretical Supplement

(A sequence also can be thought of as the list of function values attained for a function f :ℵ X, where f (n) = x n for n 1.) x 1 x N +k x N +4 x 3

The multiplicative structure of finite field and a construction of LRC

w (1) ˆx w (1) x (1) /ρ and w (2) ˆx w (2) x (2) /ρ.

The picture in figure 1.1 helps us to see that the area represents the distance traveled. Figure 1: Area represents distance travelled

Polynomial identity testing and global minimum cut

MAT1026 Calculus II Basic Convergence Tests for Series

Zeros of Polynomials

Computability and computational complexity

Recursive Algorithm for Generating Partitions of an Integer. 1 Preliminary

CHAPTER I: Vector Spaces

Sequences and Limits

Seunghee Ye Ma 8: Week 5 Oct 28

Topics. Homework Problems. MATH 301 Introduction to Analysis Chapter Four Sequences. 1. Definition of convergence of sequences.

6.3 Testing Series With Positive Terms

Review Problems 1. ICME and MS&E Refresher Course September 19, 2011 B = C = AB = A = A 2 = A 3... C 2 = C 3 = =

Introduction to Automata Theory. Reading: Chapter 1

Math 61CM - Solutions to homework 3

6 Integers Modulo n. integer k can be written as k = qn + r, with q,r, 0 r b. So any integer.

Solutions for the Exam 9 January 2012

Sequences and Series

CS 270 Algorithms. Oliver Kullmann. Growth of Functions. Divide-and- Conquer Min-Max- Problem. Tutorial. Reading from CLRS for week 2

ECE-S352 Introduction to Digital Signal Processing Lecture 3A Direct Solution of Difference Equations

1 Review and Overview

Notes for Lecture 11

sin(n) + 2 cos(2n) n 3/2 3 sin(n) 2cos(2n) n 3/2 a n =

The Borel hierarchy classifies subsets of the reals by their topological complexity. Another approach is to classify them by size.

Resampling Methods. X (1/2), i.e., Pr (X i m) = 1/2. We order the data: X (1) X (2) X (n). Define the sample median: ( n.

Chapter 3. Strong convergence. 3.1 Definition of almost sure convergence

# fixed points of g. Tree to string. Repeatedly select the leaf with the smallest label, write down the label of its neighbour and remove the leaf.

b i u x i U a i j u x i u x j

3.2 Properties of Division 3.3 Zeros of Polynomials 3.4 Complex and Rational Zeros of Polynomials

Lecture 1: Basic problems of coding theory

Proof of Goldbach s Conjecture. Reza Javaherdashti

Some remarks for codes and lattices over imaginary quadratic

OPTIMAL ALGORITHMS -- SUPPLEMENTAL NOTES

Solutions to Math 347 Practice Problems for the final

1 Approximating Integrals using Taylor Polynomials

Problem Set 2 Solutions

UC Berkeley CS 170: Efficient Algorithms and Intractable Problems Handout 17 Lecturer: David Wagner April 3, Notes 17 for CS 170

TEACHER CERTIFICATION STUDY GUIDE

ACO Comprehensive Exam 9 October 2007 Student code A. 1. Graph Theory

THE ASYMPTOTIC COMPLEXITY OF MATRIX REDUCTION OVER FINITE FIELDS

Advanced Analysis. Min Yan Department of Mathematics Hong Kong University of Science and Technology

Homework 9. (n + 1)! = 1 1

x c the remainder is Pc ().

Machine Learning Theory Tübingen University, WS 2016/2017 Lecture 12

Course 8 Properties of Regular Languages

Addition: Property Name Property Description Examples. a+b = b+a. a+(b+c) = (a+b)+c

Sequences A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

September 2012 C1 Note. C1 Notes (Edexcel) Copyright - For AS, A2 notes and IGCSE / GCSE worksheets 1

Product measures, Tonelli s and Fubini s theorems For use in MAT3400/4400, autumn 2014 Nadia S. Larsen. Version of 13 October 2014.

Model of Computation and Runtime Analysis

Assignment 5: Solutions

A Note on the Symmetric Powers of the Standard Representation of S n

Last time, we talked about how Equation (1) can simulate Equation (2). We asserted that Equation (2) can also simulate Equation (1).

Quantum Computing Lecture 7. Quantum Factoring

Ch3. Asymptotic Notation

Lecture 2: Monte Carlo Simulation

Mon Feb matrix inverses. Announcements: Warm-up Exercise:

4.1 Sigma Notation and Riemann Sums

Machine Learning Theory Tübingen University, WS 2016/2017 Lecture 11

A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

11. FINITE FIELDS. Example 1: The following tables define addition and multiplication for a field of order 4.

MA131 - Analysis 1. Workbook 2 Sequences I

Math 155 (Lecture 3)

Chapter 4. Fourier Series

Read carefully the instructions on the answer book and make sure that the particulars required are entered on each answer book.

Chapter 0. Review of set theory. 0.1 Sets

Convergence of random variables. (telegram style notes) P.J.C. Spreij

Square-Congruence Modulo n

4.3 Growth Rates of Solutions to Recurrences

Information Theory Tutorial Communication over Channels with memory. Chi Zhang Department of Electrical Engineering University of Notre Dame

6.867 Machine learning, lecture 7 (Jaakkola) 1

Math 105 TOPICS IN MATHEMATICS REVIEW OF LECTURES VII. 7. Binomial formula. Three lectures ago ( in Review of Lectuires IV ), we have covered

Lecture 10: Universal coding and prediction

SEQUENCES AND SERIES

Infinite Sequences and Series

6. Sufficient, Complete, and Ancillary Statistics

Math 216A Notes, Week 5

Math 312 Lecture Notes One Dimensional Maps

Let us consider the following problem to warm up towards a more general statement.

Lecture 9: Pseudo-random generators against space bounded computation,

3 Gauss map and continued fractions

Time-Domain Representations of LTI Systems

62. Power series Definition 16. (Power series) Given a sequence {c n }, the series. c n x n = c 0 + c 1 x + c 2 x 2 + c 3 x 3 +

Lecture 19: Convergence

WHEN IS THE (CO)SINE OF A RATIONAL ANGLE EQUAL TO A RATIONAL NUMBER? 1. My Motivation Some Sort of an Introduction

Efficient GMM LECTURE 12 GMM II

Mathematical Foundation. CSE 6331 Algorithms Steve Lai

Chapter 7: Numerical Series

Notes 5 : More on the a.s. convergence of sums

Pairs of disjoint q-element subsets far from each other

Model of Computation and Runtime Analysis

Stochastic Matrices in a Finite Field

Transcription:

CSE 200 Computability ad Complexity Wedesday, April 3, 2013 Lecture 2: Ucomputability ad the Halig Problem Istructor: Professor Shachar Lovett Scribe: Dogcai She 1 The Uiversal Turig Machie I the last class, we saw that the defiitio of TM is robust: chagig the alphabet, # of tapes, etc. do ot chage its computatio power. Hece, w.l.o.g. assume a TM M is composed of a alphabet Γ, a set of states Q, a trasitio fuctio δ : Q Γ 3 Q Γ 2 {L, S, R} 2, ad 3 tapes: INPUT, WORK, ad OUTPUT. A uiversal TM ca be viewed as a virtual machie. Defiitio 1 (Uiversal TM) A ormal TM: M def = (Γ; Q; δ) ca be treated as a strig i {0, 1}. A TM U is a uiversal machie if U( M, x) = M(x). A aalogy is a compiler. Note that a compiler is of fixed-size, but it ca compile code of ay legth. The iput to U is the descriptio (ecodig) of a TM, for example: Γ Q δ x ( stads for cocateatio i some uambiguous way). U simulates the iput TM. We ca have some covetio C about how to iterpret a arbitrary strig i {0, 1} as a TM. W.l.o.g., if a strig does t make ay sese i our pre-specified covetio C, we just treat it as a special TM that always output othig ad halts immediately after start. C does t map each strig i {0, 1} ito a meaigful TM just i the same way as some real-world programs do t compile. Ecodig C: TM Strigs {0, 1} M M M x The, how to costruct a uiversal TM U? Descriptio of U. U is simply a iterpreter. It has two parts of iput M ecoded as M ad iput x fed to M. U uses a work tape to keep track of the rutime cofiguratio of M. U simulates each step of M(x). At each such step, U scas M s curret cofiguratio o U s work tape ad it scas the trasitio fuctio i M to fid the accordig actio. U performs the correspodig actio by updatig the cofiguratio. Fially, output of M(x) is writte out to the output tape. Theorem 2 (Existece of U) The uiversal TM exists. 2 The Haltig Problem Defiitio 3 (Haltig problem) Halt : {0, 1} {0, 1} {0, 1} Halt( M, x) def = { 0 If M(x) halts. 1 If M(x) loops forever. 2-1

Ituitive implicatio: You ca prove whether some specific program (say, a program for fidig the shortest path) halts or ot evetually. But you caot write a uiversal program that works for all programs. This etails that o automatio for decidig TM haltig exists. Theorem 4 Halt is ot computable. Proof Assume towards cotradictio that Halt is computable by a TM M. Defie g : {0, 1} {0, 1} g(x) def = { 0 Halt(x, x) = 1 loops forever Halt(x, x) = 0 If Halt is computable the so is g. Suppose g is computable by a TM M. What is g( M )? If g( M ) = 0, the by the defiitio of g( ), Halt( M, M ) = 1, which meas that M( M ) loops forever. So g( M ) M( M ). If g( M ) loops forever, the by the defiitio of g( ), Halt( M, M ) = 0, which meas that M( M ) halts. So g( M ) M( M ). Digressio. The proof we saw is by a method called diagoilizatio. It was iveted by Georg Cator to prove that the cardiality of real umbers (R) is bigger tha that of ratioal umbers (Q). 3 Reductios Halt ca be used as the steppig stoe to prove that may other problems are icomputable, too. The basic idea is to obtai cotradictio by reducig Halt to a targeted problem. The assumptio that the target problem is computable will imply that Halt is computable, which is a cotradictio. Defiitio 5 (Busy Beaver) Cosider TM with just oe tape. Alphabet Γ def = {0, 1}. Have o iput. Iitial tape is 00... 0. If they halt, cotet of tape is output. BB() def = maximal umber of 1 s o the tape output by a haltig TM with states. Historical otes. 1 A busy beaver is a TM that attais the maximum umber of steps performed or umber of o-blak symbols fially o the tape amog all TMs i a certai class. The TMs i this class must meet certai desig specificatios ad are required to evetually halt after beig started with a blak tape. A busy beaver fuctio quatifies these upper limits o a give measure, ad is a o-computable fuctio. I fact, a busy beaver fuctio ca be show to grow faster asymptotically tha ay computable fuctio. The cocept was first itroduced by Tibor Radó [2]. For example, let Σ(, 2) deote the largest # of 1 s pritable by a -state, 2-symbol (i.e., {0, 1}) TM started o a iitially blak tape before haltig. Table 1 gives a sese how fast this fuctio skyrockets. Theorem 6 BB is ucomputable. 1 From Busy Beaver s Wiki etry: http://e.wikipedia.org/wiki/busy_beaver. 2-2

Table 1: Values of Σ(, 2) 2-state 3-state 4-state 5-state 6-state 2-symbol 4 6 13 4, 098 3.5 1018267 Proof Assume BB is computable by a TM M with k states. Let DBL be a TM with k states that performs the followig operatio 1111 0 0 2 111111 0 0 Let be large eough to be specific later. Cosider the followig Turig machie M : Writes 1 s o tape : 00 Apply DBL: Apply M: Apply M agai: 11111 0. 2 1111 0 11 1 0. BB(2) 11 11 0. BB(BB(2)) 11 11 0. How may states does M have? The first step takes states; the secod k states; ad the third ad fourth k states. So i total + 2k + k states. We get that BB( + 2k + k ) BB(BB(2)). Note that BB is mootoe icreasig because BB( + 1) BB() for ay N. So BB(2) + 2k + k which is clearly impossible if is large eough (say, > 2k + k ). It turs out that there are o o-trivial computable fuctio of the output of a computatio. Theorem 7 (Rice s Theorem) Let f : {0, 1} {0, 1} {0, 1} be a computable fuctio so that f( M, x) depeds just o M(x). The f must be a costat fuctio. Rice s Theorem is i Exercise 1.12 i [1]. Cojecture 8 (The 3 + 1 Problem, aka Collatz cojecture) Cosider the followig fuctio f : N N. { /2 eve f() = 3 + 1 odd It is cojectured that for ay startig value, if we apply f eough times we will reach 1 evetually (ote that f(f(f(1))) = 1, e.g. 1 is i a cycle). This was verified for may values of, but it is ukow if it is true for all. Defiitio 9 (The Geeralized 3 + 1 Problem) Iput: m, a 0, b 0, a m 1, b m 1 atural umbers. Cosider a fuctio of the form a 0 + b 0 mod m 0 a 1 + b 1 mod m 1 f() =... a m 1 + b m 1 mod m m 1 2-3

For example, lettig m = 2 ad a 0 = 1 2, b 0 = 0, a 1 = 3, a 1 = 1 yields the 3 + 1 problem. Theorem 10 Cosider the followig fuctio F (m, a 0, b 0,..., a m 1, b m 1 ) = the geeralized 3 + 1 problem always reaches 1 from ay startig value is ucomputable. Here is aother example of a ucomputable fuctio. Defiitio 11 (Hilbert s 10 th problem 2 ) Give a multivariate polyomial p(x 1,..., x ) with iteger coefficiets, figure out if p has a iteger solutio. Theorem 12 This is ucomputable. 4 Time Complexity Defiitio 13 (Time complexity) TM M has time complexity T : N N if for all iput x {0, 1}, M(x) always halts; M(x) halts after at most T ( x ) steps, where x deotes the legth of the iput x. f : {0, 1} {0, 1} has time complexity T if there exists a TM M computig f which has time complexity T. Defiitio 14 (TIME) TIME(T ()) def = fuctios computable i time O(T ()). For example, the problem of decidig whether a give graph is bipartite (f : graph Is it bipartite?) is i TIME( 2 ). Be cautious that this is a upperboud istead of a lowerboud. Defiitio 15 (P ad EXP) P def = c 1 TIME( c ). E.g., shortest paths, liear programmig. EXP def = c 1 TIME(2 c ). E def = c 1 TIME(2 c ). E.g., SAT. Remark #1: Why do we care about polyomial-time computatio? Why care about polyomial time ad ot specifically o liear, quadratic, or cubic time? The aswer is, i reality, the degrees of polyomials that upperboud the ruig time of problems i P are usually very small. P captures the ituitio of efficietly computatio. However, i some scearios, people do wat to fid algorithms that ru i a more restricted time boud, say, liear. For example, algorithms for property testig may require sub-liear time, which meas that it caot eve read the whole iput. Remark #2: The defiitio of EXP is robust. Some graph algorithms, for -vertex graph takes 2 time. How do we ecode the graph (say, it s sparse) matters: List of edges: (algorithm rus i O(2 ) steps). Adjacecy matrix: 2 (algorithm rus i O(2 ) steps). EXP is more robust tha E i that a problem caot escape EXP eve its descriptio s size is blow up from to 2. Usually, we take atural ecodig for a problem ad they fit ito EXP. 2 http://e.wikipedia.org/wiki/hilbert s_problems 2-4

Refereces [1] Sajeev Arora ad Boaz Barak. Computatioal Complexity - A Moder Approach. Cambridge Uiversity Press, 2009. [2] Tibor Radó. O o-computable fuctios. Bell System Techical Joural, 41:877 884, 1962. 2-5