Download presentation

Presentation is loading. Please wait.

1
1 Section 8.2 Graph Terminology

2
2 Terms related to undirected graphs Adjacent: 2 vertices u & v in an undirected graph G are adjacent (neighbors) in G if there is an edge {u,v} Incident, connect: if edge e = {u,v}, e is incident with vertices u & v, and e connects u and v Endpoints: vertices u & v are endpoints of edge e

3
3 Terms related to undirected graphs Degree of vertex in an undirected graph is the number of edges incident with it –loops count twice –degree of vertex v is denoted deg(v) Example: what are the degrees of the vertices in this graph?

4
4 Terms related to undirected graphs Isolated vertex (like e in previous example) has degree 0, not adjacent to any other vertex Pendant vertex (like d in previous example) - adjacent to exactly one vertex The sum of the degrees of all vertices in a graph is exactly twice the number of edges in the graph

5
5 Handshaking Theorem Let G=(V,E) be an undirected graph with e edges; then 2e = Note that sum of degrees of vertices is always even; this leads to the theorem: An undirected graph has an even number of vertices of odd degree

6
6 Terminology related to directed graphs Let G be a directed graph, with an edge e=(u,v): –u is initial vertex –v is terminal, or end vertex –u is adjacent TO v –v is adjacent FROM u –initial & terminal vertex of a loop are the same

7
7 Terminology related to digraphs In-degree of vertex v, denoted deg - (v), is the number of edges with v as the terminal vertex Out-degree of vertex v, denoted deg + (v), is the number of edges with v as the initial vertex A loop has one of each

8
8 Terminology related to digraphs The sum of in-degrees is equal to the sum of out- degrees Both are equal to the number of edges in the graph: –Let G=(V,E) be a directed graph; then The undirected graph that results from ignoring arrows in a directed graph is called the underlying undirected graph

9
9 Classes of simple graphs Complete graphs: complete graph on n vertices, denoted K n, is the simple graph that contains exactly one edge between each pair of distinct vertices; Examples:

10
10 Classes of Simple Graphs Cycle: C n, where n 3, consists of n vertices v 1, v 2, …, v n and edges {v 1, v 2 }, {v 2, v 3 }, …, {v n-1, v n } Examples:

11
11 Classes of Simple Graphs Wheel: a cycle with an additional vertex, which is adjacent to all other vertices; example:

12
12 Classes of Simple Graphs n-Cube: denoted Q n, is a graph representing the 2 n bit strings of length n: 2 vertices are adjacent if and only if the bit strings they represent differ in exactly one position. Examples:

13
13 Bipartite Graphs A simple graph G is called bipartite if its vertex set V can be partitioned into 2 disjoint non-empty sets V 1 and V 2 such that: –every edge connects a vertex in V 1 with a vertex in V 2 –no edge connects 2 vertices in V 1 or in V 2

14
14 Example: lining up 1st graders CateJohn MaryMark Mary AnnTerry Mary PatTim MarieJimmy

15
15 Example - cycle C6 is bipartite; can partition its vertex set into 2 distinct sets: –V 1 = {v 1, v 3, v 5 ) –V 2 = {v 2, v 4, v 6 } –with every edge connecting a vertex in V 1 with one in V 2

16
16 Examples Graph at left is not bipartite; to divide into 2 sets, one set must include 2 vertices and to be bipartite, those vertices must not be connected But every vertex in this graph is connected to 2 others This graph, on the other hand, is bipartite; the two sets are V 1 = {v 1, v 3, v 5 } and V 2 = {v 2, v 4, v 6 } Note that the definition doesn’t say a vertex in one set can’t connect to more than one vertex in the other - only that each in one must connect to one in the other, and no vertex in a set can connect to a vertex in the same set

17
17 Examples: are they bipartite?

18
18 Complete Bipartite Graphs Denoted K m,n is the graph that has its vertex set partitioned into 2 subsets of m vertices and n vertices There is an edge between 2 vertices if and only if one vertex is in the first subset and the other is in the second subset

19
19 Examples

20
20 Applications of Special Types of Graphs: LAN topology A star is a complete bipartite K 1,n graph: A ring is an n-cycle: A redundant network may have both a central hub and a ring, forming a wheel:

21
21 Subgraph Graph obtained by removing vertices and their associated edges from a larger graph; more formally: Subgraph of G=(V,E) is H=(W,F) where W V and F E

22
22 Subgraph Example

23
23 Can combine graphs, forming a union Let G 1 = (V 1, E 1 ) and G 2 = (V 2, E 2 ) The union, G 1 G 2 = (V 1 V 2, E 1 E 2 )

24
24 Section 8.2 Graph Terminology

Similar presentations

© 2021 SlidePlayer.com Inc.

All rights reserved.

To make this website work, we log user data and share it with processors. To use this website, you must agree to our Privacy Policy, including cookie policy.

Ads by Google