Module15 - 1 Module 15 FSAs Defining FSAs Computing with...

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

View Full Document Right Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 1 Module 15 FSAs Defining FSAs Computing with FSAs Defining L(M) Defining language class LFSA Comparing LFSA to set of solvable languages (REC) 2 Finite State Automata New Computational Model 3 Tape We assume that you have already seen FSAs in CSE 260 If not, review material in reference textbook Only data structure is a tape Input appears on tape followed by a B character marking the end of the input Tape is scanned by a tape head that starts at leftmost cell and always scans to the right 4 Data type/States The only data type for an FSA is char The instructions in an FSA are referred to as states Each instruction can be thought of as a switch statement with several cases based on the char being scanned by the tape head 5 Example program 1 switch(current tape cell) { case a: goto 2 case b: goto 2 case B: return yes } 2 switch (current tape cell) { case a: goto 1 case b: goto 1 case B: return no; } 6 New model of computation FSA M=(Q, ,q , A , ) Q = set of states = {1,2} = character set = {a,b} dont need B as we see below q = initial state = 1 A = set of accepting (final) states = {1} A is the set of states where we return yes on B Q-A is set of states that return no on B = state transition function 1 switch(current tape cell) { case a: goto 2 case b: goto 2 case B: return yes } 2 switch (current tape cell) { case a: goto 1 case b: goto 1 case B: return no; } 7 Textual representations of * 1 switch(current tape cell) { case a: goto 2 case b: goto 2 case B: return yes...
View Full Document

Page1 / 26

Module15 - 1 Module 15 FSAs Defining FSAs Computing with...

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

View Full Document Right Arrow Icon
Ask a homework question - tutors are online