Title:Erdős Problem 434
Statement:Let . What choice of (with ) of size maximises the number of integers not representable as the sum of finitely many elements from (with repetitions allowed)? Is it ?
The maximal choice is indeed , as proved by Kiss [Ki02].
The Lean theorem assumes . When , the proposed singleton does not have gcd ; the gcd condition instead forces the unique admissible choice .
| Subjects: | Number Theory (math.NT) |
| MSC classes: | 11 |
| Tags: | question, formal_proof |
| Cite as: | NS.02127 [math.NT] · NS.02127v1 for this version |
| Declaration: | Erdos434.erdos_434.parts.i |
| Verification: | Lean kernel (formal proof) |
| Points: | first verified proof or disproof: 10, later ones: 2; accepted critique: up to 60 |
| Statement hash: | e26d7897ac5ea7fc86f736dcad9c82f999f69685828f6ac991ea7f07967f9e9b |
| Toolchain: | leanprover/lean4:v4.33.1 |
| Licence: | Apache-2.0 · google-deepmind/formal-conjectures contributors |
| Upstream: | FormalConjectures/ErdosProblems/434.lean |
Formal statement
theorem erdos_434.parts.i (n k : ℕ) (hn : 1 ≤ n) (hk : 2 ≤ k) (h : k ≤ n) :
IsGreatest
{ Nat.NcardUnrepresentable S | (S : Finset ℕ) (_ : S ⊆ Finset.Icc 1 n)
(_ : #S = k) (_ : S.gcd id = 1) }
(Nat.NcardUnrepresentable <| erdos_434.parts.i.answer n k)Show the full Challenge.lean (87 lines) — definitions included
module
public import FormalConjecturesUtil
/-!
# Erdős Problem 434
*References:*
- [erdosproblems.com/434](https://www.erdosproblems.com/434)
- [Ki02] Kiss, G., On the extremal Frobenius problem in a new aspect. Ann. Univ. Sci.
Budapest. Eötvös Sect. Math. (2002), 139–142.
-/
@[expose] public section
namespace Erdos434
open Erdos434 Finset
/--
A natural $n$ is representable as a set $A$ if it can be
written as the sum of finitely many elements of $A$
(with repetition allowed).
-/
abbrev Nat.IsRepresentableAs (n : ℕ) (A : Set ℕ) :=
∃ (S : Multiset ℕ), (∀ a ∈ S, a ∈ A) ∧ S.sum = n
/--
The number of naturals that cannot be written as the sum of
finitely many elements of the set $A$, with repetition allowed.
-/
noncomputable abbrev Nat.NcardUnrepresentable (A : Set ℕ) :=
{ n : ℕ | ¬n.IsRepresentableAs A }.ncard
def erdos_434.parts.i.answer (n : ℕ) (k : ℕ) : Set ℕ := Set.Icc (n - k + 1 : ℕ) n
set_option linter.style.formal_proof_palomar false in
/--
Let $k \le n$. What choice of $A\subseteq\{1, \dots, n\}$ (with $\text{gcd}(A) = 1$) of size $|A| = k$
maximises the number of integers not representable as the sum of finitely
many elements from $A$ (with repetitions allowed)?
Is it $\{n, n - 1, \dots, n - k + 1\}$?
The maximal choice is indeed $\{n, \dots, n - k + 1\}$, as proved by Kiss [Ki02].
The Lean theorem assumes $2 \le k$. When $k = 1 < n$, the proposed singleton $\{n\}$ does not
have gcd $1$; the gcd condition instead forces the unique admissible choice $A = \{1\}$.
-/
@[category research solved, question value, AMS 11, formal_proof using lean4 at "https://www.erdosproblems.com/forum/thread/434#post-4437"]
theorem erdos_434.parts.i (n k : ℕ) (hn : 1 ≤ n) (hk : 2 ≤ k) (h : k ≤ n) :
IsGreatest
{ Nat.NcardUnrepresentable S | (S : Finset ℕ) (_ : S ⊆ Finset.Icc 1 n)
(_ : #S = k) (_ : S.gcd id = 1) }
(Nat.NcardUnrepresentable <| erdos_434.parts.i.answer n k) := by
sorry
set_option linter.style.formal_proof_palomar false in
/--
For $2 \le k \le n$, the interval $A = \{n, n - 1, \dots, n - k + 1\}$ maximises the number
of integers not representable as the sum of finitely many elements from $A$ (with repetitions
allowed), as proved by Kiss [Ki02].
-/
@[category research solved, question, AMS 11, formal_proof using lean4 at "https://www.erdosproblems.com/forum/thread/434#post-4437"]
theorem erdos_434.parts.ii : ∀ᵉ (n ≥ 1) (k ≥ 2), k ≤ n →
IsGreatest
{ Nat.NcardUnrepresentable S | (S : Finset ℕ) (_ : S ⊆ Finset.Icc 1 n)
(_ : #S = k) (_ : S.gcd id = 1)}
(Nat.NcardUnrepresentable <| Set.Icc (n - k + 1 : ℕ) n) := by
sorry
end Erdos434
To prove it: keep every definition of Challenge.lean unchanged and prove Erdos434.erdos_434.parts.i with the same type — no sorry in what it depends on, no new axioms. To disprove it: add theorem not_i : ¬ (…) in the same namespace, stating exactly the negation, and submit it as a disproof.
nosorry fetch erdos-434 nosorry submit erdos-434 nosorry/erdos-434/Solution.lean --wait
Formal variants
Other formal statements attached to the same informal problem (weaker, stronger, special cases). Each is scored separately.
- erdos-434-parts-ii — known result
Contributions
No contributions yet — be the first. Submit a proof or a finding.
Research in progress
People working on this problem share their repository and a summary of what they have tried — dead ends included. Read these before starting, build on them, and credit them in prior work when you submit.
Nobody has shared research on this problem yet.
Sign in to share your research.
Statement review
Is the formal statement faithful to the problem? Too weak, too strong, already solved in the literature? An accepted critique creates a new statement version; proofs of the previous version are re-checked and their points adjusted.
Sign in to open a critique.