Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
13 views25 pages

TAFL Unit 1 Part 3

The document discusses the construction and analysis of Non-deterministic Finite Automata (NFA) and Non-deterministic Finite Automata with epsilon transitions (NEA). It includes the creation of transition diagrams, transition tables, and the concept of epsilon closure for various states. Additionally, it covers the conversion of NFAs to NEAs and the properties of the languages they accept.

Uploaded by

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

TAFL Unit 1 Part 3

The document discusses the construction and analysis of Non-deterministic Finite Automata (NFA) and Non-deterministic Finite Automata with epsilon transitions (NEA). It includes the creation of transition diagrams, transition tables, and the concept of epsilon closure for various states. Additionally, it covers the conversion of NFAs to NEAs and the properties of the languages they accept.

Uploaded by

rehmanhggf9532
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

a.

classMAte
Date
Page

Pha) a NFA fo all posible tints stet and end


Ath ame Jettei dafined ove, albhabet =fa,b.
For

Conistuct NEA tRataceht setof all sting oYer<efo,1E


sle Constuta danguae
Sae lergdR-19/=2
E=1o, lo0, lol, foll--
=2+=3
D,1

G Constct a NÉA Rat acteht et of all rings Rat

of tates mtl=i+1= &states


Noc NPA '
Dote
Page 3

C3: Desn. the NEA tnasibbn dag'am fo 6.


thanaton table as gien below
tates Lnbut
1
%,42|{6V

The MEA

Now

8(%, o) = 1%,

Now,
NEA thansitor diagtae.
Qt
clasSMAte
Date
Page

nbtuct a tramion diagham for the NDFA

(5,o)
a Naw he NDEA tranaitiÝn table' s girenas
&tates Inbut
1

Nocs te dansiton dagnsn giken

0,
00(%,11 1loo) 8%,
1l00 sting Considena Nol),
NEA
Inbut States
asien üstable
Not
(o+
í-{0,
}. oYe double
0' by
adouble
1 Which in NEAContucta e
classmate
Date

oge 33

Nole 1loo

. 11oo) =S( l1o0)


8V, lo0)

J(V3, o)

hcamed and reachig to -Linal stata


Dexgn NFA acehting all tinjs nding wdk o
S- (o+)o|
A S=fol, go,!|o, 000lol, ololol, ----
Nolg te NEA tramsihon dagsam cis gizen

Consider a string
Now.
J(Vo, o0olor) =d%, 00|o|)
S(o, olo)
Date

TRe e tnamitiot in NEA ane


gözon. uithe
state to amather
to move from one
faing amy Aybal orm unput st

The Jangut
by M (a, ,J o Can hes definid
Lt M=(Q.J o, E) be a NEA ait
a
nput set

Vo c a stat state
F_us ast of Pinal statebuck that
Fea

ebe
classmate

Page

Langafe Dde tomata

()

L<L(r)UL(ia)

L-34zeLn,
geL(a.)
L=}6,0 00 o00

L=000 oo0

Now,

OR

OR
Late

35

A NFA uwith e Wkich acekt a Sanguag.a.


sring f any number of a' albuitd
b'b Flouw.ad by any numben of
umber of b's

NEA wtk E Cam be doat) as


b

No
the tranitlon table
States

ha abc, aa bbcc, aaabbb Ccc


le Considen aa strig
&%, aabbcc) - J(%, abbcc)

-8 bbcc)
=8( bc
-{ec
l{,cc)
bQ
fotatb NoLo
bfor (% afote
t<a,b
beoll e-NEA
e
bbbb- bb
for Nolo
a (b e-NEA
fo Drawaa C
bewll e-NEA
aaa, a4, L=fe,
a,
an tor Noe
e-NEA
fo Dhawa Cd
NEA
Nolo
st9+B tates NEA No,
mim teta
mino. um
bbbba, bbba, bba, ba, =be
ba, ba, ba, te=ba,
Note
NEA
state o+1=1 nl= toNow,
tal
e|=0 denqtt h strngstat inimumof mo
o
n71)} ('a:Lo) U
l
puage. the fote tates br LRaeNFA nekn
classmate
Date
Page 37

e-coswe The E- closue (P) is a set of all


states whech ae aachable hon
state q Conresponding to mull tanibonle)
uincluding ydself.U
e-close (P) Pwhere PER nan% helf sttes
T there ezist E-clozure (P) = amd
3A,E) = than
e-closue (P) {V, {|

e-Closie(A)
&{%,)-4;
e-co&e(9%) - %,h, 92

e-closoulo)

d e- casue r the lloling NEA ath E


b
sal"e- closure (9%) = {
e-cesuse (%) =f,%}
e- closue (9a) = V2,,%

e-elosuret}=ftt
e-Closure()=2, 3, 4, 6, 9
e-Clsuse (3)=2,4 64

e-clos (5) -5.8, 2,4, 6, {

e-closuru() =fI,8,2, 4,6 9


E- ctos(8)=3, 34,6, 9
e-closua(9)-4
classMate
Date
Page
3?

Fhd E-cloaure f the folloaÝn? toanshion table


sttes

e-closr() =4,b
NEA uth
.CenVesCR f NEA wihe úntNNEA
fate
Jn this methody be toy to emoye all t.
taitions em gisen NEA.

state9hom R Thon t us caled a

(JTRanS'thamsiton Cam be cbtainsd.TR


tansitons meams Qm E- cloBuse on d
3) tef 2 raheated ten eack inbut yobal
Bn each state of gien NEA

Dact thanalt'
single inut symbal.

ndiuct banithon unchon is wsed to


classMate
Date

es If we Want to ruad the si? abba then


b
6
NoTÉ;
NOTE Th n case of DFA dand d aill g'ye tha ome
dand o may or may nat gire tha same gesult
the Case of NDEA atE moves
Vle fotConlencn

a(Y, e) =E- Cosune(8)


Censde a NDEALRe moYes MaE S,%sE), kle Can. Coneat
nto NDEALhote moles m(& 8Yo, F) as follocQs se
Lm calelate G-cloBure ()fotn eachsates lkfeset in the NDEA
Ate move

Sl,a=e-cosec (6L6lWs é),a)


Reþaat te () for eve t¡te f NDEA afE MoYes
Cohoefonng to every nht ynbal
V) An t e of mu be Consideud as inal state
Dote
Poge
e Conet the given NFA waith E to NEA Le

Sa" TRa NDEA with e moYe is

wnput sets

S(%, e) =
&(e)= 2
stot stata
Rinal tate. t
Nolo We nd e-clasue of ach state

Noto the NEA whotie tansition is

Calculated.as
classMAte
Date
Page

%,o) - é-cbsra(5(5two, ¬) ,o))


e-closwre(8( Vo,V,4)o)
FE-closiÛre (E(%, o)ud (Mi,o) us%,o))
=E-closreo)

S%,l) =E-clostoreS6(Ve ¬), ))

é-ctoBwrei

=6-cloBure(d(o, ,92?),2)
-e-closne (d(6,2) Ud(V,a)v(94,2))
= e-closue (o)

8lh)= ¬- clasure (S(5(W,¬),)

=e-Closre(9)

&(2)= ¬- closue( dlI(V,e, ))


=E-closwne/ (i2)Us(e

-G-clbswhe(Va)
classMate
Date
Page y5

-e-cdoua(aB, o)

=e- clobureldVe 1))

(a,2) =G-closore 38(Va,¬),a))

Noto Can deaw the thaniiton table as


We
tates Inþut

Hera yo and a us a fu'nalstot


because
¬-clasue(%) e-Closre (V)
e-closue(e) Contains Boinal state
Now

eConet the folowin! NEA sth e to NFA

Clol

inpat sets
clasSMate
Date
Pane 47

Ss dafined by -
S/Vo,a) = V
S{42,b)

fnalstte

e-closLore(%) = %
e-closue()-44? = '(e)
-(,e)
Noso tRe NDÈA wikot etamsftan ea

calculated as
(%,a) -e-cbsoz 8 5l36, ¬), a))

=E-Clobute(

o,b)
S'(V, a) =e-close(do(e), al

=e-Closusre(d,eBs b)
=¬-Closed(%,b) UJ(12, b)
e-chae(su)
=E-Clo une()

=e-Closietoat,a
=e-clositf S(2,a)
s(a, a) =
classMate
Date

Poge_ Lg

S42s b) = e-Clotura (8(62, e), b))


=¬-Clo3ure(o {Vatb)
=e-Closue( (a, bJ)

N4
No le Can diaw the transiion table ab
States Imbut

Hed a o a final state hecase


e-closure( ) ande-closere(a) contains final
state ae
Nod, the NDEA tRot e will e
ComVet the followng NDEA uthe o M
a,c

(4
b

E,C

M=(A, , J, o, F)

%, a)
So. b)
d(o,e)={,Va
S9h,¬)=
&(ka)

Alos, wle find e-clos1e of cack states

e-closore (Va) a r(4, 6)


clAsSMAte
Date
Page51

Mnle. the NDEA Wtfout e tan&it'on i


po'=(Ry , S', Vo, F)
s's dafinad
%,2) = e-closone (8('(o,¬),a))
=e-Closlre(o4,V2a)
=e-cdosua(8%,9) Uo)Ue))
=e-closuu uoU)

lRo,b) =e-clohure( ol6(%,6),b))


-e-closnefdo, b)uf{,ud(9a,b)
=¬-Clo5he()U6-doBe(

8,)-e- closiea(((V., e), ¬))


-C-ClosioelBo,c) Ud(%c)u% c))

=6-cosuel Vo) Ue-cose(Va)

You might also like