Mfcs Unit 5
Mfcs Unit 5
GaRAPEH THEORy
Basic concept5
2Gevaph theovy and i application
sul- qhaph»
Graph epentationy
a d j a c e n t y mahun
AIncedence matyiC,
Tsomophit ta
Path circults
E Ueulerean f him ilto nlan ophb
MulH gapho
B1pecth BiPatthite E Plamat 9haphwin',n
(o) Euler's theorem
Cvanh tolbrin k covesîng)
Ch1omadlc numbey
3 spanning tree
Primokushkalsalgorith m
BFs, DPs Apamning eer
(
Crvaph:
Gvaph Consists of Paivs ofVertits ond edges ie
where V repeSrS m0 of non' ernply finite
ueof vevtices nodes and e repesents no of
get linu
finite set of edges o
non empty ec
szuane
Ex tviangle, Rectangle,
1)
and multigtaph 1
muligaPh
with lops
lo0pS and
Pbeudo A oph
called pseudoaph
no
oith no loops and
Simle glaph: A 7lorh
multighaph
Vu
Indeyee: at
Verter i3 called
the Verter ib
No Of edge ending
In degyee B called
al the Verter
Ouldegree beginning
NO o0f
No edges
out degvee
o
Find Indeqta, Ouldegua , tolaldegu ouen ohap
V
'N
Nult pb:
A haph wth no
edges Called null ghaph
TSolated gnaph:
A ghaph ith no veyhces s colled I90lalted
NulI Graph
Complete taph:
t
Ever yevteyinthe paph
A Evey
A Conneckd
cthey verRI m h 9naph
euevy
A
Edgen (n ) s(5-,
a
5( 0 to
nno o ventce
Bi Parhd graph
A haph I said to be biprkeo háph if
v u u 43,V,,Va Vs,V4 j
V, V3,Vu
V,us
u
SDegu
ae
Determine whetheY the givenV grofs
Sometic o not
N
h
NO edge3 5
at verte
Degvecs
V I t is ISometvíe
laph
fveartces
me
d3
e3
f3
33
h
NO of vertices fov Hgure D o
NO O, veytf ces for figure (i) e 8
edges for fqure= to
NO f
elges for fig uve o tD
NO of
of degvee fov figuw,O
NO of
3
3
b
3 2
d S 3
e G2
f 3 13
h3
20
to tal
20
Iometric haph
a
ITt is
eA
n thiB 9taph thou ae 4VeytiCes and c.d
G edo
n this ghaph es. ec au nsectiHng ese
s0 we0
uad ddaur an eztekio uglon 3 es
ulon
Aheel bvaph e
Tt is denoted as Wo. t S Similav to compete
gtaph but the dthem S Centval f ta Vutol
N
Vs
N
V-V2-V3 -Vu-vs is a waLK
Ve eaVges Vye» Vs
Dial
Awalk is called *tvial f all edges ane distinct
V
es
VV-v4- V3-V2- vs
e
e e V,eV2et UuezV,e,vz
e
es VS
V-v2-V3-VyVS
eV2 Vg¬s V,¬y Vs
poth s a.rial but evey ual
Nobt: Gvevy
Mecd not be a fath.
Cosed Path:
A closed ath is a path that stanting amd
etces ane 8ame
ending
V2 -Vy-V2
V,e2 V3e3Vyes V2
Civcut
defined as a closed path
A civcuit or cycle is
that doesnt' Contán repeattd
of non 3exo enth
edge V-V3-Vq-Ys-Va
V e eyvges2
Eularain Gtraph
Eular Path it cove
to be Eules Path if
A Path Is sdid
all disnct edges
Euler circuit
A 3
Civcuit
Civcuit if
S
is called Eule
Eules
Saune
Eules Path
Eules
vexticas
o
and ending
Starting
fa9haph coniot of odd , mo, ofyeytite
with odd dearee Constst only euler Pats
not Euler cir Cuit
conwt of odd no pf vertite wi
a haph then it.ha soth
even degua tAe
Euleypath ciut
V
e
e
es es
V3 e 3 e
V-V-V-Vu _v-V1-V V-V3-Ys-V4V3-V2-y
Eula fovmula
I R I 1 E l -l v l+2
sR RegBo n
EEdges
VVeYtices
total no of Yegions
tov thghofk
Find the V
R 5-4 +2
T423 e
V3
V42ib
HOmiltoniam Poth
A Path is Said to be haniltonian if i covnecs
Netfces f the given aph 9 wlth
all
all the
dlstinct vevtice Contains Btating and ending
the Path.
Hamiltonifan Cercuit
HomiHonian Path with &anting and ending vetices
then the Civcuit. s called hamiltonian
aHe a e
CCuit Poct
and tivcuit for 9lven
find Hami ltonian ghaph e
V-V-Vs-V3-Vy-v
Ne
e e e
Tuesy
Determîne
s l
whethev the
the fotlo uoing v4 C3 V3
V
O
2
Intidence Ha
h matvic COus of m umbe of vevts bn no
then 1t 3 uvwmtta a mxn so
Find the
incdene matvix fov the given qaph
ooolo1
Cicult Harix k
o mumr of cituiils
mabun Con m
as mxn
is repusented
n.o oephey hen it'
C
C
Cs
by deleting ver 1
Conoider es
ghaph q 3wOut to d'el C,h
form ub ghoph
V3
e3
Gtvaph colovin
to: be. ghhs calouted # .
a gtaph is1 2aid withdifferentColo
ph e 2
h1Oma-tic numbex
Verticey
6 the Odered n-I is even then he chvomath
umber is 3.
Ovdeved n-t dodd then 1he hvomatc
cb) te
umber is
TreS
that Condains cytles is Called cycte
A oph is called
and Conected ayelic aph
foph
a tree
lank of Gaph G
Kauk m-n +1 wheve
m is no of edges
is no of Vertice!
ank of tha iaph
Find the
KawK m-n+
5-4+
Ofannung vee
n o of Vevtices vesent
9rph G
Find Spanning ee fov 9ven oph
6 3amuin tvees
(m-1) y-[ edgey
he no of edges aud no of vetites aud Je qrons
iven find he tptaldegu h guen
a
y deg (v.):alEl
Construct
To >Panning tvee thehe au two techwie
Bveadth Fivst Seanch
Depth fivst Sennch
5FSHgovithm:
a sootd luu i cowstuutted and
n Agovithn
thid
ced giaph othid Aooted u fhms a
Thuda N1 (n-)edgs
2 4
1 4 - 2
Verten
Step2: fath stanting,at his
tovm a
8ucLesivel adding edges aylena
y
tha
Step6: Repeat procedue om begnming
no moie edg Ca be added
wtl
ntl
roblem
VV V Vs V
t wigha
ueighbed
uu a
cf a
pommimg mhinu-
4munumum
Gwith
a pomning o
haph
unight Ksukals
K al Algdithm: elect n
Select edge
a n edge
we ihot ameng thu
ths algouthm ameng
o w e s t Weight
T
Tm COntinUe
Continue
which ha loops
of which
ane
not
h a e bee
been
edges in G
Cdges until
-
n-11 edges
hae
Ts Procew
sele cted munumum wnight
Step 1:choose an edg minimu)
tham one eahe
of
her is mde ag
chooSe abitaty
onm h o e
wheiqht
chose he edge F
At each stage
sep 2: wil not
lowest welght whose nclude
Cucles
Slep3: 9t G has n vetites then Stop aft n-1
haue bcem Chosen othewise Aepeat
edges
edges
Stop 2
VVs1
6 Vs
VsiV -3
V2Vs -
10 Vu-Sy
VVs
Ve
VV2Va Ngy+7
Vy Vs Vs V
2 3 S Vi,-8x
VI,V
N Uy,Vlo
N3,V
V,V-I
vs
b3, 1 3
37
V
Psimb Algorithm:
choose the edge
Step1: Select any veltex amd
th miimun ede eight
P2A each Stoge choose edge of `malast
mluded
joining a vetex alheaaly
weiqht
at intuded.
to,the ventey not
ae include d
SPP3Continue until all Venticer
fG has n vextices then tDp afte
n-1 edge hdi been
choosen othiuo
upeai t p 2.
Ans weA
e b
3
2
3 C
d
A92
39