1.1 Finite Automata What's a finite automaton or finite state machine? Draw an example finite automaton on the board. even parity for ones machine (error checking application) What's a State Diagram? states (circles) start state (arrow from nowhere) accept state (double circle) transitions (arrows) How does a finite automaton process input or execute? 1. begin in start state 2. read input symbols one by one take edge with same label as input symbol 3. when input is consumed, produce output accept if in accept state, otherwise reject Trace the execution of the example machine with input 01101. Analyze the example machines. Describe the language each machine recognizes. What's a String? a sequence of symbols an input to a finite automaton What's a Language? a set of strings example: {11, 101, 1100} What's the Language of a Machine M? the set of strings that M accepts L(M) = { w | M accepts w } M recognizes L(M) What's a Regular Language? language recognized by some finite automaton How do you prove that a language is Regular? What's a Formal Definition of a finite automaton? 5-tuple (Q, S, d, q0, F) (S should be Sigma) 1. Q is a finite set (states) (note finite) 2. S is a finite set (input alphabet) (note finite) 3. d: QxS -> Q is the transition function (note function) 4. q0 is a member of Q (start state) 5. F is a subset of Q (accept states) Give the formal definition of the example machine. Why do you need a formal definition of a finite automaton? resolve any ambiguities notation simplifies definitions and proofs better for input to a program Give the state diagram from the formal definition. M = ( {x, y, z}, {a, b}, d, x, {z} ) a b x z y y y y z z z