Planarity and Euler Formula
Planarity asks whether a graph can be drawn in the plane without edge crossings. This is not a question about the first drawing we happen to see; it is a question about whether some crossing-free drawing exists. A graph with a messy drawing may still be planar, while and remain nonplanar no matter how cleverly they are redrawn.
Euler's formula is the main counting tool for plane graphs. It connects vertices, edges, and faces, and it gives quick proofs that certain dense graphs cannot be planar. Wilson's treatment uses this formula as the bridge from intuitive drawings to structural obstructions such as and .
Definitions
A graph is planar if it has a drawing in the plane with no edge crossings except at common endpoints. A particular crossing-free drawing is a plane graph. The connected regions into which a plane graph divides the plane are its faces, including the unbounded outer face.
A plane embedding is the combinatorial information of a crossing-free drawing, especially the cyclic order of edges around each vertex and the boundary walks of faces.
A graph is a subdivision of a graph if it is obtained by replacing edges of with internally vertex-disjoint paths. Two graphs are homeomorphic if they have isomorphic subdivisions.
The complete graph and the complete bipartite graph are the classical minimal nonplanar graphs in Kuratowski's theorem.
Key results
Euler's formula. If is a connected plane graph with vertices, edges, and faces, then
Proof sketch: if is a tree, then and , so the formula holds. If has a cycle, delete one edge from a cycle. This keeps the graph connected and reduces both and by , preserving . Repeat until a tree remains.
Planar edge bound. If is a simple planar graph with , then
Reason: every face has boundary length at least , and each edge is counted twice across all face boundaries. Hence . Substitute into Euler's formula.
Bipartite planar edge bound. If is simple, planar, bipartite, and , then
Every face has boundary length at least because bipartite graphs have no odd cycles.
Kuratowski's theorem. A finite graph is planar if and only if it contains no subgraph homeomorphic to or .
Maximal planar graphs. A simple planar graph with is maximal planar if no further edge can be added without destroying planarity. In a maximal planar graph, every face is triangular, and the edge bound is tight:
This is a useful diagnostic. If a simple planar drawing has a face with boundary length at least and two nonadjacent vertices on that face, an edge can often be added inside the face. Maximality fails unless every possible such chord is already present or would violate simplicity.
Subdivisions preserve planarity. Replacing an edge by a path does not change the essential crossing behavior. If a graph is planar, every subdivision is planar. If a subdivision of or appears inside a graph, the larger graph is nonplanar by Kuratowski's theorem. This is why planarity proofs often search for stretched versions of the two forbidden graphs rather than exact copies.
Face-bound variants. The inequality is only the first member of a family. If a simple plane graph has girth , meaning its shortest cycle has length , then every face boundary has length at least when bridges are absent and the graph is connected enough for the usual counting argument. Counting edge-face incidences gives
Together with Euler's formula, this gives
For bipartite planar graphs the girth is at least , so this recovers . For triangle-free planar graphs the same inequality is often the main tool.
Planarity algorithms. The theorems above are structural, but practical planarity testing is algorithmic. Modern planarity algorithms can decide planarity in linear time and, when the graph is planar, produce an embedding. For hand calculations, however, Euler bounds, subdivisions of and , and constructive drawings remain the most useful tools.
Visual
The wheel is planar. Its center connects to all four vertices of an outer cycle, producing four triangular inner faces and one outer face.
| Graph | Planarity test by edge bound | ||
|---|---|---|---|
| 5 | 10 | violates | |
| 6 | 9 | violates bipartite bound | |
| 5 | 8 | satisfies | |
| Cube graph | 8 | 12 | satisfies and is planar |
Worked example 1: Count faces in a planar drawing
Problem. The wheel has an outer cycle on four vertices and one center joined to all outer vertices. Use Euler's formula to find the number of faces.
Method.
- Count vertices: four outer vertices plus one center gives
- Count edges: the outer cycle has edges, and the center has spokes, so
- Euler's formula gives
- Substitute:
- Solve:
Checked answer. has faces in this plane drawing: four bounded triangular faces and one unbounded outer face.
Worked example 2: Prove is nonplanar by counting
Problem. Show that is not planar.
Method.
- has vertices.
- It has edges.
- It is bipartite, so it contains no odd cycle.
- If were planar, every face boundary would have length at least .
- Counting face-edge incidences gives
so
- Euler's formula says
- The face bound says
so
Since must be an integer, , contradicting .
Checked answer. is nonplanar.
The contradiction used the stronger bipartite face bound, not just the ordinary planar edge bound. The ordinary bound gives , which says nothing. Recognizing that has no triangles is the key step because it raises the minimum face boundary length from to .
Code
This code checks the two standard edge-count obstructions. Passing these tests does not prove planarity; failing one proves nonplanarity under the stated hypotheses.
def planar_edge_obstruction(n, m, bipartite=False):
if n < 3:
return False
if bipartite:
return m > 2 * n - 4
return m > 3 * n - 6
print(planar_edge_obstruction(5, 10)) # K5
print(planar_edge_obstruction(6, 9, True)) # K3,3
print(planar_edge_obstruction(8, 12)) # cube passes this test
def faces_if_connected_plane(n, m):
return 2 - n + m
print(faces_if_connected_plane(5, 8)) # W5
The code intentionally reports only obstructions from edge counts. A result of False means "this particular counting test did not disprove planarity," not "the graph is planar." To prove planarity constructively, give a crossing-free drawing or an embedding. To prove nonplanarity when the count does not suffice, look for a subdivision of or , or use a planarity-testing algorithm.
When doing hand problems, keep the proof type explicit. A planar proof is usually a drawing plus a face count. A nonplanar proof is usually a contradiction from Euler's formula or an identified forbidden subdivision. Mixing the two styles often leads to statements that are visually convincing but not logically complete.
One final check is to compare all available information, not just one inequality. Count vertices and edges, ask whether the graph is bipartite, look for triangles, and inspect whether a known nonplanar graph appears after suppressing degree- subdivision vertices. Planarity arguments become much more reliable when the counting evidence and the structural obstruction point in the same direction.
State the hypotheses beside each inequality so the reader can see exactly why the bound applies.
For example, write "simple, planar, bipartite" before using ; omitting any one of those words changes the conclusion.
A reliable planarity solution usually contains both a local and a global check. The local check identifies face lengths, bipartiteness, or a forbidden subdivision. The global check applies Euler's formula or an edge bound. If the graph is claimed planar, the drawing should make the face count visible. If it is claimed nonplanar, the contradiction should state exactly which hypothesis fails.
Common pitfalls
- Treating a drawing with crossings as proof of nonplanarity. You must rule out every possible drawing.
- Forgetting the outer face in Euler's formula.
- Applying to graphs with loops or multiple edges without checking hypotheses.
- Using the bipartite bound on a graph that is not bipartite.
- Thinking the edge bound is sufficient. Many nonplanar graphs satisfy .
- Writing Euler's formula as for connected plane graphs. The planar connected formula is .