lecture02­_finite_automata

lecture02­_finite_automata - Deterministic...

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

View Full Document Right Arrow Icon
Deterministic Finite Automata COMPSCI 102 Lecture 2
Background image of page 1

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

View Full DocumentRight Arrow Icon
Let me show you a machine so simple that you can understand it in less than two minutes
Background image of page 2
Steven Rudich: www.cs.cmu.edu/~rudich 0 0,1 0 0 1 1 1 0111 111 11 1 The machine accepts a string if the process ends in a double circle
Background image of page 3

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

View Full DocumentRight Arrow Icon
Steven Rudich: www.cs.cmu.edu/~rudich 0 0,1 0 0 1 1 1 The machine accepts a string if the process ends in a double circle Anatomy of a Deterministic Finite Automaton states states q 0 q 1 q 2 q 3 start state (q 0 ) accept states (F)
Background image of page 4
Steven Rudich: www.cs.cmu.edu/~rudich Anatomy of a Deterministic Finite Automaton 0 0,1 0 0 1 1 1 q 0 q 1 q 2 q 3 The alphabet of a finite automaton is the set where the symbols come from: The language of a finite automaton is the set of strings that it accepts {0,1}
Background image of page 5

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

View Full DocumentRight Arrow Icon
Steven Rudich: www.cs.cmu.edu/~rudich 0,1 q 0 L(M) = All strings of 0s and 1s The Language of Machine M
Background image of page 6
Steven Rudich: www.cs.cmu.edu/~rudich q 0 q 1 0 0 1 1 L(M) = { w | w has an even number of 1s}
Background image of page 7

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

View Full DocumentRight Arrow Icon
Steven Rudich: www.cs.cmu.edu/~rudich An alphabet Σ is a finite set (e.g., Σ = {0,1}) A string over Σ is a finite-length sequence of elements of Σ For a string x, |x| is the length of x The unique string of length 0 will be denoted by ε and will be called the empty or null string Notation A language over Σ is a set of strings over Σ
Background image of page 8
Steven Rudich: www.cs.cmu.edu/~rudich Q is the set of states Σ is the alphabet δ : Q × Σ → Q is the transition function q 0 Q is the start state F Q is the set of accept states A finite automaton is a 5-tuple M = (Q, Σ, δ , q 0 , F) L(M) = the language of machine M = set of all strings machine M accepts
Background image of page 9

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

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

This document was uploaded on 01/17/2012.

Page1 / 34

lecture02­_finite_automata - Deterministic...

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

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