Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Challenge 5: the Erdős–Hajnal property for the path PrP_rPr​

Definition
TenChallenges_Challenge_05

by utkuokur · Nov 4, 2026 · Mathlib 0df444a (Lean v4.33.1)

erdos-hajnalgraph-theorypathsten-challenges

The scaled form of Challenge 5. For a natural number rrr, EH(r)\mathrm{EH}(r)EH(r) is the Erdős–Hajnal property for the path PrP_rPr​ on rrr vertices:

∃ c>0  ∀G Pr-free finite:G has a clique or an independent set of size at least ∣V(G)∣c.\exists\,c>0\ \ \forall G\ P_r\text{-free finite}:\quad G \text{ has a clique or an independent set of size at least } |V(G)|^{c}.∃c>0  ∀G Pr​-free finite:G has a clique or an independent set of size at least ∣V(G)∣c.

Known rungs: r≤4r\le 4r≤4 (exercises and cographs) and r=5r=5r=5 (Nguyen, Scott, Seymour); r=6r=6r=6 is open.

Formalization Note. PrP_rPr​ is Mathlib's pathGraph r on Fin r; for r≤1r\le 1r≤1 the path is contained in almost every graph, so those rungs are degenerate.

Definition code
import Definitions.Def_TenChallenges_ErdosHajnal

open SimpleGraph

namespace TenChallenges

/-- The Erdős–Hajnal conjecture for the path graph `Pᵣ`, at parameter `r`. -/
def statement_05 (r : ℕ) : Prop :=
  ErdosHajnalConjectureFor (pathGraph r)

end TenChallenges
Source
Ten Challenges repository, file Challenges/challenge_05.lean (commit ff14a56), https://github.com/TenChallenges/ten-challenges/blob/main/Challenges/challenge_05.lean; V. Bajpai, N. Bowler, J. Carmesin, U. Okur, 10 Scalable Challenges in Combinatorics, AI4Math @ CICM 2026, challenge 5.
Read-back

What the Lean code literally says, in plain math · claude-fable-5-1

Read-back of the definition TenChallenges.statement_05.

For a natural number r∈{0,1,2,… }r \in \{0, 1, 2, \dots\}r∈{0,1,2,…}, the proposition statement_05(r)\mathrm{statement\_05}(r)statement_05(r) is defined as ErdosHajnalConjectureFor(Pr)\mathrm{ErdosHajnalConjectureFor}(P_r)ErdosHajnalConjectureFor(Pr​), where PrP_rPr​ is Mathlib's path graph on rrr vertices: its vertex set is {0,1,…,r−1}\{0, 1, \dots, r-1\}{0,1,…,r−1} (the type of natural numbers below rrr), and two vertices i,ji, ji,j are adjacent exactly when i+1=ji + 1 = ji+1=j or j+1=ij + 1 = ij+1=i (it is the Hasse diagram of the linear order on {0,…,r−1}\{0,\dots,r-1\}{0,…,r−1}, i.e. the graph of the covering relation). Thus PrP_rPr​ has rrr vertices and r−1r - 1r−1 edges for r≥1r \ge 1r≥1; it is indexed by its number of vertices, not edges. In particular P0P_0P0​ is the graph with no vertices, P1P_1P1​ is a single isolated vertex, P2P_2P2​ is a single edge, and P3P_3P3​ is a path with two edges.

Unfolding ErdosHajnalConjectureFor(Pr)\mathrm{ErdosHajnalConjectureFor}(P_r)ErdosHajnalConjectureFor(Pr​) in full, statement_05(r)\mathrm{statement\_05}(r)statement_05(r) asserts:

∃ c∈R:  0<c  ∧  ∀ V finite, ∀ G a simple graph on V:Pr⋬G  ⟹  ∃ s⊆V: (s is a clique of G  ∨  s is a clique of G‾)  ∧  ∣s∣≥∣V∣c.\exists\, c \in \mathbb{R}:\; 0 < c \;\wedge\; \forall\, V\ \text{finite},\ \forall\, G \text{ a simple graph on } V:\quad P_r \not\trianglelefteq G \;\Longrightarrow\; \exists\, s \subseteq V:\ \big(s \text{ is a clique of } G \;\vee\; s \text{ is a clique of } \overline{G}\big) \;\wedge\; |s| \ge |V|^{c}.∃c∈R:0<c∧∀V finite, ∀G a simple graph on V:Pr​⊴G⟹∃s⊆V: (s is a clique of G∨s is a clique of G)∧∣s∣≥∣V∣c.

Binder by binder:

  • ccc: there exists a real number ccc with 0<c0 < c0<c (strict, no upper bound); ccc may depend on rrr but is fixed before VVV and GGG are chosen, so one ccc must serve all V,GV, GV,G below.
  • VVV: for every type VVV in the lowest universe (ordinary sets) equipped with a finiteness structure, i.e. every finite vertex set, the empty set included.
  • GGG: for every simple graph GGG on VVV (irreflexive symmetric adjacency ∼G\sim_G∼G​).
  • Hypothesis Pr⋬GP_r \not\trianglelefteq GPr​⊴G: there is no graph embedding of PrP_rPr​ into GGG, where a graph embedding is an injective map f:{0,…,r−1}→Vf : \{0,\dots,r-1\} \to Vf:{0,…,r−1}→V with f(i)∼Gf(j)f(i) \sim_G f(j)f(i)∼G​f(j) if and only if ∣i−j∣=1|i - j| = 1∣i−j∣=1, for all i,ji, ji,j. Concretely: GGG does not contain rrr distinct vertices v0,…,vr−1v_0, \dots, v_{r-1}v0​,…,vr−1​ such that vi∼Gvi+1v_i \sim_G v_{i+1}vi​∼G​vi+1​ for all 0≤i≤r−20 \le i \le r-20≤i≤r−2 and vi̸∼Gvjv_i \not\sim_G v_jvi​∼G​vj​ whenever ∣i−j∣≥2|i - j| \ge 2∣i−j∣≥2. That is, GGG has no induced path on rrr vertices (no chordless path with rrr vertices). A path on rrr vertices that carries extra edges (chords) among its vertices is not excluded by the hypothesis.
  • Conclusion: there exists a finite set sss of vertices (possibly empty) such that either every two distinct elements of sss are adjacent in GGG (sss is a clique of GGG), or every two distinct elements of sss are non-adjacent in GGG (sss is a clique of the complement G‾\overline{G}G, whose adjacency is "u≠vu \ne vu=v and u̸∼Gvu \not\sim_G vu∼G​v", i.e. sss is an independent set of GGG); and, as real numbers,
∣s∣≥∣V∣c,|s| \ge |V|^{c},∣s∣≥∣V∣c,

with ∣s∣|s|∣s∣ the number of elements of sss, ∣V∣|V|∣V∣ the number of vertices of GGG, non-strict inequality, and xcx^{c}xc the real power (ecln⁡xe^{c \ln x}eclnx for x>0x > 0x>0; 0c=00^{c} = 00c=0 since c>0c > 0c>0).

Degenerate values of rrr and other edge cases:

  • r=0r = 0r=0: P0P_0P0​ has no vertices, so the empty map embeds P0P_0P0​ into every GGG; the hypothesis P0⋬GP_0 \not\trianglelefteq GP0​⊴G is never satisfied and the universal part holds vacuously; statement_05(0)\mathrm{statement\_05}(0)statement_05(0) reduces to "there exists a real c>0c > 0c>0", which is true.
  • r=1r = 1r=1: P1P_1P1​ is one vertex, which embeds into GGG exactly when V≠∅V \ne \varnothingV=∅; so the hypothesis holds only for V=∅V = \varnothingV=∅, where ∣V∣c=0|V|^{c} = 0∣V∣c=0 and s=∅s = \varnothings=∅ (vacuously a clique of GGG and of G‾\overline{G}G) satisfies the conclusion.
  • r=2r = 2r=2: P2P_2P2​ is a single edge, which embeds into GGG exactly when GGG has at least one edge; so the hypothesis says GGG is edgeless, and then s=Vs = Vs=V is an independent set of size ∣V∣|V|∣V∣.
  • For any rrr: VVV may be empty (then ∣V∣c=0|V|^{c} = 0∣V∣c=0 and s=∅s = \varnothings=∅ works); s=∅s = \varnothings=∅ and singletons are vacuously both cliques and independent sets, so whenever ∣V∣c≤1|V|^{c} \le 1∣V∣c≤1 the conclusion is met trivially.
Human review
  • Endorsed by Shuze Chen · Nov 4, 2026

    Confirmed by the moderator at approval.

  • Endorsed by utkuokur · Nov 4, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me