FormalConjectures/OEIS/86766.lean

GitHub source file

Explanation legend Lean4 Domain Explanation Language (L4DEL)

L4DEL explanations are a separate layer. They do not change the Lean source. Intuition is explanatory prose; numbered items are a reading path; sources link the wording back to evidence.

L4DEL
Lean4 Domain Explanation Language

Credit: The upstream authors and contributors retain credit for the project and mathematics. lean4-explainer only renders their pinned source and adds the separately disclosed explanation layer.

Project sources: Pinned project documentation, Formal Conjectures paper, arXiv v1

9 declarations, 3 contain sorry, 0 declared as axioms

Smallest $r$ such that (concatenation of $n$, $r$ times) $\cdot 10 + 1$ is prime

$a(n)$ is the smallest $r$ where (concatenation of $n$, $r$ times with itself) $\cdot 10 + 1$ is a prime, or $0$ if no such number exists. The number resulting from concatenating $n$, $r$ times, is $n \cdot \sum_{i=0}^{r-1} (10^d)^i$, where $d$ is the number of digits of $n$.

References:

Imports (1)
  1. def OeisA86766.a Sequence $a(n)$ is the smallest $r > 0$ such that the concatenation of $n$, $r$ times with itself, multiplied by $10$ plus $1$, is prime, or $0$ if no such prime exists line 38 source

    Source documentation

    Sequence $a(n)$ is the smallest $r > 0$ such that the concatenation of $n$, $r$ times with itself, multiplied by $10$ plus $1$, is prime, or $0$ if no such prime exists.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Nat

    Proof uses: ite, Eq, OfNat.ofNat, List.length, Nat.digits, HPow.hPow, HMul.hMul, Finset.sum, Finset.range, HAdd.hAdd, InfSet.sInf, Set.ofPred, And, LT.lt, Nat.Prime

    13 instances, coercions and auxiliary constants left out.

    noncomputable def a (n : ℕ) : ℕ :=
    …
  2. theorem OeisA86766.a_0 Value of the sequence a at 0 line 49 source

    Source documentation

    Value of the sequence a at 0.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Eq, Nat, OeisA86766.a, OfNat.ofNat

    Proof uses: Eq.refl

    2 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

    Open to load the checked before-and-after goal states.

    theorem a_0 : a 0 = 0 := by rfl
    …

    Mentions: OeisA86766.a

  3. theorem OeisA86766.a_1 Value of the sequence a at 1 line 53 source

    Source documentation

    Value of the sequence a at 1.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Eq, Nat, OeisA86766.a, OfNat.ofNat

    Proof uses: IsLeast, Set.ofPred, And, LT.lt, Nat.Prime, HAdd.hAdd, HMul.hMul, Finset.sum, Finset.range, HPow.hPow, List.length, Nat.digits, And.intro, Membership.mem, Set, lowerBounds, id, Decidable.byContradiction, Not, of_decide_eq_true and 40 more

    41 instances, coercions and auxiliary constants left out.

    Tactic trace: 20 steps

    Open to load the checked before-and-after goal states.

    theorem a_1 : a 1 = 1 := by
    …

    Mentions: OeisA86766.a

  4. theorem OeisA86766.a_2 Value of the sequence a at 2 line 73 source

    Source documentation

    Value of the sequence a at 2.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Eq, Nat, OeisA86766.a, OfNat.ofNat

    Proof uses: List.length, Nat.digits, of_decide_eq_true, id, Bool, Decidable.decide, Bool.true, Eq.refl, IsLeast, Set.ofPred, And, LT.lt, Nat.Prime, HAdd.hAdd, HMul.hMul, Finset.sum, Finset.range, HPow.hPow, And.intro, Membership.mem and 65 more

    50 instances, coercions and auxiliary constants left out.

    Tactic trace: 32 steps

    Open to load the checked before-and-after goal states.

    theorem a_2 : a 2 = 3 := by
    …

    Mentions: OeisA86766.a

  5. theorem OeisA86766.a_3 Value of the sequence a at 3 line 103 source

    Source documentation

    Value of the sequence a at 3.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Eq, Nat, OeisA86766.a, OfNat.ofNat

    Proof uses: IsLeast, Set.ofPred, And, LT.lt, Nat.Prime, HAdd.hAdd, HMul.hMul, Finset.sum, Finset.range, HPow.hPow, List.length, Nat.digits, And.intro, Membership.mem, Set, lowerBounds, id, Decidable.byContradiction, Not, of_decide_eq_true and 40 more

    41 instances, coercions and auxiliary constants left out.

    Tactic trace: 20 steps

    Open to load the checked before-and-after goal states.

    theorem a_3 : a 3 = 1 := by
    …

    Mentions: OeisA86766.a

  6. theorem OeisA86766.a_4 Value of the sequence a at 4 line 123 source

    Source documentation

    Value of the sequence a at 4.

    standard axioms: Classical.choice, Quot.sound, propext what this means

    Statement uses: Eq, Nat, OeisA86766.a, OfNat.ofNat

    Proof uses: IsLeast, Set.ofPred, And, LT.lt, Nat.Prime, HAdd.hAdd, HMul.hMul, Finset.sum, Finset.range, HPow.hPow, List.length, Nat.digits, And.intro, Membership.mem, Set, lowerBounds, id, Decidable.byContradiction, Not, of_decide_eq_true and 40 more

    41 instances, coercions and auxiliary constants left out.

    Tactic trace: 20 steps

    Open to load the checked before-and-after goal states.

    theorem a_4 : a 4 = 1 := by
    …

    Mentions: OeisA86766.a

  7. theorem OeisA86766.conjecture1 What is the smallest integer $m > 1$ such that $a(10^m)$ is nonzero? sorry line 147 source

    Source documentation

    What is the smallest integer $m > 1$ such that $a(10^m)$ is nonzero?

    • Farideh Firoozbakht, Jan 07 2015

    depends on sorry what this means

    Statement uses: Eq, Option, Nat, sorryAx, Lean.Name, Bool.false, Lean.Name.num, Lean.Name.str, Lean.Name.anonymous, OfNat.ofNat, dite, Exists, And, LT.lt, Ne, OeisA86766.a, HPow.hPow, Classical.propDecidable, Option.some, InfSet.sInf and 3 more

    14 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

    Open to load the checked before-and-after goal states.

    theorem conjecture1 :
        answer(sorry) =
          if h : ∃ m, 1 < m ∧ a (10 ^ m) ≠ 0 then
            some (sInf {m | 1 < m ∧ a (10 ^ m) ≠ 0})
          else
            none := by
    …

    Mentions: OeisA86766.a

  8. theorem OeisA86766.conjecture2 Conjecture: If $n$ is not of the form $10^m$ then $a(n)$ is nonzero sorry line 161 source

    Source documentation

    Conjecture: If $n$ is not of the form $10^m$ then $a(n)$ is nonzero.

    • Farideh Firoozbakht, Jan 07 2015

    depends on sorry what this means

    Statement uses: Nat, LT.lt, OfNat.ofNat, Ne, HPow.hPow, OeisA86766.a

    Proof uses: sorryAx, Lean.Name, Bool.false, Lean.Name.num, Lean.Name.str, Lean.Name.anonymous

    12 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

    Open to load the checked before-and-after goal states.

    theorem conjecture2 (n : ℕ) (hn : 0 < n) (h : ∀ m : ℕ, n ≠ 10 ^ m) : a n ≠ 0 := by
    …

    Mentions: OeisA86766.a

  9. theorem OeisA86766.conjecture3 What is the smallest odd prime $p$ such that $(10^{p^2}-1)/(10^p-1)$ is a prime number (and $a(10^{p-1})$ could be nonzero)? sorry line 171 source

    Source documentation

    What is the smallest odd prime $p$ such that $(10^{p^2}-1)/(10^p-1)$ is a prime number (and $a(10^{p-1})$ could be nonzero)?

    • Farideh Firoozbakht, Jan 07 2015

    depends on sorry what this means

    Statement uses: Eq, Option, Nat, sorryAx, Lean.Name, Bool.false, Lean.Name.num, Lean.Name.str, Lean.Name.anonymous, OfNat.ofNat, dite, Exists, And, Nat.Prime, LT.lt, HDiv.hDiv, HSub.hSub, HPow.hPow, Classical.propDecidable, Option.some and 4 more

    22 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

    Open to load the checked before-and-after goal states.

    theorem conjecture3 :
        answer(sorry) =
          if h : ∃ p, p.Prime ∧ 2 < p ∧ ((10 ^ (p ^ 2) - 1) / (10 ^ p - 1)).Prime then
            some (sInf {p | p.Prime ∧ 2 < p ∧ ((10 ^ (p ^ 2) - 1) / (10 ^ p - 1)).Prime})
          else
            none := by
    …