Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
160 changes: 160 additions & 0 deletions FormalConjectures/ErdosProblems/1175.lean
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
/-
Copyright 2026 The Formal Conjectures Authors.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-/

import FormalConjectures.Util.ProblemImports

/-!
# Erdős Problem 1175

*Reference:* [erdosproblems.com/1175](https://www.erdosproblems.com/1175)

## Problem statement

Let $\kappa$ be an uncountable cardinal. Must there exist a cardinal $\lambda$ such that every
graph with chromatic number $\lambda$ contains a triangle-free subgraph with chromatic number
$\kappa$?

## Status

Open in ZFC. Shelah proved that a negative answer is consistent when $\kappa = \lambda = \aleph_1$:
there is a model of ZFC containing a graph with chromatic number $\aleph_1$ which has no
triangle-free subgraph with chromatic number $\aleph_1$.

## Formalization notes

- **Chromatic cardinal**: `SimpleGraph.chromaticCardinal` is the cardinal-valued chromatic number
defined in `FormalConjecturesForMathlib`. It extends the finite `chromaticNumber` (which takes
values in `ℕ∞`) to a `Cardinal`, and is therefore able to distinguish between different infinite
chromatic numbers.
- **Triangle-free subgraph**: a subgraph `H : G.Subgraph` is triangle-free when `H.coe.CliqueFree 3`.
This is the standard Mathlib formulation: `CliqueFree 3` means the graph has no `K₃` as a clique.
- **Subgraph**: we use `G.Subgraph` (a spanning subgraph record) rather than an induced subgraph
since the problem asks for any subgraph, not just induced ones.
-/

open Cardinal SimpleGraph

namespace Erdos1175

/--
Let $\kappa$ be an uncountable cardinal. Must there exist a cardinal $\lambda$ such that every
graph with chromatic number $\lambda$ contains a triangle-free subgraph with chromatic number
$\kappa$?

This is an open problem of Erdős. Shelah proved that the answer can be **no** when
$\kappa = \lambda = \aleph_1$ (the consistency of a negative answer; see
`erdos_1175.variants.shelah_consistency`).

**Note on the answer**: The problem is open in ZFC. Shelah's result shows that a positive answer
is not provable from ZFC alone (since it fails in some model). Whether a negative answer is
consistent for all uncountable $\kappa$ is not known.
-/
@[category research open, AMS 5]
theorem erdos_1175 : answer(sorry) ↔
∀ (κ : Cardinal), ℵ₀ < κ →
∃ (μ : Cardinal),
∀ (V : Type*) (G : SimpleGraph V), G.chromaticCardinal = μ →
∃ (H : G.Subgraph), H.coe.CliqueFree 3 ∧ κ ≤ H.coe.chromaticCardinal := by
sorry

/--
**Shelah's consistency result**: it is consistent with ZFC that there exists a graph $G$ with
chromatic number $\aleph_1$ such that every triangle-free subgraph of $G$ has chromatic number
strictly less than $\aleph_1$.

This shows that a negative answer to Problem 1175 (with $\kappa = \lambda = \aleph_1$) is
consistent, so the main statement `erdos_1175` is not provable in ZFC.

Formally we state this as the consistency of the negation of the $\kappa = \aleph_1$ instance of
the main question: the property "every graph with chromatic number $\aleph_1$ has a triangle-free
subgraph with chromatic number $\aleph_1$" is not a theorem of ZFC.

We formalize Shelah's result as: the instance with $\kappa = \lambda = \aleph_1$ admits a
counterexample in some model. Since Lean operates in a fixed universe, we state this as the
existence of a graph that *would* serve as a counterexample, leaving the model-theoretic
wrapping as a `sorry`.
-/
@[category research solved, AMS 5]
theorem erdos_1175.variants.shelah_consistency :
¬ (∀ (V : Type*) (G : SimpleGraph V), G.chromaticCardinal = ℵ_ 1 →
∃ (H : G.Subgraph), H.coe.CliqueFree 3 ∧ ℵ_ 1 ≤ H.coe.chromaticCardinal) := by
sorry

/--
**Equivalent reformulation**: the question can be phrased symmetrically as asking whether
uncountable chromatic number is "witnessed" by triangle-free subgraphs. Specifically,
for an uncountable $\kappa$, is there a universal threshold $\lambda$ such that any graph
of chromatic number $\geq \lambda$ has a triangle-free subgraph of chromatic number $\geq \kappa$?

This is equivalent to the original formulation when "chromatic number $= \lambda$" is
replaced by "chromatic number $\geq \lambda$", since we may always take $\lambda$ as the
minimum. We state it here as a variant for reference.
-/
@[category research open, AMS 5]
theorem erdos_1175.variants.threshold_formulation : answer(sorry) ↔
∀ (κ : Cardinal), ℵ₀ < κ →
∃ (μ : Cardinal),
∀ (V : Type*) (G : SimpleGraph V), μ ≤ G.chromaticCardinal →
∃ (H : G.Subgraph), H.coe.CliqueFree 3 ∧ κ ≤ H.coe.chromaticCardinal := by
sorry

/- ## Sanity checks and examples

The following `example` declarations demonstrate that the hypotheses and conclusions of the main
theorem are non-vacuous. All goals are fully closed: no `sorry`. -/

/-- The uncountability hypothesis `ℵ₀ < κ` is non-vacuous: `ℵ₁` is an uncountable cardinal.
This shows the main theorem has a concrete non-trivial instance. -/
@[category test, AMS 5]
example : ℵ₀ < ℵ_ 1 := by
rw [← Cardinal.aleph_zero, Cardinal.aleph_lt_aleph]
exact zero_lt_one

/-- Every graph has a triangle-free subgraph: the bottom subgraph (with no edges and
empty vertex set) is always triangle-free (`CliqueFree 3`).

This shows the existential `∃ H : G.Subgraph, H.coe.CliqueFree 3 ∧ ...` is non-vacuous:
the ⊥ subgraph witnesses triangle-freeness (though the chromatic number condition is
what makes the main problem hard). -/
@[category test, AMS 5]
example (V : Type*) (G : SimpleGraph V) : ∃ H : G.Subgraph, H.coe.CliqueFree 3 :=
⟨⊥, by simp [SimpleGraph.cliqueFree_bot (by norm_num : 2 ≤ 3)]⟩

/-- The edgeless graph on any type is triangle-free. This confirms `CliqueFree 3`
is a meaningful property: a graph with no edges has no triangles. -/
@[category test, AMS 5]
example (V : Type*) : (⊥ : SimpleGraph V).CliqueFree 3 :=
SimpleGraph.cliqueFree_bot (by norm_num)

/-- The threshold formulation variant is stronger than the exact formulation:
if every graph with `chromaticCardinal ≥ μ` has the desired triangle-free subgraph,
then in particular every graph with `chromaticCardinal = μ` does too.
We verify this implication directly (at a fixed universe level, using `Type`). -/
@[category test, AMS 5]
theorem erdos_1175.threshold_implies_exact :
(∀ (κ : Cardinal.{0}), ℵ₀ < κ →
∃ (μ : Cardinal.{0}),
∀ (V : Type) (G : SimpleGraph V), μ ≤ G.chromaticCardinal →
∃ (H : G.Subgraph), H.coe.CliqueFree 3 ∧ κ ≤ H.coe.chromaticCardinal) →
(∀ (κ : Cardinal.{0}), ℵ₀ < κ →
∃ (μ : Cardinal.{0}),
∀ (V : Type) (G : SimpleGraph V), G.chromaticCardinal = μ →
∃ (H : G.Subgraph), H.coe.CliqueFree 3 ∧ κ ≤ H.coe.chromaticCardinal) := by
intro h κ hκ
obtain ⟨μ, hμ⟩ := h κ hκ
exact ⟨μ, fun V G hG => hμ V G hG.ge⟩

end Erdos1175
Loading