0% found this document useful (0 votes)
20 views18 pages

TC 1.note

The document discusses the concepts of Deterministic Finite Automata (DFA) and Non-Deterministic Finite Automata (NFA), including their definitions, transition functions, and accepted languages. It outlines the operations on regular languages such as union, intersection, and complementation, as well as the closure properties of these languages. The document also highlights the differences between DFA and NFA, emphasizing the unique characteristics of each type of automaton.
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)
20 views18 pages

TC 1.note

The document discusses the concepts of Deterministic Finite Automata (DFA) and Non-Deterministic Finite Automata (NFA), including their definitions, transition functions, and accepted languages. It outlines the operations on regular languages such as union, intersection, and complementation, as well as the closure properties of these languages. The document also highlights the differences between DFA and NFA, emphasizing the unique characteristics of each type of automaton.
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/ 18

We G- typle (R2,5,r) The DEA M, 1s a 5-tuple (e, 2,8,o, F) chere

whee

2-fa, b} 3|a ] b

3) The trunsiton fune,s s defne! a


state

,
(o)
9, 4,
Draw the state DEA
EX of the foll o«
\eyt(Rang
(Domay) My
Hene
D D

Soj? 0,1
5) F= 4, is the set of acept steted
(O) 1

Ex O
Gives te fornal def DRA M,
,1 0,1

This s of DEA My
a,b *sel of
* The DFA My
accepted stngs =j¬, o,! ,0o, o1, 10,
aCcepts all e sings who5e lengt is atmasa
Shhany poESENYi DEA Language of a Machine -(Lon)
O,1 Jn DFA Ms , 4e set f aicepted shmgs
{oo,01, 000, ol0, o0,oll, -
(DFA M) ie the set of aciepted sthn
stat coits o0 on
= (set of stngs that Start
Lnput Sny processm outpul ith o1

4i, Accept We nDua Language-i 5 sed of stngs


2) 1011 ,44 Redectd Hence L(M%) w|we{o,1} and wstants with
o0or o1
3) O00 1 Acept
Anite
£veny Mahine on Automats Lecognizs te languge
In a finite Acto mata (FA), the nput strngis proasey end accepts the Stng
fhon left to ignt stortg om te stot state So
L(M) =wlnacepts
’After all the nbols of te sting
iE the accept state (on fnd state) is reached, te
he stng s accepted. otenwise nestng s ie’The ’The langge
langage o a machne on fnite atomata
unou)n rafens to the set ofof Stngs hose' and accepted
in the Machne (Tke ini te autnata i5 als
by that FA.
Anite state Mache) FA = FSM
FSM ) nd te languge of the
O, 1
o1
b,... aaaaj bby aa,aby
, ba L{e, So
10,113L<foo,o1, i.e A
bbba, ata,a ba,e, L= So
lengthel
b
l=(e i-e
is wof
L=(a,
b] ie
DFA of Des
4,6
t of
is lengta and (wlwt
S* =L 091, 000,10,11, 1,(o9, sang aceqkd ofset
fwjwe{o1j"
and L(M)"
nt2. he
bDEA statsin
of no. e hen
engto, 50 eNen

L=
lengho
lengh
legt
-2
ab
e,
aaa,
length of lenghod
aab,*
a,b
a,b w
is
risble
lwMo)
8
by
3=o 3
i.e

V)
L= So v)
L l= a's SO
w)w =e,a, {wlu
a L-aa
has

odd
bb, has has
aa, odd
ad oab,
b5a
no. aba eren
b's] of nb'osof
. no. of
,
bab, of a's bbb,baa,3 no.
a's of
aaa, ? a's
abb.
-..}
nddsodd

J
00l,.
100o,
ooo, 10l,
el
ifo,1} 0l,
o0, 100,
-fo, 10,
L l:
So
5o
Ex
-
a* 2)
d basie operafons
ase
y The ’
to
concatenaton det
The
Ex operations
Regular
wnown e
Th

maip)ate Law has
reglan 4 star3) )
Concatencton diffenent
Union
opEn Ly
=languges
and {w
ations
:operabons con
AoB then tns o1
apped langunges.
Regler
= pes cognizedby e
lepeation AB laggs
relotwo of
o
are
- ae lenOLUnovn
wyl bsic
de
of fned sbShing!
neA nglor negular
ag ay
a
- o ag fni
faa,a',.] fol)ows
Relagru
langges
e8 peratons te
The auto

lngoges
neguler *>
staebot is *)
at:
2
Ljl soa-a-
Union (e<posihve
dosue + :-kleen
dose
one
|10)fiD,
operato.
onoryis
and -at, on
concate more
loare.reglg
n
olo, nahion repeoVn

l0)|l,loi0,
are
of
binay afa',a',a',...
9d
l00)0,
operatong
1o1[
?
=fe,1ol, lo, lo|lo|l, lol10 , lolo|l,1oj0, ..) So we Can pnigre thad A,uay-{wis of od lengts
o w s ends n 13 is a

1
Closune
propenty o,1
t N{,,3,4 ......*be te set of nat
nubens . Now N is Closed nden Additon(+)
0, 1
(DFA M, for A,)
(DF A Mi for A,)
operaton , bot ot in substnachon (-) openahon. UA,
Ex
Now Constrwct a new DFA M for Aj
E 36N, 5¬ N
3+5- 8EN sakshog dosne propeny
|1 1
’A se Unden Some
of elemets is dosed Unden
operaton if app that openaton,e result is
set.
dosed nden
the negolor languges
i) Union
iv o=2,r,
oo3) sta operatonG

dosed uneden nion operaton

EX et A, { wis of odd length} and A,-fa ends d


n 1] be tuo egolat lengges ojen i-(o,1].
= e, 1o1, lo, lo|lo, lo)10 , )ololl, JOjo. So ue can pri tad AjUAzwis of odd
or ws ends n 13is a

closune propenty
te set of d ,1
Jet Ní,3,3,Y -....* be
Additn(al
nubens , Now N is Closed nden o, 1
(DFA M on Ay)
openation, but mt n substaacton (-) openan. (DFA M, fon A)
a new DFA Mfor A, UA,
Ex 36N, 5¬ N Now constwct

dosune pmpeny osinoi

Undea Some o|1


A set of elemets is dosed
he nesult s 4, 4,
operaton if appng that openatson
'set. (
ore closed unden

operatsonfo
dosed unden vnion
EXE Jet A,:(isof odd leng
n 1] be tuo reglar longunges oven z(91].
Theora The class of nagula s
Under nion openaton ie if A andlangvages
A, are
is closey s(a.a),)- (4,),5, (n,)
languages, then AJA is a ngobe anguge
proof ke ctat state of both te DFA,
Shce A, is a regle langunge , tet DFA M,
re cogni ses A,:.
yF-{(e,)(,n) ¬ Q and 96 F, or eF?
whene. The state contans the acept shte
aCcept state
4c) DFA.
Sini lady , snce Aa is a gle lngg tel DFA of te

M ecomises A whene Ma Smcethe new


DFA FA, MM ecognizes A VAz, So
o

n
Now constwcd a new DFA M 4ht wll
neglae lagge Proed
ill atogoize
A,UA, whene
M (e, 2j8,%, F) EX ConStrwct a DFA fon l= fw stats ith o on
w has even no. of o's

he cartesjan prodwct of set of stty So we Can prove that


of both the DFAs
L
A w starts with o3
so lel: lalx le) Ly w hag enen no. of o's}

So L= L,ulz
D) 8, the teansi on functon is defned as follows
et (a,) be any state m e ad ae i,then
Q1
( lo1 Reiecked
001 Accepled
(DFA M, fon L) (DEA M, for L)
L)
Now Des) a DFA M=(Q, ,ay F) fron the (DFA M fon
DFAs M My that will recognize L, ULy3
Intensechon operaton
no. of Os
f(e,n).(a,nJ, (4y,),(4,),5,) th O cnd eren
L e fw Btats

and eL
L,0Lz n|eL
In Indensechon opeahon,
?
1
F I(eyn))seF, and
both te states no
74, 323 A stde ill be accepled ife
(Transiton Table) acceptd.

9,r, , 2 Ln he above exenple, 4r, îs te ony ac(ept


*, 4 State
a DrA that necogiseg 6 1
of
Lfwis en length and whag, emen os)
Li

So
Desim DF A M, forn ,:
0,1 Conplement penation
0) 1
of wjs not eren
Ly f length
DrA M, fon L: prroess
Lyflength, of wis Enen)
complenet

Now Desig DFA M=}2,) 5, oy F from te


DFA', , 2 M, hat wil ecogoize o,1

9,1
Conplenent
-(6,,n), (o,n), (3,n), (%y7)
o,1

’In Conple ment openation, the accept and non


accept States ae renesed i the
ougioal DEA.
Ad
Contan doesn't Lfu for DFA
bb
, ab,bay, aa, }a,b, 91
L=¬
2
) 1
b So1
asb
-¬, aso1' Contan not does L=
j
b-] ,as, aab ab, b,a,
lbguye eogises
he had DFA Desiagn ’
a'b',..] ,a'b', fayo
I 2
0 20] |i,j fa'b' L=
bb] ab, -a,
o
a, b, ba, bat a , -f,a,
b,
b
o. fa'a',
a',
L-fa"Jko} EX
'-L Geneaad,
I In ’
Non- deteamnisi Finite. Automat The rage of taansiton
2) The Range of trensi hon. ’functon 5 the set of pouen
91 foncton is tte set of states.
EX
set of sttes (i-e p())
6iQx2’ PQ) ¬r :0xé ’ P
) 1 hag no t- transi kon hare E- transion,
9,1
,1
Ex
,3,)
Def
-NFA is a fnite automata n which Severa )"-fo,13
choices mey exist foon ay tzansiton NFA
i.e Thene Can be2ero mone tansitons fon ,, 1 ’DFA
any mput Sgmbo) ron
on a shte
9,1
’ the NFA ay condan a teensi hon fon E gobol ’NrA
n this Cse t s nowsn as - NFA.
O,1
BFA
Dlfenences bet DFA and NFA .
NEA o,1
DFA
be more
next
i) There is a singe than one next State for a Forsal De fneton of NFA
state fon a tansion.
tunsiion. The NFA N is a
) i hag a sngle thans on 2) t has zeno on
mone 5-tple N(2,=,5,to, f)hene
a Soite set of tetes
for on io put synbol frsn trans on faor n mput
each Gtate. Synbol fron a stte.
Ex Give he fortrmd de fioton ct e
iollsg
:.Qx NEA.

Ex If is0, 13, hen ie {o,, e]

so The NEA is a 5-tuple (as,5, Go,F) whene


v)F is he set of accept states Ais the stert
)e-f4, B, D} 4 o
se!
s)F= (9 }is te
EX Gve the forod defsnaton of tte folloaz NEA of Accept stete
a b

o,
So
The NFA is a 5-tple (3,s,Q, ,,f) whene

sty processng in NFA


S|o|1 0n

iy o h is te stat stak et he nput Stngs w 0001


)F-3] is te set of accept state
It is accepled ag it Reaches the accept state
i:e 2y m one of the branch.
is protessed n the NFA, it wil) Desig of NFA
hae mlple branches of enecohon Aften, proes let s-fo,13 pesign he NFA forn the given

branch reaches an accept stete then the sty with o...


is Sad to be accepd othenwise it is nejec iy L= ( w tarts 31

Ex
o?
2) L {w ends with

det the sthng isis we bbb aa


3) L= fw stots with 1o?
o1
b: Hence te
A
b! A
accepkd, Kon 3
b: A B B aLceplke.
a:

wContahs o01 as ashstg


D is reached
stete ie 3
Snce te accept 1
w bbbaa is accepley.
dAfferent branche, the stnng wbbbaa
'o,
DFA
1 VFA and
Eguivlene of o?
hand sid storts with
L -fw

CNFA)
(Ora)
eyuvalet
automata
’ Two fnte
-fe, o1 ,o101, .....] the sane
equivaden
Can be
NFA
both DFA DFA is a NFA
-) So (Defavt) Evey
) DFA -) NEA Eveny NEA
NFA Can be
(Convet)
) NEA ’ DFA Conventcd to a DFA

of NFA to DFA
-fe,o, 1, 1,oo1, o0), --] Con ven)on
2,5,9.) )
1 Consideno,1te follny NEA N, =(a,

O,1
det Mi be the e,vivlemt DFA oF N,
’ Aften 1. hee toill no
(vo) whene ,,)
M-(e',e,5,,F)
)Pe'pQ)-{e,a), i3, ), i4,3,)3
s(4,8),°)
* - 6(119) 5(a,) ’A
a
B Here iA,B3 s
Unneachable stete.
DFA M

DFA

yF-2:],i%,,43] o,1

Hene , Gnd ore neachble stles Theoron eyal ent DFA.a


are disCarded. NEA hag an
Eveng
E Con ventthe follong NFA to DFA proof
tnt
je,2,8, 5, F} be the gven NFA 4ht
et N
1
it
gulo langunge A. Assume that
ecopniB tunson.
has no E -

Hene det M=(o, ,8, ,,F) be the egialet


DFA tte gven NFA N thnt ill recognize te
the equvden DFA of N,
of the
det 2 be A. The DFA Mis Construcled as
where M2=2', s',s'y follows states o f A
i) e Pa) i.e the Set of, DFA is the se of all
)a'- p(2) - {41A,(B] ,[a8) y
subsets f tte a' set of sttes of NEA.
ie NFA has k no. of states, then its equvalet
DFA hag z no. of states
stte Rea' d
nedSgmbol
DEA
teansion fmchon ,s' > de ned
fmchon as!
ag follo 1
’A

B (1
of
This DEA should hane &no.
union af the ddl But it hag 4 no. of
NFA. Uneachable stteg e
1V) .'-9, ie start stete of DFA =start d {r49), 14,0], i6, 0],14B,b1)
NFAae
V)F-R]REQ and R Ognton s te acept s
NEA N
-TThe Con5twcted DFA sl) ecognize the aag
A and hence both He NFA and DFA

EX Fnd the equent DF


DFAA of te NFA.

) e'- P(e) -(b, In1,189, i03, 146),1A0), 190),1a8)]

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