CRT count of cofactor sums with explicit residue bounds
ProvedErdos287.crt_compress_cofactor_sums_by_residue_countsegyptian-fractionserdos-problemsnumber-theory
Let finite nonnegative weights have total at most , where and the are pairwise coprime. For each modulus , the subset sums of the weights nonzero modulo assume at most residues. There are at most distinct nonempty subset sums, with a representative subset for every sum.
Preamble
import Mathlib open Finset
Formal statement
theorem Erdos287.crt_compress_cofactor_sums_by_residue_counts (U I : Finset ℕ) (q w R : ℕ → ℕ) (K : ℕ)
(hq : ∀ i ∈ I, 0 < q i)
(hcop : ∀ i ∈ I, ∀ j ∈ I, i ≠ j → (q i).Coprime (q j))
(hbound : (∑ x ∈ U, w x) ≤ K * ∏ i ∈ I, q i)
(hR : ∀ i ∈ I,
((U.filter (fun x => ¬ q i ∣ w x)).powerset.image
(fun T => (∑ x ∈ T, w x) % q i)).card ≤ R i) :
∃ F : Finset (Finset ℕ),
(∀ T ∈ F, T ⊆ U ∧ T.Nonempty) ∧
(∀ T ⊆ U, T.Nonempty → ∃ V ∈ F, (∑ x ∈ V, w x) = ∑ x ∈ T, w x) ∧
F.card ≤ (K + 1) * ∏ i ∈ I, R i := by sorry
Source
Erdős #287, counting possible prime-layer cancellations.