FormalConjectures/ErdosProblems/422.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

7 declarations, 4 contain sorry, 0 declared as axioms

Erdős Problem 422

References:

Imports (1)
  1. def Erdos422.IsHofstadterQ Documented declaration: IsHofstadterQ line 47 source

    Source documentation

    IsHofstadterQ f means that $f$ is Hofstadter's $Q$-sequence (OEIS A005185): $f(1) = f(2) = 1$ and for $n > 2$ $$ f(n) = f(n - f(n - 1)) + f(n - f(n - 2)), $$ where the recurrence requires $f(n - 1) < n$ and $f(n - 2) < n$, so that both arguments on the right-hand side are positive integers. The sequence begins $1, 1, 2, 3, 3, 4, \ldots$.

    At most one function satisfies this predicate. Some function satisfies it if and only if $f(n)$ is well-defined for all $n$, which is not known.

    standard axioms: propext what this means

    Statement uses: PNat

    Proof uses: And, Eq, OfNat.ofNat, LT.lt, HSub.hSub, HAdd.hAdd

    14 instances, coercions and auxiliary constants left out.

    def IsHofstadterQ (f : ℕ+ → ℕ+) : Prop :=
    …
  2. theorem Erdos422.erdos_422.test.f3 The third term of Hofstadter's $Q$-sequence is $f(3) = f(2) + f(2) = 2$ line 54 source

    Source documentation

    The third term of Hofstadter's $Q$-sequence is $f(3) = f(2) + f(2) = 2$.

    standard axioms: propext what this means

    Statement uses: PNat, Erdos422.IsHofstadterQ, Eq, OfNat.ofNat, Nat

    Proof uses: LT.lt, And, HSub.hSub, HAdd.hAdd, of_decide_eq_true, id, Bool, Decidable.decide, Bool.true, Eq.refl, Eq.mpr, congrFun', congrArg, Eq.trans, congr, rfl

    22 instances, coercions and auxiliary constants left out.

    Tactic trace: 5 steps

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

    theorem erdos_422.test.f3 : ∀ f : ℕ+ → ℕ+, IsHofstadterQ f → f 3 = 2 := by
    …

    Mentions: Erdos422.IsHofstadterQ

  3. theorem Erdos422.erdos_422.test.f4 The fourth term of Hofstadter's $Q$-sequence is $f(4) = f(2) + f(3) = 3$ line 62 source

    Source documentation

    The fourth term of Hofstadter's $Q$-sequence is $f(4) = f(2) + f(3) = 3$.

    standard axioms: propext what this means

    Statement uses: PNat, Erdos422.IsHofstadterQ, Eq, OfNat.ofNat, Nat

    Proof uses: Erdos422.erdos_422.test.f3, And, LT.lt, HSub.hSub, HAdd.hAdd, of_decide_eq_true, id, Bool, Decidable.decide, Bool.true, Eq.refl, Eq.mpr, congrFun', congrArg, Eq.trans, congr, rfl

    21 instances, coercions and auxiliary constants left out.

    Tactic trace: 7 steps

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

    theorem erdos_422.test.f4 : ∀ f : ℕ+ → ℕ+, IsHofstadterQ f → f 4 = 3 := by
    …

    Mentions: Erdos422.IsHofstadterQ

  4. theorem Erdos422.erdos_422 Let $f(1) = f(2) = 1$ and for $n > 2$ $$ f(n) = f(n - f(n - 1)) + f(n - f(n - 2)). $$ Does $f(n)$ miss infinitely many integers? sorry line 78 source

    Source documentation

    Let $f(1) = f(2) = 1$ and for $n > 2$ $$ f(n) = f(n - f(n - 1)) + f(n - f(n - 2)). $$ Does $f(n)$ miss infinitely many integers?

    depends on sorry what this means

    Statement uses: Iff, True, PNat, Erdos422.IsHofstadterQ, Set.Infinite, Set.ofPred, Ne

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

    1 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

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

    theorem erdos_422 : answer(sorry) ↔
        ∀ f : ℕ+ → ℕ+, IsHofstadterQ f → Set.Infinite {n | ∀ x, f x ≠ n} := by
    …

    Mentions: Erdos422.IsHofstadterQ

  5. theorem Erdos422.erdos_422.variants.surjective Is $f$ surjective? sorry line 86 source

    Source documentation

    Is $f$ surjective?

    depends on sorry what this means

    Statement uses: Iff, True, PNat, Erdos422.IsHofstadterQ, Function.Surjective

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

    1 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

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

    theorem erdos_422.variants.surjective : answer(sorry) ↔
        ∀ f : ℕ+ → ℕ+, IsHofstadterQ f → f.Surjective := by
    …

    Mentions: Erdos422.IsHofstadterQ

  6. theorem Erdos422.erdos_422.variants.growth_rate How does $f$ grow? sorry line 94 source

    Source documentation

    How does $f$ grow?

    depends on sorry what this means

    Statement uses: PNat, Erdos422.IsHofstadterQ, Asymptotics.IsBigO, Real, Filter.atTop, sorryAx, Bool.false

    Proof uses: Lean.Name, Lean.Name.num, Lean.Name.str, Lean.Name.anonymous, OfNat.ofNat, Nat

    21 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

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

    theorem erdos_422.variants.growth_rate :
        ∀ f : ℕ+ → ℕ+, IsHofstadterQ f →
        (fun n ↦ (f n : ℝ)) =O[atTop] (answer(sorry) : ℕ+ → ℝ) := by
    …

    Mentions: Erdos422.IsHofstadterQ

  7. theorem Erdos422.erdos_422.variants.eventually_const Does $f$ become stationary at some point? sorry line 103 source

    Source documentation

    Does $f$ become stationary at some point?

    depends on sorry what this means

    Statement uses: Iff, True, PNat, Erdos422.IsHofstadterQ, Filter.EventuallyConst, Filter.atTop

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

    13 instances, coercions and auxiliary constants left out.

    Tactic trace: 1 steps

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

    theorem erdos_422.variants.eventually_const : answer(sorry) ↔
        ∀ f : ℕ+ → ℕ+, IsHofstadterQ f → EventuallyConst f atTop := by
    …

    Mentions: Erdos422.IsHofstadterQ