Download presentation
Presentation is loading. Please wait.
1
Chapter 5 Fundamental Concept
Graph Theory Chapter 5 Fundamental Concept 1.1 What Is a Graph? 1.2 Paths, Cycles, and Trails 1.3 Vertex Degree and Counting 1.4 Directed Graphs
2
The KÖnigsberg Bridge Problem
Graph Theory The KÖnigsberg Bridge Problem Königsber is a city on the Pregel river in Prussia The city occupied two islands plus areas on both banks Problem: Whether they could leave home, cross every bridge exactly once, and return home. X Y Z W
3
A Model e1 e6 e2 e5 e4 e3 e7 A vertex : a region
Graph Theory A Model A vertex : a region An edge : a path(bridge) between two regions e1 e2 e3 e4 e6 e5 e7 Z Y X W X Y Z W
4
General Model A vertex : an object
Graph Theory General Model A vertex : an object An edge : a relation between two objects common member Committee 1 Committee 2
5
Graph Theory What Is a Graph? A graph G is a triple consisting of: A vertex set V(G ) An edge set E(G ) A relation between an edge and a pair of vertices e1 e2 e3 e4 e6 e5 e7 Z Y X W
6
Loop, Multiple edges Loop : An edge whose endpoints are equal
Graph Theory Loop, Multiple edges Loop : An edge whose endpoints are equal Multiple edges : Edges have the same pair of endpoints Multiple edges loop
7
Simple Graph Simple graph : A graph has no loops or multiple edges
Graph Theory Simple Graph Simple graph : A graph has no loops or multiple edges Multiple edges loop It is not simple. It is a simple graph.
8
Graph Theory Adjacent, neighbors Two vertices are adjacent and are neighbors if they are the endpoints of an edge Example: A and B are adjacent A and D are not adjacent A B C D
9
Subgraphs A subgraph of a graph G is a graph H such that:
Graph Theory Subgraphs A subgraph of a graph G is a graph H such that: V(H) V(G) and E(H) E(G) and The assignment of endpoints to edges in H is the same as in G.
10
Subgraphs Example: H1, H2, and H3 are subgraphs of G G H3 H1 H2 a b c
Graph Theory Subgraphs Example: H1, H2, and H3 are subgraphs of G a b G c d e b a a b H3 c d c H1 H2 e d d e
11
Finite Graph, Trivial Graph
Graph Theory Finite Graph, Trivial Graph Finite graph : an graph whose vertex set and edge set are finite Trivial graph : the graph with one vertex and no edges, i.e. a single point.
12
Complement Complement of G: The complement G’ of a simple graph G :
Graph Theory Complement Complement of G: The complement G’ of a simple graph G : A simple graph V(G’) = V(G) E(G’) = { uv | uv E(G) } G’ u v w x y u v w x y G
13
Graph Theory Bipartite Graphs A graph G is bipartite if V(G) is the union of two disjoint independent sets called partite sets of G Also: The vertices can be partitioned into two sets such that each set is independent Matching Problem Job Assignment Problem Workers Boys Girls Jobs
14
Graph Theory Walks, Trails1.2.2 A walk : a list of vertices and edges v0, e1, v1, …., ek, vk such that, for 1 i k, the edge ei has endpoints vi-1 and vi . A trail : a walk with no repeated edge.
15
Graph Theory Path and Cycle Path : a sequence of distinct vertices such that two consecutive vertices are adjacent Example: (a, d, c, b, e) is a path (a, b, e, d, c, b, e, d) is not a path; it is a walk Cycle : a closed Path Example: (a, d, c, b, e, a) is a cycle a b c e d
16
Connected and Disconnected
Graph Theory Connected and Disconnected Connected : There exists at least one path between two vertices Disconnected : Otherwise Example: H1 and H2 are connected H3 is disconnected a b d e a b c d c d H3 H1 H2 e
17
Adjacency, Incidence, and Degree
Graph Theory Adjacency, Incidence, and Degree Assume ei is an edge whose endpoints are (vj,vk) The vertices vj and vk are said to be adjacent The edge ei is said to be incident upon vj Degree of a vertex vk is the number of edges incident upon vk . It is denoted as d(vk) ei vj vk
18
Adjacency matrix Let G = (V, E), |V| = n and |E|=m
Graph Theory Adjacency matrix Let G = (V, E), |V| = n and |E|=m The adjacency matrix of G written A(G), is the n-by-n matrix in which entry ai,j is the number of edges in G with endpoints {vi, vj}. w x y z wxyz a b c d e w x y z
19
Incidence Matrix Let G = (V, E), |V| = n and |E|=m
Graph Theory Incidence Matrix Let G = (V, E), |V| = n and |E|=m The incidence matrix M(G) is the n-by-m matrix in which entry mi,j is 1 if vi is an endpoint of ei and otherwise is 0. w a b c d e b wxyz y a c z e d x
20
Graph Theory Special Graphs Complete Graph : a simple graph whose vertices are pairwise adjacent. [ A graph is complete if each vertex is connected to every other vertex.] The complete graph with n vertices is denoted by Kn Complete Graph
21
Complete Bipartite Graph or Biclique
Graph Theory Complete Bipartite Graph or Biclique Complete Bipartite Graph
22
Graph Theory Paths A u,v-walk or u,v-trail has first vertex u and last vertex v; these are its endpoints. A u,v-path: a u,v-trail with no repeated vertex. The length of a walk, trail, path, or cycle is its number of edges. A walk or trail is closed if its endpoints are the same.
23
Graph Theory Even Graph, Even Vertex1.2.24 An even graph is a graph with vertex degrees all even. A vertex is odd [even] when its degree is odd [even].
24
Regular G is regular if (G ) = (G )
Graph Theory Regular G is regular if (G ) = (G ) G is k-regular if the common degree is k. The neighborhood of v, written Ng (v ) or N (v ) is the set of vertices adjacent to v. 3-regular
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.