Download as pdf
Download as pdf
You are on page 1of 16
Weex 3: Lecture Notes E- NPA = Mows a transition on &, the empty sting ( spontaneous Hransition without xeceiving an input ) - Doesnot en the class of longuages Hol con be accepted by FA —U qives us some added “programing convenience” —Closely veloted to sequloy eapressions and useful in Groving tne equivalence. loekween classes of language® auepted by FA and boy tres An appli cation : Tent Search + Z + every printable ASC characters © Ana, Oy 2 Om Key word HES > NPA thal recognizes yay. Oy bea, + NEA that recognizes oia,--ay oY bbe -- by ay o: as an > 4 5 I ee ¢ ) b be. b, Ser 4+@ DPA thet Terognizes Ge «Ae (use subset Construction, NEA stavt state Io peA stort tate {40}. 2 if Qe in NFA then the BEA state fae Pemine ted vohere ye treet Ody 2+ Oro hes ‘Wye TES every other stote of the NCA trot is reachable jrom q, jpllowing o path whose labels ove o sufbin of 1.0, --: Om Example web ebay z € b start gO ee Sue {4.83 —— = ~O+- 02-079 DFA state fav,c} > ave + of states of the NPA = # of states of DEA ° Transitions are more in bEA Finite Automata voith gemoves (E-alfa) + quibtuple (8, 2,8.4,,°) same as NFA, only differs in + 8 Ax(Sufet) » 2° Enample: = 6. 8.8 E- APA for o” acephing the lem uage Le fw | consits of omy ne. of 0's followed by any vo. of J followed ley ony 72. of a's} * 002 is accepted by the £-NFA by the poth Fo Vo to Ms Oy 14, with ares labeled 0,0,£,¢,2 ° o e & 2 Ye 4. — 4, — 5 4, 1G) stort inputs te itp} + + {2.4 4, + fp + it} a + + fp &- closure E-closure (g)+ J P] there is a path Prom 4 to p ‘7% with all aves labeled e} State Enample: €- closure (9) + {4 %,%3 } Jor the previous ernample - Te € E-closuve (te) a5 poth Consisting of along hes wo are, hence trivially gil it’s ares ave Recursively " GEé &-closuve (4) 4. if pe & closure (q) ond ve 8 (pe) Then + € &-closuce (9) oF pe & closure (4), then 5 (p.€) € & closure (4) 5 > tronsition function of the s-NEA invelved &- closure lp) P > a set of slates U_ & ctosure (p) beP Extended transition junction jer e- nea ( é) Gilqe) © 6 iclocue (9) 2 Blane) + €- closure (p), achere em a6 oe Pe f P| dor some ve 8 (an) pisin 8 (naj » fplee. pe s(Blaad, a} * (8 laa) Eatend Sand 6 to sets of states. 3, §(R,0)- U_ 8(2,0) ER 4. $(Rw)s U Bla) qeR jor sets of states Re &. * 8(4,4) wot necessevily equal to 52,9) jor £-NFA as 6 (ae) + all states teachalole from 7 by peths labeled a ( includin poths with ores labeled <) sl4,a) > only states teachable from 4 ey aves labeled a Enomple Co 1 2 me OOS Blae)+ 84%, €e) = E- closure ( 5(B(4., 2),0)) * €- closure (s (é- closure (ae). £)) : &- closure (s Uf 4644,93),0)) £- closure ( tt} v4) > $- closure ( £403) * $44.4) Slits, ot) + €~- closure ( $ (3 1%, 0), 1)) + $+ closure [5 ( £44,9,8,3,1) 2 £- closure (4 ufas,u 4) > E- closure ( {4,3) > {44,3 ae 5 (4.2): t4,4. E- NFA * allows a transition Spontaneously without receiving on input. symbol + this new capability gives some added prog sammin convenience , without enpanding the class of language > that can be accepted by finite automata. + useful in proving the equivalence between the Classes of long uages accepted by finite automata and by teqular eapre ssions - Equivalence of N¢A's ord DFA'S ‘Theorem: Lis accepted by some &- NFA if? Lis occepted by some NFA Proof: GP) M+ (8,2, 64,6) , on NEA con be interpreted as an & NFA mm. (8, zu fe}, 3’, 4, where 5 is defined by 8 (4,0) « § Sita) if age, o€l + otherwise (omy if) ome (8. Zug}, S.a,F) se NEA on NFA con be constructed Mm. (8.2.8.4, 6) where 8 (4,0) > $ (4,0) jor qeh, a€L£ Fs j Fo tees if ¢- closure (0) OF + 4 F otherwise: Faample (& NEA to NEA construction), mr OG HO ¢" [oot &- we nt +4 Fo, otherwise $44 iat + 45 £4.,%]J > e {%s, Us} + ¢ £45,45 + tts.43 4 + + + 8(%4t)e 8 lana): F(aner). 2¢(5U8 Ue), +) 2 e-e($ (€¢( 40)54)) selte): §%,%$ 7s fa3ue ES {a3 zclu)= £4,3 a, Mt a 14,3 4 bas) ES ba, cole tut ea edt tcl@s)= §4s, teh eeldtude $4} e¢ (4¢)= $4.3 {uy Laat 14,45 ing FF At taayy fas 4+ + + $4s,4.3 t%,%d | + + $4,5%,43 £%,%uS * 44,45 | 4 + + £45,463 *it4,%) + 4 + 49,45} OY LZ. oS oy" stort > Grd) GP it,ah)° Grs.4s, 13) NL! On Dey Teng (dead steotes and all transition to the dead state i$ not shovon) Enaveple ( & NPA 4 NEA conversion’) e-nen (8, Zu tes, & de, FD aw @Oe@o® G G&G & > Vo {to} + + its 4, t+ ith ¢ tt} * 4, + + ts ¢ Equivalent NEA (B, 2,8, I, F’) & © ' 2 I. 14, %, 4) iust} t4%} 4, + tan} $4} ca + + int FS oO Claim J: Lum) = LL’) where Mie €- NPR MEUBREDIE, &. 4s, 6) ond M is wea (8, £,8', 4%, €) where, — §'(aa)- 8 (4,0) ond of’, FU, if €-closure (te) AF 4% F otherwise + accepts a stving w iff Blawgs -m! acepts a string vo if 8 (tw) Aktst = cle): elm’) if? 8 law) 8) lewd Claim 1 holds if Claim tolds lai ts eu lau) e 8 (4,0) jora string ata Pees U—() We prove his by induction on |awl fase: [wl+)2 te. we ae FE 8’ (4,0)+ 8 ltera) > 6'lwade 84,4) ; a by our construction > 6 (4,w) Induction: lwlyt , awe me, nE5", oth 5! lune Blan a) Now, LHS of 1: i $ (4, w) = Bl, ma)z 8 (8’ (4%), a) '8 (8 (a.m). a) by 12 me. Bltwad| 28 (Pade U8 lr) (2) by induction hypothesis + UV. Slane) rer by construction Rows. of 1 B law)» 8 lt xa) + &-clsure f pl pe 5 (ma) jor some re $4.) U €-closure (Pp) be BLE (ta) > LU € closure (p) pesblpa) U & closure Lp) pe Slr) jor some rep © Cones - SS c Equivalence of s-NFr's and DEAS Theorem: A \emauage L iff Lis accepted by some DEA. is acceptable by some €-NFA Proofs Gwen a dDPA ds (B, 2,8) 40, £) such thet 1+ LUD) an construct & NFA E+ (B, 20 b> 8s Ie f) we cf where § id defined by 8 (4,2) eae ee “2 + Poe €, OE x Anak there ove kransitions out of any € emplicitly states 4 Le LtDe Lle)- skate on & x £-NPA G= (Be, 2018 8e,%, Fe) pea de (Bs Z> Spite Fe) Now, qves we can construct as gpllowss: 1 Bp? J 520 | 52 E-elosure [s)} + Er closed sulesel= of a 2. 4p + E-closuse & qo): tle differs jrom subset construction 3. f+ {seds| soe ted 4 bp (s.0), SEO, 2€2, defined by: W lek Se Dee pr}, note thot $+ £-closure(s) compute U d¢ (Piva) » let thie set be Late td o ¢-closure (15) o Wo 6 [s,@) = s,(sa)e U. be Ls 4) sed » UU. tectomte ( 56 (Be (48.29) ses a ¢- closuse (5, (-closure ),0)) K UL erclosure ( S¢ (é- closure | pet) 2) ter K U_ &- closure (se Cpe, a)) te eS and S*E closure os Pi g-closure Lpi) & $ “ é- cl . ercle Hl sure ( ¥ Se re) = €- closure (x, neon Ue) m : i €- closure [ %; )

You might also like