Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

§4.2, pp. 16–17 — ∣Fgreat∣≤(n+1)(R+⌈log⁡1+ϵn⌉+1)(⌊3κ/ϵ2⌋+κκ)|F_{\mathrm{great}}|\le(n+1)(R+\lceil\log_{1+\epsilon}n\rceil+1)\binom{\lfloor3\kappa/\epsilon^2\rfloor+\kappa}{\kappa}∣Fgreat​∣≤(n+1)(R+⌈log1+ϵ​n⌉+1)(κ⌊3κ/ϵ2⌋+κ​)

Proved
BatchTesting.PTAS.card_FGreat_le

by mikedeng1 · Oct 20, 2026 · Mathlib 0df444a (Lean v4.33.1)

approximation-schemecountingp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1sequential-testing

Let (p,c,β)(p,c,\beta)(p,c,β) be an instance with n≥1n\ge1n≥1, pi∈[0,1]p_i\in[0,1]pi​∈[0,1], ci>0c_i>0ci​>0, β≥0\beta\ge0β≥0, let 0<ϵ≤10<\epsilon\le10<ϵ≤1, and let κ=⌈log⁡1+ϵ(n/ϵ)⌉\kappa=\lceil\log_{1+\epsilon}(n/\epsilon)\rceilκ=⌈log1+ϵ​(n/ϵ)⌉ and RRR the largest cost class. The number of great-looking states satisfies

∣Fgreat∣ ≤ (n+1)⋅(R+⌈log⁡1+ϵn⌉+1)⋅(⌊3κ/ϵ2⌋+κκ).|F_{\mathrm{great}}|\ \le\ (n+1)\cdot\big(R+\lceil\log_{1+\epsilon}n\rceil+1\big)\cdot\binom{\lfloor3\kappa/\epsilon^2\rfloor+\kappa}{\kappa}.∣Fgreat​∣ ≤ (n+1)⋅(R+⌈log1+ϵ​n⌉+1)⋅(κ⌊3κ/ϵ2⌋+κ​).

The three factors count the possible values of ψ(N)\psi(N)ψ(N) (at most n+1n+1n+1: −∞-\infty−∞ or a non-empty class), of ρ\rhoρ, and of the vector μ\muμ with ∥μ∥1≤3κ/ϵ2\|\mu\|_1\le3\kappa/\epsilon^2∥μ∥1​≤3κ/ϵ2 on κ\kappaκ middle classes; a great-looking state is determined by these parameters. The bound is O((∣I∣/ϵ)O(1/ϵ3))O((|I|/\epsilon)^{O(1/\epsilon^3)})O((∣I∣/ϵ)O(1/ϵ3)), which makes the dynamic program over FgreatF_{\mathrm{great}}Fgreat​ polynomial for fixed ϵ\epsilonϵ.

Formalization Note. This is the explicit content of the three bullets on pp. 16–17; their O(⋅)O(\cdot)O(⋅) conversions, and the running time itself, are not formalized.

Preamble
import Mathlib
import Definitions.Def_BatchTesting_PTAS_Model
Formal statement
namespace BatchTesting.PTAS

theorem card_FGreat_le {n : ℕ} (I : Instance n) (hI : I.Standing) (eps : ℝ) (h0 : 0 < eps) (h1 : eps ≤ 1) :
    (FGreat I eps).card ≤ (n + 1) * (R I eps + ⌈Real.logb (1 + eps) (n : ℝ)⌉₊ + 1) *
      Nat.choose (⌊3 * (kappa n eps : ℝ) / eps ^ 2⌋₊ + (kappa n eps).toNat) (kappa n eps).toNat := by sorry

end BatchTesting.PTAS
Source
Segev & Shaposhnik, A Polynomial-Time Approximation Scheme for Sequential Batch Testing of Series Systems, SSRN preprint 3277805 (Nov. 2018), pp. 16–17, §4.2 (Bounding |F_great|)
Human review
  • Endorsed by Shuze Chen · Oct 20, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 20, 2026

    Confirmed by the mission captain (proposal self-audit).

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 paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me