{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# l7 - Lecture 7 Turing Machines David Dill Department of...

This preview shows pages 1–8. Sign up to view the full content.

Lecture 7: Turing Machines David Dill Department of Computer Science 1

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Outline (finish up) Decision problems on regular languages. Turing machines and their languages. Programming tricks. 2
Some decision problems Decision problem: A question with a yes/no answer. Is string x L ( N ) ? (The membership problem.) Solution: Compute ˆ δ ( q 0 , x ) , check for final states. Given a finite automaton, N , is L ( N ) = ? (The emptiness problem.) Given a FA, how do you check for emptiness reasonably quickly? Answer: Do depth-first or breadth-first search from q 0 for a reachable final state. Is L ( N ) = Σ * ? (The universality problem.) Answer: Check L ( N ) = . This is easy if N is a DFA. Otherwise, your best bet is to convert it to a DFA and complement. Is L ( N ) L ( M ) ? (The subset problem) Answer: Check for L ( N ) L ( M ) = Equivalence? Answer: Check for subset in both directions, OR minimize both DFAs and check if they are the same. 3

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Turing Machines Models of computation so far have been highly restricted. Next model is really the most general useful of computation. This material is full of surprises. The proof that some problems are undecidable is one of the greatest intellectual accomplishments of humanity. First surprise: There IS a most general model of computation. It seems that all general models of computation have the same power. This is called the “Church-Turing thesis.” It’s not really provable, but it seems to be true. 4
Turing Machines Finite control with a tape which is used for input and for unbounded storage. There is a “head” that can read/write the tape. (( TM picture )) The tape is infinite in both directions. There is s special “blank” symbol (B). All but a finite number of positions are blank at any given time. Def A move of a TM is based on the current state and the symbol currently being scanned, and it changes state, writes a new symbol, and moves left or right. 5

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Def. of Turing Machine All sets are finite: M = ( Q, Σ , Γ , δ, q 0 , B, F ) Q states Σ input symbols Γ tape symbols . Σ Γ δ : Q × Γ Q × Γ × { L, R } q 0 – start symbol B – “blank” B Γ Σ . F – Final states. 6
TM Instantaneous Descriptions An ID for a TM is a string X 1 X 2 . . . X i - 1 qX i . . . X n where q is the current state.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### Page1 / 19

l7 - Lecture 7 Turing Machines David Dill Department of...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online