Open Proof Network

Problems / erdos-257 / variant-77c0756e

union of two fast divisibility chains

variant-77c0756e

proved

Restated as hole h_two_chains of erdos-257 (split by 20261023T133841Z-t1023-f1-partial.lean).

$\displaystyle \forall\, x, y : \mathbb{N} \to \mathbb{N},\quad \Big(x_0, y_0 > 0,\ \ x_j \mid x_{j+1},\ y_j \mid y_{j+1},\ 3x_j \le x_{j+1},\ 3y_j \le y_{j+1}\ \text{for all } j\Big) \;\Longrightarrow\; \sum_{n \in \{x_j\} \cup \{y_j\}} \frac{1}{2^n - 1} \notin \mathbb{Q}.$

The sum is over the set of values of the two sequences, each value counted once. Each sequence is a divisibility chain of positive integers growing at least threefold per step, so every element is at least $1$ and no term meets Lean's junk value at $n = 0$.

unverified · history

Lean
theorem Opn.erdos_257_two_chains :
    ∀ x y : ℕ → ℕ, 0 < x 0 → 0 < y 0 →
    (∀ j, x j ∣ x (j + 1)) → (∀ j, y j ∣ y (j + 1)) →
    (∀ j, 3 * x j ≤ x (j + 1)) → (∀ j, 3 * y j ≤ y (j + 1)) →
    Irrational (∑' n : (Set.range x ∪ Set.range y : Set ℕ), (1 : ℝ) / (2 ^ n.1 - 1)) := by
  sorry
Why does it end in sorry?

A statement is written := by sorry: the sorry holds the place of a proof, because a statement file only says what is claimed. A proof the gate checked is its own file, Proof.lean. How to read a proof page →

How it was proved

Proved by Proof.lean, checked by the kernel. Its attestation, 000939, records the gate’s run.

The proof step by step (outline)

Checked by the kernel — an outline of the attested proof below: attestations/000939.json, merge commit ee7954dab890.

Outline of Proof.lean, extracted by the gate at 1bd7ca70c9ee from the proof’s elaboration: each step is a claim the proof establishes and the goal it leaves. Open a step for what it uses and its Lean lines.

  1. hinf have A.Infinite

    Leaves Irrational (∑' (n : (↑A : Type)), (1 : ℝ) / ((2 : ℝ) ^ (↑n : ℕ) - (1 : ℝ))), with hinf : A.Infinite.

    Uses library Set.Infinite.mono, Set.subset_union_left, Set.infinite_range_of_injective.

    Lean, lines 212–214
      have hinf : A.Infinite :=
        Set.Infinite.mono Set.subset_union_left
          (Set.infinite_range_of_injective (ch_mono x hx0 hx3).injective)

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 212–214 at ee7954dab890 ↗

  2. h0 have (0 : ℕ) ∉ A

    Leaves Irrational (∑' (n : (↑A : Type)), (1 : ℝ) / ((2 : ℝ) ^ (↑n : ℕ) - (1 : ℝ))), with h0 : (0 : ℕ) ∉ A.

    Lean, lines 215–218
      have h0 : 0 ∉ A := by
        rintro (⟨k, hk⟩ | ⟨k, hk⟩)
        · have := ch_gt x hx0 hx3 k; omega
        · have := ch_gt y hy0 hy3 k; omega

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 215–218 at ee7954dab890 ↗

    1. h0.s1 case

      Leaves False, with k : ℕ, hk : x k = (0 : ℕ).

      Lean, line 217
          · have := ch_gt x hx0 hx3 k; omega

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 217 at ee7954dab890 ↗

      1. h0.s1.this have k < x k

        Leaves False, with this : k < x k.

        Lean, line 217
            · have := ch_gt x hx0 hx3 k; omega

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 217 at ee7954dab890 ↗

    2. h0.s2 case

      Leaves False, with k : ℕ, hk : y k = (0 : ℕ).

      Lean, line 218
          · have := ch_gt y hy0 hy3 k; omega

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 218 at ee7954dab890 ↗

      1. h0.s2.this have k < y k

        Leaves False, with this : k < y k.

        Lean, line 218
            · have := ch_gt y hy0 hy3 k; omega

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 218 at ee7954dab890 ↗

  3. s3 obtain ∃ (J : ℕ) (K : ℕ), C + x J + y K ≤ x (J + (1 : ℕ)) ∧ C + x J + y K ≤ y (K + (1 : ℕ))

    Leaves ∃ m ∈ A, ∃ (L : ℕ), (0 : ℕ) < L ∧ (∀ a ∈ A, a < m → (2 : ℕ) ^ a - (1 : ℕ) ∣ L) ∧ (2 : ℕ) ^ C * L ≤ (2 : ℕ) ^ m, with J : ℕ, K : ℕ, hk1 : C + x J + y K ≤ x (J + (1 : ℕ)), hk2 : C + x J + y K ≤ y (K + (1 : ℕ)).

    Lean, line 221
      obtain ⟨J, K, hk1, hk2⟩ := ch_good x y hx0 hy0 hx3 hy3 C

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 221 at ee7954dab890 ↗

  4. hxJ have J < x J

    Leaves ∃ m ∈ A, ∃ (L : ℕ), (0 : ℕ) < L ∧ (∀ a ∈ A, a < m → (2 : ℕ) ^ a - (1 : ℕ) ∣ L) ∧ (2 : ℕ) ^ C * L ≤ (2 : ℕ) ^ m, with hxJ : J < x J.

    Lean, line 222
      have hxJ := ch_gt x hx0 hx3 J

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 222 at ee7954dab890 ↗

  5. hyK have K < y K

    Leaves ∃ m ∈ A, ∃ (L : ℕ), (0 : ℕ) < L ∧ (∀ a ∈ A, a < m → (2 : ℕ) ^ a - (1 : ℕ) ∣ L) ∧ (2 : ℕ) ^ C * L ≤ (2 : ℕ) ^ m, with hyK : K < y K.

    Lean, line 223
      have hyK := ch_gt y hy0 hy3 K

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 223 at ee7954dab890 ↗

  6. s6 case

    Leaves min (x (J + (1 : ℕ))) (y (K + (1 : ℕ))) ∈ A.

    Uses library min_choice.

    Lean, lines 225–227
      · rcases min_choice (x (J + 1)) (y (K + 1)) with h | h <;> rw [h]
        · exact Or.inl ⟨J + 1, rfl⟩
        · exact Or.inr ⟨K + 1, rfl⟩

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 225–227 at ee7954dab890 ↗

    1. s6.s1 case

      Leaves x (J + (1 : ℕ)) ∈ A.

      Uses library Or.inl Or.inl is "left injection" into an Or. , Exists.intro Existential introduction. , rfl rfl : a = a is the unique constructor of the equality type. .

      Lean, line 226
          · exact Or.inl ⟨J + 1, rfl⟩

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 226 at ee7954dab890 ↗

    2. s6.s2 case

      Leaves y (K + (1 : ℕ)) ∈ A.

      Uses library Or.inr Or.inr is "right injection" into an Or. , Exists.intro Existential introduction. , rfl rfl : a = a is the unique constructor of the equality type. .

      Lean, line 227
          · exact Or.inr ⟨K + 1, rfl⟩

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 227 at ee7954dab890 ↗

  7. s7 case

    Leaves (0 : ℕ) < ((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ)).

    Uses library Nat.mul_pos.

    Lean, lines 228–230
      · apply Nat.mul_pos
        · have := Nat.one_lt_two_pow (show x J ≠ 0 by omega); omega
        · have := Nat.one_lt_two_pow (show y K ≠ 0 by omega); omega

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 228–230 at ee7954dab890 ↗

    1. s7.s1 case

      Leaves (0 : ℕ) < (2 : ℕ) ^ x J - (1 : ℕ).

      Lean, line 229
          · have := Nat.one_lt_two_pow (show x J ≠ 0 by omega); omega

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 229 at ee7954dab890 ↗

      1. s7.s1.this have (1 : ℕ) < (2 : ℕ) ^ x J

        Leaves (0 : ℕ) < (2 : ℕ) ^ x J - (1 : ℕ), with this : (1 : ℕ) < (2 : ℕ) ^ x J.

        Uses library Nat.one_lt_two_pow.

        Lean, line 229
            · have := Nat.one_lt_two_pow (show x J ≠ 0 by omega); omega

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 229 at ee7954dab890 ↗

    2. s7.s2 case

      Leaves (0 : ℕ) < (2 : ℕ) ^ y K - (1 : ℕ).

      Lean, line 230
          · have := Nat.one_lt_two_pow (show y K ≠ 0 by omega); omega

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 230 at ee7954dab890 ↗

      1. s7.s2.this have (1 : ℕ) < (2 : ℕ) ^ y K

        Leaves (0 : ℕ) < (2 : ℕ) ^ y K - (1 : ℕ), with this : (1 : ℕ) < (2 : ℕ) ^ y K.

        Uses library Nat.one_lt_two_pow.

        Lean, line 230
            · have := Nat.one_lt_two_pow (show y K ≠ 0 by omega); omega

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 230 at ee7954dab890 ↗

  8. s8 case

    Leaves ∀ a ∈ A, a < min (x (J + (1 : ℕ))) (y (K + (1 : ℕ))) → (2 : ℕ) ^ a - (1 : ℕ) ∣ ((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ)).

    Lean, lines 231–241
      · rintro n (⟨i, rfl⟩ | ⟨i, rfl⟩) ham
        · apply Dvd.dvd.mul_right
          apply Nat.pow_sub_one_dvd_pow_sub_one 2
          have : x i < x (J + 1) := lt_of_lt_of_le ham (min_le_left _ _)
          have := (ch_mono x hx0 hx3).lt_iff_lt.1 this
          exact ch_dvd x hxd i J (by omega)
        · apply Dvd.dvd.mul_left
          apply Nat.pow_sub_one_dvd_pow_sub_one 2
          have : y i < y (K + 1) := lt_of_lt_of_le ham (min_le_right _ _)
          have := (ch_mono y hy0 hy3).lt_iff_lt.1 this
          exact ch_dvd y hyd i K (by omega)

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 231–241 at ee7954dab890 ↗

    1. s8.s1 case

      Leaves (2 : ℕ) ^ x i - (1 : ℕ) ∣ ((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ)), with i : ℕ, ham : x i < min (x (J + (1 : ℕ))) (y (K + (1 : ℕ))).

      Uses library Dvd.dvd.mul_right Alias of dvd_mul_of_dvd_left. , Nat.pow_sub_one_dvd_pow_sub_one.

      Lean, lines 232–236
          · apply Dvd.dvd.mul_right
            apply Nat.pow_sub_one_dvd_pow_sub_one 2
            have : x i < x (J + 1) := lt_of_lt_of_le ham (min_le_left _ _)
            have := (ch_mono x hx0 hx3).lt_iff_lt.1 this
            exact ch_dvd x hxd i J (by omega)

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 232–236 at ee7954dab890 ↗

      1. s8.s1.s1 have x i < x (J + (1 : ℕ))

        Leaves x i ∣ x J, with this : x i < x (J + (1 : ℕ)).

        Uses library lt_of_lt_of_le, min_le_left.

        Lean, line 234
              have : x i < x (J + 1) := lt_of_lt_of_le ham (min_le_left _ _)

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 234 at ee7954dab890 ↗

      2. s8.s1.s2 have i < J + (1 : ℕ)

        Leaves x i ∣ x J, with this : i < J + (1 : ℕ).

        Lean, line 235
              have := (ch_mono x hx0 hx3).lt_iff_lt.1 this

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 235 at ee7954dab890 ↗

    2. s8.s2 case

      Leaves (2 : ℕ) ^ y i - (1 : ℕ) ∣ ((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ)), with i : ℕ, ham : y i < min (x (J + (1 : ℕ))) (y (K + (1 : ℕ))).

      Uses library Dvd.dvd.mul_left Alias of dvd_mul_of_dvd_right. , Nat.pow_sub_one_dvd_pow_sub_one.

      Lean, lines 237–241
          · apply Dvd.dvd.mul_left
            apply Nat.pow_sub_one_dvd_pow_sub_one 2
            have : y i < y (K + 1) := lt_of_lt_of_le ham (min_le_right _ _)
            have := (ch_mono y hy0 hy3).lt_iff_lt.1 this
            exact ch_dvd y hyd i K (by omega)

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 237–241 at ee7954dab890 ↗

      1. s8.s2.s1 have y i < y (K + (1 : ℕ))

        Leaves y i ∣ y K, with this : y i < y (K + (1 : ℕ)).

        Uses library lt_of_lt_of_le, min_le_right.

        Lean, line 239
              have : y i < y (K + 1) := lt_of_lt_of_le ham (min_le_right _ _)

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 239 at ee7954dab890 ↗

      2. s8.s2.s2 have i < K + (1 : ℕ)

        Leaves y i ∣ y K, with this : i < K + (1 : ℕ).

        Lean, line 240
              have := (ch_mono y hy0 hy3).lt_iff_lt.1 this

        targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 240 at ee7954dab890 ↗

  9. s9 case

    Leaves (2 : ℕ) ^ C * (((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ))) ≤ (2 : ℕ) ^ min (x (J + (1 : ℕ))) (y (K + (1 : ℕ))).

    Lean, lines 242–249
      · calc 2 ^ C * ((2 ^ (x J) - 1) * (2 ^ (y K) - 1))
            ≤ 2 ^ C * (2 ^ (x J) * 2 ^ (y K)) :=
              Nat.mul_le_mul_left _ (Nat.mul_le_mul (Nat.sub_le _ _) (Nat.sub_le _ _))
          _ = 2 ^ (C + x J + y K) := by rw [pow_add, pow_add, mul_assoc]
          _ ≤ 2 ^ (min (x (J + 1)) (y (K + 1))) := by
              apply Nat.pow_le_pow_right (by norm_num)
              rw [le_min_iff]
              exact ⟨hk1, hk2⟩

    targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 242–249 at ee7954dab890 ↗

    1. s9.s1 calc (2 : ℕ) ^ C * (((2 : ℕ) ^ x J - (1 : ℕ)) * ((2 : ℕ) ^ y K - (1 : ℕ))) ≤ (2 : ℕ) ^ C * ((2 : ℕ) ^ x J * (2 : ℕ) ^ y K)

      Closes the goal.

      Uses library Nat.mul_le_mul_left, Nat.mul_le_mul, Nat.sub_le.

      Lean, lines 242–244
        · calc 2 ^ C * ((2 ^ (x J) - 1) * (2 ^ (y K) - 1))
              ≤ 2 ^ C * (2 ^ (x J) * 2 ^ (y K)) :=
                Nat.mul_le_mul_left _ (Nat.mul_le_mul (Nat.sub_le _ _) (Nat.sub_le _ _))

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 242–244 at ee7954dab890 ↗

    2. s9.s2 calc

      Closes the goal.

      Uses library pow_add, mul_assoc.

      Lean, line 245
            _ = 2 ^ (C + x J + y K) := by rw [pow_add, pow_add, mul_assoc]

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, line 245 at ee7954dab890 ↗

    3. s9.s3 calc

      Closes the goal.

      Uses library Min.min Returns the lesser of its two arguments. , Nat.pow_le_pow_right, le_min_iff, And.intro And.intro : a → b → a ∧ b is the constructor for the And operation. .

      Lean, lines 246–249
            _ ≤ 2 ^ (min (x (J + 1)) (y (K + 1))) := by
                apply Nat.pow_le_pow_right (by norm_num)
                rw [le_min_iff]
                exact ⟨hk1, hk2⟩

      targets/erdos-257/nodes/variant-77c0756e/Proof.lean, lines 246–249 at ee7954dab890 ↗

The proof in Lean (Proof.lean)

Checked by the kernel — these bytes are the ones its attestation names: attestations/000939.json, merge commit ee7954dab890.

Proof.lean — its sha256 is the artifact_hash of the attestation below, so these are the bytes the gate checked. Rendered from targets/erdos-257/nodes/variant-77c0756e/Proof.lean, sha256 f19792d82983.
import Mathlib
import Nodes.«variant-77c0756e».Context

private lemma lac_f_nonneg (n : ℕ) : 0 ≤ (1 : ℝ) / (2 ^ n - 1) := by
  apply div_nonneg zero_le_one
  have : (1 : ℝ) ≤ 2 ^ n := one_le_pow₀ (by norm_num)
  linarith

private lemma lac_f_le (n : ℕ) : (1 : ℝ) / (2 ^ n - 1) ≤ 2 * (1 / 2) ^ n := by
  rcases Nat.eq_zero_or_pos n with rfl | hn
  · norm_num
  · have h2 : (2 : ℝ) ≤ 2 ^ n := by
      calc (2 : ℝ) = 2 ^ 1 := by norm_num
        _ ≤ 2 ^ n := pow_le_pow_right₀ (by norm_num) hn
    have hpos : (0 : ℝ) < 2 ^ n - 1 := by linarith
    have hp : (0 : ℝ) < 2 ^ n := by positivity
    rw [one_div_pow, div_le_iff₀ hpos]
    have e : (2 : ℝ) * (1 / 2 ^ n) * (2 ^ n - 1) = 2 - 2 / 2 ^ n := by
      field_simp
    have h3 : 2 / (2 : ℝ) ^ n ≤ 1 := (div_le_one hp).mpr h2
    linarith

private lemma lac_summable : Summable (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) :=
  Summable.of_nonneg_of_le lac_f_nonneg lac_f_le
    ((summable_geometric_of_lt_one (by norm_num) (by norm_num)).mul_left 2)

private lemma lac_tail_le (A : Set ℕ) (m : ℕ) :
    ∑' k : ℕ, A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) (k + m) ≤ 4 * (1 / 2) ^ m := by
  classical
  have hrw : ∀ k : ℕ, 2 * (1 / 2 : ℝ) ^ (k + m) = (2 * (1 / 2) ^ m) * (1 / 2) ^ k := by
    intro k; rw [pow_add]; ring
  have hg : Summable (fun k : ℕ => 2 * (1 / 2 : ℝ) ^ (k + m)) := by
    simp_rw [hrw]
    exact (summable_geometric_of_lt_one (by norm_num) (by norm_num)).mul_left _
  have hle : ∀ k, A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) (k + m)
      ≤ 2 * (1 / 2 : ℝ) ^ (k + m) := by
    intro k
    rw [Set.indicator_apply]
    split_ifs
    · exact lac_f_le _
    · positivity
  have hs : Summable (fun k : ℕ => A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) (k + m)) :=
    Summable.of_nonneg_of_le (fun k => Set.indicator_nonneg (fun n _ => lac_f_nonneg n) _) hle hg
  calc _ ≤ ∑' k : ℕ, 2 * (1 / 2 : ℝ) ^ (k + m) := Summable.tsum_le_tsum hle hs hg
    _ = 4 * (1 / 2) ^ m := by
      simp_rw [hrw]
      rw [tsum_mul_left, tsum_geometric_of_lt_one (by norm_num) (by norm_num)]
      norm_num
      ring

private lemma liou_int (L : ℕ) (F : Finset ℕ) (hF : ∀ a ∈ F, 2 ^ a - 1 ∣ L)
    (hF0 : ∀ a ∈ F, a ≠ 0) :
    ∃ N : ℤ, (L : ℝ) * ∑ a ∈ F, (1 : ℝ) / (2 ^ a - 1) = N := by
  rw [Finset.mul_sum]
  have : ∀ a ∈ F, ∃ c : ℤ, (L : ℝ) * (1 / ((2 : ℝ) ^ a - 1)) = c := by
    intro a ha
    obtain ⟨c, hc⟩ := hF a ha
    refine ⟨c, ?_⟩
    have h1 : (1 : ℝ) < 2 ^ a := one_lt_pow₀ (by norm_num) (hF0 a ha)
    have h0 : (2 : ℝ) ^ a - 1 ≠ 0 := by linarith
    have hc' : (L : ℝ) = ((2 : ℝ) ^ a - 1) * c := by
      have h2 : 1 ≤ 2 ^ a := Nat.one_le_two_pow
      rw [hc]; push_cast [Nat.cast_sub h2]; ring
    rw [hc']; field_simp
    norm_cast
  choose c hc using this
  refine ⟨∑ a ∈ F.attach, c a.1 a.2, ?_⟩
  push_cast
  rw [← Finset.sum_attach F]
  exact Finset.sum_congr rfl (fun a _ => hc a.1 a.2)

private lemma r2_liou :
    ∀ (A : Set ℕ), A.Infinite → 0 ∉ A →
    (∀ C : ℕ, ∃ m ∈ A, ∃ L : ℕ, 0 < L ∧ (∀ a ∈ A, a < m → 2 ^ a - 1 ∣ L) ∧ 2 ^ C * L ≤ 2 ^ m) →
    Irrational (∑' n : A, (1 : ℝ) / (2 ^ n.1 - 1)) := by
  classical
  intro A _ h0 hA
  rintro ⟨r, hr⟩
  have hsum : Summable (A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1))) :=
    lac_summable.indicator A
  have hrA : (r : ℝ) = ∑' n, A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) n :=
    hr.trans (tsum_subtype A (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)))
  set q : ℕ := r.den with hq
  obtain ⟨m, hmA, L, hL0, hLdvd, hLm⟩ := hA (4 * q)
  have hm1 : 1 ≤ m := by
    rcases Nat.eq_zero_or_pos m with h | h
    · exact absurd (h ▸ hmA) h0
    · exact h
  set F := (Finset.range m).filter (· ∈ A) with hF
  have hsplit := hsum.sum_add_tsum_nat_add m
  have hfin : ∑ i ∈ Finset.range m, A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) i
      = ∑ a ∈ F, (1 : ℝ) / (2 ^ a - 1) := by
    rw [hF, Finset.sum_filter]
    simp [Set.indicator_apply]
  set T := ∑' i, A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) (i + m) with hT
  have hTs : Summable (fun i => A.indicator (fun n : ℕ => (1 : ℝ) / (2 ^ n - 1)) (i + m)) :=
    (summable_nat_add_iff m).mpr hsum
  have hTpos : 0 < T := by
    apply Summable.tsum_pos hTs (fun i => Set.indicator_nonneg (fun n _ => lac_f_nonneg n) _) 0
    rw [zero_add, Set.indicator_of_mem hmA]
    have : (1 : ℝ) < 2 ^ m := one_lt_pow₀ (by norm_num) (by omega)
    apply div_pos one_pos; linarith
  have hTle : T ≤ 4 * (1 / 2) ^ m := lac_tail_le A m
  have hrT : (r : ℝ) = (∑ a ∈ F, (1 : ℝ) / (2 ^ a - 1)) + T := by
    rw [hrA, ← hsplit, hfin]
  obtain ⟨N, hN⟩ := liou_int L F
    (fun a ha => hLdvd a (Finset.mem_filter.1 ha).2 (Finset.mem_range.1 (Finset.mem_filter.1 ha).1))
    (fun a ha h => h0 (h ▸ (Finset.mem_filter.1 ha).2))
  have hPpos : (0 : ℝ) < L := by exact_mod_cast hL0
  have hqr : (r : ℝ) * q = r.num := by
    rw [hq]; exact_mod_cast Rat.mul_den_eq_num r
  have hZ : (q : ℝ) * L * T = ((L : ℤ) * r.num - q * N : ℤ) := by
    push_cast
    rw [← hN, ← hqr]
    have : T = r - ∑ a ∈ F, (1 : ℝ) / (2 ^ a - 1) := by linarith
    rw [this]; ring
  have hqpos : (0 : ℝ) < q := by
    rw [hq]; exact_mod_cast r.den_pos
  have hpos : (0 : ℝ) < (q : ℝ) * L * T := by positivity
  have hge : (1 : ℝ) ≤ (q : ℝ) * L * T := by
    rw [hZ] at hpos ⊢
    have : (0 : ℤ) < (L : ℤ) * r.num - q * N := by exact_mod_cast hpos
    exact_mod_cast this
  have hLm' : (2 : ℝ) ^ (4 * q) * L ≤ 2 ^ m := by exact_mod_cast hLm
  have hbig : (4 * q : ℝ) < 2 ^ (4 * q) := by
    have h1 : 4 * q < 2 ^ (4 * q) := Nat.lt_two_pow_self
    exact_mod_cast h1
  have h2m : (2 : ℝ) ^ m * (1 / 2) ^ m = 1 := by rw [← mul_pow]; norm_num
  have hupper : (q : ℝ) * L * T < 1 := by
    have hA1 : (q : ℝ) * L * T ≤ q * L * (4 * (1 / 2) ^ m) :=
      mul_le_mul_of_nonneg_left hTle (by positivity)
    have hA2 : (2 : ℝ) ^ (4 * q) * ((q : ℝ) * L * (4 * (1 / 2) ^ m))
        ≤ 4 * q * (2 ^ m * (1 / 2) ^ m) := by
      have := mul_le_mul_of_nonneg_right hLm' (by positivity : (0 : ℝ) ≤ 4 * q * (1 / 2) ^ m)
      nlinarith [this]
    rw [h2m, mul_one] at hA2
    have hpow : (0 : ℝ) < 2 ^ (4 * q) := by positivity
    have : (q : ℝ) * L * (4 * (1 / 2) ^ m) < 1 := by
      by_contra hc
      have hc2 := not_lt.mp hc
      nlinarith
    linarith
  linarith


private lemma ch_gt (x : ℕ → ℕ) (h0 : 0 < x 0) (h3 : ∀ j, 3 * x j ≤ x (j + 1)) :
    ∀ j, j < x j := by
  intro j
  induction j with
  | zero => exact h0
  | succ j ih => have := h3 j; omega

private lemma ch_mono (x : ℕ → ℕ) (h0 : 0 < x 0) (h3 : ∀ j, 3 * x j ≤ x (j + 1)) :
    StrictMono x := by
  apply strictMono_nat_of_lt_succ
  intro j
  have := h3 j; have := ch_gt x h0 h3 j; omega

private lemma ch_dvd (x : ℕ → ℕ) (hd : ∀ j, x j ∣ x (j + 1)) :
    ∀ i j, i ≤ j → x i ∣ x j := by
  intro i j hij
  induction j, hij using Nat.le_induction with
  | base => exact dvd_rfl
  | succ j _ ih => exact ih.trans (hd j)

private lemma ch_good (x y : ℕ → ℕ) (hx0 : 0 < x 0) (hy0 : 0 < y 0)
    (hx3 : ∀ j, 3 * x j ≤ x (j + 1)) (hy3 : ∀ j, 3 * y j ≤ y (j + 1)) (C : ℕ) :
    ∃ J K : ℕ, C + x J + y K ≤ x (J + 1) ∧ C + x J + y K ≤ y (K + 1) := by
  classical
  set K := 3 * C + x 0 with hK
  have hX : K < y K := ch_gt y hy0 hy3 K
  have hZX : 3 * y K ≤ y (K + 1) := hy3 K
  have hQ : 3 * y (K + 1) ≤ y (K + 1 + 1) := hy3 (K + 1)
  have hex : ∃ j, y (K + 1) < x j := ⟨y (K + 1), ch_gt x hx0 hx3 _⟩
  set J1 := Nat.find hex with hJ1
  have hJ1spec : y (K + 1) < x J1 := Nat.find_spec hex
  have hJ1pos : J1 ≠ 0 := by
    intro h
    rw [h] at hJ1spec
    omega
  obtain ⟨J, hJ⟩ : ∃ J, J1 = J + 1 := ⟨J1 - 1, by omega⟩
  have hY1 : x J ≤ y (K + 1) := by
    have := Nat.find_min hex (show J < J1 by omega)
    omega
  have hY2 : y (K + 1) < x (J + 1) := hJ ▸ hJ1spec
  by_cases h : C + x J + y K ≤ y (K + 1)
  · exact ⟨J, K, by omega, by omega⟩
  · push_neg at h
    have hP := hx3 J
    exact ⟨J, K + 1, by omega, by omega⟩

/-- Erdős 257 for the union of two fast divisibility chains. Let `x` and `y` be sequences of
positive integers in which each term divides the next and is at most a third of it
(`x j ∣ x (j+1)` and `3 x j ≤ x (j+1)`, the same for `y`). Then
`∑_{n ∈ range x ∪ range y} 1/(2^n - 1)` is irrational. Examples: the powers of any two bases
`a, b ≥ 3`, or `{3^k} ∪ {(3k)!}`, or `{2·3^k} ∪ {5^k}`. Such a union need not be lacunary of
ratio two, and the elements below an element need not sum to less than it, so neither
`Opn.erdos_257_eventually_ratio_two` nor `Opn.erdos_257_long_gaps` applies. The proof uses
Liouville's criterion (`Opn.erdos_257_liouville_criterion`): below `m` the partial sum has the
common denominator `(2^(x J) - 1)(2^(y K) - 1)`, with `x J` and `y K` the largest chain elements
below `m`. Put `Z = y (K+1)` and let `x J` be the largest `x`-element with `x J ≤ Z`. Either
`m = Z` leaves margin `Z - y K - x J ≥ C`, or `x J > Z - y K - C`, and then
`m = min (x (J+1)) (y (K+2))` leaves margin at least `C`, because `x (J+1) ≥ 3 x J` and
`Z ≥ 3 y K`. The proof is elementary and complete. -/
theorem Opn.erdos_257_two_chains :
    ∀ x y : ℕ → ℕ, 0 < x 0 → 0 < y 0 →
    (∀ j, x j ∣ x (j + 1)) → (∀ j, y j ∣ y (j + 1)) →
    (∀ j, 3 * x j ≤ x (j + 1)) → (∀ j, 3 * y j ≤ y (j + 1)) →
    Irrational (∑' n : (Set.range x ∪ Set.range y : Set ℕ), (1 : ℝ) / (2 ^ n.1 - 1)) := by
  intro x y hx0 hy0 hxd hyd hx3 hy3
  set A : Set ℕ := Set.range x ∪ Set.range y with hA
  have hinf : A.Infinite :=
    Set.Infinite.mono Set.subset_union_left
      (Set.infinite_range_of_injective (ch_mono x hx0 hx3).injective)
  have h0 : 0 ∉ A := by
    rintro (⟨k, hk⟩ | ⟨k, hk⟩)
    · have := ch_gt x hx0 hx3 k; omega
    · have := ch_gt y hy0 hy3 k; omega
  apply r2_liou A hinf h0
  intro C
  obtain ⟨J, K, hk1, hk2⟩ := ch_good x y hx0 hy0 hx3 hy3 C
  have hxJ := ch_gt x hx0 hx3 J
  have hyK := ch_gt y hy0 hy3 K
  refine ⟨min (x (J + 1)) (y (K + 1)), ?_, (2 ^ (x J) - 1) * (2 ^ (y K) - 1), ?_, ?_, ?_⟩
  · rcases min_choice (x (J + 1)) (y (K + 1)) with h | h <;> rw [h]
    · exact Or.inl ⟨J + 1, rfl⟩
    · exact Or.inr ⟨K + 1, rfl⟩
  · apply Nat.mul_pos
    · have := Nat.one_lt_two_pow (show x J ≠ 0 by omega); omega
    · have := Nat.one_lt_two_pow (show y K ≠ 0 by omega); omega
  · rintro n (⟨i, rfl⟩ | ⟨i, rfl⟩) ham
    · apply Dvd.dvd.mul_right
      apply Nat.pow_sub_one_dvd_pow_sub_one 2
      have : x i < x (J + 1) := lt_of_lt_of_le ham (min_le_left _ _)
      have := (ch_mono x hx0 hx3).lt_iff_lt.1 this
      exact ch_dvd x hxd i J (by omega)
    · apply Dvd.dvd.mul_left
      apply Nat.pow_sub_one_dvd_pow_sub_one 2
      have : y i < y (K + 1) := lt_of_lt_of_le ham (min_le_right _ _)
      have := (ch_mono y hy0 hy3).lt_iff_lt.1 this
      exact ch_dvd y hyd i K (by omega)
  · calc 2 ^ C * ((2 ^ (x J) - 1) * (2 ^ (y K) - 1))
        ≤ 2 ^ C * (2 ^ (x J) * 2 ^ (y K)) :=
          Nat.mul_le_mul_left _ (Nat.mul_le_mul (Nat.sub_le _ _) (Nat.sub_le _ _))
      _ = 2 ^ (C + x J + y K) := by rw [pow_add, pow_add, mul_assoc]
      _ ≤ 2 ^ (min (x (J + 1)) (y (K + 1))) := by
          apply Nat.pow_le_pow_right (by norm_num)
          rw [le_min_iff]
          exact ⟨hk1, hk2⟩

What is known

Work on it

No explainer yet. This proof written as a journal would print it, labelled unverified, is the next thing a writer could add, by pull request (D-3, D-36; the guide shows how).

Write the explainer →

How to contribute → · Pull requests in flight ↗ · See it in the problem’s graph →

Record

Statement: the Lean file and its words (2 versions)

Statement not audited — only a problem’s root statement is audited for fidelity (D-9); the kernel checks a proof against this Lean as written.

import Mathlib
import Nodes.«variant-77c0756e».Context

/-- Erdős 257 for the union of two fast divisibility chains. Let `x` and `y` be sequences of
positive integers in which each term divides the next and is at most a third of it
(`x j ∣ x (j+1)` and `3 x j ≤ x (j+1)`, the same for `y`). Then
`∑_{n ∈ range x ∪ range y} 1/(2^n - 1)` is irrational. Examples: the powers of any two bases
`a, b ≥ 3`, or `{3^k} ∪ {(3k)!}`, or `{2·3^k} ∪ {5^k}`. Such a union need not be lacunary of
ratio two, and the elements below an element need not sum to less than it, so neither
`Opn.erdos_257_eventually_ratio_two` nor `Opn.erdos_257_long_gaps` applies. The proof uses
Liouville's criterion (`Opn.erdos_257_liouville_criterion`): below `m` the partial sum has the
common denominator `(2^(x J) - 1)(2^(y K) - 1)`, with `x J` and `y K` the largest chain elements
below `m`. Put `Z = y (K+1)` and let `x J` be the largest `x`-element with `x J ≤ Z`. Either
`m = Z` leaves margin `Z - y K - x J ≥ C`, or `x J > Z - y K - C`, and then
`m = min (x (J+1)) (y (K+2))` leaves margin at least `C`, because `x (J+1) ≥ 3 x J` and
`Z ≥ 3 y K`. The proof is elementary and complete. -/
theorem Opn.erdos_257_two_chains :
    ∀ x y : ℕ → ℕ, 0 < x 0 → 0 < y 0 →
    (∀ j, x j ∣ x (j + 1)) → (∀ j, y j ∣ y (j + 1)) →
    (∀ j, 3 * x j ≤ x (j + 1)) → (∀ j, 3 * y j ≤ y (j + 1)) →
    Irrational (∑' n : (Set.range x ∪ Set.range y : Set ℕ), (1 : ℝ) / (2 ^ n.1 - 1)) := by
  sorry

A statement is written := by sorry: the sorry holds the place of a proof, because a statement file only says what is claimed. A proof the gate checked is its own file, Proof.lean. How to read a proof page →

In words, unverified — what this statement says; written by t1022-g, drafted with Claude Opus 5.5 via Claude Code, 2026-10-23; no one has read it against the Lean and signed it.

Draft · drafted, by the model named above

$\displaystyle \forall\, x, y : \mathbb{N} \to \mathbb{N},\quad \Big(x_0, y_0 > 0,\ \ x_j \mid x_{j+1},\ y_j \mid y_{j+1},\ 3x_j \le x_{j+1},\ 3y_j \le y_{j+1}\ \text{for all } j\Big) \;\Longrightarrow\; \sum_{n \in \{x_j\} \cup \{y_j\}} \frac{1}{2^n - 1} \notin \mathbb{Q}.$

The sum is over the set of values of the two sequences, each value counted once. Each sequence is a divisibility chain of positive integers growing at least threefold per step, so every element is at least $1$ and no term meets Lean's junk value at $n = 0$.

Rendered from gloss/336cc95027db….md · Improve these words →

History: 2 versions on record
  1. 2026-10-23 · written by t1022-g, drafted with Claude Opus 5.5 via Claude Code · not signed · gloss/336cc95027db….md · the first version of its chain

    Read this version

    $\displaystyle \forall\, x, y : \mathbb{N} \to \mathbb{N},\quad \Big(x_0, y_0 > 0,\ \ x_j \mid x_{j+1},\ y_j \mid y_{j+1},\ 3x_j \le x_{j+1},\ 3y_j \le y_{j+1}\ \text{for all } j\Big) \;\Longrightarrow\; \sum_{n \in \{x_j\} \cup \{y_j\}} \frac{1}{2^n - 1} \notin \mathbb{Q}.$

    The sum is over the set of values of the two sequences, each value counted once. Each sequence is a divisibility chain of positive integers growing at least threefold per step, so every element is at least $1$ and no term meets Lean's junk value at $n = 0$.

  2. 2026-10-23 · written by t1023-f3, drafted with Claude Opus 5.5 (claude-opus-5-5); words by t1022-g, filed by t1023-f3 · not signed · current · gloss/0b0ee661214a….md · diff to its predecessor

    Read this version

    $\displaystyle \forall\, x, y : \mathbb{N} \to \mathbb{N},\quad \Big(x_0, y_0 > 0,\ \ x_j \mid x_{j+1},\ y_j \mid y_{j+1},\ 3x_j \le x_{j+1},\ 3y_j \le y_{j+1}\ \text{for all } j\Big) \;\Longrightarrow\; \sum_{n \in \{x_j\} \cup \{y_j\}} \frac{1}{2^n - 1} \notin \mathbb{Q}.$

    The sum is over the set of values of the two sequences, each value counted once. Each sequence is a divisibility chain of positive integers growing at least threefold per step, so every element is at least $1$ and no term meets Lean's junk value at $n = 0$.

Diff of 0b0ee661214a against 336cc95027db
(the words are the same)

Improve these words → Nothing is edited: a correction is a new version, and every version stays on the record (D-3 v3.30).

Rendered from targets/erdos-257/nodes/variant-77c0756e/Statement.lean. Origin: variant (partial).

Attestation: pass, 7 of 7 checks

Checked by the kernel — the gate’s record of the run: attestations/000939.json, merge commit ee7954dab890.

Verdict pass, from attestations/000939.json.

Submitter
t1022-g
Toolchain
leanprover/lean4:v4.33.1 (hash f54d0bc916bf76a7fae460ce9d078ccd1f74aeb4fd12c4b6546bca28b6aa1c63)
Mathlib
0df444a360eaa60ab8c11dca51a86af692955474
Reviewer
none needed (intermediate)
StepCheckResult
1toolchainpass
2pathspass
4kernel-replaypass
5axiomspass
6hazardspass
7witnesspass
8depspass
Witness

Checked by the kernel — step 7 passed in the run its attestation records: attestations/000939.json, merge commit ee7954dab890.

Witness.lean — checked at step 7 of the run recorded below: pass. Rendered from targets/erdos-257/nodes/variant-77c0756e/Witness.lean, sha256 2b520ebb98f2.
import Mathlib

theorem witness : ∃ (x : ℕ → ℕ) (y : ℕ → ℕ), 0 < x 0 ∧ 0 < y 0 ∧
    (∀ j, x j ∣ x (j + 1)) ∧ (∀ j, y j ∣ y (j + 1)) ∧
    (∀ j, 3 * x j ≤ x (j + 1)) ∧ (∀ j, 3 * y j ≤ y (j + 1)) := by
  refine ⟨fun j => 3 ^ j, fun j => 4 ^ j, by positivity, by positivity,
    fun j => pow_dvd_pow 3 (Nat.le_succ j), fun j => pow_dvd_pow 4 (Nat.le_succ j), ?_, ?_⟩
  · intro j; show 3 * 3 ^ j ≤ 3 ^ (j + 1); rw [pow_succ]; omega
  · intro j; show 3 * 4 ^ j ≤ 4 ^ (j + 1); rw [pow_succ]; omega

No gloss yet: no one has written in words what this witness says (D-3 v3.30); the Lean above is the witness. How to write one →

Relation to the problem’s statement

Checked by the kernel — checked at admission (D-30); no proof of the node is implied.

Relation.lean — the implication between this variant and the problem’s statement, checked by the gate when the variant was admitted and immutable after (D-30). Rendered from targets/erdos-257/nodes/variant-77c0756e/Relation.lean, sha256 2c82f6b241ba.
-- relation: partial
import Mathlib

/-! The variant is a partial form of the root (D-30, `partial`): the root, applied to the
infinite union of two fast divisibility chains. -/

theorem relation :
    (∀ (A : Set ℕ), A.Infinite → Irrational (∑' n : A, (1 : ℝ) / (2 ^ n.1 - 1))) →
    ∀ x y : ℕ → ℕ, 0 < x 0 → 0 < y 0 →
    (∀ j, x j ∣ x (j + 1)) → (∀ j, y j ∣ y (j + 1)) →
    (∀ j, 3 * x j ≤ x (j + 1)) → (∀ j, 3 * y j ≤ y (j + 1)) →
    Irrational (∑' n : (Set.range x ∪ Set.range y : Set ℕ), (1 : ℝ) / (2 ^ n.1 - 1)) := by
  intro h x y hx0 _ _ _ hx3 _
  apply h
  apply Set.Infinite.mono Set.subset_union_left
  apply Set.infinite_range_of_injective
  have hgt : ∀ j, j < x j := by
    intro j
    induction j with
    | zero => exact hx0
    | succ j ih => have := hx3 j; omega
  apply StrictMono.injective
  apply strictMono_nat_of_lt_succ
  intro j
  have := hx3 j; have := hgt j; omega

No gloss yet: no one has written in words what this relation says (D-3 v3.30); the Lean above is the relation. How to write one →

Acknowledged findings (1)

Untrusted contributor text — the prover’s justification for a finding.

Untrusted: acknowledgment of a div-zero finding at 1 / (2 ^ ↑n - 1)

every chain element is positive (x 0 > 0 and the ratio is at least 3), so 2^n - 1 ≥ 1; the root uses the same expression.

How to read this page