1 Module 8 Halting Problem revisited –Universal Turing machine half-solves halting problem –A universal Turing machine is an operating system/general purpose.

Slides:



Advertisements
Similar presentations
1 Lecture 4: Formal Definition of Solvability Analysis of decision problems –Two types of inputs:yes inputs and no inputs –Language recognition problem.
Advertisements

Questions Considered l What is computation in the abstract sense? l What can computers do? l What can computers not do? (play basketball, reproduce, hold.
1 Module 2: Fundamental Concepts Problems Programs –Programming languages.
1 9/29/06CS150 Introduction to Computer Science 1 Loops Section Page 255.
1 Module 10 Universal Algorithms –moving beyond one problem at a time –operating system/general purpose computer.
1 Module 9 Recursive and r.e. language classes –representing solvable and half-solvable problems Proofs of closure properties –for the set of recursive.
Snick  snack A Working Computer Slides based on work by Bob Woodham and others.
1 Module 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex.
Announcements The first graded lab will be posted Sunday 2/15 and due Friday 2/27 at midnight It is brand new, so please don’t hand in last semester’s.
1 Module 11 Proving more specific problems are not solvable Input transformation technique –Use subroutine theme to show that if one problem is unsolvable,
Ch. 1: Software Development (Read) 5 Phases of Software Life Cycle: Problem Analysis and Specification Design Implementation (Coding) Testing, Execution.
Complexity Analysis (Part I)
Lecture 6: for Loops Yoni Fridman 7/6/01 7/6/01. OutlineOutline  The for statement  The for statement’s format  The for statement’s flow  Comparing.
1 Lecture 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex.
CS1001 Lecture 23. Overview Incompleteness and the Halting Problem Incompleteness and the Halting Problem Methods in Artificial Intelligence Methods in.
1 Lecture 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex.
Recursive Algorithms Nelson Padua-Perez Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
1 Lecture 10 Universal Algorithms –moving beyond one problem at a time –operating system/general purpose computer.
1 Lecture 13 Turing machine model of computation –Sequential access memory (tape) –Limited data types and instructions –Graphical representation –Formal.
1 Lecture 11 Proving more specific problems are not solvable Input transformation technique –Use subroutine theme to show that if one problem is unsolvable,
1 Module 11 Proving more specific problems are not solvable Input transformation technique –Use subroutine theme to show that if one problem is unsolvable,
1 Lecture 13 Turing machine model of computation –Sequential access memory (tape) –Limited data types and instructions –Formal Definition –Equivalence.
1 Module 4: Formal Definition of Solvability Analysis of decision problems –Two types of inputs:yes inputs and no inputs –Language recognition problem.
Chapter 1 Program Design
1 Module 10 Recursive and r.e. language classes –representing solvable and half-solvable problems Proofs of closure properties –for the set of recursive.
CHAPTER 10 Recursion. 2 Recursive Thinking Recursion is a programming technique in which a method can call itself to solve a problem A recursive definition.
Theory of Computation. Computation Computation is a general term for any type of information processing that can be represented as an algorithm precisely.
1 CS Programming Languages Random Access Machines Jeremy R. Johnson.
Presented by Ravi Teja Pampana
Algorithms: Selected Exercises Goals Introduce the concept & basic properties of an algorithm.
CS-2852 Data Structures LECTURE 3A Andrew J. Wozniewicz Image copyright © 2010 andyjphoto.com.
1.1 1 Introduction Foundations of Computer Science  Cengage Learning.
Computer Architecture Computational Models Ola Flygt V ä xj ö University
Week 2.  Understand what the processor is and what it does.  Execute basic LMC programs.  Understand how CPU characteristics affect performance.
CISC 110 Day 1 Hardware, Algorithms, and Programming.
Turing Machines – Decidability Lecture 25 Section 3.1 Fri, Oct 19, 2007.
How computers work The CPU & Memory. The parts of a computer.
1 09/20/04CS150 Introduction to Computer Science 1 Let ’ s all Repeat Together.
Chapter 2 Pseudocode. Objectives To introduce common words, keywords and meaningful names when writing pseudocode To define the three basic control structures.
Lecture 4: Calculating by Iterating. The while Repetition Statement Repetition structure Programmer specifies an action to be repeated while some condition.
IB Computer Science Unit 5 – Advanced Topics Recursion.
ELEN 033 Lecture #1 Tokunbo Ogunfunmi Santa Clara University.
BEGINNING PROGRAMMING.  Literally – giving instructions to a computer so that it does what you want  Practically – using a programming language (such.
Computer Architecture
Overview Go over parts of quiz? Another iteration structure for loop.
HOW COMPUTERS WORK THE CPU & MEMORY. THE PARTS OF A COMPUTER.
ECE 250 Algorithms and Data Structures Douglas Wilhelm Harder, M.Math. LEL Department of Electrical and Computer Engineering University of Waterloo Waterloo,
The Big Picture Chapter 3.
The Big Picture Chapter 3. A decision problem is simply a problem for which the answer is yes or no (True or False). A decision procedure answers a decision.
Agenda What is algorithm? Procedural programming vs OOP More object concepts Practice Java language Features(Chap. 1) packages and classes Types and identifiers.
Chapter 9 Turing Machines What would happen if we change the stack in Pushdown Automata into some other storage device? Truing Machines, which maintains.
Control Structures: Examples. for-loop example Q: If a=1, b=3, and x=7, what is the value of x when the loop terminates? A: x=1 for(k=a; k
Chapter I: Introduction to Computer Science. Computer: is a machine that accepts input data, processes the data and creates output data. This is a specific-purpose.
Princeton University COS 423 Theory of Algorithms Spring 2002 Kevin Wayne Lecture S1: Sample Lecture.
Module 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex 1.
Exercise 2 : Using for loop Repetition (loop) (1)control variable initialization (2)Test Conditon (3)Modification of control variable value order : (1)
Fluency with Information Technology
while Repetition Structure
Chapter No. : 1 Introduction to Java.
Algorithm Analysis CSE 2011 Winter September 2018.
Turing Machine
1.#.
Stack Memory 1 (also called Call Stack)
Software Programming J. Holvikivi 2014.
Systems Architecture I (CS ) Lecture 1: Random Access Machines
CSC Classes Required for TCC CS Degree
Algorithmic Complexity and Random Strings
State Machines EECS 20 Lecture 8 (February 2, 2001) Tom Henzinger.
P.V.G’s College of Engineering, Nashik
Systems Architecture I (CS ) Lecture 1: Random Access Machines
Presentation transcript:

1 Module 8 Halting Problem revisited –Universal Turing machine half-solves halting problem –A universal Turing machine is an operating system/general purpose computer

2 Half-solving the Halting Problem State the Halting Problem Give an input instance of the Halting Problem We saw last time that the Halting Problem is not solvable. How might we half-solve the Halting Problem?

3 Example Input Program P bool main(unsigned Q) { int i=2; if ((Q = = 0) || (Q= = 1)) return false; while (i<Q) { if (Q%i = = 0) return (false); i++; } return (true); } Nonnegative integer 4

4 Organization Universal Turing machine’s Memory Program P Program P’s Memory Program P bool main(unsigned Q) { int i=2; if ((Q = = 0) || (Q= = 1)) return false; while (i<Q) { if (Q%i = = 0) return (false); i++; } return (true); } Program Counter int i,Q; 4 Line 1

5 Description of universal Turing machine * Basic Loop –Find current line of program P –Execute current line of program P Update program P’s memory –Update program counter –Return to Top of Loop Program P Program P’s Memory Program Counter

6 Past, Present, Future Turing came up with the concept of a universal Turing machine in the 1930’s –This is well before the invention of the general purpose computer –People were still thinking of computing devices as special-purpose devices (calculators, etc.) –Turing helped move people beyond this narrow perspective Turing/Von Neumann perspective –Computers are general purpose/universal algorithms Focused on computation Stand-alone Today, we are moving beyond this view –Internet, world-wide web –However, results in Turing perspective still relevant

7 Debuggers How are debugger’s like gdb or ddd related to universal Turing machines? How do debuggers simplify the debugging process?

8 Placing the Halting Problem Solvable Half-solvable  ll Problems H

9 Summary Universal Turing machines –1930’s, Turing –Introduces general purpose computing concept –Not a super intelligent program, merely a precise follower of instructions Halting Problem half-solvable but not solvable