9.2 Graph Terminology and Special Types Graphs

Slides:



Advertisements
Similar presentations
CSE 211 Discrete Mathematics
Advertisements

Chapter 8 Topics in Graph Theory
Lecture 5 Graph Theory. Graphs Graphs are the most useful model with computer science such as logical design, formal languages, communication network,
 期中测验时间:本周五上午 9 : 40  教师 TA 答疑时间 : 周三晚上 6 : 00—8 : 30  地点:软件楼 315 房间,  教师 TA :李弋老师  开卷考试.
1 Slides based on those of Kenneth H. Rosen Slides by Sylvia Sorkin, Community College of Baltimore County - Essex Campus Graphs.
Discrete Mathematics and Its Applications
 Graph Graph  Types of Graphs Types of Graphs  Data Structures to Store Graphs Data Structures to Store Graphs  Graph Definitions Graph Definitions.
1 Section 8.2 Graph Terminology. 2 Terms related to undirected graphs Adjacent: 2 vertices u & v in an undirected graph G are adjacent (neighbors) in.
SE561 Math Foundations Week 11 Graphs I
Graph Theory in CS Route Search in Online Map Services
Discrete Structures Chapter 7A Graphs Nurul Amelina Nasharuddin Multimedia Department.
Selected Topics in Data Networking Graph Representation.
Applied Discrete Mathematics Week 12: Trees
Graphs.
K-Coloring k-coloring: A k-coloring of a graph G is a labeling f: V(G)  S, where |S|=k. The labels are colors; the vertices of one color form a color.
KNURE, Software department, Ph , N.V. Bilous Faculty of computer sciences Software department, KNURE Discrete.
9.3 Representing Graphs and Graph Isomorphism
Let us switch to a new topic:
GRAPH Learning Outcomes Students should be able to:
Graphs Chapter 10.
1 Graphs Chapters 9.1 and 9.2 University of Maryland Chapters 9.1 and 9.2 Based on slides by Y. Peng University of Maryland.
GRAPHS CSE, POSTECH. Chapter 16 covers the following topics Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component,
Lecture 5.2: Special Graphs and Matrix Representation CS 250, Discrete Structures, Fall 2013 Nitesh Saxena Adopted from previous lectures by Zeph Grunschlag.
Module #19: Graph Theory: part I Rosen 5 th ed., chs. 8-9 내년 3 월 ? 교환 학생 프로그램 영어 점수 미리미리 준비하세요.
Fall 2015 COMP 2300 Discrete Structures for Computation Donghyun (David) Kim Department of Mathematics and Physics North Carolina Central University 1.
Lecture 10: Graphs Graph Terminology Special Types of Graphs
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sixth Edition, Mc Graw-Hill, 2007 Chapter 9 (Part 2): Graphs  Graph Terminology (9.2)
aka “Undirected Graphs”
9.2: Graph Terminology. Special Simple Graphs Complete GraphsK 1,… CyclesC 3,… WheelsW 3,… N-cubesQ 1,… Complete bipartiteK 2,2,…
Copyright © Zeph Grunschlag, More on Graphs.
1 CS104 : Discrete Structures Chapter V Graph Theory.
9.1 Introduction to Graphs
GRAPHS THEROY. 2 –Graphs Graph basics and definitions Vertices/nodes, edges, adjacency, incidence Degree, in-degree, out-degree Subgraphs, unions, isomorphism.
Graphs.  Definition A simple graph G= (V, E) consists of vertices, V, a nonempty set of vertices, and E, a set of unordered pairs of distinct elements.
Graphs What are Graphs? General meaning in everyday math: A plot or chart of numerical data using a coordinate system. Technical meaning in discrete.
1/24 Introduction to Graphs. 2/24 Graph Definition Graph : consists of vertices and edges. Each edge must start and end at a vertex. Graph G = (V, E)
9 Graphs. A graph G = (V, E) consists of V, a nonempty set of vertices (or nodes) and E, a set of edges. Each edge has either one or two vertices associated.
September1999 CMSC 203 / 0201 Fall 2002 Week #13 – 18/20/22 November 2002 Prof. Marie desJardins.
Chapter 5 Graphs  the puzzle of the seven bridge in the Königsberg,  on the Pregel.
CS 103 Discrete Structures Lecture 20
Graph Theory and Applications
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sixth Edition, Mc Graw-Hill, 2007 Chapter 9 (Part 1): Graphs  Introduction to Graphs (9.1)
Graphs 9.1 Graphs and Graph Models أ. زينب آل كاظم 1.
And before you really hate (mathematical) relations and begin to break your (social) relations, let’s switch to a new topic: Graphs Discrete Structures.
GRAPHS. Graph Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component, spanning tree Types of graphs: undirected,
Discrete Structures CISC 2315 FALL 2010 Graphs & Trees.
1 Graphs Terminology By: Sandeep Tuli Astt. Prof. CSE.
Chapter 9: Graphs.
Chap 7 Graph Def 1: Simple graph G=(V,E) V : nonempty set of vertices E : set of unordered pairs of distinct elements of V called edges Def 2: Multigraph.
1 GRAPH Learning Outcomes Students should be able to: Explain basic terminology of a graph Identify Euler and Hamiltonian cycle Represent graphs using.
رياضيات متقطعة لعلوم الحاسب MATH 226. Chapter 10.
1 Graphs Chapters 10.1 and 10.2 University of Maryland Chapters 10.1 and 10.2 Based on slides by Y. Peng University of Maryland.
Chapter Chapter Summary Graphs and Graph Models Graph Terminology and Special Types of Graphs Representing Graphs and Graph Isomorphism Connectivity.
Chapter 9 (Part 2): Graphs
Lecture 19: CONNECTIVITY Sections
Applied Discrete Mathematics Week 13: Graphs
Special Graphs By: Sandeep Tuli Astt. Prof. CSE.
Copyright © Zeph Grunschlag,
Graph Graphs and graph theory can be used to model:
Graphs Hubert Chan (Chapter 9) [O1 Abstract Concepts]
Chapters 8.1 and 8.2 Based on slides by Y. Peng University of Maryland
Graph theory Definitions Trees, cycles, directed graphs.
Taibah University College of Computer Science & Engineering Course Title: Discrete Mathematics Code: CS 103 Chapter 10 Graphs Slides are adopted from “Discrete.
Graphs Chapters 10.1 and 10.2 Based on slides by Y. Peng University of Maryland.
Graphs.
Chapters 8.1 and 8.2 Based on slides by Y. Peng University of Maryland
CS100: Discrete structures
Let us switch to a new topic:
Lecture 10: Graphs Graph Terminology Special Types of Graphs
Graphs: An Introduction
Presentation transcript:

9.2 Graph Terminology and Special Types Graphs Basic Terminology Definition 1: Two vertices u and v in an undirected graph G are called adjacent (or neighbors) in G if u and v are endpoints of an edge of G . If e is associated with {u, v}, the edge e is called incident with the vertices u and v . The edge e is also said to connect u and v. The vertices u and v are called endpoints of an edge associated with {u, v}. Definition 2: The degree of a vertex in an undirected graph is the number of edges incident with it, except that a loop at vertex contributes twice to the degree of that vertex. The degree of the vertex v is denoted by deg(v).

Basic Terminology Example 1: What are the degrees of the vertices in the graphs G and H displayed in Figure 1? FIGURE 1 The Undirected Graphs G and H.

Basic Terminology Theorem 1: The Handshaking Theorem Let G = (V, E) be an undirected graph with e edges. Then 2e = vV deg(v) Example 3: How many edges are there in a graph with 10 vertices each of degree six ?

Basic Terminology Theorem 2: An undirected graph has an even number of vertices of odd degree . Definition 3: When (u, v) is an edge of the graph G with directed edges, u is said to be adjacent to v and v is said to be adjacent from u. The vertex u is called the initial vertex of (u, v), and v is called the terminal or end vertex of (u, v). The initial vertex and terminal vertex of a loop are the same.

Basic Terminology Definition 4: In a graph with directed edges The in-degree of a vertex v, denoted by deg- (v) , is the number of edges with v as their terminal vertex. The out-degree of v, denoted by deg+ (v) , is the number of edges with v as their initial vertex. (Note that a loop at a vertex contributes 1 to both the in-degree and the out-degree of this vertex.)

Basic Terminology Example 4: Find the in-degree and out-degree of each vertex in the graph G with directed edges shown in Figure 2. FIGURE 2 The Directed Graph G.

vV deg- (v) = vV deg+ (v)= |E| Basic Terminology Theorem 3 : Let G=(V, E) be a graph with directed edges. Then vV deg- (v) = vV deg+ (v)= |E|

Some Special Simple Graphs Example 5: Complete Graphs The complete graph on n vertices, denoted by Kn, is the simple graph that contains exactly one edge between each pair of distinct vertices. The graphs Kn, for n= 1, 2, 3, 4, 5, 6, are displayed below. FIGURE 3 The Graphs Kn for 1≦ n ≦6.

Some Special Simple Graphs Example 6: cycles The cycle Cn, n  3, consists of n vertices v1, v2, . . ., vn and edges {v1, v2}, {v2, v3 } ,. . . , {vn-1, vn} , and {vn , v1}. The cycles C3, C4, C5, and C6 are displayed below. FIGURE 4 The Cycles C3, C4, C5, and C6.

Some Special Simple Graphs Example 7: Wheels We obtain the wheel Wn when we add an additional vertex to the cycle Cn, for n  3, and connect this new vertex to each of the n vertices in Cn, by new edges. The wheels W3 ,W4, W5, and W6 are displayed below. FIGURE 5 The Wheels W3, W4, W5, and W6.

Some Special Simple Graphs Example 8: n-Cubes The n-dimensional hypercube, or n-cube, denoted by Qn, is the graph that has vertices representing the 2n bit strings of length n. Two vertices are adjacent if and only if the displayed in Figure 6. Note that you can construct the (n+1)-cube Qn+1 from the n-cube Qn by making two copy of Qn , prefacing the labels on the vertices with a 0 in one copy of Qn and with a 1 in the other copy of Qn, and adding edges connecting two vertices that have labels differing only in the first bit.

Some Special Simple Graphs FIGURE 6 The n-cube Qn for n = 1, 2, and 3.

Bipartite Graphs Definition 5: A simple graph G is called bipartite if its vertex set V and be partitioned into two disjoint sets V1 and V2 such that every edge in the graph connects a vertex in V1 and a vertex in V2 . (so that no edge in G connects either two vertices in V1 or two vertices in V2 ). When this condition holds, we call the pair (V1 , V2 ) a bipartition of the vertex set V of G.

Bipartite Graphs Example 9: C6 is bipartite, as shown in Figure 7, because is vertex set can be partitioned into the two sets V1 ={v1 , v3 , v5 }, V2 ={v2 , v4 , v6 }, and every edge of C6 connects a vertex in V1 and a vertex in V2. FIGURE 7 Showing That C6 Is Bipartite.

Bipartite Graphs Example 11: Are the graph G and H displayed in Figure 8 bipartite? FIGURE 8 The Undirected Graphs G and H.

Bipartite Graphs Theorem 4 : A simple graph is bipartite if and only if it is possible to assign one of two different colors to each vertex of the graph so that no two adjacent vertices are assigned the same color. Example 12: Use Theorem 4 to determine whether the graphs in Example 11 are bipartite.

Bipartite Graphs Example 13: Complete Bipartite Graphs The complete bipartite graph Km,n is the graph that has its vertex set partitioned into two subsets of m and n vertices, respectively . There is an edge between two vertices if and only if one vertex is in the first subset and the other vertex is in the second subset . The complete bipartite graphs K2,3 , K3,3 , K3,5 , K2,6 are displayed in Figure 9.

Bipartite Graphs FIGURE 9 Some Complete Bipartite Graphs.

Some Applications of Special Types of Graphs Example 14: Job Assignments Suppose that there are m employees in a group and j different jobs that need to be done where m  j. Each employee is trained to do one or more of these j jobs. We can use a graph to model employee capabilities. We represent each employee by a vertex and each job by a vertex. For each employee, we include an edge from the vertex representing that employee to the vertices representing all jobs that the employee has been trained to do. Note that the vertex set of this graph can be partitioned into two disjoint sets, the set of vertices representing employees and the set of vertices representing jobs, and each edge connects a vertex representing an employee to a vertex representing a job. Consequently, this graph is bipartite.

Some Applications of Special Types of Graphs To complete the project, we must assign jobs to the employees so that every job has an employee assigned to it and no employee is assigned more than one job. FIGURE 10 Modeling the Jobs for Which Employees Have Been Trained.

New Graphs from Old Definition 6: A subgraph of a graph G= (V, E) is a graph H =(W, F), where W  V and F  E. A subgraph H of G is a proper subgraph of G if H  G .

New Graphs from Old Example 17: The graph G shown below is a subgraph of K5. FIGURE 15 A Subgraph of K5.

New Graphs from Old Definition 7: The union of two simple graphs G1= (V1, E1) and G2= (V2, E2) is the simple graph with vertex set V1  V2 and edge set E1  E2 . The union of G1 and G2 is denoted by G1  G2 .

New Graphs from Old Example 18: Find the union of the graphs G1 and G2 shown in below. FIGURE 17 (a) The Simple Graphs G1 and G2; (b) Their Union G1∪G2.