1 / 13

Proof of the Pumping Theorem for Regular Languages

Proof of the Pumping Theorem for Regular Languages. Richard Beigel CIS Temple University. The Pumping Theorem for Regular Languages. If L is regular then  N  z such that z  L and | z |  N  u , v , w such that z = uvw , | uv |  N , and | v | > 0

iman
Download Presentation

Proof of the Pumping Theorem for Regular Languages

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Proof of the Pumping Theorem for Regular Languages Richard Beigel CIS Temple University

  2. The Pumping Theorem for Regular Languages If L is regular then N z such that z  L and |z|  N u,v,w such that z = uvw , |uv|  N, and |v| > 0 i [uviw  L]

  3. Proof • Assume L is regular • Then there is a (standardized) DFR P that recognizes L (no EOF or NOOP) • Let be N be the number of control states in P • Let z  L and |z|  N • Consider P’s accepting computation on input z • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N.

  4. Proof • Then there is a standardized DFR P that recognizes L (no EOF or NOOP) • Let be N be the number of control states in P • Let z  L and |z|  N • Consider P’s accepting computation on input z • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N. • By the pigeonhole principle qj=qk for some j<k

  5. Proof • Let be N be the number of control states in P • Let z  L and |z|  N • Consider P’s accepting computation on input z • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N. • By the pigeonhole principle qj=qk for some j<k • Let u be the string scanned between q0 and qj

  6. Proof • Let z  L and |z|  N • Consider P’s accepting computation on input z • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N. • By the pigeonhole principle qj=qk for some j<k • Let u be the string scanned between q0 and qj • Let v be the string scanned between qj and qk

  7. Proof • Consider P’s accepting computation on input z • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N. • By the pigeonhole principle qj=qk for some j<k • Let u be the string scanned between q0 and qj • Let v be the string scanned between qj and qk • Let w be the string scanned between qk and qn

  8. Proof • Let q0, q1, …, qn be the sequence of control states in that computation. Then n N. • By the pigeonhole principle qj=qk for some j<k • Let u be the string scanned between q0 and qj • Let v be the string scanned between qj and qk • Let w be the string scanned between qk and qn • Then uvw = z, |uv|  N, |v|  1, • and P accepts uviw for all i  0

  9. Proof • By the pigeonhole principle qj=qk for some j<k • Let u be the string scanned between q0 and qj • Let v be the string scanned between qj and qk • Let w be the string scanned between qk and qn • Then uvw = z, |uv|  N, |v|  1, • and P accepts uviw for all i  0 • Therefore uviwL for all i  0, completing the proof of the Pumping Theorem

  10. qj = qk Picture-proof that uv*w  L v u w q0 qj qn

  11. Example: L = {an2 : n 0} • Assume L is regular • Let N be given by the Pumping Theorem • Let z = aN2 • Let u, v, w be given by the Pumping Theorem • Then v = ak where 0 <k  N • Let i = 2 • Then uviw = uv2w = uvvw = aN2+ k • Since N2 < N2 + k N2 + N < N2 + 2N + 1 = (N + 1)2, N2 + k is not a square, so uviw = aN2+ k L • This contradicts the Pumping Theorem, so L is not regular

  12. Example: L = {ambn : mn} • Assume L is regular • Let N be given by the Pumping Theorem • Let z = aN bN • Let u, v, w be given by the Pumping Theorem • Then v = ak where 0 <k  N • Let i = 2 • Then uviw = uvvw = aN+k bN • Since k > 0, N+k> N, so uviw = aN+k bN L • This contradicts the Pumping Theorem, so L is not regular

  13. Example: L = {ambn : mn} • Assume L is regular • Let N be given by the Pumping Theorem • Let z = aN bN • Let u, v, w be given by the Pumping Theorem • Then v = ak where 0 <k  N • Let i = 0 • Then uviw = uw = aN-k bN • Since k > 0, N-k< N, so uviw = aN-k bN L • This contradicts the Pumping Theorem, so L is not regular

More Related