1 / 133

Chapter 1 Fundamental Concept

Chapter 1 Fundamental Concept. 1.1 What Is a Graph? 1.2 Paths, Cycles, and Trails 1.3 Vertex Degree and Counting 1.4 Directed Graphs. X. W. Y. Z. The K Ö nigsberg Bridge Problem. Königsber is a city on the Pregel river in Prussia

gtidwell
Download Presentation

Chapter 1 Fundamental Concept

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 1 Fundamental Concept 1.1 What Is a Graph? 1.2 Paths, Cycles, and Trails 1.3 Vertex Degree and Counting 1.4 Directed Graphs Ch. 1. Fundamental Concept

  2. X W Y Z 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. Ch. 1. Fundamental Concept

  3. X e1 e6 e2 X W Y e5 e4 W Y e3 e7 Z Z A Model • Avertex: a region • An edge: a path(bridge) between two regions Ch. 1. Fundamental Concept

  4. X e1 e6 e2 W e5 Y e4 e3 e7 Z 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 Ch. 1. Fundamental Concept

  5. Loop, Multiple edges • Loop: An edge whose endpoints are equal • Multiple edges: Edges have the same pair of endpoints Multiple edges loop Ch. 1. Fundamental Concept

  6. Simple Graph • Simple graph: A graph has no loops or multiple edges Multiple edges loop It is a simple graph. It is notsimple. Ch. 1. Fundamental Concept

  7. 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. B A C D Ch. 1. Fundamental Concept

  8. Finite Graph, Null Graph • Finite graph: an graph whose vertex set and edge set are finite. • Null graph: the graph whose vertex set and edges are empty. Ch. 1. Fundamental Concept

  9. u u v y y v G’ w w x x 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 Ch. 1. Fundamental Concept

  10. Clique and Independent set • A Clique in a graph: a set of pairwise adjacent vertices (a complete subgraph) • An independent set in a graph: a set of pairwise nonadjacent vertices. • Example: • {x, y, u} is a clique in G. • {u, w} is an independent set. u G v y w x Ch. 1. Fundamental Concept

  11. Bipartite Graphs • A graph G is bipartite if V(G) is the union of two disjoint independent sets called partite sets ofG • Also: The vertices can be partitionedinto two sets such that each set is independent • Matching Problem • Job Assignment Problem Workers Boys Girls Jobs Ch. 1. Fundamental Concept

  12. Green Blue Blue Red Chromatic Number • The chromatic number of a graph G, written x(G), is the minimum number of colors needed to label the vertices so that adjacent vertices receive different colors x(G) = 3 Ch. 1. Fundamental Concept

  13. Maps and coloring • A map is a partition of the plane into connected regions • Can we color the regions of every map using at most four colors so that neighboring regions have different colors? • Map Coloring  graph coloring • A region  A vertex • Adjacency  An edge Ch. 1. Fundamental Concept

  14. Scheduling and graph Coloring 1 • Two committees can not hold meetings at the same time if two committees have common member Committee 2 Committee 1 common member Ch. 1. Fundamental Concept

  15. Scheduling and graph Coloring 1 • Model: • One committee being represented by a vertex • An edge between two vertices if two corresponding committees have common member • Two adjacent vertices can not receive the same color Committee 2 Committee 1 common member Ch. 1. Fundamental Concept

  16. Scheduling and graph Coloring 2 • Scheduling problem is equivalent to graph coloring problem. Committee 2 common member Common Member Different Color Committee 1 Committee 3 No Common Member Same Color OK Same time slot OK Ch. 1. Fundamental Concept

  17. 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 Ch. 1. Fundamental Concept

  18. 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. Ch. 1. Fundamental Concept

  19. c d Subgraphs • Example: H1, H2, and H3 are subgraphs of G b a c G d e b a b a H3 c H1 H2 e d d e Ch. 1. Fundamental Concept

  20. b a d e b a c c d d Connected and Disconnected • Connected: There exists at least one path between two vertices. • Disconnected: Otherwise • Example: • H1 and H2 are connected. • H3 is disconnected. H3 H1 H2 e Ch. 1. Fundamental Concept

  21. ei vk vj 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 uponvj • Degree of a vertex vk is the number of edges incident upon vk . It is denoted as d(vk) Ch. 1. Fundamental Concept

  22. w w x y z 0 1 1 0 1 0 2 0 1 2 0 1 0 0 1 0 b wxyz y z a c e d x 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}. Ch. 1. Fundamental Concept

  23. w b y a z c e d x Incidence Matrix • Let G = (V, E), |V| = n and |E|=m • The incidence matrixM(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. a b c d e 1 1 0 0 0 1 0 1 1 0 0 1 1 1 1 0 0 0 0 1 wxyz Ch. 1. Fundamental Concept

  24. Isomorphism • An isomorphism from a simple graph G to a simple graph H is a bijection f:V(G)V(H) such that uvE(G) if and only if f(u)f(v) E(H) • We say “G is isomorphic to H”, written GH f1: w x y z c b d a y c w d H G a z f2: w x y z a d b c x b Ch. 1. Fundamental Concept

  25. Complete Graph, Complete Bipartite Graph or Biclique • Complete Graph: a simple graph whose vertices are pairwise adjacent. • Complete bipartite graph (biclique) is a simple bipartite graph such that two vertices are adjacent if and only if they are in different partite sets. Complete Bipartite Graph Complete Graph Ch. 1. Fundamental Concept

  26. Petersen Graph 1.1.36 • The petersen graph is the simple graph whose vertices are the 2-element subsets of a 5-element set and whose edges are pairs of disjoint 2-element subsets Ch. 1. Fundamental Concept

  27. 12 35 34 45 25 13 24 14 15 23 Petersen Graph 1.1.37 • Assume: the set of 5-element be (1, 2, 3, 4, 5) • Then, 2-element subsets: (1,2) (1,3) (1,4) (1,5) (2,3) (2,4) (2,5) (3,4) (3,5) (4,5) 45: (4, 5) Disjoint, so connected Ch. 1. Fundamental Concept

  28. Petersen Graph 1.1.36 • Three drawings Ch. 1. Fundamental Concept

  29. u, v Theorem: If two vertices are non-adjacent in the Petersen Graph, then they have exactly one common neighbor. 1.1.38 Proof: No connection, Joint, One common element. 3 elements in these vertices totally x, z x, y Since 5 elements totally, 5-3 elements left. Hence, exactly one of this kind. Ch. 1. Fundamental Concept

  30. Girth 1.1.39, 1.1.40 • Girth: the length of its shortest cycle. • If no cycles, girth is infinite Ch. 1. Fundamental Concept

  31. Girth and Petersen graph1.1.39, 1.1.40 • Theorem: The Petersen Graph has girth 5. Proof: • Simple  no loop  no 1-cycle (cycle of length 1) • Simple  no multiple  no 2-cycle • 5 elements no three pair-disjoint 2-sets no 3-cycle • By previous theorem, two nonadjacent vertices has exactly one common neighbor no 4-cycle • 12-34-51-23-45-12 is a 5-cycle. Ch. 1. Fundamental Concept

  32. 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. Ch. 1. Fundamental Concept

  33. Paths1.2.2 • 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. Ch. 1. Fundamental Concept

  34. Lemma: Every u,v-walk contains a u,v-path 1.2.5 Proof: • Use induction on the length l of a u, v-walk W. • Basis step: l = 0. • Having no edge, W consists of a single vertex (u=v). • This vertex is a u,v-path of length 0. to be continued Ch. 1. Fundamental Concept

  35. Lemma: Every u,v-walk contains a u,v-path 1.2.5 Proof:Continue • Induction step : l  1.(see the figure in the next page) • Suppose that the claim holds for walks of length less than l. • If W has no repeated vertex, then its vertices and edges form a u,v-path. • If W has a repeated vertex w, then deleting the edges and vertices between appearances of w (leaving one copy of w) yields a shorter u,v-walk W’ contained in W. (see next page) • By the induction hypothesis, W ’ contains a u,v-path P,and this path P is contained in W. Ch. 1. Fundamental Concept

  36. Lemma: Every u,v-walk contains a u,v-path 1.2.5 • An example: Delete Ch. 1. Fundamental Concept

  37. Components 1.2.8 • The components of a graph G are its maximal connected subgraphs. • A component (or graph) is trivial if it has no edges; otherwise it is nontrivial. • An isolated vertex is a vertex of degree 0. Ch. 1. Fundamental Concept

  38. Theorem: Every graph with n vertices and k edges has at least n-k components 1.2.11 Proof: • An n-vertex graph with no edges has n components • Each edge added reduces this by at most 1 • If k edges are added, then the number of components is at least n-k Ch. 1. Fundamental Concept

  39. Theorem: Every graph with n vertices and k edges has at least n-k components 1.2.11 • Examples: n=6, k=3, 4 components n=6, k=3, 3 components n=2, k=1, 1 component n=3, k=2, 1 component Ch. 1. Fundamental Concept

  40. Not a Cut-vertex Cut-edge Cut-edge Cut-vertex Cut-edge, Cut-vertex 1.2.12 • A cut-edge or cut-vertexof a graph is an edge or vertex whose deletion increases the number of components. Ch. 1. Fundamental Concept

  41. Cut-edge, Cut-vertex 1.2.12 • G-e or G-M : The subgraph obtained by deleting an edge e or set of edges M. • G-v or G-S : The subgraph obtained by deleting a vertex v or set of vertices S. G-e G e Ch. 1. Fundamental Concept

  42. B A C D E B A C D Induced subgraph 1.2.12 • An induced subgraph: • A subgraph obtained by deleting a set of vertices. • We write G[T] for G- T’, where T’ =V(G)-T; • G[T] is the subgraph of G induced by T. • Example: • Assume T:{A, B, C, D} G[T] G Ch. 1. Fundamental Concept

  43. C D E B A D B C A D B C B A C Induced subgraph 1.2.12 • More Examples: • G2 is the subgraph of G1 induced by (A, B, C, D) • G3 is the subgraph of G1 induced by (B, C) • G4 is not the subgraph induced by (A, B, C, D) G3 G4 G1 G2 Ch. 1. Fundamental Concept

  44. B A C D E B C Induced subgraph 1.2.12 • A set S of vertices is an independent set if and only if the subgraph induced by it has no edges. • G3 is an example. G3 G1 Ch. 1. Fundamental Concept

  45. Theorem: An edge e is a cut-edge if and only if e belongs to no cycles.1.2.14 Proof :1/2 • Let e= (x, y) be an edge in a graph G and H be the component containing e. • Since deletion of e effects no other component, it suffices to prove that H-e is connected if and only if e belongs to a cycle. • First suppose that H-e is connected. • This implies that H-e contains an x, y-path, • This path completes a cycle with e. Ch. 1. Fundamental Concept

  46. Theorem: An edge e is a cut-edge if and only if e belongs to no cycles.1.2.14 Proof :2/2 • Now suppose that e lies in a cycle C. • Choose u, vV(H) • Since H is connected, H has a u, v-path P. • If P does not contain e • Then P exists in H-e • Otherwise • Suppose by symmetry that x is between u and y on P • Since H-e contains a u, x-path along P, the transitivity of the connection relation implies that H-e has a u, v-path. • We did this for all u, v  V(H), so H-e is connected. Ch. 1. Fundamental Concept

  47. Theorem: An edge e is a cut-edge if and only if e belongs to no cycles. 1.2.14 • An Example: Ch. 1. Fundamental Concept

  48. Lemma: Every closed odd walk contains an odd cycle Proof:1/2 • Use induction on the length l of a closed odd walk W. • l=1. A closed walk of length 1 traverses a cycle of length 1. • We need to prove the claim holds if it holds for closed odd walks shorter than W. Ch. 1. Fundamental Concept

  49. Lemma: Every closed odd walk contains an odd cycle Proof: 2/2 • Suppose that the claim holds for closed odd walks shorter than W. • If W has no repeated vertex (other than first = last), then W itself forms a cycle of odd length. • Otherwise, • Need to prove: If repeated, W includes a shorter closed odd walk. By induction, the theorem hold • If W has a repeated vertex v, then we view W as starting at v and break W into two v,v-walks. • Since W has odd length, one of these is odd and the other is even. (see the next page) • The odd one is shorter than W, by induction hypothesis, it contains an odd cycle, and this cycle appears in order in W. Ch. 1. Fundamental Concept

  50. Lemma: Every closed odd walk contains an odd cycle 1.2.15 Odd = Odd + Even v Odd Even Ch. 1. Fundamental Concept

More Related