0% found this document useful (0 votes)
103 views40 pages

Unit 2 Notes

The document discusses regular expressions and their representations in formal language theory, highlighting operations such as union, concatenation, and complement. It provides examples of constructing regular expressions for specific languages and outlines the process of finite automata elimination. Additionally, it covers the rules and properties of regular expressions, including how to manipulate and derive new expressions from existing ones.

Uploaded by

sahilak73984
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
103 views40 pages

Unit 2 Notes

The document discusses regular expressions and their representations in formal language theory, highlighting operations such as union, concatenation, and complement. It provides examples of constructing regular expressions for specific languages and outlines the process of finite automata elimination. Additionally, it covers the rules and properties of regular expressions, including how to manipulate and derive new expressions from existing ones.

Uploaded by

sahilak73984
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
Aribaa duce to Requbler © ALSTON an th motkematiced * Regular Enrparssions which one ‘sentation of a donguage acceplid by Finck ‘odocdte! + Guowcion EBT Peeps bigut Bete aig IE, iti eereens (Gremmes oe of ener Mae mil Aeepl => Some mallandtivel ap fo shiek (f we gin a Shing if exll Se the Flu| the Shin a (Patzenl on th, beng or nol: —_ Pecepbas err FA; | Gemma op Cann = Tonpeoge., ab vat) gui s is ccna ia “To Centactor, arr Grorornas 2) Rigmler xprasiion = RL com be mailemeh' cal; | ep rsioled ay Ra epa? Reg alles Enparssion ‘ They owe ths Leprrsentetions of the iy" bohkickl au ctiinlly accepted by frnik. aulemete , OR If any Yang. can be aceepled by FA, whicl. can if esplisnd *y RE. v RE tactacas B_opercliony +. 1) Unin (+) 2) Concelination (+) DUnin (+, v) Dtoncotinetio: (+) : < Me Jo, on} Lye qe, ory hive fer er} Lye fe, eh Lily « {0,01 000) ny A LU Le t ob, ol €, woh : S) kirine clos (x) ¥ Ong ... a = 1% A ey Oe 5 +o. vee a 14 aa, a2, 3 ee f9 | RuLEs “OF REGULAR EXPRESSIONS - of d,6€ aed ae wlan Enpression thin. He language Fethnaonte te WD supasentahcn H é ond nm ED Gre 4 > emply sat ie it > onlay my null sions. deh v a) aed ~— ta} Ge, ond oee ass _purivifve sugelor enpveriic ) @ J we Tak oppuntin segeohe nanan saya" ond ta, Te: i a Regula Spe. Gai ae RE Gps re @) If we oe se bol aul (mul &) end C2. beg nos of tienes!) Thun iso will get a argodon CHD a Ree = at(dat)* ~ *faee)* 2 Examples of Requlos Enpasssiont Be Regeln Enprtrssion OV Te fa, ay whew “Ih, Saf of all ihoge whose. bogie is enaclly 2. . faa ab, ba, bb} Hea The yt ty qinile, Dhuneva The lang: “ile These exist a paile aulsmale of pic ts obo possible . jak the Res Srmpply ‘a (ie at. ‘ OF dicey in The ee =) ah+ ob + ba + bb 2) a(a+s) + b(a+s ) : (Cate) (ath) Einf RE ovr Se fagy Oh te st of vy fen 2 3.4, all Sliema who or fength is | Be Re, iy by \Oce& | b+ faa, a4, ba, bb, 244... 5 pai A ae sulssert ) | v Or mo ® Find RE who leva is enaclly 3 >{ @x) (ath) (a+b) @) Find RE om Z- fash hun th sel of all Slings lose leqgth ts abot 2. + dino, 2 | | Le feas, an ab, ba £e 4 = File Language. { | > etarhbs ant abt bat $b a sae pat of Set th + a thre ova E+ fash wha th st f al sions OL of fete ape deno, 2,4 6 Bos 2x8 an 2x ax a als a nz0 L-7e, aa ob, ba bb, Bae, sal 3 7 C ((c +b) (a+ wy : | fang Find RE oven = + fabh whee th seb 4 all slide of Agile odd. vy he fa bana, ony hin 1, 3,8,- [ (a+) (#4) (orb) ) com lf x ts 0 > lend cceepl: + o 4 > Gtp)(a1n Cath) 2 Las Hi ee 7 (a4a}(a%))*Ca) ay bea, angi. of Sng divisible by 8, fas} Le 1% aaa aah abe... aaaaaa..- }- PT gat ( (emery) ) Set of ob] Stures coher tk AB A rosd 3 ( = 2med 3) “ Seppuent i J Ms Te) med 3 2 2. 255 by ar a “Tov * é. (a b) (a+ ) (cows) Cas) (ate) : te a ee = | (Eis ty te fovmet GAB) mzo vu @. STR by (Cassy CastCats))” Comet) ~6 — oe ©) @) Exadll, too a's on F fas} ( : Brab'as’ J bles 2 al Cora bia (aru) Atmest 24s (oals 4 a, 2a's ) Ce (lee ED Thu tan be on lal ox no la * va ty pe. . Nef Aso J Le fe, aa bea. - ule RE fox eeallly allay. bbb Was apes al / X30 € < Bs C ( bade Bestest)" ) vot) data. = Xe2, tas ¥23 Bab © Buk The “Te abe Re rel genes by, Baby ves » Se add b* abo abn wilh tk chee Re. 1 (Ba ey eR) OR xf (Globes!) as) 0 i) [a doera'l- masa flat 4 in Mey oa Abe ou zal (3. Sit of alt shings that slat will ta! } | f al{ats)* ) ; * Goo > tring with eraey sity wdk ba) “a 4 Clos)’ (B) | Corboms bal ® Shining cof coding with duff. syenbe Colaye + bl Sliikig & fading with Same Syrobd rhefeajboa 3 t Slialing toting with a a fatty « | % > beg (at5)* & Pleo Thar will be €, 4 and &- + 6 RE «5s of “bE ate st a (aaa + b(any " | sol ET two 4's Should. | Come tegehrey . bbb... a, ab aba abab, aboba, ba, hf Le é, bab, baba, baba... Y k Use com use b) oo deste bhele beog it oh Pasduee: ; b, bb, bbb, --. Chun ne 2s together) since at k we con! make ‘aw buitd-9 block Pasducer + a O04 aaq... 2 2 Hers aq aaq aaaq... ay not ir cthy le Se ik is tol “pessibl ts we b “al a» 0 build g blo cle. bie con un ‘ab’ a hts block be ab, aba abob yon These ions Delonas do ou “ay Pls we cers es se! a Te bidding bleh. Boos ba baba yn lk iw the lage # We cont tose ab! ene! 'bd am togellen budletcsg block - 0 ~ te @b+ba)* Thre is a hente te Come ( togeten | Rash Come tule can We band ‘ab’ thaetlen og buifling block : ~ ays V ce dalle fe (4 tab)” : “on my thes No too als Come toge lla + = O,4,a-- feb bb bbb... ab, abab,... } (b+ ab)* Y = wt of all Sling slaalng Sel of all nth Yat and bnds silt sl: leak Me Jit ‘ht We con alse Ramey iene whicl ends asa, (tai: (b+ 4)" + (bres) a y WV Lnels wilh a Staabing wil Ly end a itt ta! 3 leatiag waite ‘at erdc i . 1 hth. ") blotting wilh be’ ard| endenc, wih ‘a! Ub ‘Bin b]a 7 Ihens DA | CEE (| Ne 2s and ne 28s tome tagether : Lefea, b, ab ba aba bab, 3 eT tae aba aba (aby. “allay” fab, abab, ababeh-} a {be babs bababs ...} 6} (ba) Yenye — {bY bab bebeb 3] b (aytb op Hasy* (b)* on a(55)"6 p |o |p oo | } uae edthiy ore Re | Cdentl: taker bolt.) Kloss: Hales era drow del ond ¢! a fs ony } cane tn4 j C(asy'a> oa ol ba)" ox a(be)* b Cyt om (ba)* b on CBlab)¥> Here [am taleng (@b) ton - > (bla FC)" + Mabe + Met? ~ (aby (ate) + ban)" (at e) > (ore), (omr + aay" = (ax*) (a (e *b))) 2 (e+6) (ab)* (eta) of J am a (ba) Teds then 2 A(bay + a( bay b + (be)* + (ba) 2 a(ba)" +(ba)¥ + alba)” b+ Cha” S | 2 (ba )(ate) + (be8)" b (ate) =) (c+) (bsy'( erb) So th answus an er: De Et) (0b) (e 7) 02 ce Ere (bey Cem _/ Closuar parpeatis of Pigular Languages . sep gs + 4st 8 eifesguial prspeatlia au - 1) Union (Vd 2) Inhasecho~ (0) 3) Complement x} Leb Ond M au th 2 own F- I Vina csvilduns There _ ts othe dont . Hen oy beth all thot ax & and ot, Lum = px: axel a fame] naa The 4 2 Of Lng M arm Atgular Lavgueres (Unie ) 1 the LUM és “Te a ug ae a Lis 4@ ag wa 4 mage, | a te mal} Le eee of a tags nett Pike nF Yk and M Ou eee deg eeage tes, Clotersidlion ) Lam is aby. a 7 ites wg ynege. e yl | JY Theo 5 b 4 amg Se ie ~ Reversal) “9 y Thin 4s Gy toy eh Bil 3 J-H th aby 4 Dra fh RE (Finite AUTOMATA to R: E) ies sale eliminctinn ret hecl s- » Initia) slak shouldnet have aay EOS edgu- x have edge , carali med wietial clal AO - ay edge te A- Coral new stealing sti 2) Coming te Jeral slik, thear cshoufdot have ‘© ig "4 edges Bad then ahsetd Be one pra alah « OO) enish such eae cuak neo sak oy frol slak om €-mor. Of thes eutsb moss than one jfirraf alls combiner those jiwaf slalis ond make «< neo pnw Stak om E-moet- O2-G@++] ~~ nag y of 3 — eq mad "as pelisae @ Gees €- mee 3) ‘one than inihel slak | stealing sla ond | Finof slate | elimsinale The Atmaining stale | One by om in dade . J | Tks is lak elinenation matted _- ; * Eno mples fe Q. Eid Asa e enppansasion ant the Brians” DEA. ar => No tate min + Ne Delis edge jen final slak 4, > nist moa then one ino} stale- 1 _ trswards willed) «RE 92 => Nb iohamediah Glaky te elimincte - 5 fe Fo te. af will accel ethno of 4. © So the nesses Ang wlan Se pnetbas is? - ie ——— ids oP the following FA. Fad RE a 4 4 QED “ = er Atle ay ne onlin oO abe @® pot (atbee) SSF Q? Fd Re- i. . 7 Here nei ! fen tion Elminale B- slaatiag of > onlgetn ed a {res 6 pref stale able . QAO Fag ae 7 Hoon eed Ai 2 wobel stab A @ é OA) 3 act wi DARE POA PO sexratig es ft Sabo. Eliminale Elisinnele & af el ® ole) » of the Polling FA. 5-© 12 @) A : ts eet stele 4 7 fleas ne ee eae 4 5 letes:, No oe “i ja } nol . Fin RE De mother Ont qi see “7 stetu teaseg’ qhiag Cvisl ak ge uel oe peer “4 pe ‘or E- msvt - Now eliminak each slate mm befceen wtb a ane alsieat} Stal one *Y ome in “af prdey . b . * a ‘ *® O=- By bed, 5 O40 Elminal B- Ose" © aCb+ c+ 4) ———_—— Hex incormhg eddge bias slaaleg shale 9. wo cavali Piast? lial sll onl E-mave, O° ALIS +O No culgeing eelge from trop sali te! en ” not a ve Slete 1 = > Now peafearn iptiamedials. slilelinsmaly ? lininale A Pfla sroaalaa sla A, ik shorlda't affect th pall . . be ye dom: Ses The ‘Teonelien Gai end 4 po at 2B. Q e i} 4-6 Spfli. ehini naling A, Tear 3 a tron sition ona’ Jollesed by b' ho olele B- 3 v “? * Bewab *- On slak B, fhe is 2 self fowpo (en ‘el ang tat! So (ctab)* 5 th we een [terse | Q , Qe @ Hear. Thean ensl one ei a the Slatin shle A. Go carat new 37 . slat Qe 7 Cua * Ou L pbe ale cage ial soa skli - & cacafi new firaf stele: + Now eliminele ipitemuicien alepe- Eliniinale 8 fis) é Bow é€ Elinsinat A OLS Qi Find Re, 1 qe «lm conmn ealge toward, 4, & Canale new stiating stat - 4a 4;) _* 2. QO be Dale or eaipe fron final stots 4a 4 Se ate mus fioal stelir oo L Now élaal Alinmiineling intuyudeali stala~ / elimina $4 9-4 Va. * Betis edtetlp Elininele 4 ¥ G3) 4 +0 (00) 4 “6 O(ov)¥ L on)” + 0(00) 4 Corny essed eb tom Gy -: RED ¥ 1+ ofc)” + (sr) 4 (04 +84) N To FINITE NvTOMA TE > ” REGULOR ExpRESIID >| Basis: a) Construchon of FA fox RE H-O@ « 6 ~O ) om RE 7@) 2 Conslinchon of RED fon REG > Induction. case ty RTS, Cese2 - RS a POF 1O= crse 3. Re e ® Examp bu : 0 fal Fo fa te Re om } & é OSHS P+@ ot € (or!) o4. — 4) Cot)” (oot!) VW Con emve- s)} to + (or) o'4 RE te (PA; Bera Vite verse - 2] Con" (po-1).(ot!)” l- Se bok [ot equal power. | ey Pumpin LEMMA por ReGuipr Lon aueber “Pammpin domme, ts a evap < test to check vohull o fan Is segues on rok - yl al L is an inpinite ae ©, then theae exish nn C pumps Length) such Thal tony lini “we h thay lhepth Oa de, olan, thin 10! can be divieled. Sof 3 pol satisfies the fpllewim Some tve TED: 5 condi lens 1) for each ize, xg Bde 2» lyl 70 and 2 Jayl pusping past d d ye Leorys--- Crema » C J Oro checle, tok tr te on HO (a) lyre a i. fd shld be > e] @ lay agen Wlze ~ Yr lay| en z heb n= } | vt “ on. aig tea 2 aackeb lt Ye caababbb ¢ Ly Test foil, . Se L is nol Argebar. —— { | | i es MPING LemMmrA - STEPS I | grpsiiaanas fan. e Lis ag pte 2. Ie hag te have Pumpin thy” 3: All sluings ia than n Can he pumped : | [wl en 4. New tn a “lesa lol ie bo Such that Jal] 2 n. Divide ‘a! wnt ‘3 pools wa 3- Sheers thal 3 L fox Some 170,12%,--- ‘| Then Consider all it thal ‘we! can he cliviclad | tnte mya a Daeg el J TO, 12. ED) lyl>o 3) laa in ok the Same lenguece L, q Vale compel? be Purpec| — contradiction: | lnhig om Seve i mugen bs mad ~ | x} If a lao qin, ab will A W nibindy eg ab. | Loe can daa Regulon exparision ond Vice VOASE + imile Language Is Arguber Se *\3 an infimli lage age, Then There Should Venist a ale atl. So that the i we 2. « chould hae a cataton patlin ( ep) 50 that there exist a pate cute mata. fips ke a abet, cbebel, .-. } | | ()—7® yf} (©) iis Angeles. don't a buch co palin thin Were rs nn we i ne possibitilg om ony a FA. | al- ts TS po famma a x | pi Lerorms Says that sb Serre 96 Sie alte fy Fa then There shoul os insicle if FA, whil) wean Aasidloue ole a lesp + we put a pall voluzh we Should aapeal,, wat gil” lh wate in the a ay den is ne duck Pallian, the we coll serene le new FA = “Yd inpiailes oe ae Pumping lenme is a Negativ tye. x ¥ & X Patt 20S, Pumping Liroma Says if the Language is_nal daguden Vy we cant! fine] such 6 Upattn ‘ Bul Pumpra derma doesn't sa poh Then te | Lan poe is tau oa Net ye soe fend ouek | Potten: fe, WY we com find @ paltan , then welt able do ginwale many of the ste in Ube onguege « But iP oii) doesnit Guaredtus Thee 4d | Li tle ads Lor - a nl. we he Sore othr ste > te , duck 4 way thal We Cen! cs do. in pot any Upallian m « FA- Tat, tet, atetat, lV fat[p u pom} SS . acprotert at pellicn - Pe lien I cctlinn es E i OP oe . pre mey nel ‘bo if a cone. hat ular, we tows a ausstatl Fe and RC. } | \ | ly Check the ell owing tongues au eeoale, oF mal d [e-forf ney | We con carat FA O10) So ib is Atqular » Le | arb” | ng cc 4 7 2 Swa nis bounded So tb ts rk Aan mage Pad weg Jinik i, bin aL is i, ular. 0 > Can tal: FA - on 84o S Lis Asgullas Dycteora” [20 j nN is unbo weal Hun ne-ef a's clepends oth me. of ab. re vnpinel Cuchag Sine FA ls tea _ fink memory , af cant pufoam - bk is mek Beata 6) [ Le Foct | | talim, Be ess} | nile en ee inf saan LO? aa wR » aA ab ba $e aé bh b4 he ; ° aide qeab 2 fine bS55 _ Sine oy pore vie tons is seater: - eT if wis 4 re (inpioil agit) Stas thin FA do Paes The capacity fee oy gt d)xen 2 Lots vol wlan’ 7 | [efor / weiss J | Uf ud is bspenile length , fs nok prssbl for $0 - L iy: nef TY Leg = | "ene J nmr res | | J Dny nevf o followed & nog b V ity i La 7 te (qrowstig 4 nd c indupend enlty | ‘ | Her ne esate, Joeman = So A: tan Ae sie di pal Ree ladeee | Sok ods ear. Re» aor bb( 4b)” inee RE Ws thu, al is uber - Also we Con guoaete FA @* & tase) - - ——_$___ yy Beis a + fan] nis wen} | he fo, a atid | (Aen 8, 24,2 | Lis inftarle Language ond lhe dhting lng liz | ub Path Hogg 1a | at ot at... poy. a tommen oli ffaune (ii 2, Mae) tm So I palate be bh goles — and {he far | mis odd} "da oF afin G —+ A-p- pre Siner parime ney oat nok ts PP, Cet nok Lis nol sigeten a) A) L- far [rey Le fa ah, a ale, at — nel in ap- L is net aye bit po) \ . 4 48 .. [es wp Lefaat, a, % |- J ek | | | L ts (wel Rien | SS ‘y [L- fae” | ty Jan —no paflin = BS He apaupme., jy [i 8 [oa03 | al Le > Ne pater a Lis moh sep. %) Le{ata? )P "5 prdee teh ] Ree obh tb se 4 pallin lew PS ~ L ts nok Saget Ma Co) + nto f ) wefaby” m) 2 {2} OIN | Aloef a and a equef. Comating Ts Aone. hot unbounded courtin Se 7 here became & werd con be of dong tv. t | So ils not posrbh to sane neg 2 and & | and Compare Lois mb sag wba: ny (2) moda } | Is) Lefel/ ng le) med 3 = Mo dlabar Courting i osacble in Ea. | So L is war. pHa y Clings of Lngih. oblate 40, So can gensale Fo. aL Is Aageber- | | » Ss if iy) Es ows af | wetas)” { ( + Can be nag ht a . res she “sy Y — oe iu OT ka. coda tot > Pil cox ee > Conol be dow y Fr. Le {arene nz ‘} Wile comnst sku a? and 5” Becoun Au tounting i then. If comact be dene ty FA. Le i ope | mm nat Need te slr. aly. Then Compare nev of aly wilh Revd by. Sane eb A not possibu ‘ 2 & his nel Aslan * Lis nol Aga ston. % Usin umPing Lemma pA ales Caravce. L. {aren n20 is not Aeguba. 7 Solidi uw I) Pyssume Lis a Re ea bar lamer 2. Thin thes east oY pasos fa Ui hee», Pumping og beagih, Such Thal nd ahi Wink Uh length 2 » iy 7 te ) les! Zn = Lis bh, we _aaawe DoE ful. 1 Let n=: 3 » lolz». . So divide w wh 3 paub > m4 Cased: —> Parspina logit. wW> aAaaaabb bb la[-2 = y S l¥l: 3 km Y 3 lele se 1 lag] = Sen x43 > aa aac bbbbh kisses aps => 4A Bacaaa bbbhh ( lal-8 ! [bles ( 4 lal atu . aa ee (ee Iyle2 and lag <>) sik mp fb, Lm np case 2 Cpa ER ne Wa aime klbb ples ee ao i °c J 8 lz]-3 ; lay[=7 sn aya nace. Bb bbb 7 mf > aeaaa bbbb bbb lal-5 sean te beth ‘a! aod 'b' pat-)- We ageaabhbsh le oie ee esas a 2 Iyls ye po a true: \ lzl- 3 - a3 = aaaaabbhbsh 7 Ingle on “3 > 444 gabhaabh bbs FE> Tue ‘e Shoal felled 'b’ Lupe gh > Linde Dry. we = n bide aca tis nol Aegeban. Ww (\ssume i ee hel pomp m4 1, Fis ot Lb we dacaacae a i fof zz x a EK Se divide ne peal - wD > B66 4eacdsy tafieae 2 gf #2 Jyle3 Igl= 3 i | 20 —s Tank Pl in= > Teor. ma = GOR A442 44 - | 2 le aup = Ge aasase 22 - EL fal: ! q? : . te Le fa wt ae: i a4 Hye ma

You might also like