suffix

# suffix - Computer Science E-207 A Proof by Construction and...

This preview shows pages 1–2. Sign up to view the full content.

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

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Computer Science E-207 A Proof by Construction and Mutual Inclusion Let L be a language and define Suffix( L ) = { x : ∃ w ∈ Σ * s.t. wx ∈ L } . Prove that, if L is regular, then so is Suffix( L ) . Proof Idea: Since L is regular, let M = ( Q, Σ ,q ,δ,F ) be a DFA recognizing L . Assume without loss of generality that M has no states that are unreachable from q . Informally, we change M into an NFA M by creating a new start state q and adding ε transitions from q to all other states. This allows M to “skip” the “prefix” part of any word in L . Note that the reason we don’t want any unreachable states here is that this construction might otherwise let us “jump” to some state that no word could bring M to, and this would be a bad thing! Proof: Formally, let M be as above and define M = ( Q , Σ ,q ,δ ,F ) where Q = Q ∪ { q } , δ ( q,σ ) = { δ ( q,σ ) } for all q ∈ Q and σ ∈ Σ, δ ( q ,ε ) = Q , δ ( q ,σ ) = ∅ for all σ ∈ Σ, and δ ( q,ε ) = ∅...
View Full Document

{[ snackBarMessage ]}

### Page1 / 2

suffix - Computer Science E-207 A Proof by Construction and...

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

View Full Document
Ask a homework question - tutors are online