Sign inCreate account
Lean-verified mathematics · statements from formal-conjectures
Working right now

Loading…

[Imported from formal-conjectures on 23 Nov 2026]

Title:Erdős Problem 1179

Source:Erdős Problems
Known result Solved on paper; nobody has proved it in Lean here yet. First verified proof: +10 points.
Statement:reviewed
Statement:

Let 0<ϵ<10<\epsilon<1 and let gϵ(N)g_\epsilon(N) be the minimal kk such that if GG is an abelian group of size NN and A⊆GA\subseteq G is a uniformly random subset of size kk, and FA(g)=#{S⊆A:g=∑x∈Sx},F_A(g) = \#\left\{ S\subseteq A : g = \sum_{x\in S}x\right\}, then, with probability →1\to 1 as N→∞N\to \infty, ∣FA(g)−2kN∣≤ϵ2kN\left\lvert F_A(g)-\frac{2^k}{N}\right\rvert \leq \epsilon \frac{2^k}{N} for all g∈Gg\in G.

Estimate gϵ(N)g_\epsilon(N) - in particular, is it true that for all ϵ>0\epsilon>0 gϵ(N)=(1+oϵ(1))log⁡2N?g_\epsilon(N)=(1+o_\epsilon(1))\log_2N?

It is trivial that gϵ(N)≥log⁡2Ng_\epsilon(N)\geq \log_2N for all 0<ϵ<10<\epsilon<1. Erdős and Rényi [ErRe65] proved that for all 0<ϵ<10<\epsilon<1, gϵ(N)≤(2+o(1))log⁡2N+Oϵ(1)g_\epsilon(N) \leq (2+o(1))\log_2N+O_\epsilon(1). Erdős and Hall [ErHa76] proved that, for all 0<ϵ<10<\epsilon<1, gϵ(N)≤(1+Oϵ(log⁡log⁡log⁡Nlog⁡log⁡N))log⁡2N.g_\epsilon(N)\leq \left(1+O_\epsilon\left(\frac{\log\log\log N}{\log\log N}\right)\right) \log_2N.

The upper bound gϵ(N)≤(1+o(1))log⁡2Ng_\epsilon(N)\leq (1+o(1))\log_2 N is formalised as: there is a choice of sizes k(N)=(1+o(1))log⁡2Nk(N) = (1+o(1))\log_2 N such that, along any sequence of abelian groups with ∣G∣→∞|G|\to\infty, the probability that a random k(∣G∣)k(|G|)-subset is ϵ\epsilon-balanced tends to 11. The matching lower bound is erdos_1179.variants.lower_bound.

See also 543.

Subjects:Combinatorics (math.CO); Number Theory (math.NT)
MSC classes:05, 11
Tags:question, formal_proof
Cite as:NS.00884 [math.CO] · NS.00884v1 for this version
Declaration:Erdos1179.erdos_1179
Verification:Lean kernel (formal proof)
Points:first verified proof or disproof: 10, later ones: 2; accepted critique: up to 60
Statement hash:122c313ee6c1647c9fd18a7c5a20997a5807d852d5586cd1e77a9f02d74ac7ce
Toolchain:leanprover/lean4:v4.33.1
Licence:Apache-2.0 · google-deepmind/formal-conjectures contributors
Upstream:FormalConjectures/ErdosProblems/1179.lean

Formal statement

theorem erdos_1179 : ∀ ε : ℝ, 0 < ε → ε < 1 → ∃ k : ℕ → ℕ,
    Tendsto (fun N : ℕ ↦ (k N : ℝ) / Real.logb 2 N) atTop (nhds 1) ∧
      ∀ (G : ℕ → Type) [∀ i, AddCommGroup (G i)] [∀ i, Fintype (G i)],
        Tendsto (fun i ↦ Fintype.card (G i)) atTop atTop →
          Tendsto (fun i ↦ successProbability (G i) ε (k (Fintype.card (G i)))) atTop
            (nhds 1)
Show the full Challenge.lean (104 lines) — definitions included
module

public import FormalConjecturesUtil

/-!
# Erdős Problem 1179

*References:*
- [erdosproblems.com/1179](https://www.erdosproblems.com/1179)
- [Er73] Erdős, P., *Problems and results on combinatorial number theory*. A survey of
  combinatorial theory (Proc. Internat. Sympos., Colorado State Univ., Fort Collins, Colo., 1971)
  (1973), 117-138.
- [ErRe65] Erdős, P. and Rényi, A., *Probabilistic methods in group theory*. J. Analyse Math.
  (1965), 127-138.
- [ErHa76] Erdős, P. and Hall, R. R., *Probabilistic methods in group theory. II*. Houston J.
  Math. (1976), 173-180.
-/

@[expose] public section

open Filter Finset

namespace Erdos1179

variable {G : Type*} [AddCommGroup G] [Fintype G]

open scoped Classical in
/-- $F_A(g) = \#\{ S\subseteq A : g = \sum_{x\in S}x\}$. -/
noncomputable def repCount (A : Finset G) (g : G) : ℕ :=
  (A.powerset.filter fun S ↦ ∑ x ∈ S, x = g).card

/-- `A` is `ε`-balanced: $\lvert F_A(g)-2^{|A|}/N\rvert \leq \epsilon 2^{|A|}/N$ for all `g`. -/
def IsBalanced (ε : ℝ) (A : Finset G) : Prop :=
  ∀ g : G, |(repCount A g : ℝ) - 2 ^ A.card / Fintype.card G| ≤
    ε * (2 ^ A.card / Fintype.card G)

open scoped Classical in
/-- The probability that a uniformly random `k`-element subset of `G` is `ε`-balanced. -/
noncomputable def successProbability (G : Type*) [AddCommGroup G] [Fintype G] (ε : ℝ) (k : ℕ) :
    ℝ :=
  (((univ : Finset G).powersetCard k).filter (IsBalanced ε)).card /
    ((univ : Finset G).powersetCard k).card

set_option linter.style.formal_proof_palomar false in
/--
Let $0<\epsilon<1$ and let $g_\epsilon(N)$ be the minimal $k$ such that if $G$ is an abelian
group of size $N$ and $A\subseteq G$ is a uniformly random subset of size $k$, and
$$F_A(g) = \#\left\{ S\subseteq A : g = \sum_{x\in S}x\right\},$$
then, with probability $\to 1$ as $N\to \infty$,
$$\left\lvert F_A(g)-\frac{2^k}{N}\right\rvert \leq \epsilon \frac{2^k}{N}$$
for all $g\in G$.

Estimate $g_\epsilon(N)$ - in particular, is it true that for all $\epsilon>0$
$$g_\epsilon(N)=(1+o_\epsilon(1))\log_2N?$$

It is trivial that $g_\epsilon(N)\geq \log_2N$ for all $0<\epsilon<1$. Erdős and Rényi [ErRe65]
proved that for all $0<\epsilon<1$, $g_\epsilon(N) \leq (2+o(1))\log_2N+O_\epsilon(1)$. Erdős and
Hall [ErHa76] proved that, for all $0<\epsilon<1$,
$$g_\epsilon(N)\leq \left(1+O_\epsilon\left(\frac{\log\log\log N}{\log\log N}\right)\right)
\log_2N.$$

The upper bound $g_\epsilon(N)\leq (1+o(1))\log_2 N$ is formalised as: there is a choice of sizes
$k(N) = (1+o(1))\log_2 N$ such that, along any sequence of abelian groups with $|G|\to\infty$,
the probability that a random $k(|G|)$-subset is $\epsilon$-balanced tends to $1$. The matching
lower bound is `erdos_1179.variants.lower_bound`.

See also [543](https://www.erdosproblems.com/543).
-/
@[category research solved, question, AMS 5 11, formal_proof using lean4 at
  "https://github.com/plby/lean-proofs/blob/8822f7ddef30fadbd92e1c6ab4ed897af356af5e/src/latest/ErdosProblems/Erdos1179.lean#L3564"]
theorem erdos_1179 : ∀ ε : ℝ, 0 < ε → ε < 1 → ∃ k : ℕ → ℕ,
    Tendsto (fun N : ℕ ↦ (k N : ℝ) / Real.logb 2 N) atTop (nhds 1) ∧
      ∀ (G : ℕ → Type) [∀ i, AddCommGroup (G i)] [∀ i, Fintype (G i)],
        Tendsto (fun i ↦ Fintype.card (G i)) atTop atTop →
          Tendsto (fun i ↦ successProbability (G i) ε (k (Fintype.card (G i)))) atTop
            (nhds 1) := by
  sorry

set_option linter.style.formal_proof_palomar false in
/-- It is trivial that $g_\epsilon(N)\geq \log_2N$: an $\epsilon$-balanced set $A$ with
$\epsilon < 1$ must satisfy $|G| \leq 2^{|A|}$, since every $g$ has a representation. -/
@[category research solved, AMS 5 11, formal_proof using lean4 at
  "https://github.com/plby/lean-proofs/blob/8822f7ddef30fadbd92e1c6ab4ed897af356af5e/src/latest/ErdosProblems/Erdos1179.lean#L3564"]
theorem erdos_1179.variants.lower_bound : ∀ ε : ℝ, 0 < ε → ε < 1 →
    ∀ A : Finset G, IsBalanced ε A → Fintype.card G ≤ 2 ^ A.card := by
  sorry

end Erdos1179

To prove it: keep every definition of Challenge.lean unchanged and prove Erdos1179.erdos_1179 with the same type — no sorry in what it depends on, no new axioms. To disprove it: add theorem not_erdos_1179 : ¬ (…) in the same namespace, stating exactly the negation, and submit it as a disproof.

nosorry fetch erdos-1179
nosorry submit erdos-1179 nosorry/erdos-1179/Solution.lean --wait

Formal variants

Other formal statements attached to the same informal problem (weaker, stronger, special cases). Each is scored separately.

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.