21-Isomorphism & Connectivity

21-Isomorphism & Connectivity - EECS 210 Discrete...

This preview shows pages 1–11. Sign up to view the full content.

Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 1 EECS 210 Discrete Structures David O. Johnson Fall 2016

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Reminders Connect 5 due: 11:59 PM, Thursday, November 17 Thanksgiving Holiday, Thursday, November 24 – No Assignment! Homework 6 due: Thursday, December 1 at the beginning of your lecture Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 2
Any Questions? Isomorphism & Connectivity 3 David O. Johnson EECS 210 (Fall 2016)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Representing Graphs and Graph Isomorphism (Section 10.3) Adjacency Lists Adjacency Matrices Incidence Matrices Isomorphism of Graphs Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 4
Adjacency Lists Definition : An adjacency list can be used to represent a graph with no multiple edges by specifying the vertices that are adjacent to each vertex of the graph. Example : Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 5

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Adjacency Lists Definition : An adjacency list can be used to represent a graph with no multiple edges by specifying the vertices that are adjacent to each vertex of the graph. Example : Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 6
Adjacency Matrices Definition : Suppose that G = ( V , E ) is a simple graph where | V | = n . Arbitrarily list the vertices of G as v 1 , v 2 , … , v n . The adjacency matrix A G of G , with respect to the listing of vertices, is the n × n zero-one matrix with 1 as its ( i , j )th entry when v i and v j are adjacent, and 0 as its ( i , j )th entry when they are not adjacent. In other words, if the graphs adjacency matrix is: Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 7

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Adjacency Matrices Examples : Note : The adjacency matrix of a simple graph is symmetric, i.e., a ij = a ji Also, since there are no loops, each diagonal entry a ij for i = 1, 2, 3, …, n , is 0. When a graph is sparse, that is, it has few edges relatively to the total number of possible edges, it is much more efficient to represent the graph using an adjacency list than an adjacency matrix. But for a dense graph, which includes a high percentage of possible edges, an adjacency matrix is preferable. Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 8 a b c d a b c d a b c d a b c d
Adjacency Matrices Adjacency matrices can also be used to represent graphs with loops and multiple edges. A loop at the vertex v i is represented by a 1 at the ( i , j )th position of the matrix. When multiple edges connect the same pair of vertices v i and v j , (or if multiple loops are present at the same vertex), the ( i , j )th entry equals the number of edges connecting the pair of vertices. Example : We give the adjacency matrix of the pseudograph shown here using the ordering of vertices a , b , c , d . Isomorphism & Connectivity David O. Johnson EECS 210 (Fall 2016) 9 a b c d a b c d

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Adjacency Matrices In Section 9, when we were discussing relations, we used adjacency matrices to represent directed graphs (i.e., digraphs).
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern