A topic in the Open Knowledge Graph — a free, open map of 15,290 topics and the order to learn them in.

Degree Sequences and the Erdős–Gallai Theorem

Graduate Depth 67 in the knowledge graph ☐ I know this ☆ Set as goal
3topics build on this
284prerequisites beneath it
See this on the map →
Formal Definitions in Graph Theory→→Erdős-Gallai Theorem
degree-sequences graph-characterization theorems

Core Idea

A degree sequence is the ordered list of vertex degrees in a graph. Not every sequence of non-negative integers is graphical (realizable as a degree sequence). The Erdős–Gallai theorem provides a complete characterization: a sequence is graphical if and only if the sum is even and a specific inequality holds for each prefix.

How It's Best Learned

Start with the handshaking lemma and verify why all graphical sequences have even sum. Then apply the Erdős–Gallai criterion to both graphical and non-graphical sequences to see where it catches impossible cases.

Common Misconceptions

Explainer

From the formal definitions of graph theory, you know that the degree of a vertex is the number of edges incident to it. The degree sequence of a graph is the list of all vertex degrees arranged in non-increasing order. For example, a path on 4 vertices has degrees 1, 2, 2, 1 — degree sequence (2, 2, 1, 1). A complete graph K₄ has every vertex with degree 3 — degree sequence (3, 3, 3, 3). The degree sequence is a simple invariant: isomorphic graphs have the same degree sequence. But the converse is false — two non-isomorphic graphs can share a degree sequence. Despite this limitation, degree sequences reveal a surprising amount about a graph's structure.

The first necessary condition for a sequence to be graphical (realizable by some simple graph) comes from the handshaking lemma: the sum of all degrees equals twice the number of edges, so the sum must be even. The sequence (3, 3, 1) has sum 7, which is odd — impossible for any graph. But even-sum is not sufficient. The sequence (3, 3, 3, 1) has even sum 10, but can you draw it? Each of the three degree-3 vertices needs 3 neighbors, and the single degree-1 vertex can only serve as a neighbor once — you'll quickly run into trouble. The sequence is not graphical despite having an even sum.

The Erdős–Gallai theorem gives a complete characterization. Sort the sequence in non-increasing order as d₁ ≥ d₂ ≥ ⋯ ≥ dₙ. The sequence is graphical if and only if (1) the sum is even, and (2) for every k from 1 to n, the sum of the first k terms is at most k(k−1) plus the sum of min(dᵢ, k) for i from k+1 to n. The left side counts the degree "budget" of the k highest-degree vertices; the right side bounds how many edges they can actually have. The bound k(k−1) accounts for edges among the top-k vertices themselves; the sum accounts for edges from those vertices to the remaining n−k vertices. If this inequality is ever violated, the k highest-degree vertices simply cannot all be satisfied simultaneously.

A complementary tool is the Havel-Hakimi algorithm: repeatedly take the vertex of highest degree d, connect it to the next d vertices in the sorted list, remove it, and continue. If the sequence is graphical, this construction succeeds; if you ever need to connect to a vertex with degree 0, it fails. Havel-Hakimi is both an existence proof and a construction method. Together, Erdős–Gallai and Havel-Hakimi give you two perspectives on the same question: one tells you *whether* a sequence is graphical via inequalities, the other *constructs* a graph realizing it (if one exists).

Practice Questions 5 questions

Prerequisite Chain

Understanding Zero → The Number Zero → Counting to Five → Counting to 10 → Counting to 20 → Counting a Set of Objects Up to 20 → Cardinality: The Last Number Counted → Matching Numerals to Quantities → Subitizing Small Quantities → Addition Within 10 → Making 10 as an Addition Strategy → Addition Within 20 → Doubles and Near Doubles → Doubles Facts Within 10 → Near Doubles Facts Within 20 → Mental Math Strategies for Addition → Mental Math: Adding and Subtracting Tens → Addition Within 100 → Repeated Addition as Multiplication → Multiplication as Equal Groups → Multiplication: Arrays → Basic Multiplication Facts Through 10 → Multiplication Facts Within 100 → Division as Equal Sharing → Division as Grouping (Measurement Division) → Division: Grouping (Repeated Subtraction) Model → Division: Fair Sharing Model → Division as Equal Sharing → Division as Grouping → Basic Division Facts → Division Facts Within 100 → Multiplication and Division Fact Families → Relationship Between Multiplication and Division → Division Facts as Inverse of Multiplication → Remainders and Quotients in Division → Division Word Problems → Multi-Step Word Problems → Solving Multi-Step Word Problems → Multiplication Word Problems → Division Word Problems → Introduction to Long Division → Factors and Multiples → Prime and Composite Numbers → Equivalent Fractions → Relating Fractions and Decimals → Decimal Place Value → Integers and the Number Line → Opposites and Additive Inverses → Absolute Value → Adding Integers → Subtracting Integers → Multiplying Integers → Introduction to Exponents → Order of Operations → Integer Order of Operations → Variable Expressions → The Distributive Property → Variables and Expressions Review → Introduction to Polynomials → Adding and Subtracting Polynomials → Multiplying Polynomials → Factorial → Permutations → Combinations → Counting Principles: Addition and Multiplication Rules → Introduction to Graph Theory → Formal Definitions in Graph Theory → Degree Sequences and the Erdős–Gallai Theorem

Longest path: 68 steps · 284 total prerequisite topics

Prerequisites (1)

Leads To (1)