# Determine if a set of graphs are isomorphic

I am trying to use adjacency matrices to show if the graphs are isomorphic. I have created the matrices but am finding it hard to interpret them to find a pair (or more) of isomorphic graphs for each A, B and C. I am comparing the matrices to see if they can be "rearranged" to look like another matrix. Is this a poor way to check if graphs are isomorphic??

Isn't graphs that are isomorphic able to be "redrawn" to look like each other? Would this make all graphs in A and B not possible to be isomorphic?

• Your assessment of parts (a) and (b) is correct. – Joffan Feb 20 '17 at 3:17
• Another question: Does each set of graphs have the same set of graph transformations to move between its graphs? – Jacob Wakem Feb 20 '17 at 3:19
• It is necessary but not sufficient for isomorphic graphs to have topologically isomorphic figures (representations). – Jacob Wakem Feb 20 '17 at 3:21
• @TomB Yes, adjacency matrices are usually a very poor way for humans to test for graph isomorphism. This is because in matrix terms, an isomorphism corresponds to a similarity transform by a permutation matrix. These are very difficult to eyeball since even the simplest permutation affects many matrix entries simultaneously in a visually unnatural way. Detecting a permutation that works just by looking at the matrix is already a challenge; visually testing that no permutation works would be maddening! – Erick Wong Feb 20 '17 at 5:34

The easiest way to show two graphs aren't isomorphic is to find a property of the graph that one has and the other doesn't. For example, consider the first row of graphs. The first graph has a chain of vertices in a line that have, in order, degree $1$, then $2$, then $3$. Neither of the other two graphs have this, so the first graph is different from the second two. The second graph has a vertex of degree three, while last graph doesn't have any vertices of degree $3$, so they are non-isomorphic as well.

To show that two graphs are isomorphic, you need to find an isomorphism between them. You're correct that in both the first two sets of graphs, all three graphs are non-isomorphic.

• All of the degrees of the last row of graphs are the same (3) and have the same number of vertices and edges. Does this make them all isomorphic to each other? – user418119 Feb 20 '17 at 3:19
• @TomB No! It is not enough for them to have some graph property shared, they must have ALL graph properties the same. – Jacob Wakem Feb 20 '17 at 3:22

Your assessment of parts (a) and (b) is correct. It sounds like you need some additional tools to describe the differences.

One tool is degree sequence, which simply lists the various degrees of the vertices in sorted order. If two graphs have a different degree sequence, they are not isomorphic. However two graphs that have the same degree sequence may or may not be isomorphic.

The only example here is the right-hand graph in part (a) has a different degree sequence to its counterparts, since it has no degree-3 vertex.

You can also check which vertex degrees are adjacent. So there is vertex of degree 3 in the left and centre graphs of part (a), but their adjacent vertices have degrees (2,2,1) and (2,1,1) respectively, so they are not isomorphic.

You can use similar tools to identify the graphs of part (b) as non-isomorphic.

In part (c), the graphs are all cubic (every vertex is degree 3) so you will need to think about the cycles that the vertices are part of, in particular the shortest cycle for each vertex. The right-hand graph is the famous Petersen graph.

At this point you may need to produce an explicit isomorphism. This consists of labelling the vertices and producing a mapping such that the corresponding vertices are connected in both graphs.

• Referring to part c: What do you mean by the cycles that the vertices are part of? Would the first graph not be isomorphic with the other two because of how the outer pentagon vertices connect to different vertices of the inner pentagon than the other two graphs? Does this help (or determine) that the last two graphs of row 3 are isomorphic? – user418119 Feb 20 '17 at 3:53
• Actually if you twist the inner pentagon of the left graph, keeping all connections the same, you will see that it is isomorphic to the centre graph. I added some words and a link on cycles but couldn't quickly find anything very good. – Joffan Feb 20 '17 at 4:20
• @TomB Cycle length is another graph invariant. If one graph has two cycles of length $3$ and one of length $5$, it must be different from a graph that has one cycle of length $3$ and two of length $5$. Like with degree sequences, you can also do more complicated arguments about combining cycles that are analogous to "this graph has a vertex of degree $5$ adjacent to a vertex of degree $3$" – Stella Biderman Feb 20 '17 at 4:23

To prove two graphs are not isomorphic, we can:

1. Choose a vertex invariant, i.e., a property of the vertices of graphs which remains unchanged by relabelling the vertices;

Figuring out which to choose is a bit of an art (and trial and error), but since the vertex degree, i.e., number of neighbors, seems ineffective in the later graphs in this case, maybe something slightly more complicated (e.g. the number of vertices at distance two) would be better.

2. Compute the vertex invariants for each vertex in each graph; and

3. If they have different multisets of entry invariants, they're not isomorphic.

To prove two graphs are isomorphic, we need to identify an isomorphism. To do this, we:

1. For one graph, $G$ say, we label the vertices distinctly $1,2,\ldots,n$;

2. For the other graph, $H$ say, we label them using $1,2,\ldots,n$, ensuring that vertices labelled $i$ and $j$ are neighbors if and only if they are neighbors in $G$;

3. The isomorphism is then "the vertex labeled $i$ in $G$ maps to the vertex labeled $i$ in $H$".