Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Summed head-divisor endpoint replacement

Proved
Erdos390.Full.PaperScaleMarkedCell.headDivisorMain_sum_sub_common_le

by doctosil · Sep 17, 2026 · Mathlib c5ea003 (Lean v4.30.0)

analytic-number-theoryerdos-390erdos390-source-construction

Write L=log⁡nL=\log nL=logn, y=n2/9y=n^{2/9}y=n2/9, Y=⌊y⌋Y=\lfloor y\rfloorY=⌊y⌋, U=9/2U=9/2U=9/2, and vd=U−log⁡d/log⁡yv_d=U-\log d/\log yvd​=U−logd/logy. Let ρ\rhoρ denote the Dickman function. Fix a head pattern PPP with factor fff and modulus mmm, positive A,BA,BA,B, and integers n>1,d>0n>1,d>0n>1,d>0. Assume d≤Y4d\le Y^4d≤Y4, y≥2y\ge2y≥2, and L/5≤log⁡YL/5\le\log YL/5≤logY. For every a∣ma\mid ma∣m and C∈{A,B}C\in\{A,B\}C∈{A,B} assume Cn/(fad)≥max⁡(4,L)Cn/(fad)\ge\max(4,L)Cn/(fad)≥max(4,L) and log⁡(⌊Cn⌋/(fad))≤5log⁡Y\log(\lfloor Cn\rfloor/(fad))\le5\log Ylog(⌊Cn⌋/(fad))≤5logY, using natural division. Put E(C,g)=2+5(log⁡2+∣log⁡C−log⁡g∣)+(45/2)log⁡2E(C,g)=2+5(\log2+|\log C-\log g|)+(45/2)\log2E(C,g)=2+5(log2+∣logC−logg∣)+(45/2)log2 and FP(C)=∑a∣m∣μ(a)∣E(C,fa)C/(fa)F_P(C)=\sum_{a\mid m}|\mu(a)|E(C,fa)C/(fa)FP​(C)=∑a∣m​∣μ(a)∣E(C,fa)C/(fa). Let HaH_aHa​ be the Möbius-weighted difference of the two endpoint main terms at ⌊An⌋/(fad)\lfloor An\rfloor/(fad)⌊An⌋/(fad) and ⌊Bn⌋/(fad)\lfloor Bn\rfloor/(fad)⌊Bn⌋/(fad).

∣∑a∣mHa−∑a∣mμ(a)(B−A)nfadρ(vd)∣≤(FP(B)+FP(A))ndL.\left|\sum_{a\mid m}H_a-\sum_{a\mid m}\mu(a)\frac{(B-A)n}{fad}\rho(v_d)\right|\le\frac{(F_P(B)+F_P(A))n}{dL}.​a∣m∑​Ha​−a∣m∑​μ(a)fad(B−A)n​ρ(vd​)​≤dL(FP​(B)+FP​(A))n​.

This is the error estimate that permits head inclusion–exclusion to close on one common main term.

Preamble
import Mathlib
import Definitions.Def_erdos390_source_bank_interface
import Definitions.Def_erdos390_dickman_step_function
import Theorems.Thm_MediumPNT
import Definitions.Def_erdos390_analytic_foundations_001
import Theorems.Thm_Erdos390_Full_DickmanBasic_kernel_product_bound
import Theorems.Thm_Erdos390_Full_DickmanBasic_rho_pos_on_zero_five
import Theorems.Thm_Erdos390_Full_DickmanBasic_kernel_secondDerivative_first_bound

Formal statement
theorem Erdos390.Full.PaperScaleMarkedCell.headDivisorMain_sum_sub_common_le :
∀ (P : Erdos390.Full.HeadPattern.Pattern) {A B : Real} {n d : Nat},
  LT.lt.{0} (0 : Real) A →
    LT.lt.{0} (0 : Real) B →
      LT.lt.{0} (1 : Nat) n →
        LT.lt.{0} (0 : Nat) d →
          LE.le.{0} d (HPow.hPow.{0, 0, 0} (Erdos390.Full.ArithmeticModel.yNat n) (4 : Nat)) →
            LE.le.{0} (2 : Real) (Erdos390.Full.ArithmeticModel.y n) →
              LE.le.{0} (HMul.hMul.{0, 0, 0} (1 / 5 : Real) (Erdos390.Full.Scale.L n))
                  (Real.log ↑(Erdos390.Full.ArithmeticModel.yNat n)) →
                (∀ (a : Nat),
                    Membership.mem.{0, 0} (Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P)) a →
                      And
                        (LE.le.{0} (4 : Real)
                          (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} A ↑n)
                            ↑(HMul.hMul.{0, 0, 0} (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a)
                                d)))
                        (LE.le.{0} (Erdos390.Full.Scale.L n)
                          (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} A ↑n)
                            ↑(HMul.hMul.{0, 0, 0} (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a)
                                d)))) →
                  (∀ (a : Nat),
                      Membership.mem.{0, 0} (Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P)) a →
                        And
                          (LE.le.{0} (4 : Real)
                            (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} B ↑n)
                              ↑(HMul.hMul.{0, 0, 0} (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a)
                                  d)))
                          (LE.le.{0} (Erdos390.Full.Scale.L n)
                            (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} B ↑n)
                              ↑(HMul.hMul.{0, 0, 0} (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a)
                                  d)))) →
                    (∀ (a : Nat),
                        Membership.mem.{0, 0} (Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P)) a →
                          LE.le.{0}
                            (Real.log
                              ↑(HDiv.hDiv.{0, 0, 0} (Erdos390.Full.ArithmeticModel.physicalBound A n)
                                  (HMul.hMul.{0, 0, 0}
                                    (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a) d)))
                            (HMul.hMul.{0, 0, 0} (5 : Real) (Real.log ↑(Erdos390.Full.ArithmeticModel.yNat n)))) →
                      (∀ (a : Nat),
                          Membership.mem.{0, 0} (Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P)) a →
                            LE.le.{0}
                              (Real.log
                                ↑(HDiv.hDiv.{0, 0, 0} (Erdos390.Full.ArithmeticModel.physicalBound B n)
                                    (HMul.hMul.{0, 0, 0}
                                      (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a) d)))
                              (HMul.hMul.{0, 0, 0} (5 : Real) (Real.log ↑(Erdos390.Full.ArithmeticModel.yNat n)))) →
                        LE.le.{0}
                          (abs.{0}
                            (HSub.hSub.{0, 0, 0}
                              (∑ a ∈ Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P),
                                Erdos390.Full.StructuredCellAsymptotic.headDivisorMain P
                                  (Erdos390.Full.ArithmeticModel.physicalBound A n)
                                  (Erdos390.Full.ArithmeticModel.physicalBound B n)
                                  (Erdos390.Full.ArithmeticModel.yNat n) d a)
                              (∑ a ∈ Nat.divisors (Erdos390.Full.HeadPattern.Pattern.modulus P),
                                HMul.hMul.{0, 0, 0} (↑(ArithmeticFunction.moebius a))
                                  (HSub.hSub.{0, 0, 0}
                                    (HMul.hMul.{0, 0, 0}
                                      (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} B ↑n)
                                        ↑(HMul.hMul.{0, 0, 0}
                                            (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a) d))
                                      (Erdos390.Full.DickmanBasic.rho
                                        (Erdos390.Full.PaperScaleMarkedCell.paperDivisorCoordinate n d)))
                                    (HMul.hMul.{0, 0, 0}
                                      (HDiv.hDiv.{0, 0, 0} (HMul.hMul.{0, 0, 0} A ↑n)
                                        ↑(HMul.hMul.{0, 0, 0}
                                            (HMul.hMul.{0, 0, 0} (Erdos390.Full.HeadPattern.Pattern.factor P) a) d))
                                      (Erdos390.Full.DickmanBasic.rho
                                        (Erdos390.Full.PaperScaleMarkedCell.paperDivisorCoordinate n d)))))))
                          (HDiv.hDiv.{0, 0, 0}
                            (HMul.hMul.{0, 0, 0}
                              (HAdd.hAdd.{0, 0, 0} (Erdos390.Full.PaperScaleMarkedCell.endpointFamilyCoefficient P B)
                                (Erdos390.Full.PaperScaleMarkedCell.endpointFamilyCoefficient P A))
                              ↑n)
                            (HMul.hMul.{0, 0, 0} (↑d) (Erdos390.Full.Scale.L n))) := by sorry
Source
https://github.com/ShouqiaoW/erdos/blob/61325b10bbdc29f4fb5e0618b414b9f2189333ad/390/lean/Erdos390/Full/PaperScaleMarkedCell.lean#L266-L405

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me