MC 306 Theory of Computation Tuesday, 111103 - PowerPoint PPT Presentation

1 / 5
About This Presentation
Title:

MC 306 Theory of Computation Tuesday, 111103

Description:

... in common with DFAs, NFAs, PDAs: States and transitions. Start state ... Turing machine differs from DFAs, NFAs, PDAs: Halting states (not accepting/rejecting) ... – PowerPoint PPT presentation

Number of Views:41
Avg rating:3.0/5.0
Slides: 6
Provided by: skid
Category:

less

Transcript and Presenter's Notes

Title: MC 306 Theory of Computation Tuesday, 111103


1
MC 306 Theory of ComputationTuesday, 11/11/03
  • Last time
  • Closure properties of context-free languages
  • Review of Pumping Lemma for Regular Languages
  • Todays Class
  • One more closure property
  • Pumping Lemma for Context-free Languages
  • Intro to next topic Turing Machines
  • Reading 4.1
  • Exercises
  • 4.3b, 4.4
  • No new hand-in problems yet

2
Our final machine
  • DFA/NFA Model of computer that has fixed memory.
  • Simple calculators, digital watches
  • PDA Model of computer with a single stack. More
    powerful than DFA/NFA
  • Some scientific calculators
  • Turing Machine Model of fully general computer.

3
Turing Machine Basics
  • Turing Machine has parts in common with DFAs,
    NFAs, PDAs
  • States and transitions
  • Start state
  • Turing machine differs from DFAs, NFAs, PDAs
  • Halting states (not accepting/rejecting)
  • Much more flexible input tape
  • Is also an output tape can write on it
  • No need for final states can write results on
    tape!
  • Is bidirectional can move left or right (or
    stay still)
  • Tape is infinite never runs out of room for
    writing

4
TM Computation
  • We run a TM on a string w by writing it on the
    tape, and then running the machine from its start
    state
  • A transition
  • (1) reads the current symbol,
  • (2) Either (a) writes a symbol in that spot, or
    (b) moves left or right on tape
  • (3) Changes from the current state to a new state
  • We can accept/reject by writing 1 for yes, or
    0 for no, and then halting (enter a halting
    state)
  • Can write lots of other stuff too, so can have
    much more complex output!

5
Example
  • Note Special symbols used by every Turing
    machine
  • ? marks the left end of the tape
  • ? marks a blank square on the tape
  • Let ? a, b, c, and L ?c? ? ? a, b
  • Is L context-free?
  • Design a Turing machine to accept L
  • Design a tape-cleaning machine over a,b. This
    machine simply erases all the non-blank symbols.
Write a Comment
User Comments (0)
About PowerShow.com