0% found this document useful (0 votes)
22 views13 pages

Flat. Assignment Answer

Uploaded by

fortune gamer
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)
22 views13 pages

Flat. Assignment Answer

Uploaded by

fortune gamer
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
You are on page 1/ 13
q signereal a Design a PDA fy Cem bYfnaeod : the following language lie Le Plat in (atby¥} “Tay aati Carer fnr-o§ le fab, cabb, aaabbls 3 Steps oy incling pons Sk . i is Teibatly Push all als into the stack Siete topes sua gea mtn change the skack 4 Pop ‘a’ Step 3 = : ° ; fron one shack oleae eee eames (ener ge ernphy . | let the | Input sting = aaaklls | ‘The Mapping function fs = fig Yi pushal Pou | (%,a, Zo) = (4,, 020) al a a 8 (aya, “@) = (o. aaze) | a a Zo 2 Bee oi Cr ©) ba | Pers h,,%D= (y € KS i P| : (ae) . Fa] "2? EL eee | (a, Em). (4, e) Zo [ae] Pushelown stete 2 | Prutomata xclicgrane - vy PoP | a, 2olaz. zo bale tole Ye Hy @ el 1 2ole a ing 7 a, alaaze Te accept the skring * | eaches the Gnal stake M=(f4a0,9, 424 fa,b4, 20,93, 3 4, Zo, fa2h) @ scanned with OKEN Scanner Mapping function 8 (Ae, abacka, z) 84, baaka ae) 84%, aba, Both Jopue Symbol So ik hove 2 cases = case 428 (aq, 8 Ge, ® (46, € Cnet Vetta) So ik accepk Lhe 3 (4, aaba \baa2e)) abaze) ba, aabaze) 9, ‘waaba2e) , albaabaze) xing « 3 , albagha, - - y Lee MS hake input Sting = abahba State Faqrarn . neh A push 2, 2s laze b, ble 5, Zo |b25 Qanle i - £, 26 al Ta] & easel cose ci) 3, labs pas alba DN Ss, alaa & blob op % aa ore Case tii) The Ist and top of the stack 1s, Semel oseae sy 4 ba, baz) Gy a, ado) 84, €, 2) & CAs, 20) it reaches the final @ scanned with OKEN Scanner 2/ a 7 “xplamn dhe followta 45 squage of tune: Pr J OS bLangquag 4 Mrehnn e cRy ‘ypes ob tude veaehing al ay Language of Keeney Machine ~ 7 [The boing machine can be rredetled With the help | of follosing vepresentation Ip model having infinite rook cells , eocheell “MY one Tip Syrbel and -thus the Tip Strag fan be placed ona tape “The empty tape 7S) Lead by Nblank chrcnacters 2, The finite cont! and the bape head wohich fe Yesponsible cuneot ip Sypnco! Wape head can move From left to migy ht fox xeacting -the % Finite Set Ob Symbols Thibally the tape of M contains ota followed by an Tafiniky Ob blanks aaa Repeateelly,™ veplaces the leftmost oby oy eves sight to -the leflmost 4, Feplacing TE byw M™Meves left by ind -khe wright most x, the moves erecell Might Lo the lettres 6 and Sepanate th syle 7 oO ft 4k | to) | Oy, | | n eacceees et | a aS od ot ner | The fumekion “£ i~ | Toke | = a Byrteot_ x _ Symbol y| _® - Gre) : Gay.ed} - | al . | os | Cee Goel | ics 0,2) - | % ia Gaye] - : = (49x,e) > 4 . Casye} 2 Cau,8 |e iS a | ) Semputalion Oe Oo A Ass A Anitially tb xeads 9 (tt moked aq @ scanned with OKEN Scanner @ x eo 4a2aa Be veads 4. Tt wavted acy ail » shiftto left - 2 Y 4A Fe veads o ik tememns as i fs Shift left. SS iy aia Tk veads x. Tk wemairs as tk is a ead shift right - OEY aA Te veads 6 and wasks as it is Shift right *xY 4a Fe eset eee lat acid ee ond shift wight - STS AH ae veads 4 works iLas y and is Shift le eye Tt weads y. St vermaing as rk | n PRY WIA Te yeads x. gL yemaing asi re i xxY¥Yy A Pe reads y vernaing os ik te aN acd shift ght . ay rs Te reads A ond halls. Gi ag YPes of busing machine = i ad machine S fi al Tessin is called standard uy u bl — PRED EY Rho head Finite cont] There ove 2 Ly NF nachine PES Ob “Ting machine 2 infinike bape Reina, Machine > Tice - way infinite tape “Kering ™Mechine can be Simuleted by one-way infinite buxing ma chine. \. Too ~ way 1 @ scanned with OKEN Scanner Palabal eo bof =| 7 Tare Both sides ave enclosed conto usith blank Spaces 2, Muli tape busing Machine — Tk can be contolled by a Single head. > Tr can be Simnut By Single turing mechine. [alae Te i ulol--- Get Tt tarp Pelbeba eke E eke : ed Tapes TTape 2 ice = ae DeterineGe a ine eee hoe Single, one-way Fofinite bape. 2 Tt is equivalent to clekerministfa Turing machine 2786) a SPE. 4, Male — climensional oe Machine ~ ™ Te has Multi. dimensional where the head ¢ 7 rat move % ony direction that is deus. left, wight, up or finite ont) @ scanned with OKEN Scanner Mulkihead chusing Machin. +5, | * ipl [Pore Mullitape busing Machine has Mulkiple | tapes and Mulkiple Yreads . [ele fe ffe]a- - an Med | Finite contol} Gea, bj)» (4,, aye, LR) © offline THe ae —Finike contol A Mautkiback Tertng Machine [ou afafefo... | ju jalefafa-- | | ulelalefu. | jolalatau- - i ing (46, aaba)—> (4, rexyx, LU) | : &, Universal Texing Machin + A universal Texing Machine a ckwing Machine ORD 29 opprepvake clesevipli —™M and an inpuk Sbing uw, | compukakion of vo. Lohich Cohen supplied po ob a Turing machine ND Simulate the Fate ad | | t “Teper Cilp> Tape = pe 4s (1m) P P oo. @ scanned with OKEN Scanner fe ; ne the Language 3) Design the buing Machine to recognize She | Par ars. ay | Le pars, 223% Wteeraaa,. 94 ula fafa 2]2 [o[sf Elula y 28 2 28h AN bis We ore mmoalidy aU Peer et ealetch os pe Yand gas 2 Akaceepts the Tawa Mochine . | com pukakion Geo Vig are 333uu Thttally bk yeade 4 » 7 Fe aE monked as x and move | UU it te2r22as3u0u Te vead. Te . = AAS 4 dt veman a Sik is shift wight. UG_ivir22 333 uy TE veads a TE masked 4 SS Y and shift bo wight BU li 22233, uu Tt xeads 9 falemell et as ikis SHITE wight Uwiir222 33a oy ™ Tt veads a. ay Mook, | 2 OS 2 amd sneer ty Bef @ scanned with OKEN Scanner @N r ae o,| Sux, Y22x*aax teads 4d and mask - ” as x. and Temaing os ik | SG y *S Crnove left) URxu Yr22asz yy Tk reads qy and 5 and marled ag ¥y nd semeding as ik berdue WE Ger eas yo aed n Tk vweads g and 2 moorked as 2 and vYemeans as Tk falas aca atta Gas and move lett n Te veads 4: and mw morked a BU xx, YY222au . al ea =a as ik Fs Sy oy See TE veads 2 ood e a mowrked ag y TEMAS as ik Te UUxarax yy yaoe Hcy Th ends a ond wwonkted as 2 ond Yemoing as ik is | Ww **xVYYYV222 UU a St xeads Land halts , | a Fee Sear asbs|bSasle te ambiguous solt- S— sas bs| bs asle et en \efk rg rrosk (3) (s) © j i @ scanned with OKEN Scanner BI) OD Write in cletalg —the chomsky Tevarchy for | fommal languages. |Sote defined aS chem sky's Nlomal form can be Non=-Lewninal —, nlorterninal- Nentemioal | Mon teersingl = doinal | | 2 The given crq should be © Seve Fonnat then we can Say Jrammer tg in cNE tn the verted | Atthat the | (> Before converting “the qramrnar into CNF yt Should be in veduced fom | Tak means wemee all the useless Symbols | | & productlon and unit production Form te (7? Thus, this reduced gremmer can be thes [eee oo | Conversion | ~? Ediminake stast Symbol -forn the Rits. DP the | Steak Symtbel T fs ot saght handside off ony production create mews production ag ss Creve shook Supe! > | —F Bn the gqrammnss remove the null and unt produckions and useless Symbols. | > Etietnoke terminals fom the RS ok the productions . TF there exisks Uattly cthey wm Letina oF herninal @ scanned with OKEN Scanner 5 | Sy ~ G) Simplify the ony. oO >< linale Br RWS Uwilh MOVE aR bu HOM be mninals. Conshuck ene for Abe Lott marne eyeerrnwerare + s | > ABE &—~ ee Base SF edly C4 Bcp oe (Te te Satisfy the chemstay Nowra Step as Fow)) S— abe Fake AB = y S— > xe (Tt Salisty cone’) Stepa y A> 0B Tt Aoesngit Saakisty CNE bake o-y =F A> ve Gee satisfy cn) step 3+ Bo y CNot Sekisty ene) bake yreM Bem (Cae Satisfy cur) Mpa A vp Sulbslitute y=2ny 68> 2uRp Lake ZMen A 2 NB Sa xc A> NR @ scanned with OKEN Scanner 6) How bo Steplify Abe CFG 2 plate 9 Th CFé1, Sometimes cull -the producbon anes ane ; ravekion of Symbols ome nol neecdecl forthe cleavekion of algo We Ome Shings Gesicler “Abie, Unene reeuy 7 © uw OS, PUL prpeluctions and ONT producki EGenineken dk -these Preluckions cunel Steopli freabion a Simplification Symlools, “called CP FG) lone tn 2 5 i \, Reduce ob CFG, 2 Removal Ob unit Predictor 3, Removal oF wuyl Procluckon Reduce 4h. CPot: poceching ie S664 Derivation ob an eaivaleal Joma Gy Form Ane SFA. Gl Such thet each Voriale Aenied Some temeinal Sting , Case ay toi i Dexivakion ob an eq Volen Temmear G+ . from lhe CPA, Gi Suck that each Syrnbo| appeans dau SenlerWial orn, Remove| OF unit Production = Poy Production Quy the -forrmn ORB Usheve a le of BE USE procluction . Mon Lerninals, is called} Prececlure » ¥ TO vemeve A= celel Precluctton A-® bo th, Frammay aule WohEMe vey By ce Syromennny - in Ashe 2, Delete AB —frero the Geearannay , -\ @ scanned with OKEN Scanner on f 3— Repeat the stepa until the Unt production axe vemovedt 3 Removal | | | | | Ok Mull production > Tn a CFG, a non | cterrinal Symbol A 17s a nullede Vorioble Tf there ation that is a preducho ASE ct Ahere is a deay | ats at Wand leds > & Proceckue —_ a. S vemove AE took Re call productions cohose wight Side containg A- jQ- Replace each occurences ok ‘A’ In each ok these Preductions with - B Add the ~ccultantk productions ke the qracomay. @ scanned with OKEN Scanner

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy