CS250      Lab11 - Turing Machines

Objectives:

  1. A TM differs from other automata in its transitions.  In a TM, each transition implies reading a single symbol from a tape, overwriting that symbol with a new symbol, and moving the tape head either left, right, or not at all.  A transition, therefore, for a TM is defined in JFLAP as r;w,d.  The r is exactly one symbol to read from the tape.  If r is read, the w is exactly one symbol to write to the tape over r, and d is the direction to move the tape head after writing w.  The symbols r and w must be elements of the tape alphabet and d is either R, L, or S which stand for a move Right, Left, or Stay respectively.

    Download the lab11 files and start JFLAP 6.0.  Open file file ex11.1 in the Turing Machine editor. 

    Try Step with Closure with the input aabbbb.  Does it accept?
    Try Step with Closure again with the input aabb.  Does it accept?
     
    Clearly and succinctly describe the language that is accepted by the TM in ex11.1
     

     


  2.  
    Build and thoroughly test TMs for
    a) 7g p237 of your text,.
    b) L={w| w consists of k a's where k is a power of 2}

     

  3. JFLAP allows multitape machines with two to five tapes.  An n-tape machine requires that each transition read n symbols, one for each of the tapes, each of which has one read-write head;  JFLAP progresses a configuration on a transition only if all of the n read symbols match.

    Sections 10.2 and 10.3 of your text describe how multitape machines and nondeterministic machines are equivalent to our original TM.  Open the 2-tape nondeterministic machine ex11.2.  This machine accepts if the input on the first tape is a substring of the input on the second tape.  Step through the machine with input abaa on tape1 and abbaabaab on tape2. 
     
    Clearly and succinctly describe in your own words how the machine in ex11.2 works.
     

     

  4. Build and thoroughly test a 2-tape TM for {wwR| w in {a,b}*}.  The TM should start with the input string on tape1 and tape2 blank.