Ramsey numbers of graphs #
The Ramsey number R(k, l) is the least n such that every simple graph on n vertices has a
clique of size k or an independent set of size l. A graph on Fin n is the same thing as a
red/blue colouring of the edges of the complete graph K_n (red edges are the adjacencies), so this
is the classical two-colour Ramsey number.
The upper bound is the induction of Erdős and Szekeres. To find an (a + 2)-clique or a
(b + 1)-independent set in a set of C(a + b + 1, a + 1) vertices, fix a vertex v: it has at
least C(a + b, a) neighbours or at least C(a + b, a + 1) non-neighbours in the set. An
(a + 1)-clique among the neighbours, or a b-independent set among the non-neighbours, extends
by v. Hence R(a + 1, b + 1) ≤ C(a + b, a), that is R(k, l) ≤ C(k + l - 2, k - 1) for
k, l ≥ 1, and R(k, k) ≤ 4 ^ (k - 1) [ErdosSzekeres1935, pp. 466–467].
Main definitions #
SimpleGraph.ramseyNumber k l: the Ramsey numberR(k, l).
Main results #
SimpleGraph.exists_isNClique_or_isNIndepSet_of_choose_le: every set of at leastC(a + b, a)vertices contains an(a + 1)-clique or a(b + 1)-independent set.SimpleGraph.ramseyNumber_le_card_iff,SimpleGraph.card_lt_ramseyNumber_iff: the Ramsey number in terms of graphs on an arbitrary finite vertex type.SimpleGraph.ramseyNumber_comm:R(k, l) = R(l, k).SimpleGraph.ramseyNumber_succ_succ_le:R(a + 1, b + 1) ≤ C(a + b, a).SimpleGraph.ramseyNumber_le_four_pow:R(k, k) ≤ 4 ^ (k - 1).
References #
Erdős–Szekeres: in any graph, every set of at least C(a + b, a) vertices contains a
clique of size a + 1 or an independent set of size b + 1 [ErdosSzekeres1935, pp. 466–467].
The Ramsey number R(k, l): the least n such that every simple graph on Fin n has a
clique of size k or an independent set of size l. Equivalently, every red/blue colouring of the
edges of K_n has a red K_k or a blue K_l. The set of such n is nonempty by
SimpleGraph.exists_isNClique_or_isNIndepSet_of_choose_le, so the infimum is attained, and
SimpleGraph.ramseyNumber_le_card_iff characterizes it on every finite vertex type.
R(k, l) ≤ |V| exactly when every graph on V has a k-clique or an l-independent set.
|V| < R(k, l) exactly when some graph on V has no k-clique and no l-independent set.
This is how lower bounds on Ramsey numbers are proved.
A graph with at least R(k, l) vertices has a k-clique or an l-independent set.
Ramsey numbers are symmetric: pass to the complement graph.
Erdős–Szekeres: R(a + 1, b + 1) ≤ C(a + b, a), that is, R(k, l) ≤ C(k + l - 2, k - 1)
for k, l ≥ 1 [ErdosSzekeres1935, pp. 466–467].
The diagonal upper bound R(k, k) ≤ C(2k - 2, k - 1) ≤ 4 ^ (k - 1).