Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in

Get started

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

Theoretical Computer Science

169 missions · 114 completed

The mathematical foundations of computation: which problems can be solved, by what algorithms, and at what cost in time, space, or communication. Distinguished by its emphasis on rigor and unconditional lower bounds, it spans computational complexity, algorithm design, automata and computability, cryptography, and the analysis of Boolean functions.

Missions

Open55Completed114All169
🏆Completed
Captain: marwahaha

More Asymmetry Bound: omega < 2.37134Research Paper

Motivation

The matrix-multiplication exponent measures how the arithmetic complexity of multiplying square matrices grows with the ir dimension. Known upper bounds come from constructing large independent matrix products inside tensor powers whose asymptotic rank is controlled. Improving the extraction, rather than finding a lower-rank starting tensor, has driven several recent advances.

Alman, Duan, Vassilevska Williams, Xu, Xu, and Zhou improve the combination-loss analysis by allowing all three variable directions to be treated differently. Their original fourth-power computation gives the bound ω<2.371339\omega<2.371339ω<2.371339. The mission targets the slightly weaker rational endpoint 2.371342.371342.37134, keeping the historical result distinct from the later AlphaEvolve numerical improvement incorporated into the latest manuscript. More Asymmetry Yields Faster Matrix Multiplication, version 2, SODA 2025.

Setting

Fix an arbitrary field KKK. The matrix-multiplication tensor ⟨a,b,c⟩K\langle a,b,c\rangle_K⟨a,b,c⟩K​ represents multiplication of an a×ba\times ba×b matrix by a b×cb\times cb×c matrix. A tensor's rank is the least number of pure tensors summing to it. The existing Lean definition matMulExp K is the infimum of log⁡R(⟨n,n,n⟩K)/log⁡n\log R(\langle n,n,n\rangle_K)/\log nlogR(⟨n,n,n⟩K​)/logn for integer dimensions n≥2n\ge2n≥2, with value 333 at the excluded dimensions 000 and 111. This definition, and the existing equivalence with the Strassen-preorder exponent, remain unchanged.

The source tensor is the literal fourth power T=CW5⊗4T=CW_5^{\otimes4}T=CW5⊗4​ of the Coppersmith–Winograd tensor. The public parenthesization is (CW5⊗CW5)⊗(CW5⊗CW5)(CW_5\otimes CW_5)\otimes(CW_5\otimes CW_5)(CW5​⊗CW5​)⊗(CW5​⊗CW5​). Its asymptotic rank is at most 74=24017^4=240174=2401. Its canonical coarse components are indexed by triples (i,j,k)(i,j,k)(i,j,k) with i+j+k=8i+j+k=8i+j+k=8. This is the fourth-power, recursion-level-three specialization described in Section 7, not the eighth-power specialization used by the later optimization note. More Asymmetry, Section 7.

A complete split distribution records frequencies of entire fine-grade words, rather than only the marginal split at the next recursion step. At level ℓ≥1\ell\ge1ℓ≥1, these words have length 2ℓ−12^{\ell-1}2ℓ−1 over the alphabet {0,1,2}\{0,1,2\}{0,1,2}. Three such distributions describe the X-, Y-, and Z-variable blocks. A restricted constituent power keeps only blocks approximately consistent with those distributions, in maximum-coordinate distance at most a specified ε≥0\varepsilon\ge0ε≥0. An interface tensor is a tensor product of these restricted constituent powers. The approximation tolerance and all three distributions are part of the interface. More Asymmetry, Definitions 3.4–3.6 and 4.1.

Formalization targets

The goal is the unconditional field-uniform statement

∀K  [Field(K)],matMulExp⁡(K)<237134100000.\forall K\;[\mathrm{Field}(K)],\qquad \operatorname{matMulExp}(K)<\frac{237134}{100000}.∀K[Field(K)],matMulExp(K)<100000237134​.

Its binders and exponent definition match the existing Schönhage and Stothers goals; only the declaration name and endpoint differ. No optimizer result, characteristic condition, distribution, or assumed value surplus is a hypothesis of the root.

The compact proposal has four milestones and the root, totaling five review items. The milestones concern literal fine-to-coarse source restrictions; the fourth-power rank budget; an actual strict six-symmetrized value surplus at the chosen parameter; and the conditional implication from that surplus to the exponent bound. Existing proved source and rank theorems are reused. The open surplus target contains the new complete-split extraction and exact numerical obligations, which are described separately in the proof outline rather than hidden in an opaque certificate definition.

The chosen internal parameter is τ0=3952233/5000000\tau_0=3952233/5000000τ0​=3952233/5000000, so

2.371339<3τ0=2.3713398<2.37134.2.371339<3\tau_0=2.3713398<2.37134.2.371339<3τ0​=2.3713398<2.37134.

The substantive value target is the existence of a real V>2401V>2401V>2401 such that the actual source has six-symmetrized τ0\tau_0τ0​-value at least VVV in the existing finite-witness semantics. The strict slack leaves room to translate limiting extraction rates into strict lower bases. Neither the existence of that surplus nor a completed exact numerical certificate is claimed at proposal time.

Significance

This formalization would capture a new structural improvement, not a re-optimization of the same DWZ square data. Its distinguishing feature is sequentially obtaining the necessary ownership properties for X, then Y, then Z, while preserving more useful fine blocks. The resulting complete-split and interface-tensor theory is also the mathematical foundation for the later AlphaEvolve optimization. More Asymmetry, Sections 2, 4–6; Dupont et al., Section 2.

The known mathematical result is not an open conjecture. The open work is its machine-checked reconstruction. The earlier square and Stothers roots are marked Proved. The newer DWZ fourth-power root has an accepted reduction but remains Open. Its literal fourth source, rank budget, sixfold-symmetry bridge and entropy-certificate infrastructure can be reused independently of that unfinished endpoint. A proof of the numerical DWZ bound alone would not imply the smaller bound targeted here.

Difficulty

The old hashing interface guarantees both coarse X- and Y-block uniqueness. The new method initially requires only coarse X-block uniqueness. Fine Y-block compatibility and usefulness must then establish the ownership needed for the subsequent Z-stage. Applying a theorem whose hypotheses already demand coarse Y uniqueness would discard the new method's essential advantage. Six coordinate permutations create six regions whose parameters and output interfaces must remain consistent. More Asymmetry, Section 4.1 and Figure 1.

Removing incompatible fine blocks creates holes. The relevant repair theorem concerns holes in all three modes and a quantitative supply of broken interface copies. It cannot be replaced without proof by the older square-specific Z-only repair interface. The global and recursive stages also carry subexponential losses and approximation tolerances; their limiting order must be explicit. Numerical feasibility is a separate obligation: floating-point parameters and optimization success are not exact normalization, marginal, entropy, or logarithm proofs. More Asymmetry, Theorem 4.2, Theorems 5.3 and 6.4, and Section 7.

Formalization scope

The environment is pinned to Mathlib 777aaa61dcd2a1258d2b4962dbe983ede4d23b2e and Lean v4.29.0-rc3. The development reuses TensorObj, MMObj, restrictions, degenerations, tensor powers, existing tau-value predicates, and matMulExp. The root is uniform over arbitrary fields. Source relations remain target-first: a restriction of A from B is written Restrict A B. A collection of overlapping constituent restrictions must not be relabeled as an external direct sum.

Complete split distributions, simultaneous three-mode projections, interface tensors, region permutations, and explicit finite extraction maps form reusable infrastructure. Exact rational profiles require compatible lengths; approximate profiles require their stated tolerance and limiting argument. No constant-valued replacement for tensor value, vacuous witness hypothesis, or certificate that merely assumes the desired extraction is admissible.

The authors' released code and parameter archive is the provenance source for the original computation. Versioned archive and witness hashes belong to the companion source audit. The optimization program need not be formalized: an exact certificate checker must establish its own normalization, support, marginal and interval conditions. Contributions to complete-split interfaces, sequential ownership, three-mode repair, recursive extraction, entropy certificates, and finite source-to-exponent bridges all advance this mission.

Selected references

  • Josh Alman, Ran Duan, Virginia Vassilevska Williams, Yinzhan Xu, Zixuan Xu, and Renfei Zhou, More Asymmetry Yields Faster Matrix Multiplication, SODA 2025. Pinned version 2.
  • Authors' code and parameters for the original fourth-power bounds. OSF release.
  • Ran Duan, Hongxun Wu, and Renfei Zhou, Faster Matrix Multiplication via Asymmetric Hashing, FOCS 2023. Version 5.
  • Emilien Dupont et al., Improving the matrix multiplication exponent with modern optimization and AlphaEvolve, 2026 preprint. Version 1.
149 thms10 active usersReviewed
🏆Completed
Captain: marwahaha

Duan–Wu–Zhou Fourth-Power Bound: omega < 2.37193Research Paper

Motivation

The matrix-multiplication exponent measures how the arithmetic cost of multiplying square matrices grows with their dimension. An improvement in this exponent is relevant both to algebraic complexity and to algorithms whose running times depend on matrix multiplication. This mission formalizes a known improvement using the fourth power of the Coppersmith–Winograd tensor; it does not claim a new mathematical record.

Duan, Wu, and Zhou identify a loss that arises when constituent tensors are analyzed independently although some of their finer components can coexist inside a shared variable block. Their asymmetric-hashing method recovers part of this combination loss. The paper's headline result concerns the eighth power. Its separate fourth-power computation reports 2.3719192.3719192.371919 in Table 3, printed page 78. The present target is the slightly weaker exact rational endpoint 2.371932.371932.37193. Duan–Wu–Zhou, Faster Matrix Multiplication via Asymmetric Hashing.

Setting

Fix an arbitrary field KKK. The matrix-multiplication tensor ⟨a,b,c⟩K\langle a,b,c\rangle_K⟨a,b,c⟩K​ encodes multiplication of an a×ba\times ba×b matrix by a b×cb\times cb×c matrix. Its tensor rank is the smallest number of pure tensors whose sum is that tensor. The existing Lean definition matMulExp K takes the infimum of log⁡R(⟨n,n,n⟩K)/log⁡n\log R(\langle n,n,n\rangle_K)/\log nlogR(⟨n,n,n⟩K​)/logn over integers n≥2n\ge2n≥2, with the value 333 at the two excluded small dimensions. This definition is reused without alteration.

A restriction applies a linear map separately to each of a tensor's three variable spaces. A degeneration allows polynomial families of such maps and takes an appropriate leading coefficient. The order of the Lean relation is target first: Restrict A B means that AAA is obtained from BBB. A direct sum uses disjoint variable spaces; a collection of overlapping restrictions does not constitute a direct sum.

The Coppersmith–Winograd tensor CWqCW_qCWq​ has border rank at most q+2q+2q+2. This mission fixes q=5q=5q=5 and uses the literal tensor T=(CW5⊗CW5)⊗(CW5⊗CW5)T=(CW_5\otimes CW_5)\otimes(CW_5\otimes CW_5)T=(CW5​⊗CW5​)⊗(CW5​⊗CW5​), whose asymptotic-rank budget is 74=24017^4=240174=2401. Its standard coordinate partition has 45 coarse components TijkT_{ijk}Tijk​ indexed by nonnegative integers i+j+k=8i+j+k=8i+j+k=8. Each coarse component consists of ordered products of square components, whose grades sum to (i,j,k)(i,j,k)(i,j,k). Duan–Wu–Zhou, Sections 3 and 6–8.

A restricted-splitting value pair consists of a lower value bound and a prescribed distribution on finer Z-variable blocks. In a tensor power, Z-blocks with the wrong empirical split distribution are removed before measuring value. Sixfold symmetrization, using all permutations of the three modes, is part of this definition. Keeping the scalar and discarding the prescribed distribution loses information required by the recursion. Duan–Wu–Zhou, Definition 3.9, Equation (3), and Definition 8.1.

Formalization targets

The goal is precisely

∀K  [Field(K)],matMulExp⁡(K)<237193100000.\forall K\;[\mathrm{Field}(K)],\qquad \operatorname{matMulExp}(K)<\frac{237193}{100000}.∀K[Field(K)],matMulExp(K)<100000237193​.

It has the same field quantification and exponent definition as the completed Schönhage and Stothers goals. Only the name and rational endpoint change. No distribution, optimizer, characteristic restriction, or unproved value bound is a hypothesis of this goal.

The supporting targets concern the literal fourth-power source; prescribed-splitting component values; the recursive and global extraction inequalities of Equations (34) and (25); an exact certificate for the released fourth-power computation; and the value-to-exponent implication of Theorem 3.2. The proof outline distinguishes stable formal statements from source-level tasks whose complete Lean interfaces still require development. It does not turn an unspecified certificate into an assumption that the desired extraction exists.

The compact milestone list contains four precise statements: the literal fine-to-coarse product restriction; the fourth-power asymptotic-rank bound; existence of a strict six-symmetrized value surplus; and the conditional implication from that surplus to the goal. Together with the root, these are five review items. The first, second, and fourth milestones are marked Proved. The surplus remains Open. An accepted root reduction links the surplus to the proved capstone; it is a proof sketch, not a proof of the exponent bound. Recursive component extraction and exact numerical certification remain substantial work inside that open target.

The planned internal parameter is τ=790643/1000000\tau=790643/1000000τ=790643/1000000. Thus 3τ=2.371929<2.371933\tau=2.371929<2.371933τ=2.371929<2.37193. The substantive value obligation is a strict surplus over 240124012401 for the actual fourth-power source, with asymptotic losses absorbed by choosing strict lower rates. The exact certificate must establish this surplus; neither its existence nor its numerical slack is presently claimed as proved.

Significance

The result would extend the formalized Stothers endpoint 2.37372.37372.3737 to an asymmetric fourth-power bound. More importantly, it would provide restricted-splitting interfaces that can support subsequent higher-power and more-asymmetric analyses. The mathematical improvement is already established in the cited paper. The task here is to reconstruct its argument with machine-checked statements, concrete tensor maps, and exact numerical bounds.

The earlier square and Stothers mission roots are marked Proved. Reusable infrastructure includes polynomial degenerations, tensor powers, direct-sum value witnesses, hashing and hole-repair lemmas, the literal fourth-power grading, and the final exponent bridge. Two additional literal fourth-power support/restriction bridges and an additive entropy certificate with directed-log inputs are also marked Proved. These statuses do not imply that the new restricted-value recursion or numerical witness is already formalized.

Difficulty

The central difficulty is retaining the correct dependence between each value bound and its prescribed split distribution. The released fourth-power data contains consumer-specific copies of square value pairs. Equal coarse grades do not justify identifying their chosen distributions. The 21 positive fourth-power components use the six-region recursion, whereas the 24 components with a zero coordinate require the boundary merging argument. Duan–Wu–Zhou, Equation (34), Section 7.3, and released implementation.

Global hashing must additionally control competitors with the same marginals, shared Z-blocks, missing fine blocks, and subexponential losses. An isolated restriction into each constituent is insufficient to establish a simultaneous extraction. Numerical optimization presents a separate issue: floating-point normalization and approximate maximum-entropy computations are not exact feasibility or entropy proofs. Exact marginal constraints, positivity domains, and directed error bounds must all be checked.

Formalization scope

The environment is pinned to Mathlib 777aaa61dcd2a1258d2b4962dbe983ede4d23b2e and Lean v4.29.0-rc3. The development reuses TensorObj, MMObj, Degenerates, HasTauValueAtLeast, the six-symmetrized value infrastructure, and matMulExp. All endpoint theorems remain uniform over arbitrary fields. Finite profiles use exact integer counts; rational distributions must have compatible unbounded lengths before an asymptotic statement is invoked. Real limiting rates are represented with explicit strict slack where the existing finite-witness predicate does not guarantee endpoint attainment.

No constant-valued replacement for tensor value, opaque witness carrying its desired conclusion, or external direct sum substituted for overlapping source blocks is admissible. New definitions must specify the actual coordinate projections and restrictions they represent. The authors' optimizer is used to find candidate data, not trusted as a proof oracle. Contributions to restricted-power semantics, consumer-specific square pairs, boundary merging, recursive extraction, exact entropy bounds, and source-to-exponent bridges are all directly relevant to the goal.

Selected references

  • Ran Duan, Hongxun Wu, and Renfei Zhou, Faster Matrix Multiplication via Asymmetric Hashing, FOCS 2023. Full paper, version 5.
  • Duan–Wu–Zhou, accompanying optimization and verification code, including power4_dup_2.371919.mat. Authors' release.
  • A. M. Davie and A. J. Stothers, Improved Bound for Complexity of Matrix Multiplication, Proceedings of the Royal Society of Edinburgh Section A 143(2), 2013. DOI.
  • Arnold Schönhage, Partial and Total Matrix Multiplication, SIAM Journal on Computing 10(3), 1981. DOI.
125 thms10 active usersReviewed
🏆Completed
Formal VerificationMathematical Logic·Captain: Rizwan G Mir

The Cook-Levin Theorem: NP-Completeness of Boolean Satisfiability in Lean 4Research Paper

Introduction

The Cook-Levin theorem states that CNF SAT is NP-complete. This mission formalizes the theorem over a multi-tape Turing machine model in Lean 4.

Main Goal

Prove CookLevin.cook_levin_theorem:

NPCompleteSATNPComplete SATNPCompleteSAT

under the decider and reduction hypotheses.

175 thms9 active usersReviewed
🏆Completed
Captain: marwahaha

Davie–Stothers Fourth-Power Bound: omega < 2.3737Research Paper

Motivation

The matrix-multiplication exponent ω\omegaω measures the asymptotic arithmetic cost of multiplying square matrices. An upper bound ω<c\omega<cω<c means that, over the field under consideration, two n×nn\times nn×n matrices can be multiplied using O(nc+ε)O(n^{c+\varepsilon})O(nc+ε) field operations for every ε>0\varepsilon>0ε>0. It is a central benchmark in algebraic complexity and controls the exponent of many algorithms that use matrix multiplication as a subroutine.

Coppersmith and Winograd's 1990 analysis of the square of their tensor established ω<2.375477\omega<2.375477ω<2.375477. That number remained the record for roughly two decades. Stothers' 2010 thesis first obtained a smaller exponent by analyzing the fourth tensor power, and Davie and Stothers later supplied a self-contained journal treatment. Their Theorem 5.3 and numerical parameters give ω<2.373689703\omega<2.373689703ω<2.373689703; see Davie--Stothers, printed pp. 367--368. The result is the first historical step below the classical tensor-square barrier and is the natural next capstone after a formal proof of the 2.3754772.3754772.375477 bound.

This mission formalizes the Davie--Stothers fourth-power argument at the exact rational endpoint 2.37372.37372.3737. It concentrates on the new mathematical layer introduced by the fourth power: five non-matrix constituents, their recursive value estimates, and the two-dimensional same-marginal ambiguity in the final distribution count.

Setting

For a field KKK, an order-three tensor represents a bilinear map. The matrix-multiplication tensor

⟨a,b,c⟩K=∑i<a∑j<b∑k<cxij⊗yjk⊗zki\langle a,b,c\rangle_K =\sum_{i<a}\sum_{j<b}\sum_{k<c} x_{ij}\otimes y_{jk}\otimes z_{ki}⟨a,b,c⟩K​=i<a∑​j<b∑​k<c∑​xij​⊗yjk​⊗zki​

encodes multiplication of an a×ba\times ba×b matrix by a b×cb\times cb×c matrix. Restrictions apply linear maps to the three tensor legs; degenerations permit polynomial families of maps. A direct sum of matrix-multiplication tensors has disjoint variable blocks and can be converted into an exponent inequality by Schönhage's asymptotic sum inequality.

The Coppersmith--Winograd tensor CWqCW_qCWq​ has border rank at most q+2q+2q+2 and a three-class coordinate partition. Its square decomposes into fifteen coarse constituents φijk\varphi_{ijk}φijk​ with i+j+k=4i+j+k=4i+j+k=4. Davie--Stothers square this decomposition again. The fourth power has forty-five constituents with indices summing to eight, grouped into ten symmetry classes represented by

φ008, φ017, φ026, φ035, φ044, φ116, φ125, φ134, φ224, φ233.\varphi_{008},\ \varphi_{017},\ \varphi_{026},\ \varphi_{035},\ \varphi_{044}, \ \varphi_{116},\ \varphi_{125},\ \varphi_{134},\ \varphi_{224},\ \varphi_{233}.φ008​, φ017​, φ026​, φ035​, φ044​, φ116​, φ125​, φ134​, φ224​, φ233​.

The first five classes are rectangular matrix-multiplication tensors. The last five require recursive value bounds. With ρ∈[2,3]\rho\in[2,3]ρ∈[2,3], the paper writes

E=(2q)ρ,H=(q2+2)ρ,L=4qρ(qρ+2),E=(2q)^\rho,\qquad H=(q^2+2)^\rho,\qquad L=4q^\rho(q^\rho+2),E=(2q)ρ,H=(q2+2)ρ,L=4qρ(qρ+2),

and states the five lower bounds in Lemma 5.1. The final fourth-power extraction assigns frequencies to the ten symmetry classes. Their coordinate marginals are encoded by the 9×109\times109×10 matrix QQQ in Equation (5.2); its kernel is the two-dimensional space YYY displayed immediately after that equation.

The paper's bounds are limiting exponential rates and may carry subexponential losses in their finite Salem--Spencer extractions. Prove2Me's HasTauValueAtLeast predicate instead records a constant-relative finite witness. The source-faithful formal statements therefore assert attainment of every fixed nonnegative base strictly below each displayed limiting rate, rather than unjustified attainment of the limiting endpoint itself. This downward-closed form retains the complete asymptotic conclusion and is exactly what the final strict numerical surplus needs.

Formalization targets

Goal: the Davie--Stothers fourth-power bound

For every field KKK,

matMulExp⁡(K)<2373710000=2.3737.\operatorname{matMulExp}(K)<\frac{23737}{10000}=2.3737.matMulExp(K)<1000023737​=2.3737.

The source's computed endpoint 2.3736897032.3736897032.373689703 is strictly smaller, giving slack for an exact rational certificate. The Lean goal has exactly the same field quantification and matMulExp definition as the existing Coppersmith--Winograd mission; only the theorem identifier and endpoint change.

Source-level milestones

The mission records the canonical nine-grading of CW6⊗4CW_6^{\otimes4}CW6⊗4​ and the ten symmetry classes of Table 1. It formalizes all five clauses of Lemma 5.1 for φ116\varphi_{116}φ116​, φ125\varphi_{125}φ125​, φ134\varphi_{134}φ134​, φ224\varphi_{224}φ224​, and φ233\varphi_{233}φ233​ in every-strict-lower-base form; Equation (5.2) and the stated basis of ker⁡Q\ker QkerQ; Lemma 5.2's entropy minimization along that kernel; Theorem 5.3's downward-closed fourth-power value inequality; and the Table 2 numerical specialization. The final milestones connect the resulting tau-value surplus to the border-rank budget and transfer the Strassen-preorder exponent bound to matMulExp.

Significance

Mathematically, this theorem is the first improvement obtained by passing from the square to the fourth power of the Coppersmith--Winograd tensor. It establishes the recursive constituent pattern used by the later eighth-, sixteenth-, and higher-power analyses. In particular, the five formulas in Lemma 5.1 are the first complete catalogue of genuinely recursive fourth-power constituents.

For formalization, the mission creates a reusable representation of higher-power CW gradings and their symmetry orbits. It also forces a distinction between a locally chosen joint type and all other types with the same marginals. Lemma 5.2 is the exact finite-dimensional entropy correction needed when the marginal map has nontrivial kernel. That infrastructure can be reused by later refined-laser and complete-split missions.

The result is known mathematically. The open task is a machine-checked reconstruction. Prove2Me already contains the CW tensor, its characteristic-free border-rank degeneration, its canonical square grading and constituent restrictions, the Salem--Spencer layer, direct-sum tau-value witnesses, the asymptotic sum inequality, and the exponent bridge. The exact optimizer identity for the φ116\varphi_{116}φ116​ profile is also proved. The remaining frontier is to connect the literal fourth-power constituents to finite direct-sum extractions, then assemble all five value estimates and the final kernel-corrected distribution count.

Difficulty

The fourth power contains 225 ordered products before symmetry grouping. A formal proof must show that each claimed constituent is the literal block of CWq⊗4CW_q^{\otimes4}CWq⊗4​ and that its recursive decomposition uses the correct variable spaces. Replacing a sum of overlapping blocks by an external direct sum would make the value bound artificially strong.

The five non-matrix classes have different feasible frequency polytopes. Their optimizer formulas are valid only after the corresponding nonnegativity and normalization conditions are checked. The φ233\varphi_{233}φ233​ class already has a nontrivial same-marginal family. At the global level the map QQQ has a two-dimensional kernel, so marginal counts alone do not determine a unique joint distribution. Ignoring that kernel removes the entropy penalty and invalidates Theorem 5.3.

Finally, Table 2 contains decimal witnesses obtained numerically. A formal proof must replace floating-point evaluation by exact rational parameters and certified bounds for logarithms and real powers, while retaining strict slack at 23737/1000023737/1000023737/10000.

Formalization scope

The development uses environment 777aaa61dcd2a1258d2b4962dbe983ede4d23b2e and the existing TensorObj, MMObj, restriction, degeneration, HasTauValueAtLeast, tensorAsymptoticRank, matMulExp_strassen, and matMulExp declarations. Top-level theorems quantify over an arbitrary field. Finite block indices and symmetry classes use finite types; frequency vectors and entropy inequalities use real numbers; exact finite profiles use natural numbers before passing to cofinal asymptotics.

The capstone specializes to q=6q=6q=6 and the fourth tensor power. Generic grading, orbit, multinomial, entropy, and optimizer lemmas are welcome when they shorten later missions. Every value theorem must ultimately be backed by restrictions or degenerations to direct sums of concrete matrix-multiplication tensors. An opaque value functional, a constituent definition that is an external sum rather than the source block, or a numerical hypothesis that assumes the desired endpoint is outside scope.

Contributions are welcome for the literal nine-grading, symmetry-orbit classification, the five constituent extractions, exact address factorizations, optimizer feasibility, the kernel calculation and Lemma 5.2, exact Table 2 arithmetic, and the final exponent assembly.

Selected references

  • A. M. Davie and A. J. Stothers, Improved Bound for Complexity of Matrix Multiplication, Proceedings of the Royal Society of Edinburgh Section A: Mathematics 143(2), 2013, pp. 351--369. Author PDF and DOI 10.1017/S0308210511001646.
  • A. J. Stothers, On the Complexity of Matrix Multiplication, PhD thesis, University of Edinburgh, 2010. Edinburgh Research Archive.
  • Don Coppersmith and Shmuel Winograd, Matrix Multiplication via Arithmetic Progressions, Journal of Symbolic Computation 9, 1990, pp. 251--280. DOI 10.1016/S0747-7171(08)80013-2.
  • Arnold Schönhage, Partial and Total Matrix Multiplication, SIAM Journal on Computing 10(3), 1981, pp. 434--455. DOI 10.1137/0210032.
171 thms8 active usersReviewed
🏆Completed
CombinatoricsComplexity TheoryGraph Theory+1·Captain: mikedeng1

Scheduling Subject to Resource Constraints: Classification and Complexity II: Unit-Time Jobs on Two Uniform Machines with Unit Resources Are Strongly NP-hardResearch Paper

Motivation

Machine scheduling asks how to assign jobs to machines over time. In many applications a job also needs additional scarce resources while it runs: a tool, a skilled operator, a memory bank, a channel. Adding such resources can turn a problem with a polynomial algorithm into an NP-hard one. Błażewicz, Lenstra and Rinnooy Kan (DAM 1983) extended the standard three-field classification α ∣ β ∣ γ\alpha\,|\,\beta\,|\,\gammaα∣β∣γ of scheduling problems (Graham, Lawler, Lenstra and Rinnooy Kan 1979) with a resource field resλσρres\lambda\sigma\rhoresλσρ. They then drew the complete borderline between easy and hard problems for unit-time jobs, identical or uniform machines and the makespan criterion. Their Fig. 2 marks each problem type as polynomially solvable or NP-hard.

This mission formalizes the two hardness results of that classification that come from graph partition problems (Theorems 2 and 3, p. 15). Two identical machines are easy under any resource constraints (Theorem 1, after Garey and Johnson 1975). Theorems 2 and 3 show that a third identical machine, or two machines of different speeds, already makes the problem strongly NP-hard, once the number of unit resources is part of the input.

Setting

There are nnn jobs J1,…,JnJ_1,\dots,J_nJ1​,…,Jn​ and mmm machines M1,…,MmM_1,\dots,M_mM1​,…,Mm​. Each machine processes at most one job at a time, and each job runs on one machine without interruption. Machine MiM_iMi​ has a speed qi>0q_i>0qi​>0, and every job has unit execution requirement pj=1p_j=1pj​=1, so it takes time 1/qi1/q_i1/qi​ on MiM_iMi​. Identical machines (PPP) are the case qi=1q_i=1qi​=1; uniform machines (QQQ) allow arbitrary speeds.

There are lll resources R1,…,RlR_1,\dots,R_lR1​,…,Rl​. Resource RhR_hRh​ has a positive integer size shs_hsh​, the amount available at any time. Job JjJ_jJj​ needs a nonnegative integer amount rhjr_{hj}rhj​ of RhR_hRh​ throughout its execution. A schedule assigns each job a machine μ(j)\mu(j)μ(j) and a start time Sj≥0S_j\ge 0Sj​≥0. Its completion time is Cj=Sj+1/qμ(j)C_j=S_j+1/q_{\mu(j)}Cj​=Sj​+1/qμ(j)​, and it is being executed at every time ttt with Sj≤t<CjS_j\le t<C_jSj​≤t<Cj​. A schedule is feasible when:

  • jobs on the same machine do not overlap in time;
  • at every time ttt, the set StS_tSt​ of jobs being executed satisfies
∑j∈Strhj≤sh(h=1,…,l).\sum_{j\in S_t} r_{hj}\le s_h\qquad(h=1,\dots,l).j∈St​∑​rhj​≤sh​(h=1,…,l).

The makespan is Cmax⁡=max⁡jCjC_{\max}=\max_j C_jCmax​=maxj​Cj​.

The resource type res⋅11res{\cdot}11res⋅11 means three things: the number lll of resources is part of the input, every size is sh=1s_h=1sh​=1, and every requirement satisfies rhj≤1r_{hj}\le1rhj​≤1. A unit resource is therefore a conflict: two jobs that both need it can never run at the same time. The problems here have no precedence constraints. Pm ∣ res⋅11, pj=1 ∣ Cmax⁡Pm\,|\,res{\cdot}11,\,p_j=1\,|\,C_{\max}Pm∣res⋅11,pj​=1∣Cmax​ and Qm ∣ res⋅11, pj=1 ∣ Cmax⁡Qm\,|\,res{\cdot}11,\,p_j=1\,|\,C_{\max}Qm∣res⋅11,pj​=1∣Cmax​ ask for a feasible schedule of minimum makespan. Their decision versions ask, for a threshold yyy, whether a feasible schedule with Cmax⁡≤yC_{\max}\le yCmax​≤y exists.

The source problems are two graph problems on a graph G=(V,E)G=(V,E)G=(V,E) with ∣V∣=3t|V|=3t∣V∣=3t:

  • PARTITION INTO TRIANGLES: can VVV be partitioned into ttt triples of pairwise adjacent vertices?
  • PARTITION INTO PATHS OF LENGTH 2: can VVV be partitioned into ttt triples, each with at most one nonadjacent pair, that is, each spanning a path of length 2?

Both are NP-complete (Garey and Johnson 1979, problems GT11 and GT13).

The construction of p. 15 introduces one job per vertex and one unit resource R{j,k}R_{\{j,k\}}R{j,k}​ per nonadjacent pair {j,k}\{j,k\}{j,k}, required by JjJ_jJj​ and JkJ_kJk​ only.

Formalization targets

Goal: Theorem 3

Q2 ∣ res⋅11, pj=1 ∣ Cmax⁡ is NP-hard in the strong sense.Q2\,|\,res{\cdot}11,\,p_j=1\,|\,C_{\max}\ \text{is NP-hard in the strong sense.}Q2∣res⋅11,pj​=1∣Cmax​ is NP-hard in the strong sense.

Formally: if the language of PARTITION INTO PATHS OF LENGTH 2 is NP-hard, then the language of unary codes of yes-instances of the decision version of Q2 ∣ res⋅11, pj=1 ∣ Cmax⁡Q2\,|\,res{\cdot}11,\,p_j=1\,|\,C_{\max}Q2∣res⋅11,pj​=1∣Cmax​ is NP-hard. The two speeds are arbitrary positive integers.

Milestones

  1. The construction's key property (p. 15). In the constructed instance, two distinct jobs can be executed simultaneously if and only if their vertices are adjacent.
  2. The triangle equivalence (proof of Theorem 2). GGG has a partition into triangles if and only if the constructed instance on three identical machines has a feasible schedule with Cmax⁡≤tC_{\max}\le tCmax​≤t.
  3. Theorem 2. P3 ∣ res⋅11, pj=1 ∣ Cmax⁡P3\,|\,res{\cdot}11,\,p_j=1\,|\,C_{\max}P3∣res⋅11,pj​=1∣Cmax​ is NP-hard in the strong sense, given the NP-hardness of PARTITION INTO TRIANGLES.
  4. The paths equivalence (proof of Theorem 3). GGG has a partition into paths of length 2 if and only if the constructed instance on two uniform machines with speeds q1=2q_1=2q1​=2, q2=1q_2=1q2​=1 has a feasible schedule with Cmax⁡≤tC_{\max}\le tCmax​≤t.

Significance

The results. Theorems 2 and 3 are two of the minimal NP-hard problems in the paper's classification. Together with Theorem 1 they place the borderline exactly: with unit resources whose number is part of the input, two identical machines are polynomial, while three identical machines, or two machines of different speeds, are strongly NP-hard. Strong NP-hardness rules out pseudo-polynomial algorithms unless P = NP, and it carries over to every more general resource type and machine environment in Fig. 1 and Fig. 2. Section 4.1 of the paper also derives hardness for ∑Cj\sum C_j∑Cj​ and Lmax⁡L_{\max}Lmax​ from these instances.

Formalizing it. The results are classical and proved on paper, but the paper's proofs are one sentence each ("Clearly", "It is easily seen"). No machine-checked proof exists, and the platform has no model of resource-constrained scheduling with real-valued time. This mission produces that model. It also produces a precise statement of strong NP-hardness on top of Cook's Turing-machine definitions, and the first formal NP-hardness reductions from graph partition problems to scheduling.

Difficulty

The scheduling half of each equivalence depends on the real-time model. On two uniform machines of speeds 2 and 1, jobs take time 12\tfrac1221​ and 111, so jobs on the fast machine start at half-integers or anywhere else. The resource constraint must hold at every real time, not at a finite set of checkpoints. An argument that treats time as integer slots applies to the triangle case but does not transfer to the paths case.

The complexity half needs polynomial-time computability of the construction on Cook's one-tape Turing machines, on encoded strings that include malformed inputs. It also needs closure of polynomial-time reductions under composition, which the imported complexity layer states but does not prove.

Formalization scope

  • Time and schedules. Start times are nonnegative reals, execution intervals are half-open [Sj,Cj)[S_j,C_j)[Sj​,Cj​), and the resource constraints are imposed at every real time. Schedules are nonpreemptive.
  • Indices. Jobs, machines and resources are 0-based (Fin n, Fin m, Fin l), so q1,q2q_1,q_2q1​,q2​ are q 0, q 1.
  • Decision versions. "NP-hard" refers to the decision version with a threshold yyy. Thresholds are natural numbers and the Q2Q2Q2 speeds are positive integers. This restricted problem is a subproblem of the one with rational data, so its hardness is the stronger statement.
  • Encodings and strong NP-hardness. Instances are strings over a two-letter alphabet with every number in unary. Graphs are ttt in unary followed by the 3t×3t3t\times 3t3t×3t adjacency matrix, so ∣V∣=3t|V|=3t∣V∣=3t is part of the instance. Languages contain only codes of yes-instances. Strong NP-hardness is NP-hardness of the unary code language. With unary numbers, Max(I)≤Length(I)\mathrm{Max}(I)\le\mathrm{Length}(I)Max(I)≤Length(I), so this is equivalent to Garey and Johnson's definition. The complexity layer is the published module CookPvsNP_defs.
  • Cited hypothesis. Each hardness theorem takes as its only hypothesis the NP-hardness of its source problem, which the paper cites from Garey and Johnson rather than proves. The hypothesis is a true statement about a nonempty, non-universal language. The statements are not weakened to a reduction between languages, and they assume nothing about P versus NP.
  • Source problems. The paper's phrase "three vertices, at most two of which are nonadjacent" is read as "at most one nonadjacent pair", which is Garey and Johnson's GT13. Reading it as "at most two nonadjacent pairs" would admit triples with a single edge and change the problem. PARTITION INTO PATHS OF LENGTH 2 reuses the published definition CubicP3Partition.P3Factor, a spanning non-induced P3P_3P3​-factor.
  • Construction. Resources are indexed by the nonadjacent pairs j<kj<kj<k in lexicographic order, one per unordered pair and none for a pair {j,j}\{j,j\}{j,j}. A diagonal resource would make every job infeasible.
  • Not trivial. A model that checks resources only at integer times, or only at start times, would make the paths equivalence false. A hypothesis on the target problem would make the goal circular. The definitions rule out both.

Welcome contributions: proofs of the two equivalences, polynomial-time computability of the construction on Cook's machines, and a general composition lemma for polynomial-time reductions. The composition lemma is reusable for every hardness mission built on CookPvsNP_defs.

Selected references

  • J. Błażewicz, J. K. Lenstra, A. H. G. Rinnooy Kan, Scheduling subject to resource constraints: classification and complexity, Discrete Applied Mathematics 5 (1983) 11–24. https://doi.org/10.1016/0166-218X(83)90012-4
  • M. R. Garey, D. S. Johnson, Complexity results for multiprocessor scheduling under resource constraints, SIAM Journal on Computing 4 (1975) 397–411. https://doi.org/10.1137/0204035
  • M. R. Garey, D. S. Johnson, Computers and Intractability: A Guide to the Theory of NP-Completeness, Freeman, San Francisco, 1979, ISBN 0-7167-1045-5.
  • R. L. Graham, E. L. Lawler, J. K. Lenstra, A. H. G. Rinnooy Kan, Optimization and approximation in deterministic sequencing and scheduling: a survey, Annals of Discrete Mathematics 5 (1979) 287–326. https://doi.org/10.1016/S0167-5060(08)70356-X
  • S. Cook, The P versus NP problem, Clay Mathematics Institute Millennium Problems. https://www.claymath.org/wp-content/uploads/2022/06/pvsnp.pdf
41 thms7 active usersReviewed
🏆Completed
CombinatoricsGraph Theory·Captain: hao jia

Immune High-Girth Bipartite Graphs (Feghali-Lucke-Paulusma-Ries 2025)Research Paper

Motivation

A matching cut is a vertex bipartition whose crossing edges form a matching. The property was introduced under the name decomposability and has links to graph algorithms, stable cutsets in line graphs, and several graph-labeling problems. An Open Problem Garden question asked whether sufficiently large girth forces a matching cut once average degree is bounded.

Feghali, Lucke, Paulusma, and Ries answered that question negatively. Their conference paper appeared at ISAAC 2023, and the version of record was published in Algorithmica in 2025. The paper proves NP-completeness for bipartite graphs of arbitrarily prescribed girth and bounded maximum degree. A central input, Lemma 5, is a stronger structural existence statement: for every girth threshold there is an immune 141414-regular bipartite graph of at least that girth, and it has a perfect matching.

This is therefore a ResearchPaper mission, not a new open-problem mission. Its goal is to formalize the published theorem and its graph-theoretic consequence. Repository candidate constructions and finite arithmetic audits remain separate and are not credited as solving the problem.

Setting

For a finite simple graph GGG and a vertex set A⊆V(G)A\subseteq V(G)A⊆V(G), the associated cut consists of all edges with one endpoint in AAA and one in V(G)∖AV(G)\setminus AV(G)∖A. The cut is nontrivial when both shores are nonempty. It is a matching cut when each vertex is incident with at most one crossing edge. A graph is called immune in the cited paper when it has no matching cut.

The girth is the length of a shortest simple cycle; forests have infinite girth. A graph is 141414-regular when every vertex has exactly fourteen neighbors. Bipartiteness is witnessed by a partition into two independent sides. A perfect matching pairs every vertex with one adjacent partner.

The original OPG wording has a literal one-vertex boundary ambiguity: with nonempty shores required, K1K_1K1​ has no matching cut, average degree zero, and infinite girth. The research-paper target avoids that vacuity by constructing connected graphs with at least two vertices, exact degree fourteen, and arbitrarily large finite girth.

Formalization targets

Lemma 5 — immune high-girth graphs

The main theorem follows the paper's structural lemma:

∀g≥3 ∃G,G is finite, connected, bipartite, and 14-regular,\forall g\ge3\ \exists G, \quad G\text{ is finite, connected, bipartite, and $14$-regular}, ∀g≥3 ∃G,G is finite, connected, bipartite, and 14-regular, girth⁡(G)≥g,G has no matching cut,G has a perfect matching. \operatorname{girth}(G)\ge g, \qquad G\text{ has no matching cut}, \qquad G\text{ has a perfect matching}.girth(G)≥g,G has no matching cut,G has a perfect matching.

The graph may depend on ggg. The existence quantifier does not request an efficient algorithm or a numerical order bound.

Negative OPG consequence

A supporting theorem removes the perfect-matching and bipartite fields and records the direct substantive counterexample family:

∀g≥3 ∃G,d‾(G)=14<15,girth⁡(G)≥g,G has no matching cut.\forall g\ge3\ \exists G, \qquad \overline d(G)=14<15, \quad \operatorname{girth}(G)\ge g, \quad G\text{ has no matching cut}.∀g≥3 ∃G,d(G)=14<15,girth(G)≥g,G has no matching cut.

Thus choosing d=15d=15d=15 refutes the intended universal assertion that some girth threshold works for every graph of average degree below ddd.

Significance

The theorem shows that large girth and bounded degree do not force matching cuts. The examples are highly nontrivial: they are connected, regular, bipartite, and can have arbitrarily large girth. This separates local tree-like structure from the global expansion that prevents a matching cut.

Within the paper, the immune graphs serve as gadgets for hardness reductions. The journal theorem states that, for every g≥3g\ge3g≥3, Matching Cut is NP-complete even for bipartite graphs of girth at least ggg and maximum degree at most 606060. Formalizing Lemma 5 supplies the graph-theoretic core needed to reconstruct that result without forcing this mission to formalize an entire complexity-theory reduction in its first stage.

Difficulty

Large girth alone makes bounded neighborhoods look like trees, and trees have many matching cuts. Immunity must therefore come from global expansion rather than short local cycles. The paper obtains the required family from Lubotzky–Phillips–Sarnak Ramanujan graphs and combines spectral and isoperimetric bounds to show that every nontrivial cut has too many crossing incidences to be a matching.

A formal proof must bridge several exact interfaces: existence of suitable primes, the finite Cayley-graph construction, bipartiteness and regularity, the girth lower bound, the spectral-to-isoperimetric inequality, and Hall's theorem for the perfect matching. None of these can be replaced by a finite sample or an asymptotic slogan.

Formalization scope

Graphs are finite and simple. Connectedness is nonempty mutual graph reachability. A simple cycle is a cyclic list of at least three distinct vertices; girth at least ggg means every such cycle has length at least ggg, so forests satisfy every threshold. A matching cut requires both shores nonempty and is encoded by the condition that every vertex has at most one crossing neighbor. A perfect matching is represented by an adjacent involution.

The main theorem explicitly requires at least two vertices, although exact 14-regularity already forces nontrivial order; the redundant bound documents exclusion of the K1K_1K1​ ambiguity. The mission does not claim that the frozen OPG contract was well-posed at order one. It formalizes the paper's substantive counterexample family and the consequence for the intended question.

Candidate files in the associated repository explore alternative bounded-degree constructions and integer counts. They are candidate_only and are not proof dependencies. Contributions should follow the published Lemma 5 and its cited inputs, or provide a separately sourced proof of the same declaration. The later maximum-degree-60 NP-completeness theorem is welcome as a future extension after the finite complexity framework is fixed.

Selected references

  • C. Feghali, F. Lucke, D. Paulusma, and B. Ries, Matching Cuts in Graphs of High Girth and H-Free Graphs, Algorithmica 87 (2025), 1199–1221. https://doi.org/10.1007/s00453-025-01318-8
  • C. Feghali, F. Lucke, D. Paulusma, and B. Ries, ISAAC 2023 version. https://drops.dagstuhl.de/entities/document/10.4230/LIPIcs.ISAAC.2023.31
  • A. Lubotzky, R. Phillips, and P. Sarnak, Ramanujan graphs, Combinatorica 8 (1988), 261–277. https://doi.org/10.1007/BF02126799
  • Open Problem Garden, Matching cut and girth. https://www.openproblemgarden.org/op/matching_cut_and_girth
20 thms6 active usersReviewed
🏆Completed
Captain: joe

The Sipser–Gács–Lautemann TheoremResearch Paper

Randomness appears to enlarge efficient computation, but the Sipser–Gács–Lautemann theorem places every bounded-error probabilistic polynomial-time language at the second level of the polynomial hierarchy, giving one of complexity theory’s foundational limits on the power of randomization.

66 thms6 active usersReviewed
🏆Completed
CombinatoricsOperations Research·Captain: mikedeng1

Competitive Paging Algorithms IV: An Algorithm Competitive against Several Others Exists iff the Reciprocal Ratios Sum to at Most 1Research Paper

Motivation

Paging is the problem of managing a fast memory that holds kkk pages out of nnn: when a requested page is not in fast memory (a page fault), some resident page must be evicted, and the cost of an algorithm is its number of faults. Practitioners have many eviction rules. Least-recently-used (LRU) performs well on real workloads but can be kkk times worse than the optimal off-line schedule; the randomized marking algorithm of the same paper is 2Hk2H_k2Hk​-competitive and so has better worst-case guarantees. Fiat, Karp, Luby, McGeoch, Sleator and Young asked in 1991 whether one on-line algorithm can combine the advantages of several given ones, and answered the question exactly: the attainable combinations of ratios are characterized by one inequality (arXiv:cs/0205038, §6).

The question of combining on-line algorithms has since become a theme of its own: combining heuristics with worst-case-safe algorithms, and, more recently, combining machine-learned predictions with robust fallbacks, both ask for the same kind of guarantee against several reference algorithms at once.

Setting

A type (k,n)(k,n)(k,n) consists of kkk servers and a finite set MMM of nnn vertices with the uniform metric: two distinct vertices are at distance 111. This is paging: vertices are pages, the vertices covered by servers are the pages in fast memory, and a server move is a page fault.

A deterministic on-line algorithm AAA of type (k,n)(k,n)(k,n) has an initial configuration of its kkk servers and, after each request r∈Mr\in Mr∈M, moves servers so that some server covers rrr; its configuration after a request sequence depends only on that sequence. Its cost CA(σ)C_A(\sigma)CA​(σ) on a request sequence σ\sigmaσ is the total distance its servers travel, i.e. the number of server moves.

For algorithms AAA and BBB of the same type and a constant ccc, AAA is ccc-competitive against BBB if there is a constant aaa such that for every request sequence σ\sigmaσ

CA(σ)≤c⋅CB(σ)+a.C_A(\sigma)\le c\cdot C_B(\sigma)+a .CA​(σ)≤c⋅CB​(σ)+a.

A sequence c∗=(c(1),…,c(m))c^*=(c(1),\dots,c(m))c∗=(c(1),…,c(m)) of positive reals is realizable if for every type (k,n)(k,n)(k,n) and every mmm deterministic on-line algorithms B(1),…,B(m)B(1),\dots,B(m)B(1),…,B(m) of that type there is a deterministic on-line algorithm AAA of the same type that is c(i)c(i)c(i)-competitive against B(i)B(i)B(i) for every iii.

Formalization targets

Goal: Theorem 6

For m≥1m\ge1m≥1 and positive reals c(1),…,c(m)c(1),\dots,c(m)c(1),…,c(m),

c∗ is realizable  ⟺  ∑1≤i≤m1c(i)≤1.c^*\ \text{is realizable}\iff \sum_{1\le i\le m}\frac1{c(i)}\le 1 .c∗ is realizable⟺1≤i≤m∑​c(i)1​≤1.

Milestones

In the order of the paper's proof:

  1. Punishments are paid for. If AAA punishes BBB at a time step (an AAA-interval on a vertex vvv ends at that step and contains the end of a BBB-interval on vvv that began no later), then BBB has moved a server; the number of such steps is at most CB(σ)C_B(\sigma)CB​(σ).
  2. A fault leaves room to punish. If ∣SA∣=k|S_A|=k∣SA​∣=k, ∣SB∣≤k|S_B|\le k∣SB​∣≤k, x∈SBx\in S_Bx∈SB​ and x∉SAx\notin S_Ax∈/SA​, then some u∈SAu\in S_Au∈SA​ is not in SBS_BSB​.
  3. The greedy quota claim. If ∑i1/c(i)≤1\sum_i 1/c(i)\le 1∑i​1/c(i)≤1 and each unit of cost punishes the B(i)B(i)B(i) minimizing c(i)(PUN(i)+1)c(i)(\mathrm{PUN}(i)+1)c(i)(PUN(i)+1) (other algorithms may be punished incidentally), then after cost rrr every B(i)B(i)B(i) has been punished at least ⌊r/c(i)⌋\lfloor r/c(i)\rfloor⌊r/c(i)⌋ times.
  4. Shuttle algorithms. With 2m−12m-12m−1 servers on 2m2m2m vertices there are mmm algorithms, each keeping all vertices outside its own pair covered, no two of which move at the same step; in particular their total cost on any σ\sigmaσ is at most ∣σ∣|\sigma|∣σ∣.
  5. A forcing adversary. With 2m−12m-12m−1 servers on 2m2m2m vertices every algorithm can be forced to move at each of NNN steps, so CA(τ(N))≥NC_A(\tau(N))\ge NCA​(τ(N))≥N.

Significance

The result. Theorem 6 is an exact characterization, not a bound: the region of simultaneously attainable ratios against arbitrary deterministic paging algorithms is {c:∑1/c(i)≤1}\{c:\sum 1/c(i)\le 1\}{c:∑1/c(i)≤1}. For example, any two paging algorithms can be combined into one that is 222-competitive against each, and no better symmetric pair is possible in general. Combined with Theorem 7 of the same paper (not part of this mission), the same region is attainable against randomized algorithms, which is how LRU's practical behaviour and the marking algorithm's 2Hk2H_k2Hk​ worst-case guarantee can be obtained within constant factors by one algorithm.

Formalizing it. The theorem has been proved since 1991; no machine-checked proof is known. A formal proof produces a reusable notion of competitiveness of one on-line algorithm against another, built on the published KServer_model definitions, and a formal account of the scheduling fact at the core of the sufficiency proof.

Difficulty

Sufficiency looks like an averaging argument, but the combined algorithm cannot simulate the B(i)B(i)B(i) and follow one of them: switching between their configurations costs up to kkk per switch, which no additive constant absorbs. The accounting has to charge each of AAA's faults to a specific move of a specific B(i)B(i)B(i), and the charge must be injective; the paper's claim that CB(σ)C_B(\sigma)CB​(σ) is at least the number of punishments is where this happens, and it depends on how server intervals are matched. The allocation of faults to algorithms is then a deadline-scheduling problem whose feasibility is exactly ∑1/c(i)≤1\sum 1/c(i)\le 1∑1/c(i)≤1, and the floor functions make the counting delicate at the boundary. The paper's own definition of punishment only counts intervals that start with a move, so the first kkk faults of AAA (servers on their initial vertices) need separate treatment; they are absorbed by the additive constant.

Necessity needs the right family of hard instances: the mmm algorithms must never move at the same step, which pins the type to (2m−1,2m)(2m-1,2m)(2m−1,2m).

Formalization scope

The Lean development works in the namespace CompetitivePaging.Combining and imports the published KServer_model definitions: KServer.OnlineAlgorithm k M (a configuration map from request prefixes to Fin k → M with a serving condition) and OnlineAlgorithm.cost. Committed conventions:

  • a type (k,n)(k,n)(k,n) is any k : ℕ and any finite M : Type with a metric in which distinct points are at distance 111; realizability quantifies over all of them, never over one fixed type;
  • servers are labelled; each algorithm has its own initial configuration, and the additive constant aaa is chosen before the request sequence;
  • c(i)>0c(i)>0c(i)>0 and m≥1m\ge1m≥1 are hypotheses of the goal, as in the paper; without positivity, 1/0=01/0=01/0=0 in Lean would make a zero ratio free;
  • time ttt is the step processing the ttt-th request; the paper's PUN\mathrm{PUN}PUN counts time steps.

Trivializing encodings are ruled out: realizability is not stated for a single fixed type, the metric is not the metric of Fin n, and the competitive constant is not allowed to depend on the request sequence.

A complete proof needs the construction of the punishing algorithm as a KServer.OnlineAlgorithm (a lazy, injective algorithm whose moves depend on the prefix and on the B(i)B(i)B(i)'s configurations), the injective charging argument, the scheduling lemma, and the explicit shuttle algorithms. The scheduling lemma and the charging lemma are independent of paging and reusable. Proofs of any milestone are welcome, as are alternative statements of the sufficiency construction.

Selected references

  • A. Fiat, R. M. Karp, M. Luby, L. A. McGeoch, D. D. Sleator, N. E. Young, Competitive Paging Algorithms, J. Algorithms 12(4):685–699, 1991. doi:10.1016/0196-6774(91)90041-V; preprint arXiv:cs/0205038.
  • D. D. Sleator, R. E. Tarjan, Amortized efficiency of list update and paging rules, Comm. ACM 28(2):202–208, 1985. doi:10.1145/2786.2793
  • M. S. Manasse, L. A. McGeoch, D. D. Sleator, Competitive algorithms for server problems, J. Algorithms 11(2):208–230, 1990. doi:10.1016/0196-6774(90)90003-W
9 thms5 active usersReviewed
🏆Completed
Captain: marwahaha

Coppersmith–Winograd Bound: omega < 2.376Research Paper

AI generated but i think correct. I think the milestones make it really annoying but the central theorem looks correct.

Motivation

The matrix-multiplication exponent measures the asymptotic number of field operations needed to multiply two square matrices. A bound ω<c\omega<cω<c means that, for every ε>0\varepsilon>0ε>0, two n×nn\times nn×n matrices can be multiplied using O(nc+ε)O(n^{c+\varepsilon})O(nc+ε) arithmetic operations. Matrix multiplication is a central benchmark in algebraic complexity and a primitive for many algorithms in linear algebra, graph theory, and symbolic computation.

After Strassen showed that ω<3\omega<3ω<3, a sequence of tensor constructions reduced the exponent further. Schönhage's asymptotic sum inequality made it possible to exploit simultaneous matrix products rather than a single square product. In 1990, Don Coppersmith and Shmuel Winograd combined an explicit low-border-rank tensor with a block extraction argument based on Salem--Spencer sets. Their basic analysis gave ω<2.38719\omega<2.38719ω<2.38719; coupling the random weights in the tensor square sharpened this to ω<2.375477\omega<2.375477ω<2.375477, hence the exact rational consequence ω<2.376\omega<2.376ω<2.376.

This mission formalizes that historical Coppersmith--Winograd result. It follows the source tensor and its actual block restrictions, while excluding placeholder “laser values” that are not backed by extracted direct sums of matrix-multiplication tensors.

Setting

For a field KKK, an order-three tensor is represented by three finite-dimensional KKK-vector spaces and an element of their tensor product. The matrix-multiplication tensor

⟨a,b,c⟩K=∑i<a∑j<b∑k<cxij⊗yjk⊗zki\langle a,b,c\rangle_K =\sum_{i<a}\sum_{j<b}\sum_{k<c} x_{ij}\otimes y_{jk}\otimes z_{ki}⟨a,b,c⟩K​=i<a∑​j<b∑​k<c∑​xij​⊗yjk​⊗zki​

encodes multiplication of an a×ba\times ba×b matrix by a b×cb\times cb×c matrix. A restriction applies one linear map to each tensor leg. A degeneration permits those maps to depend polynomially on a formal parameter and selects their first nonzero coefficient. Thus a degeneration from the diagonal tensor IrI_rIr​ is a border-rank certificate R‾(T)≤r\underline R(T)\le rR​(T)≤r.

The Coppersmith--Winograd tensor with parameter qqq is

Tq=∑i=1q(x0yizi+xiy0zi+xiyiz0)+x0y0zq+1+x0yq+1z0+xq+1y0z0.T_q= \sum_{i=1}^{q} (x_0y_i z_i+x_i y_0z_i+x_i y_i z_0) +x_0y_0z_{q+1}+x_0y_{q+1}z_0+x_{q+1}y_0z_0.Tq​=i=1∑q​(x0​yi​zi​+xi​y0​zi​+xi​yi​z0​)+x0​y0​zq+1​+x0​yq+1​z0​+xq+1​y0​z0​.

It has border rank at most q+2q+2q+2. Its coordinates carry three classes, indexed by 0,1,20,1,20,1,2, and its six nonzero block types are

(0,1,1), (1,0,1), (1,1,0), (0,0,2), (0,2,0), (2,0,0).(0,1,1),\ (1,0,1),\ (1,1,0),\ (0,0,2),\ (0,2,0),\ (2,0,0).(0,1,1), (1,0,1), (1,1,0), (0,0,2), (0,2,0), (2,0,0).

The first three blocks are matrix-multiplication tensors with dimensions (1,1,q)(1,1,q)(1,1,q), (q,1,1)(q,1,1)(q,1,1), and (1,q,1)(1,q,1)(1,q,1); the other three are scalar products. Tensor powers therefore contain many typed rectangular matrix products. The laser method selects a large family with disjoint coordinate blocks and applies Schönhage's asymptotic sum inequality to all surviving products simultaneously.

Formalization targets

Goal: the 1990 Coppersmith--Winograd bound

For every field KKK,

matMulExp⁡(K)<297125=2.376.\operatorname{matMulExp}(K)<\frac{297}{125}=2.376.matMulExp(K)<125297​=2.376.

The Lean goal has the same quantified proposition and the same matMulExp definition as the existing Schönhage-bound mission; only the theorem identifier and rational endpoint change.

Tensor and block foundations

The development records the characteristic-free order-three degeneration

Tq⊴Iq+2T_q\unlhd I_{q+2}Tq​⊴Iq+2​

and the exact matrix-product dimensions associated with every supported type sequence in Tq⊗NT_q^{\otimes N}Tq⊗N​. These statements identify the algebraic input before any asymptotic counting is used.

Coupled-weight extraction

For q=6q=6q=6, the tensor-square grading and the coupled-weight pruning must produce the direct sums and asymptotic inequality stated in Section 8 and in the coupled-constituent lemma on journal pp. 270--272. The final numerical milestone certifies the rational endpoint 297/125297/125297/125 from exact inequalities, rather than treating the decimal 2.3754772.3754772.375477 as a proof object.

Significance

The result was the strongest matrix-multiplication bound for roughly two decades and introduced the tensor family that underlies the classical laser-method line of work. A formal proof supplies a checked bridge from an explicit border-rank identity to an exponent bound whose combinatorial extraction is substantially more delicate than the earlier Schönhage examples.

The formalization also produces reusable infrastructure. The order-three CW degeneration is an explicit polynomial-family test case over arbitrary fields. The six block identifications and type-count formulas can be reused in analyses of tensor powers. A faithful extraction predicate, stated through actual restrictions to direct sums of MMObj tensors, separates sound laser arguments from formulas that count incompatible or coordinate-sharing blocks as independent.

The mathematical bound is known. The open work is its machine-checked reconstruction in Lean. The border-rank theorem, per-type matrix-product restriction layer, tensor-square support invariant, balanced block calculation, Salem--Spencer set theorem, and exact q=6q=6q=6 numerical endpoint are already proved. The unrestricted value/rank bridge, the coupled-constituent extraction, and the full Section 8 auxiliary inequality remain the substantive frontier.

Difficulty

The main difficulty is not expanding TqT_qTq​ or evaluating a decimal logarithm. A tensor power contains exponentially many typed terms, but most share variables. They cannot all be placed in a direct sum, and counting all joint type sequences overestimates the usable matrix products. The source hashes coordinate blocks into a large progression-free set and prunes collisions so that the surviving blocks are genuinely independent.

The 2.3762.3762.376 improvement adds a second layer. It begins with Tq⊗2T_q^{\otimes2}Tq⊗2​, regroups variables into five classes, couples weights that were independent in the simpler analysis, and estimates a nontrivial central block by a further extraction. A formal proof must track the direction of every restriction, the exact multiplicities of all block types, and the loss introduced by pruning. Replacing exponential surviving-block counts by a polynomial number of blocks, or using joint entropy without the marginal compatibility constraints, changes the mathematical claim and is outside the mission.

Formalization scope

The mission uses the existing TensorObj, MMObj, TensorObj.Restrict, Degenerates, tensorAsymptoticRank, matMulExp, and matMulExp_strassen declarations in the Mathlib environment pinned by the earlier matrix-multiplication mission. Tensor dimensions and type counts are natural numbers; exponent and optimization inequalities are real-valued. All top-level bounds quantify over an arbitrary field, matching the integral polynomial identities used by the construction.

Laser statements must exhibit, directly or through a faithful reusable predicate, restrictions from a tensor power to a finite direct sum of concrete matrix-multiplication tensors. The number and dimensions of the summands remain part of the witness. A constant-valued “laser functional,” a vacuous witness hypothesis, or a capacity definition that discards the exponential number of surviving blocks does not satisfy the mission.

Welcome contributions include restriction composition lemmas, tensor-power block equivalences, multinomial and entropy estimates with all marginal constraints, formal Salem--Spencer pruning, exact real-inequality certificates, and the coupled central-block value lemma. Every milestone should cite the corresponding equation, table, or lemma in the primary paper.

Selected references

  • Don Coppersmith and Shmuel Winograd, Matrix Multiplication via Arithmetic Progressions, Journal of Symbolic Computation 9, 1990, pp. 251--280. ScienceDirect.
  • Arnold Schönhage, Partial and Total Matrix Multiplication, SIAM Journal on Computing 10(3), 1981, pp. 434--455. DOI 10.1137/0210032.
  • Avi Wigderson and Jeroen Zuiddam, Asymptotic Spectra: Theory, Applications and Extensions, 2023, for the tensor restriction and asymptotic-rank framework used by the Lean development. Author manuscript.
72 thms5 active usersReviewed
🏆Completed
Combinatorics·Captain: mikedeng1

Three Partition Refinement Algorithms 2: Refining by the Smaller HalfResearch Paper

Motivation

Many equivalence problems on finite structures reduce to computing the coarsest partition of a finite set that is compatible with a relation. Deciding whether two states of a finite labelled transition system are bisimilar, testing congruence of finite-state processes in Milner's calculus of communicating systems (CCS), and minimizing a deterministic finite automaton are all instances. Kanellakis and Smolka studied the relational version in connection with CCS equivalence and gave an O(mn)O(mn)O(mn)-time algorithm, conjecturing that O(mlog⁡n)O(m \log n)O(mlogn) was possible. Paige and Tarjan's 1987 paper answers that conjecture with an algorithm that has since become the standard method for bisimulation minimization in model checkers and process-algebra tools.

Timeline:

  • 1971 — Hopcroft gives an O(nlog⁡n)O(n \log n)O(nlogn) algorithm for minimizing deterministic finite automata, i.e. for the coarsest partition stable with respect to one or more functions, using the rule "process the smaller half".
  • 1983/1990 — Kanellakis and Smolka give an O(mn)O(mn)O(mn)-time, O(m+n)O(m + n)O(m+n)-space algorithm for the relational problem, and O(c2nlog⁡n)O(c^2 n \log n)O(c2nlogn) when every element has at most ccc successors; they conjecture an O(mlog⁡n)O(m \log n)O(mlogn) algorithm.
  • 1987 — Paige and Tarjan combine Hopcroft's smaller-half strategy with refinement by unions of blocks and obtain O(mlog⁡n)O(m \log n)O(mlogn) time and O(m+n)O(m + n)O(m+n) space for the relational problem.

Setting

Let UUU be a finite set with n=∣U∣n = |U|n=∣U∣ elements and let E⊆U×UE \subseteq U \times UE⊆U×U be a binary relation on UUU; write xEyxEyxEy for (x,y)∈E(x, y) \in E(x,y)∈E and m=∣E∣m = |E|m=∣E∣. For S⊆US \subseteq US⊆U the preimage of SSS is

E−1(S)={x∈U∣∃y∈S, xEy}.E^{-1}(S) = \{x \in U \mid \exists y \in S,\ xEy\}.E−1(S)={x∈U∣∃y∈S, xEy}.

A partition of UUU is a family of nonempty, pairwise disjoint subsets of UUU, its blocks, whose union is UUU. A partition RRR is a refinement of a partition PPP if every block of RRR lies inside a block of PPP.

A set B⊆UB \subseteq UB⊆U is stable with respect to S⊆US \subseteq US⊆U if B⊆E−1(S)B \subseteq E^{-1}(S)B⊆E−1(S) or B∩E−1(S)=∅B \cap E^{-1}(S) = \emptysetB∩E−1(S)=∅: either every element of BBB has an EEE-successor in SSS, or none does. A partition is stable with respect to SSS if all its blocks are, and a partition is stable if it is stable with respect to each of its own blocks.

Given EEE and an initial partition PPP, the coarsest stable refinement of PPP is a stable partition QQQ refining PPP such that every stable partition refining PPP is a refinement of QQQ. The relational coarsest partition problem asks for it.

The algorithms refine by the operation split(S,Q)\mathrm{split}(S, Q)split(S,Q), which replaces each block BBB of QQQ that meets both E−1(S)E^{-1}(S)E−1(S) and its complement by the two blocks B∩E−1(S)B \cap E^{-1}(S)B∩E−1(S) and B−E−1(S)B - E^{-1}(S)B−E−1(S). The set SSS is a splitter of QQQ if split(S,Q)≠Q\mathrm{split}(S, Q) \neq Qsplit(S,Q)=Q.

  • The naïve algorithm starts from Q=PQ = PQ=P and, while possible, picks a splitter SSS of QQQ that is a union of blocks of QQQ and replaces QQQ by split(S,Q)\mathrm{split}(S, Q)split(S,Q).
  • The improved algorithm also maintains a partition XXX, initially {U}\{U\}{U}, of which QQQ is a refinement. While Q≠XQ \neq XQ=X, it picks a block S∈XS \in XS∈X that is not a block of QQQ and a block B∈QB \in QB∈Q with B⊆SB \subseteq SB⊆S and ∣B∣≤∣S∣/2|B| \le |S|/2∣B∣≤∣S∣/2, replaces SSS in XXX by BBB and S−BS - BS−B, and replaces QQQ by split(S−B,split(B,Q))\mathrm{split}(S - B, \mathrm{split}(B, Q))split(S−B,split(B,Q)).

The improved algorithm is analysed under the standing assumption ∣E({x})∣≥1|E(\{x\})| \ge 1∣E({x})∣≥1 for all x∈Ux \in Ux∈U: every element has at least one successor. (The paper reduces the general case to this one by a preprocessing step.)

Formalization targets

Goal: the improved algorithm

For every run (Q0,X0)=(P,{U}),…,(QK,XK)(Q_0, X_0) = (P, \{U\}), \dots, (Q_K, X_K)(Q0​,X0​)=(P,{U}),…,(QK​,XK​) of the improved algorithm with refining blocks B0,…,BK−1B_0, \dots, B_{K-1}B0​,…,BK−1​:

  1. at every stage QjQ_jQj​ and XjX_jXj​ are partitions, QjQ_jQj​ refines XjX_jXj​, and QjQ_jQj​ is stable with respect to every block of XjX_jXj​;
  2. if QK=XKQ_K = X_KQK​=XK​, then QKQ_KQK​ is the coarsest stable refinement of PPP;
  3. if QK≠XKQ_K \neq X_KQK​=XK​, another step applies;
  4. K≤n−1K \le n - 1K≤n−1;
  5. every x∈Ux \in Ux∈U satisfies
#{ j<K∣x∈Bj }≤log⁡2n+1.\#\{\, j < K \mid x \in B_j \,\} \le \log_2 n + 1.#{j<K∣x∈Bj​}≤log2​n+1.

Items 1–4 are the correctness of the improved algorithm, which the paper deduces from that of the naïve one. Item 5 is the counting fact on which the O(mlog⁡n)O(m \log n)O(mlogn) bound rests.

Milestones

  • §3, p. 978: SSS is a splitter of QQQ if and only if QQQ is unstable with respect to SSS.
  • Properties (1)–(3), p. 978: stability is inherited under refinement and under union; split\mathrm{split}split is monotone in its second argument.
  • §3, p. 979: a stable partition is stable with respect to every union of its blocks.
  • Lemma 2, p. 979: every stable refinement of PPP refines each partition produced by the naïve algorithm.
  • Theorem 2, p. 979: the naïve algorithm stops after at most n−1n - 1n−1 steps at the unique coarsest stable refinement.
  • Property (4), p. 978: split\mathrm{split}split is commutative, and split(S,split(Q,P))\mathrm{split}(S, \mathrm{split}(Q, P))split(S,split(Q,P)) is the coarsest refinement of PPP stable with respect to both SSS and QQQ.
  • Lemma 3, p. 980: the three-way split of a block DDD into D11D_{11}D11​, D12D_{12}D12​ and D2D_2D2​, including D12=D1∩(E−1(B)−E−1(S−B))D_{12} = D_1 \cap (E^{-1}(B) - E^{-1}(S - B))D12​=D1​∩(E−1(B)−E−1(S−B)).

Significance

The coarsest stable refinement of the partition of states by their labels is the bisimilarity relation of a finite transition system, so the goal certifies, for any sequence of choices, the correctness of the refinement loop at the core of bisimulation minimization. The halving count is the combinatorial half of the O(mlog⁡n)O(m \log n)O(mlogn) bound: once the implementation charges O(∣B∣+∑y∈B∣E−1({y})∣)O(|B| + \sum_{y \in B} |E^{-1}(\{y\})|)O(∣B∣+∑y∈B​∣E−1({y})∣) per refining block BBB, the count bounds the total work.

The results are proved in the paper, some by one-line arguments and the elementary properties (1)–(4) not at all ("stated without proof"). No machine-checked proof of the Paige–Tarjan algorithm's correctness or of its halving count is known to be available in Lean or Mathlib. The mission produces a checked account of the invariant, the final correctness and the counting argument for every run, not only for a particular implementation.

Difficulty

The correctness of the improved algorithm is not a special case of the naïve one read off directly. An improved step refines by BBB and by S−BS - BS−B, and S−BS - BS−B is a union of blocks of QQQ only because QQQ refines XXX. The invariant that QQQ is stable with respect to every block of XXX is what makes Q=XQ = XQ=X a stopping condition, and it holds initially only under the standing assumption. The naive idea of reusing Hopcroft's argument fails: for relations, stability with respect to SSS and BBB does not imply stability with respect to S−BS - BS−B, which is why both refinements are performed. For the halving count, the refining blocks that contain a fixed element must be shown to be nested across steps, which requires tracking how blocks of XXX are replaced.

Formalization scope

  • UUU is a Fintype with decidable equality, EEE a decidable relation U → U → Prop. Partitions are Finset (Finset U) with an explicit predicate IsPartition (nonempty, pairwise disjoint blocks covering UUU); blocks are required to be nonempty, which the paper leaves implicit.
  • "Coarsest" means: every stable partition refining PPP refines it. The paper's "every other stable partition" is read this way, since a stable partition that does not refine PPP need not refine the answer.
  • Algorithms are step relations; a run is a finite sequence of states indexed by Fin (K + 1), with the choices Sj,BjS_j, B_jSj​,Bj​ recorded. Every statement holds for every run, so no choice rule is fixed.
  • Added hypotheses: UUU nonempty (so {U}\{U\}{U} is a partition and "at most n−1n - 1n−1 steps" is meaningful); the standing assumption ∀x ∃y, xEy\forall x\, \exists y,\ xEy∀x∃y, xEy for the goal only. Lemma 2 is stated for every stable refinement of PPP, which is what its proof gives and what Theorem 2 uses; it implies the printed form.
  • Explicit forms: ∣B∣≤∣S∣/2|B| \le |S|/2∣B∣≤∣S∣/2 is 2 * B.card ≤ S.card, K≤n−1K \le n - 1K≤n−1 is K + 1 ≤ n, log⁡2\log_2log2​ is Real.logb 2 of nnn cast to R\mathbb{R}R. The termination bound for the improved algorithm is not printed in the paper and is derived as in the proof of Theorem 2. Running times (O(mn)O(mn)O(mn), O(mlog⁡n)O(m \log n)O(mlogn)) and the data structures of the implementation are out of scope.
  • A trivializing reading is ruled out: the goal quantifies over all runs from (P,{U})(P, \{U\})(P,{U}) with every side condition of the step (in particular S∉QS \notin QS∈/Q and the half-size condition), and the conclusion is a full correctness statement, not the existence of some stable partition; the discrete partition is stable but is not the answer in general.
  • Reusable beyond this mission: preimage, stability, split\mathrm{split}split and its algebra (properties (1)–(4)), which apply to Hopcroft's algorithm and to bisimulation minimization in general. Contributions proving the elementary properties first, then Lemma 2 and Theorem 2, are the natural attack order.

Selected references

  • R. Paige, R. E. Tarjan, Three Partition Refinement Algorithms, SIAM Journal on Computing 16(6):973–989, 1987. https://doi.org/10.1137/0216062
  • P. C. Kanellakis, S. A. Smolka, CCS expressions, finite state processes, and three problems of equivalence, Information and Computation 86(1):43–68, 1990. https://doi.org/10.1016/0890-5401(90)90025-D
  • J. E. Hopcroft, An n log n algorithm for minimizing states in a finite automaton, in Theory of Machines and Computations, Academic Press, 1971, pp. 189–196. https://doi.org/10.1016/B978-0-12-417750-5.50022-1
  • A. V. Aho, J. E. Hopcroft, J. D. Ullman, The Design and Analysis of Computer Algorithms, Addison-Wesley, 1974.
12 thms4 active usersReviewed
🏆Completed
Operations ResearchProbability·Captain: mikedeng1

Competitive Paging Algorithms I: The Marking Algorithm Is 2H_k-CompetitiveResearch Paper

Motivation

Paging is the problem of managing a two-level memory: a fast cache holds kkk pages out of an address space of nnn pages, requests to pages arrive one at a time, and a request to a page outside the cache (a page fault) forces the algorithm to bring that page in and, when the cache is full, to evict another. The cost is the number of faults. An on-line algorithm decides which page to evict without knowing future requests. The comparison of paging policies with the optimal off-line policy is where competitive analysis began.

Sleator and Tarjan showed that LRU and FIFO are within a factor kkk of the off-line optimum and that no deterministic on-line algorithm does better than kkk (Sleator–Tarjan 1985). Randomization changes the picture: Fiat, Karp, Luby, McGeoch, Sleator and Young introduced the marking algorithm and proved that its expected cost is within a factor 2Hk2H_k2Hk​ of the optimum, where Hk=1+12+⋯+1k≈ln⁡kH_k = 1 + \frac12 + \dots + \frac1k \approx \ln kHk​=1+21​+⋯+k1​≈lnk (arXiv:cs/0205038).

Timeline.

  • 1985: Sleator and Tarjan: LRU and FIFO are kkk-competitive; no deterministic algorithm beats kkk.
  • 1988: Karlin, Manasse, Rudolph and Sleator coin "competitive" and analyse flush-when-full (Algorithmica 3).
  • 1990: Manasse, McGeoch and Sleator introduce the kkk-server problem and define competitiveness for randomized algorithms (J. Algorithms 11).
  • 1991: Fiat et al.: the marking algorithm is 2Hk2H_k2Hk​-competitive, and Hn−1H_{n-1}Hn−1​-competitive when k=n−1k = n-1k=n−1; no randomized paging algorithm beats HkH_kHk​.
  • 1991: McGeoch and Sleator give an HkH_kHk​-competitive randomized paging algorithm (Algorithmica 6).
  • 2000: Achlioptas, Chrobak and Noga determine the exact competitive ratio of the marking algorithm, 2Hk−12H_k - 12Hk​−1 (Theoret. Comput. Sci. 234).

Setting

The paper works in the uniform kkk-server problem, which is isomorphic to paging. There is a set MMM of nnn vertices, enumerated e(0),…,e(n−1)e(0), \dots, e(n-1)e(0),…,e(n−1), and moving a server between two distinct vertices costs 111. There are kkk servers, 1≤k≤n1 \le k \le n1≤k≤n. A request is a vertex, and after each request some server must be on it. Cached pages are covered vertices; a fault is a server move.

The marking algorithm starts with its servers on e(0),…,e(k−1)e(0), \dots, e(k-1)e(0),…,e(k−1) and keeps a set of marked vertices, initially the covered ones. On a request to rrr:

  1. Marking. rrr is marked; the moment k+1k+1k+1 vertices are marked, all marks except the one on rrr are erased.
  2. Serving. If rrr is covered, nothing moves. Otherwise a server is chosen uniformly at random among the covered unmarked vertices and moved to rrr.

The marks are updated before the server is chosen. For a finite request sequence σ\sigmaσ, CM(σ)C_M(\sigma)CM​(σ) is the algorithm's expected number of server moves. OPT(σ)\mathrm{OPT}(\sigma)OPT(σ) is the least number of moves with which kkk servers, starting from the same configuration C0C_0C0​ and knowing σ\sigmaσ in advance, can serve σ\sigmaσ.

A randomized algorithm is ccc-competitive if there is a constant aaa such that CM(σ)≤c⋅CB(σ)+aC_M(\sigma) \le c \cdot C_B(\sigma) + aCM​(σ)≤c⋅CB​(σ)+a for every request sequence σ\sigmaσ and every algorithm BBB.

The marks divide σ\sigmaσ into phases. A new phase begins at the request that would make k+1k+1k+1 vertices marked. A vertex is clean in a phase if it was not requested in the previous phase and not yet in this one, and stale if it was requested in the previous phase but not yet in this one.

Formalization targets

Goal: Theorem 1

∃ a∈R  ∀σ:CM(σ)  ≤  2Hk⋅OPT(σ)+a.\exists\, a \in \mathbb R\ \ \forall \sigma:\qquad C_M(\sigma) \;\le\; 2H_k \cdot \mathrm{OPT}(\sigma) + a .∃a∈R  ∀σ:CM​(σ)≤2Hk​⋅OPT(σ)+a.

The constant aaa may depend on nnn, kkk and the enumeration, never on σ\sigmaσ.

Milestones (proof of Theorem 1, pp. 4–5)

  1. Without loss of generality the adversary is lazy: no move on a covered request, exactly one move otherwise (reference item, already proved on the platform).
  2. At the start of every phase the marked vertices are exactly the covered ones, and the first request of a phase is unmarked.
  3. In a phase with lll clean requests, a lazy adversary pays CA≥l−dC_A \ge l - dCA​≥l−d, where ddd counts its servers off the marking algorithm's servers at the start of the phase.
  4. It also pays CA≥d′C_A \ge d'CA​≥d′, where d′d'd′ counts its servers off the final marked set at the end of the phase.
  5. Hence CA≥max⁡(l−d,d′)≥12(l−d+d′)C_A \ge \max(l-d, d') \ge \tfrac12(l - d + d')CA​≥max(l−d,d′)≥21​(l−d+d′).
  6. A request to a stale vertex is a fault with probability c/sc/sc/s (ccc clean vertices requested so far, sss stale vertices left).
  7. The marking algorithm's expected cost in a phase is at most l(Hk−Hl+1)≤lHkl(H_k - H_l + 1) \le lH_kl(Hk​−Hl​+1)≤lHk​.

Companions

  • Theorem 2: for k=n−1k = n-1k=n−1, CM(σ)≤Hn−1⋅OPT(σ)+aC_M(\sigma) \le H_{n-1} \cdot \mathrm{OPT}(\sigma) + aCM​(σ)≤Hn−1​⋅OPT(σ)+a.
  • Tightness remark (pp. 5–6): for k=2k = 2k=2, n=4n = 4n=4 there is no aaa with CM(σ)≤H2⋅OPT(σ)+aC_M(\sigma) \le H_2 \cdot \mathrm{OPT}(\sigma) + aCM​(σ)≤H2​⋅OPT(σ)+a for all σ\sigmaσ.

Significance

The result. Theorem 1 was the first proof that randomization beats the deterministic barrier kkk for paging, bringing the ratio down to O(log⁡k)O(\log k)O(logk). Together with the paper's lower bound HkH_kHk​ for every randomized algorithm, it determines the randomized competitive ratio of paging up to a factor 222. Its phase and clean/stale accounting is reused throughout the analysis of randomized caching.

Formalizing it. The theorem is proved (1991). As far as is known it has no machine-checked proof. Formalizing it requires a probabilistic model of a randomized on-line algorithm, an off-line optimum, and a phase decomposition with an exchangeability argument, and these are the first such objects in this library. Theorem 2 and the k=2k = 2k=2, n=4n = 4n=4 example use the same definitions and also check that the formal algorithm is the paper's. The sharp ratio 2Hk−12H_k - 12Hk​−1 is a natural follow-up.

Difficulty

The comparison is between a random process and a deterministic adversary, and each side has its own obstacle.

On the algorithm's side, the configuration inside a phase is random, and the fault probability of a stale request depends on the whole history of the phase. The claim that the ccc uncovered stale vertices form a uniformly random subset of the sss stale ones is an exchangeability property of the process, and must be established from the step-by-step uniform choice. The worst-case ordering of the requests within a phase then has to be justified as a bound, not assumed.

On the adversary's side, the per-phase bound max⁡(l−d,d′)\max(l-d, d')max(l−d,d′) does not sum directly. The ddd and d′d'd′ terms telescope across phases only because the configuration of the marking algorithm at each phase boundary is deterministic. The first phase, which begins after an initial run of requests to e(0),…,e(k−1)e(0), \dots, e(k-1)e(0),…,e(k−1), and the last, incomplete phase have to be absorbed into the additive constant.

Formalization scope

The vertex set is an abstract metric space MMM with e:Fin n≃Me : \mathrm{Fin}\,n \simeq Me:Finn≃M and dist(x,y)=1\mathrm{dist}(x,y) = 1dist(x,y)=1 for x≠yx \ne yx=y. The natural metric ∣i−j∣|i - j|∣i−j∣ on Fin n\mathrm{Fin}\,nFinn is deliberately not used. The configurations and the off-line optimum OPT\mathrm{OPT}OPT are the published KServer definitions (KServer.Config, KServer.offlineCost), with OPT\mathrm{OPT}OPT taken from the marking algorithm's initial configuration. An off-line algorithm starting elsewhere changes the cost by at most kkk, which is absorbed into aaa.

The marking algorithm is a Markov chain on pairs (covered set, marked set). Each step is a PMF, with the eviction drawn by PMF.uniformOfFinset from the covered unmarked vertices. The expected cost is the sum over requests of the probability that the request is not covered, which is exact because the algorithm moves exactly one server per fault. Harmonic numbers are Mathlib's harmonic, cast to R\mathbb RR. Phases, clean counts and lazy off-line schedules are defined once, in the mission's definition file, and all milestones use them.

A trivializing formalization is ruled out as follows. The additive constant is quantified before σ\sigmaσ, so a per-sequence constant cannot be used. The comparison is with the optimum over all off-line schedules, not a particular one. The random choice is among the covered unmarked vertices, with marks updated first. The hypothesis 1≤k≤n1 \le k \le n1≤k≤n excludes the degenerate case k=0k = 0k=0, where H0=0H_0 = 0H0​=0.

Proofs of individual milestones are welcome. The laziness reduction for off-line schedules, the exchangeability lemma for the uniform eviction process, and the harmonic-sum identity ∑j=l+1kl/j=l(Hk−Hl)\sum_{j=l+1}^{k} l/j = l(H_k - H_l)∑j=l+1k​l/j=l(Hk​−Hl​) are reusable beyond this mission.

Selected references

  • A. Fiat, R. M. Karp, M. Luby, L. A. McGeoch, D. D. Sleator, N. E. Young, Competitive Paging Algorithms, J. Algorithms 12(4):685–699, 1991; arXiv:cs/0205038v1. https://arxiv.org/abs/cs/0205038
  • D. D. Sleator, R. E. Tarjan, Amortized Efficiency of List Update and Paging Rules, Comm. ACM 28(2):202–208, 1985. https://doi.org/10.1145/2786.2793
  • A. R. Karlin, M. S. Manasse, L. Rudolph, D. D. Sleator, Competitive Snoopy Caching, Algorithmica 3:79–119, 1988. https://doi.org/10.1007/BF01762111
  • M. S. Manasse, L. A. McGeoch, D. D. Sleator, Competitive Algorithms for Server Problems, J. Algorithms 11(2):208–230, 1990. https://doi.org/10.1016/0196-6774(90)90003-W
  • L. A. McGeoch, D. D. Sleator, A Strongly Competitive Randomized Paging Algorithm, Algorithmica 6:816–825, 1991. https://doi.org/10.1007/BF01759073
  • D. Achlioptas, M. Chrobak, J. Noga, Competitive Analysis of Randomized Paging Algorithms, Theoret. Comput. Sci. 234:203–218, 2000. https://doi.org/10.1016/S0304-3975(98)00116-9
10 thms4 active usersReviewed
🏆Completed
CombinatoricsGraph TheoryOperations Research+1·Captain: mikedeng1

An Analysis of Several Heuristics for the Traveling Salesman Problem I: Nearest Neighbor Tours Can Be Far from OptimalResearch Paper

Motivation

The traveling salesman problem with the triangle inequality asks for a shortest closed tour through nnn points whose distances form a metric. It is NP-hard, so in practice tours are built by fast construction heuristics, and the natural question is how far such a tour can be from optimal in the worst case. Rosenkrantz, Stearns and Lewis (SIAM J. Comput. 6(3), 1977) gave the first systematic worst-case analysis of the standard heuristics. Their results are reproduced in textbooks on approximation algorithms and combinatorial optimization, and they are the reference point against which later guarantees (Christofides' 3/23/23/2 algorithm, the double-tree 222-approximation) are compared.

The simplest heuristic studied is the nearest neighbor algorithm (Bellmore and Nemhauser, 1968; the "next best method" of Gavett, 1965): from the current node, always move to the closest node not yet visited, and return to the start at the end. The paper shows that this greedy rule is never worse than logarithmic (Theorem 1) and that the logarithm cannot be removed (Theorem 2). This mission is about Theorem 2, the lower bound.

Setting

A traveling salesman graph on nnn nodes is a complete graph with a distance d(a,b)∈Rd(a,b)\in\mathbb Rd(a,b)∈R that is symmetric, d(a,b)=d(b,a)d(a,b)=d(b,a)d(a,b)=d(b,a), nonnegative, d(a,b)≥0d(a,b)\ge 0d(a,b)≥0, and satisfies the triangle inequality d(a,c)≤d(a,b)+d(b,c)d(a,c)\le d(a,b)+d(b,c)d(a,c)≤d(a,b)+d(b,c). A tour lists the nodes in a visiting order τ(0),…,τ(n−1)\tau(0),\dots,\tau(n-1)τ(0),…,τ(n−1) and returns to τ(0)\tau(0)τ(0); its length is the sum of the nnn distances along it. OPTIMAL is the least length of a tour.

The nearest neighbor algorithm starts at an arbitrary node τ(0)\tau(0)τ(0); having reached τ(k)\tau(k)τ(k), it moves to a node τ(k+1)\tau(k+1)τ(k+1) that minimizes d(τ(k),⋅)d(\tau(k),\cdot)d(τ(k),⋅) over the nodes not yet visited, breaking ties arbitrarily; after the last node it returns to τ(0)\tau(0)τ(0). The length of the resulting tour is written NEARNEIBER. Because the start node and the ties are free, one instance has in general several nearest-neighbor tours. A lower bound needs only one of them; an upper bound must hold for all.

The instances of the proof are built from a recursive family of weighted graphs. With li=16(4⋅2i−(−1)i+3)l_i=\frac16(4\cdot 2^i-(-1)^i+3)li​=61​(4⋅2i−(−1)i+3) (so l1,l2,l3,l4=2,3,6,11l_1,l_2,l_3,l_4=2,3,6,11l1​,l2​,l3​,l4​=2,3,6,11), the graph F1F_1F1​ is a triangle with unit weights, and Fi+1F_{i+1}Fi+1​ consists of two copies of FiF_iFi​ joined through one new node by two edges of length 111 and two edges of length lil_ili​. Each FiF_iFi​ has 2i+1−12^{i+1}-12i+1−1 nodes and a path PiP_iPi​ from its start node to its middle node through every node, of length LiL_iLi​ with L1=2L_1=2L1​=2, Li+1=2Li+2liL_{i+1}=2L_i+2l_iLi+1​=2Li​+2li​. The graph GiG_iGi​ adds two closing edges to FiF_iFi​, and Gˉi\bar G_iGˉi​ is the complete graph on the same nodes whose distance is the shortest-path distance of GiG_iGi​.

Formalization targets

Goal: Theorem 2 (p. 566)

For each m>3m>3m>3 there is a traveling salesman graph with n=2m−1n=2^m-1n=2m−1 nodes and a nearest-neighbor tour on it such that

NEARNEIBEROPTIMAL>13lg⁡(n+1)+49.\frac{\mathrm{NEARNEIBER}}{\mathrm{OPTIMAL}}>\frac13\lg(n+1)+\frac49 .OPTIMALNEARNEIBER​>31​lg(n+1)+94​.

The statement is existential in both the instance and the run of the algorithm, exactly as in the paper.

Milestones, in the order the proof uses them

  1. (2.12): the difference equation Li+1=2Li+2liL_{i+1}=2L_i+2l_iLi+1​=2Li​+2li​, L1=2L_1=2L1​=2, has the solution Li=19(6 i 2i+8⋅2i+(−1)i−9)L_i=\frac19(6\,i\,2^i+8\cdot2^i+(-1)^i-9)Li​=91​(6i2i+8⋅2i+(−1)i−9).
  2. Gˉi\bar G_iGˉi​ is a traveling salesman graph: the shortest-path distance of GiG_iGi​ is symmetric, nonnegative and satisfies the triangle inequality.
  3. (2.13)–(2.17): the shortest-path distances in Fi+1F_{i+1}Fi+1​ between the seven named nodes A,…,GA,\dots,GA,…,G of Fig. 1, e.g. AG‾=li+2−2\overline{AG}=l_{i+2}-2AG=li+2​−2.
  4. Property a): every edge of GiG_iGi​ is a shortest path between its endpoints.
  5. Property b): the nearest neighbor algorithm started at the start node of Gˉi\bar G_iGˉi​ can follow PiP_iPi​ and return along the edge of length li−1l_i-1li​−1.
  6. The optimal tour: OPTIMAL(Gˉi)=2i+1−1\mathrm{OPTIMAL}(\bar G_i)=2^{i+1}-1OPTIMAL(Gˉi​)=2i+1−1.
  7. The exact ratio: the tour along PiP_iPi​ has length Li+li−1L_i+l_i-1Li​+li​−1, so its ratio is (Li+li−1)/n(L_i+l_i-1)/n(Li​+li​−1)/n.
  8. The inequality: (Li+li−1)/n>13lg⁡(n+1)+49(L_i+l_i-1)/n>\frac13\lg(n+1)+\frac49(Li​+li​−1)/n>31​lg(n+1)+94​ for i≥3i\ge3i≥3.

The instance for mmm is Gˉm−1\bar G_{m-1}Gˉm−1​.

Significance

Theorem 1 of the same paper shows NEARNEIBER/OPTIMAL≤12⌈lg⁡n⌉+12\mathrm{NEARNEIBER}/\mathrm{OPTIMAL}\le\frac12\lceil\lg n\rceil+\frac12NEARNEIBER/OPTIMAL≤21​⌈lgn⌉+21​ for every nearest-neighbor tour on every traveling salesman graph. Theorem 2 shows that this bound has the right order: no constant-factor guarantee holds for the nearest neighbor rule, and the gap between the two constants (13\frac1331​ against 12\frac1221​) is all that remains. This separates the nearest neighbor rule from the insertion rules analysed later in the same paper, of which nearest and cheapest insertion are within a factor 222 of optimal. It is the standard example of a natural greedy heuristic whose approximation ratio grows with nnn.

The upper bound, Theorem 1, is already on Prove2Me with a machine-checked proof (SupplyChainTheory.nearest_neighbor_bound); its statement notes that the lower-bound instances are not formalized there. This mission supplies them: an explicit recursive family of metric instances, the shortest-path computations that certify it, and the arithmetic of its ratio. The result is proved in the paper; to our knowledge it has not been formalized in any proof assistant. The construction (a recursively defined weighted graph with a closed-form shortest-path table) is also a reusable pattern for other worst-case lower bounds of greedy heuristics.

Difficulty

The arithmetic ((2.12) and the final inequality) is routine. The content is in properties a) and b). A shortest-path distance is an infimum over all walks, and property a) asks that no detour through the recursive structure is shorter than the direct edge, at every level of the recursion. The paper handles this by an induction on (2.13)–(2.17) that tracks only seven nodes per level, and argues that distances inside a copy of FiF_iFi​ are not shortened by embedding it into Fi+1F_{i+1}Fi+1​. Property b) then needs that at each step of PiP_iPi​ the chosen node is at least as close as every unvisited node, including nodes in the other copy and nodes reached through the start or right nodes; ties occur, and the claim is only that some resolution of them follows PiP_iPi​. Checking small cases by computer does not give either property for all iii.

Formalization scope

Nodes of an instance are Fin n, a tour is a permutation of Fin n, the tour length is the sum over consecutive pairs including the closing edge, and OPTIMAL is a minimum over the finite set of permutations. The model is the paper's: symmetric, nonnegative distances with the triangle inequality. The distance structure also carries d(a,a)=0d(a,a)=0d(a,a)=0, a normalization not in the paper; the diagonal never enters a tour length. A nearest-neighbor tour is a permutation in which each step goes to a node at least as close as every unvisited node, from an arbitrary start with arbitrary ties.

Ratios are multiplied out: the goal is (13log⁡2(n+1)+49)⋅OPTIMAL<NEARNEIBER(\frac13\log_2(n+1)+\frac49)\cdot\mathrm{OPTIMAL}<\mathrm{NEARNEIBER}(31​log2​(n+1)+94​)⋅OPTIMAL<NEARNEIBER together with OPTIMAL>0\mathrm{OPTIMAL}>0OPTIMAL>0, the paper's standing assumption (1.1). lg⁡(n+1)\lg(n+1)lg(n+1) is Real.logb 2 of n+1n+1n+1, as printed. Because of the strict inequality and the conjunct OPTIMAL>0\mathrm{OPTIMAL}>0OPTIMAL>0, the all-zero distance does not satisfy the goal, so the statement cannot be met by a degenerate instance.

In the construction the nodes of FiF_iFi​, GiG_iGi​, Gˉi\bar G_iGˉi​ are numbered 0,…,2i+1−20,\dots,2^{i+1}-20,…,2i+1−2 from left to right (start node 000, middle node 2i−12^i-12i−1, right node 2i+1−22^{i+1}-22i+1−2); in Fi+1F_{i+1}Fi+1​ the left copy comes first, then the new node, then the right copy. Graphs are edge lists with real weights and lil_ili​ is defined in R\mathbb RR exactly as in (2.11). The shortest-path distance is the infimum of walk weights over an inductive walk predicate; it would be 000 for two nodes with no connecting walk, a case that does not arise because every GiG_iGi​ and FiF_iFi​ is connected. LiL_iLi​ is defined by its difference equation; its identification with the length of the tour along PiP_iPi​ is milestone 7. All construction statements assume i≥1i\ge1i≥1.

A complete development needs a small library for shortest-path distances of finite weighted edge lists (symmetry, triangle inequality, attainment, behaviour under relabelling and under gluing two graphs at a few nodes); this part is reusable beyond the mission. Contributions welcome: proofs of any milestone, and such general shortest-path lemmas as separate theorems. Theorem 1 is not part of this mission.

Selected references

  • D. J. Rosenkrantz, R. E. Stearns, P. M. Lewis II, An Analysis of Several Heuristics for the Traveling Salesman Problem, SIAM J. Comput. 6(3):563–581, 1977. https://doi.org/10.1137/0206041
  • M. Bellmore, G. L. Nemhauser, The Traveling Salesman Problem: A Survey, Operations Research 16(3):538–558, 1968. https://doi.org/10.1287/opre.16.3.538
  • J. W. Gavett, Three Heuristic Rules for Sequencing Jobs to a Single Production Facility, Management Science 11(8):B166–B176, 1965. https://doi.org/10.1287/mnsc.11.8.B166
  • N. Christofides, Worst-Case Analysis of a New Heuristic for the Travelling Salesman Problem, Report 388, Graduate School of Industrial Administration, Carnegie Mellon University, 1976.
12 thms4 active usersReviewed
🏆Completed
CombinatoricsOperations ResearchOptimization·Captain: mikedeng1

Worst-Case Performance Bounds for Simple One-Dimensional Packing Algorithms 2: First-Fit and Best-Fit with Bounded Item SizesResearch Paper

Motivation

Bin packing asks for the fewest unit-capacity bins that hold a given list of item sizes. It models cutting stock, memory allocation, file placement and the loading of trucks, and it is NP-hard, so in practice lists are packed by simple rules that look at one item at a time. The two most widely used rules are First-Fit and Best-Fit, and the question that Johnson, Demers, Ullman, Garey and Graham answered in 1974 is how far from optimal they can be in the worst case.

Their headline answer is that both rules use at most about 1710\tfrac{17}{10}1017​ times the optimal number of bins, and that 1710\tfrac{17}{10}1017​ is asymptotically attained. The lists that force this ratio use items larger than 12\tfrac1221​. When all items are known to be small, which is typical of memory and storage applications, the guarantee is much better, and this mission is about that refinement: the paper's Theorem 2.3 and its corollary, which determine the asymptotic worst-case ratio of First-Fit and Best-Fit exactly as a function of the largest allowed item size α≤12\alpha\le\tfrac12α≤21​.

Timeline. Ullman (1971) introduced the worst-case analysis of First-Fit with a 1710L∗+3\tfrac{17}{10}L^*+31017​L∗+3 bound. Garey, Graham and Ullman (1972) and Johnson's thesis (MIT, 1973) extended it to Best-Fit and to the decreasing variants. The 1974 SIAM paper collects these results; Theorem 2.3 there is the parametric bound for items of size at most α\alphaα. The additive constants in the unrestricted 1710\tfrac{17}{10}1017​ bound were sharpened over the following four decades, culminating in Dósa and Sgall's proof (2013) that FF(L)≤⌊1710L∗⌋FF(L)\le\lfloor\tfrac{17}{10}L^*\rfloorFF(L)≤⌊1017​L∗⌋.

Setting

A list is a finite sequence L=(a1,…,an)L=(a_1,\dots,a_n)L=(a1​,…,an​) of real numbers in (0,1](0,1](0,1]. Its optimum L∗L^*L∗ is the least number of bins into which the elements of LLL can be placed so that no bin contains numbers whose sum exceeds 111. The level of a bin is the sum of the numbers in it. For a real α>0\alpha>0α>0, write L⊆(0,α]L\subseteq(0,\alpha]L⊆(0,α] when every element of LLL is at most α\alphaα.

First-Fit (FFFFFF) considers bins B1,B2,…B_1,B_2,\dotsB1​,B2​,…, all initially empty, and places a1,a2,…,ana_1,a_2,\dots,a_na1​,a2​,…,an​ in that order: aia_iai​ goes into the bin BjB_jBj​ of least index whose level β\betaβ satisfies β≤1−ai\beta\le 1-a_iβ≤1−ai​. Best-Fit (BFBFBF) is the same except that, among the bins with β≤1−ai\beta\le 1-a_iβ≤1−ai​, it chooses one of largest level β\betaβ (least index among ties). FF(L)FF(L)FF(L) and BF(L)BF(L)BF(L) denote the numbers of nonempty bins at the end.

The restricted worst-case ratios are

RFFα(k)=max⁡{FF(L)L∗:L⊆(0,α], L∗=k},RBFα(k)=max⁡{BF(L)L∗:L⊆(0,α], L∗=k}.R^\alpha_{FF}(k)=\max\Big\{\frac{FF(L)}{L^*}: L\subseteq(0,\alpha],\ L^*=k\Big\},\qquad R^\alpha_{BF}(k)=\max\Big\{\frac{BF(L)}{L^*}: L\subseteq(0,\alpha],\ L^*=k\Big\}.RFFα​(k)=max{L∗FF(L)​:L⊆(0,α], L∗=k},RBFα​(k)=max{L∗BF(L)​:L⊆(0,α], L∗=k}.

Throughout, 0<α≤120<\alpha\le\tfrac120<α≤21​ and m=⌊α−1⌋m=\lfloor\alpha^{-1}\rfloorm=⌊α−1⌋, an integer with m≥2m\ge 2m≥2 and 1m+1<α≤1m\tfrac1{m+1}<\alpha\le\tfrac1mm+11​<α≤m1​.

Formalization targets

Goal: the asymptotic ratio (Corollary of Theorem 2.3, p. 308)

lim⁡k→∞RFFα(k)=lim⁡k→∞RBFα(k)=1+1⌊α−1⌋.\lim_{k\to\infty}R^\alpha_{FF}(k)=\lim_{k\to\infty}R^\alpha_{BF}(k)=1+\frac{1}{\lfloor\alpha^{-1}\rfloor}.k→∞lim​RFFα​(k)=k→∞lim​RBFα​(k)=1+⌊α−1⌋1​.

The goal is stated as a limit, which is the stable form of the result: it is unaffected by any improvement of the additive constants below.

Theorem 2.3(i): the lower bound (p. 307)

For each k≥1k\ge1k≥1 there is a list L⊆(0,α]L\subseteq(0,\alpha]L⊆(0,α] with L∗=kL^*=kL∗=k and FF(L)≥m+1mL∗−1mFF(L)\ge\frac{m+1}{m}L^*-\frac1mFF(L)≥mm+1​L∗−m1​; likewise for BFBFBF.

Two steps of the First-Fit upper bound (p. 308)

If no element of LLL exceeds 1m\frac1mm1​, then in the First-Fit packing every bin except possibly the last contains at least mmm elements, and all but at most two bins have level at least mm+1\frac{m}{m+1}m+1m​.

Theorem 2.3(ii): the upper bounds (p. 307)

For every list L⊆(0,α]L\subseteq(0,\alpha]L⊆(0,α],

FF(L)≤m+1mL∗+2,BF(L)≤m+1mL∗+2.FF(L)\le\frac{m+1}{m}L^*+2,\qquad BF(L)\le\frac{m+1}{m}L^*+2.FF(L)≤mm+1​L∗+2,BF(L)≤mm+1​L∗+2.

Significance

The theorem gives an exact, parametric description of how the worst case of the two greedy rules improves as items shrink: the asymptotic ratio is 32\tfrac3223​ when items are at most 12\tfrac1221​, 43\tfrac4334​ when at most 13\tfrac1331​, and tends to 111 as the maximum item size tends to 000. Combined with the 1710\tfrac{17}{10}1017​ bound for unrestricted lists, it shows that the bad behaviour of First-Fit is caused entirely by items larger than 12\tfrac1221​. Such parametric bounds are the standard way bin-packing heuristics are compared in the literature on online and semi-online packing, and the construction in part (i) is a reusable template for lower-bound lists.

The paper proves the First-Fit upper bound and the lower bound (the verification of the lower-bound construction is left to the reader). The Best-Fit upper bound is stated but not proved: the paper says only that "a similar, but slightly more complicated, argument can be used". A formal proof of the goal therefore requires supplying that argument. None of these results is known to have a machine-checked proof; Mathlib contains no bin-packing development.

Difficulty

For First-Fit the upper bound is a counting argument, but it rests on a property of the run, not of the final packing: an item that went into a later bin did not fit into an earlier bin at the moment it was placed. Turning that into a statement about the final levels requires an invariant maintained through the whole sequence of placements.

The Best-Fit upper bound is harder because that property fails: Best-Fit may put a small item into a fuller, later bin while an earlier, lighter bin still has room, so a light early bin and a light later bin can coexist longer than under First-Fit. The paper gives no argument for this case.

The lower bound requires computing the exact behaviour of both algorithms on a specific interleaved list with item sizes perturbed by powers of mmm, and computing L∗L^*L∗ exactly for that list, which needs a matching lower bound on the optimum.

Formalization scope

A list is L : List ℝ with the hypothesis IsList L (every element in (0,1](0,1](0,1]); L⊆(0,α]L\subseteq(0,\alpha]L⊆(0,α] is the additional hypothesis ∀ a ∈ L, a ≤ α. L∗L^*L∗ is optBins L, a sInf in ℕ over numbers of bins admitting a feasible assignment; the hypothesis IsList makes the set nonempty. The runs ffPack L and bfPack L are folds over the list that keep the nonempty bins in the order they were opened, each with its contents; an item that fits nowhere opens a new bin at the end, which is the paper's "least jjj" over infinitely many empty bins. Comparisons are exact (classical decidability on ℝ), and FF(L)FF(L)FF(L), BF(L)BF(L)BF(L) are the lengths of the final bin lists. mmm is Nat.floor α⁻¹, cast before any division.

The ratios RFFα(k)R^\alpha_{FF}(k)RFFα​(k), RBFα(k)R^\alpha_{BF}(k)RBFα​(k) are suprema taken in ℝ≥0∞: an unbounded family would give +∞+\infty+∞, never a default value, and at k=0k=0k=0 the only admissible list is empty and the value is 000. The goal is a Tendsto … atTop (𝓝 (1 + (⌊α⁻¹⌋₊)⁻¹)) statement in ℝ≥0∞. A real-valued sSup would have returned 000 on an unbounded family and made a false bound look provable; that encoding is ruled out. The upper bounds keep the additive constant 222 and the lower bound the subtractive 1m\frac1mm1​ exactly as printed.

The two proof steps are stated under the proof's own hypothesis "no element exceeding 1/m1/m1/m", which is weaker than L⊆(0,α]L\subseteq(0,\alpha]L⊆(0,α].

A complete development needs invariants of the First-Fit and Best-Fit folds, a lower bound L∗≥∑iaiL^*\ge\sum_i a_iL∗≥∑i​ai​, and exact evaluation of both runs on the construction of part (i). Lemmas about the fold encoding of First-Fit and Best-Fit and about L∗L^*L∗ are reusable in the companion missions on the 1710\tfrac{17}{10}1017​, 119\tfrac{11}{9}911​ and 7160\tfrac{71}{60}6071​ bounds of the same paper. Contributions on the Best-Fit upper bound are especially welcome, since the source gives no proof.

Selected references

  • D. S. Johnson, A. Demers, J. D. Ullman, M. R. Garey, R. L. Graham, Worst-Case Performance Bounds for Simple One-Dimensional Packing Algorithms, SIAM Journal on Computing 3(4):299–325, 1974. https://doi.org/10.1137/0203025
  • J. D. Ullman, The Performance of a Memory Allocation Algorithm, Technical Report 100, Princeton University, 1971.
  • M. R. Garey, R. L. Graham, J. D. Ullman, Worst-Case Analysis of Memory Allocation Algorithms, Proc. 4th ACM Symposium on Theory of Computing, 143–150, 1972. https://doi.org/10.1145/800152.804907
  • D. S. Johnson, Near-Optimal Bin Packing Algorithms, PhD thesis, Massachusetts Institute of Technology, 1973. http://hdl.handle.net/1721.1/57819
  • G. Dósa, J. Sgall, First Fit Bin Packing: A Tight Analysis, Proc. 30th STACS, LIPIcs 20:538–549, 2013. https://doi.org/10.4230/LIPIcs.STACS.2013.538
7 thms4 active usersReviewed
🏆Completed
CombinatoricsOperations ResearchOptimization·Captain: mikedeng1

Local Search Heuristics for k-Median and Facility Location Problems III: Add-Drop-Swap Local Search for Uncapacitated Facility Location Has Locality Gap 3Research Paper

Motivation

The uncapacitated facility location (UFL) problem is one of the basic models of location theory and operations research: a firm chooses which warehouses, plants or servers to open, paying a fixed cost for each open site and a service cost for every client according to its distance to the nearest open site. It is also a standard test case for approximation algorithms.

Local search is the simplest of these and the one most used in practice: start from any set of open facilities and repeatedly add, drop or exchange one facility while this lowers the cost. The question is how bad a solution can be when no such move helps. Arya, Garg, Khandekar, Meyerson, Munagala and Pandit (SIAM J. Comput. 33(3), 2004) answered it for UFL with an exact constant.

Timeline. Korupolu, Plaxton and Rajaraman (SODA 1998, J. Algorithms 2000) analysed local search with add, drop and swap moves and proved a locality gap of at most 5; their analysis contains the service cost bound restated here as Lemma 4.1. Charikar and Guha (FOCS 1999) proved a locality gap of 3 for a different local search, in which one facility is added and any number are dropped. Arya et al. (STOC 2001; journal version 2004) proved that the add/drop/swap neighbourhood itself has locality gap at most 3, and gave an instance showing that 3 cannot be improved (§4.3).

Setting

A metric instance consists of a finite set CCC of clients, a finite set FFF of facilities, and a distance ddd on C∪FC \cup FC∪F that is nonnegative, symmetric and satisfies the triangle inequality. The cost of serving client jjj by facility iii is cji=d(j,i)c_{ji} = d(j,i)cji​=d(j,i); the distance cii′c_{ii'}cii′​ between two facilities is also available. Each facility i∈Fi \in Fi∈F has an opening cost fi≥0f_i \ge 0fi​≥0.

A solution is a nonempty set S⊆FS \subseteq FS⊆F of open facilities. Every client is served by its nearest open facility, so

costf(S)=∑i∈Sfi,costs(S)=∑j∈Cmin⁡i∈Scji,cost(S)=costf(S)+costs(S).\mathrm{cost}_f(S) = \sum_{i \in S} f_i, \qquad \mathrm{cost}_s(S) = \sum_{j \in C} \min_{i \in S} c_{ji}, \qquad \mathrm{cost}(S) = \mathrm{cost}_f(S) + \mathrm{cost}_s(S).costf​(S)=i∈S∑​fi​,costs​(S)=j∈C∑​i∈Smin​cji​,cost(S)=costf​(S)+costs​(S).

The neighbourhood of SSS is the set of solutions reachable by adding one facility, dropping one facility, or swapping one open facility for another:

B(S)={S+{s′}}∪{S−{s}∣s∈S}∪{S−{s}+{s′}∣s∈S}.\mathcal B(S) = \{S + \{s'\}\} \cup \{S - \{s\} \mid s \in S\} \cup \{S - \{s\} + \{s'\} \mid s \in S\}.B(S)={S+{s′}}∪{S−{s}∣s∈S}∪{S−{s}+{s′}∣s∈S}.

SSS is locally optimum if cost(S)≤cost(S′)\mathrm{cost}(S) \le \mathrm{cost}(S')cost(S)≤cost(S′) for every S′∈B(S)S' \in \mathcal B(S)S′∈B(S). The locality gap is the supremum, over all instances, of the ratio between the cost of a worst local optimum and the cost of a global optimum.

The proofs use the following notation, which appears in the milestones but not in the goal. Fix a second solution OOO and nearest-facility assignments σS:C→S\sigma_S : C \to SσS​:C→S, σO:C→O\sigma_O : C \to OσO​:C→O; write Sj=cjσS(j)S_j = c_{j\sigma_S(j)}Sj​=cjσS​(j)​, Oj=cjσO(j)O_j = c_{j\sigma_O(j)}Oj​=cjσO​(j)​, NS(s)=σS−1(s)N_S(s) = \sigma_S^{-1}(s)NS​(s)=σS−1​(s), NO(o)=σO−1(o)N_O(o) = \sigma_O^{-1}(o)NO​(o)=σO−1​(o) and Nso=NO(o)∩NS(s)N^o_s = N_O(o) \cap N_S(s)Nso​=NO​(o)∩NS​(s). A facility s∈Ss \in Ss∈S captures o∈Oo \in Oo∈O if ∣Nso∣>12∣NO(o)∣|N^o_s| > \tfrac12 |N_O(o)|∣Nso​∣>21​∣NO​(o)∣; sss is good if it captures no facility of OOO and bad otherwise. The proof of the facility cost bound uses a permutation π\piπ of the clients that maps each NO(o)N_O(o)NO​(o) onto itself, moves every client of a non-capturing block NsoN^o_sNso​ out of that block (Property 3.1), and fixes every client of a capturing block that it would map into the same block.

Formalization targets

Goal: Theorem 4.3

cost(S)≤3⋅cost(O)for every locally optimum S and every solution O.\mathrm{cost}(S) \le 3 \cdot \mathrm{cost}(O) \quad \text{for every locally optimum } S \text{ and every solution } O.cost(S)≤3⋅cost(O)for every locally optimum S and every solution O.

This is the locality gap bound of Theorem 4.3 (p. 557) in its strongest printed form: OOO is any solution, not only an optimal one.

Milestones

  1. Lemma 4.1 (service cost), p. 554: costs(S)≤costf(O)+costs(O)\mathrm{cost}_s(S) \le \mathrm{cost}_f(O) + \mathrm{cost}_s(O)costs​(S)≤costf​(O)+costs​(O).
  2. The refined mapping π\piπ of the proof of Lemma 4.2, p. 555: such a permutation exists for any two assignments.
  3. Inequality (5), p. 555: the drop move for a good facility sss,
−fs+∑j∈NS(s), π(j)≠j(Oj+Oπ(j)+Sπ(j)−Sj)+2∑j∈NS(s), π(j)=jOj≥0.-f_s + \sum_{j \in N_S(s),\ \pi(j) \neq j} (O_j + O_{\pi(j)} + S_{\pi(j)} - S_j) + 2 \sum_{j \in N_S(s),\ \pi(j) = j} O_j \ge 0.−fs​+j∈NS​(s), π(j)=j∑​(Oj​+Oπ(j)​+Sπ(j)​−Sj​)+2j∈NS​(s), π(j)=j∑​Oj​≥0.
  1. Inequality (6), pp. 555–556: the swap of a bad facility sss with the facility ooo it captures that is nearest to it.
  2. Inequality (8), p. 556: for a bad facility sss capturing the set P⊆OP \subseteq OP⊆O, the analogue of (5) with ∑o′∈Pfo′−fs\sum_{o' \in P} f_{o'} - f_s∑o′∈P​fo′​−fs​ in place of −fs-f_s−fs​.
  3. Lemma 4.2 (facility cost), p. 555: costf(S)≤costf(O)+2⋅costs(O)\mathrm{cost}_f(S) \le \mathrm{cost}_f(O) + 2 \cdot \mathrm{cost}_s(O)costf​(S)≤costf​(O)+2⋅costs​(O).

A companion item, not a milestone, states the bound in the proof of Theorem 4.4 with α=2\alpha = \sqrt2α=2​: a local optimum of the instance with facility costs 2fi\sqrt2 f_i2​fi​ costs at most (1+2) cost(O)(1+\sqrt2)\,\mathrm{cost}(O)(1+2​)cost(O) in the original instance.

Significance

The result. Theorem 4.3 shows that the simplest local search for metric UFL is within a factor 3 of optimal at every local optimum, with no LP and no rounding, and the tight example of §4.3 shows the analysis cannot be improved for this neighbourhood. Because Lemmas 4.1 and 4.2 hold against every solution OOO, scaling the facility costs before running local search trades the two bounds against each other and gives the 1+2+ϵ1 + \sqrt2 + \epsilon1+2​+ϵ guarantee of Theorem 4.4. The same capture-and-reassign technique is used for k-median (§3) and capacitated facility location (§5).

Formalizing it. The theorem is proved on paper; no machine-checked proof of it or of any locality gap bound for facility location is known to this mission. A formal development would check the reassignment arguments, which are stated case by case in the paper, and would produce reusable Lean infrastructure for metric facility location instances, nearest-facility costs and neighbourhood-based local optimality.

Difficulty

The service cost bound is routine; the facility cost bound is where the work lies. The natural first idea, closing a facility s∈Ss \in Ss∈S and sending each of its clients to the facility of SSS nearest to that client's optimal facility, fails when sss serves most of the clients of some o∈Oo \in Oo∈O: the nearest facility of SSS to ooo may be sss itself, so the client has nowhere to go. The proof separates good facilities, which can be dropped, from bad ones, which must be swapped with a captured facility, and pays for the clients that cannot be moved through the distance between sss and its nearest captured facility. The combinatorial core is the construction of a permutation within each NO(o)N_O(o)NO​(o) that avoids every non-capturing block and has fixed points only where they are unavoidable.

Formalization scope

Clients and facilities are finite types Cl and Fa. The distance is a real-valued function on Cl ⊕ Fa that is nonnegative, symmetric and satisfies the triangle inequality; d(x,x)=0d(x,x) = 0d(x,x)=0 is not assumed, since the paper neither states nor uses it. Opening costs are a function f : Fa → ℝ with 0 ≤ f i, and demands are unit, as in the paper.

Solutions are nonempty Finsets. The service cost is ∑jmin⁡i∈Scji\sum_j \min_{i \in S} c_{ji}∑j​mini∈S​cji​ (Finset.inf') and is defined only for nonempty sets, so no junk value for ∅\emptyset∅ enters. Accordingly the drop move is considered only when a facility remains open; with at least one client, ∅\emptyset∅ cannot serve anyone and is not a solution. Local optimality is required for all moves of B(S)\mathcal B(S)B(S): every added facility, every dropped facility and every swap, not only the moves used in the proof. The goal is stated as the multiplied-out inequality cost(S)≤3 cost(O)\mathrm{cost}(S) \le 3\,\mathrm{cost}(O)cost(S)≤3cost(O) for every nonempty OOO, never as a ratio, since cost(O)\mathrm{cost}(O)cost(O) may be 000.

In the milestones, the nearest-facility assignments σS\sigma_SσS​, σO\sigma_OσO​ are arbitrary among the nearest ones (ties broken arbitrarily), and the family of bijections π:NO(o)→NO(o)\pi : N_O(o) \to N_O(o)π:NO​(o)→NO​(o) is a single permutation of the clients with σO∘π=σO\sigma_O \circ \pi = \sigma_OσO​∘π=σO​. Inequality (5) assumes at least one client, which the paper assumes implicitly: with no clients and S={s}S = \{s\}S={s} it would read −fs≥0-f_s \ge 0−fs​≥0. The goal and Lemma 4.2 need no such assumption.

A statement that assumes local optimality only for the moves the proof uses, that fixes OOO to be a global optimum defined by hypotheses, or that allows the empty set a zero service cost would be a different theorem; none of these is used.

Needed infrastructure: sums over nearest-facility assignments and their fibers NO(o)N_O(o)NO​(o), the permutation π\piπ, and bookkeeping of the three kinds of moves. The instance, cost and local optimality definitions are reusable for other local search analyses of metric location problems. Proofs of any milestone are welcome, as are alternative proofs of the goal.

Selected references

  • V. Arya, N. Garg, R. Khandekar, A. Meyerson, K. Munagala, V. Pandit, Local Search Heuristics for k-Median and Facility Location Problems, SIAM J. Comput. 33(3):544–562, 2004. https://doi.org/10.1137/S0097539702416402
  • M. R. Korupolu, C. G. Plaxton, R. Rajaraman, Analysis of a Local Search Heuristic for Facility Location Problems, J. Algorithms 37(1):146–188, 2000. https://doi.org/10.1006/jagm.2000.1100
  • M. Charikar, S. Guha, Improved Combinatorial Algorithms for the Facility Location and k-Median Problems, FOCS 1999, 378–388. https://doi.org/10.1109/SFFCS.1999.814609
10 thms4 active usersReviewed
🏆Completed
Linear OptimizationOptimization·Captain: moutei

Primal-Dual Online Algorithms II: Finite LP Duality and Complementary SlacknessTextbook

Motivation

Almost every competitive online algorithm built by the primal-dual method rests on the same two facts about a pair of linear programs. The first is weak duality: any feasible solution of the dual is a lower bound on any feasible solution of the primal. The second is complementary slackness: if a feasible primal-dual pair satisfies a local, per-coordinate tightness condition, the pair is optimal — and if it satisfies that condition only up to factors α\alphaα and β\betaβ, the primal is within αβ\alpha\betaαβ of optimal.

The second fact in its approximate form is the engine of the whole method. An online algorithm cannot compute an optimum; what it can do is maintain a primal solution and a dual solution side by side so that each new request preserves an approximate tightness invariant. The approximate complementary slackness theorem then converts that local invariant into a global competitive ratio, with no reference to the optimum at all. Chapter 2 of Buchbinder's thesis states it as the background result on which the rest of the work is built.

Setting

Fix finite index types III (primal variables) and JJJ (primal constraints), a matrix A:I×J→RA : I \times J \to \mathbb{R}A:I×J→R, a cost vector c:I→Rc : I \to \mathbb{R}c:I→R and a right-hand side b:J→Rb : J \to \mathbb{R}b:J→R. The covering primal and packing dual are

(P)min⁡∑icixi  s.t.  ∑iAijxi ≥ bj  (∀j),x≥0,(P)\quad \min \sum_{i} c_i x_i \ \text{ s.t. } \ \sum_{i} A_{ij} x_i \ \ge\ b_j \ \ (\forall j), \qquad x \ge 0,(P)mini∑​ci​xi​  s.t.  i∑​Aij​xi​ ≥ bj​  (∀j),x≥0, (D)max⁡∑jbjyj  s.t.  ∑jAijyj ≤ ci  (∀i),y≥0.(D)\quad \max \sum_{j} b_j y_j \ \text{ s.t. } \ \sum_{j} A_{ij} y_j \ \le\ c_i \ \ (\forall i), \qquad y \ge 0.(D)maxj∑​bj​yj​  s.t.  j∑​Aij​yj​ ≤ ci​  (∀i),y≥0.

Note the index convention: AijA_{ij}Aij​ carries the primal-variable index first, so the primal constraint indexed by jjj sums over iii and the dual constraint indexed by iii sums over jjj.

Given α,β≥1\alpha, \beta \ge 1α,β≥1, the pair (x,y)(x,y)(x,y) satisfies approximate complementary slackness when

  • primal side: for every iii with xi>0x_i > 0xi​>0, ci/α ≤ ∑jAijyj ≤ ci\quad c_i/\alpha \ \le\ \sum_j A_{ij} y_j \ \le\ c_ici​/α ≤ ∑j​Aij​yj​ ≤ ci​;
  • dual side: for every jjj with yj>0y_j > 0yj​>0, bj ≤ ∑iAijxi ≤ β bj\quad b_j \ \le\ \sum_i A_{ij} x_i \ \le\ \beta\, b_jbj​ ≤ ∑i​Aij​xi​ ≤ βbj​.

Formalization targets

Goal — approximate complementary slackness

For a primal-feasible xxx, a dual-feasible yyy, and α,β≥1\alpha,\beta \ge 1α,β≥1 satisfying the two conditions above,

∑icixi ≤ αβ∑jbjyj.\sum_{i} c_i x_i \ \le\ \alpha\beta \sum_{j} b_j y_j .i∑​ci​xi​ ≤ αβj∑​bj​yj​.

Taking α=β=1\alpha = \beta = 1α=β=1 recovers exact complementary slackness and hence optimality of both members of the pair. The goal is stated with the source's hypotheses, including the two-sided bounds, rather than the weakest hypotheses that make the inequality go through; a separate item records the minimal-hypothesis strengthening.

Weak duality

∑jbjyj ≤ ∑icixifor every feasible x and y,\sum_j b_j y_j \ \le\ \sum_i c_i x_i \quad \text{for every feasible } x \text{ and } y,j∑​bj​yj​ ≤ i∑​ci​xi​for every feasible x and y,

with no nonnegativity assumption on AAA, bbb or ccc beyond feasibility itself.

Strong duality — imported, not reproved

Strong duality is not proved in this mission. The platform already carries LinearOptimization.lp_strong_duality, proved in this exact environment, for linear programs in Bertsimas–Tsitsiklis general form over Fin-indexed data. This mission's contribution is an adapter: from a primal optimum of (P)(P)(P), produce a dual optimum of (D)(D)(D) of equal value, for Fin-indexed instances. Reference items point at the imported theorem, its dual construction, and the dual-of-dual identity.

The biconditional — a dual optimum exists if and only if a primal optimum does — is deliberately left open. Weak duality does not derive the existence of a primal optimum from the existence of a dual one; the reverse implication needs strong duality applied to the dual program together with the dual-of-dual identity, and that reduction is not yet compiled. It is offered as a parallel target rather than claimed as established.

Significance

This mission is the foundation of the series. Every later mission — set cover, ski rental, and the online covering and packing problems that follow — states its approximation or competitiveness result as an instance of approximate complementary slackness. Formalizing it once, over arbitrary finite index types, is what makes the later missions short.

It also fills a real gap. Mathlib currently has no linear-programming duality: four separate attempts were closed unmerged. Approximate (α,β)(\alpha,\beta)(α,β) complementary slackness appears not to be formalized in any public library, so the goal theorem is, as far as we can determine, first of its kind.

Difficulty

The goal is a summation argument, not a deep theorem: the work is in handling the per-coordinate case split on xi>0x_i > 0xi​>0 versus xi=0x_i = 0xi​=0 and in interchanging a double sum. Three mechanical milestones isolate exactly those steps. The strong-duality adapter is the hard item, because it must reconcile two different presentations of the same program — index types, matrix orientation, and bundling all differ between our definitions and the imported theorem's.

Formalization scope

Definitions cover §2.1 of the source. Four distinct notions of "the program has a finite optimum" are separated on purpose — attained optimum, nonempty feasible set, bounded objective, and the conjunction — because the source's informal word "bounded" conflates them. The definitions are stated over arbitrary finite index types; the strong-duality items are stated only for Fin, because that is the only index type for which the imported dependency path exists.

Selected references

  • Niv Buchbinder, Designing Competitive Online Algorithms via a Primal-Dual Approach, PhD thesis, Tel Aviv University, 2008, §2.1, pp. 7–9. https://www.tau.ac.il/~nivb/download/phd-thsis.pdf
  • Dimitris Bertsimas and John N. Tsitsiklis, Introduction to Linear Optimization, Athena Scientific, 1997 — the general form used by the imported strong-duality theorem.
11 thms4 active usersReviewed
🏆Completed
Algorithmic Game Theory·Captain: Shuze Chen

Algorithmic Game Theory I: Existence of Nash EquilibriumTextbook

Motivation

The strategic-form game is the basic object of noncooperative game theory, and the Nash equilibrium — a profile of randomized strategies from which no player benefits by deviating unilaterally — is its central solution concept. Nash proved in 1951 that every game with finitely many players and finite strategy sets has such an equilibrium (Nash, Non-cooperative games, Ann. Math. 54 (1951)); this single existence theorem is the reason the concept organizes the rest of the field, from the computational complexity of finding equilibria to the price of anarchy. The theorem is stated as Theorem 1.8 of Nisan–Roughgarden–Tardos–Vazirani (eds.), Algorithmic Game Theory (Cambridge, 2007), the source text of this mission series, whose first chapter (Tardos–Vazirani) also treats the two special cases that admit direct algorithmic proofs: two-person zero-sum games, where equilibria are exactly the optimal solutions of a dual pair of linear programs (von Neumann 1928; Theorem 1.11), and a simple linear market, where equilibrium prices are computed by an ascending tight-set algorithm (Theorem 1.17).

A timeline of the existence theorem: von Neumann (1928) proved the minimax theorem for two-person zero-sum games; Nash (1950, 1951) extended existence to arbitrary finite games, first via Kakutani's fixed-point theorem and then via Brouwer's. All known proofs of the general theorem pass through a fixed-point principle, and this is not an artifact: computing a Nash equilibrium is PPAD-complete (Daskalakis–Goldberg–Papadimitriou 2009; Chen–Deng–Teng 2009), and PPAD is precisely the complexity class of the fixed-point arguments.

Setting

A finite strategic-form game consists of a finite set ι\iotaι of players, for each player iii a finite nonempty set SiS_iSi​ of pure strategies, and for each player a payoff function ui:∏jSj→Ru_i : \prod_j S_j \to \mathbb{R}ui​:∏j​Sj​→R; all players are utility maximizers. A mixed strategy for player iii is a probability distribution on SiS_iSi​, represented as a weight function σi:Si→R\sigma_i : S_i \to \mathbb{R}σi​:Si​→R with σi≥0\sigma_i \ge 0σi​≥0 and ∑sσi(s)=1\sum_{s} \sigma_i(s) = 1∑s​σi​(s)=1 (a lottery). Players randomize independently, so a mixed profile σ=(σi)i\sigma = (\sigma_i)_{i}σ=(σi​)i​ induces the product distribution on pure strategy vectors, and player iii's expected payoff is

Ui(σ)  =  ∑s∈∏jSj(∏jσj(sj)) ui(s).U_i(\sigma) \;=\; \sum_{s \in \prod_j S_j} \Big(\prod_j \sigma_j(s_j)\Big)\, u_i(s).Ui​(σ)=s∈∏j​Sj​∑​(j∏​σj​(sj​))ui​(s).

A mixed profile σ\sigmaσ is a (mixed) Nash equilibrium if for every player iii and every lottery τ\tauτ on SiS_iSi​, replacing σi\sigma_iσi​ by τ\tauτ does not increase UiU_iUi​.

A two-person zero-sum game is given by a matrix A∈Rm×nA \in \mathbb{R}^{m \times n}A∈Rm×n: the row player picks a row distribution ppp, the column player a column distribution qqq, and the column player pays the row player pTAqp^{\mathsf T} A qpTAq in expectation.

The market of §1.8.1 of the source has finitely many divisible goods, good aaa in sas_asa​ units, and finitely many buyers, buyer jjj bringing budget mj>0m_j > 0mj​>0 and interested in a nonempty set of goods; utilities are linear 0/1, so a buyer wants any goods from her interest set and none other. Market-clearing prices are positive prices under which each buyer can spend her whole budget on cheapest goods in her interest set while every good sells out exactly.

Formalization targets

Goal (capstone) — Theorem 1.8

Every finite strategic-form game has a mixed Nash equilibrium.\text{Every finite strategic-form game has a mixed Nash equilibrium.}Every finite strategic-form game has a mixed Nash equilibrium.

Stated for an arbitrary finite family of finite nonempty strategy types; no bound on the number of players, no genericity assumptions.

Supporting — Brouwer fixed-point theorem

K⊆E nonempty compact convex, E finite-dimensional, f:K→K continuous  ⟹  ∃x, f(x)=x.K \subseteq E \text{ nonempty compact convex},\ E \text{ finite-dimensional},\ f : K \to K \text{ continuous} \implies \exists x,\ f(x) = x.K⊆E nonempty compact convex, E finite-dimensional, f:K→K continuous⟹∃x, f(x)=x.

Mathlib currently has no form of Brouwer's theorem; every known proof of Theorem 1.8 needs it (or an equivalent), so it enters the mission as an explicit milestone rather than an assumed library fact.

Theorem 1.11 — zero-sum games

∃ p∗,q∗:∀p, pTAq∗≤p∗TAq∗,∀q, p∗TAq∗≤p∗TAq,and(p∗,q∗) is a mixed Nash equilibrium\exists\, p^\ast, q^\ast:\quad \forall p,\ p^{\mathsf T} A q^\ast \le {p^\ast}^{\mathsf T} A q^\ast, \quad \forall q,\ {p^\ast}^{\mathsf T} A q^\ast \le {p^\ast}^{\mathsf T} A q, \quad\text{and}\quad (p^\ast, q^\ast) \text{ is a mixed Nash equilibrium}∃p∗,q∗:∀p, pTAq∗≤p∗TAq∗,∀q, p∗TAq∗≤p∗TAq,and(p∗,q∗) is a mixed Nash equilibrium

of the explicit two-player game with payoffs AxyA_{xy}Axy​ to the row player and −Axy-A_{xy}−Axy​ to the column player. The source states the result as: optimal solutions of a dual pair of LPs form a Nash equilibrium of the zero-sum game; the first two conjuncts are the saddle point that LP optimality amounts to, and the third states the Nash-equilibrium clause against the mission's own game vocabulary, so "zero-sum" is formal (the two payoffs sum to zero) rather than implicit in the shape of the statement.

Theorem 1.17 (existence form)

The 0/1-utilities linear market admits market-clearing prices and allocations.\text{The 0/1-utilities linear market admits market-clearing prices and allocations.}The 0/1-utilities linear market admits market-clearing prices and allocations.

The source proves this by an ascending-price algorithm and also bounds its running time; the complexity half has no formal counterpart in this mission.

Significance

The capstone is the foundation of the whole mission series: correlated equilibria, price-of-anarchy bounds, and mechanism-design characterizations in later missions all quantify over or compare against Nash equilibria, and the series inherits its game vocabulary (IsLottery, IsMixedProfile, expectedPayoff, IsMixedNash) from this mission.

Formalizing it produces the first Brouwer fixed-point theorem in this environment — a well-known gap in mathlib with reuse value far beyond game theory (every degree-theoretic and equilibrium-existence argument needs it). The zero-sum milestone yields the minimax theorem, reusable for the learning-dynamics mission that follows. All results here are classical and proved on paper; the work requested is machine-checked proof, not new mathematics.

Difficulty

The central difficulty is Brouwer. The standard routes are (i) Sperner's lemma plus a limit argument, which needs a formal theory of simplicial subdivisions that does not exist in mathlib; (ii) algebraic topology (no retraction of the ball onto the sphere), for which mathlib has singular homology but not yet the homology of spheres in usable form; (iii) analytic proofs (Milnor–Rogers). None is short; the milestone is deliberately stated for a general nonempty compact convex set in a finite-dimensional normed space so that any route serves, and so the lemma lands in reusable generality.

Given Brouwer, Theorem 1.8 still requires Nash's gain-function construction on the product of simplices and the verification that fixed points are equilibria — bookkeeping-heavy but standard. Theorem 1.11 does not need Brouwer: mathlib's Sion minimax theorem (Mathlib.Topology.Sion) applies to the bilinear payoff on the product of standard simplices, or one can argue by LP duality directly. Theorem 1.17 needs the tight-set/max-flow argument of Lemmas 1.15–1.16 or any direct construction of the equilibrium.

Formalization scope

Games are presented concretely: players form a finite index type, strategies a finite type per player, payoffs are functions into R\mathbb{R}R; mixed strategies are weight functions with a IsLottery predicate, not measure-theoretic distributions. Deviations in the equilibrium definition range over all lotteries (not only pure strategies): the pure-deviation reduction is a lemma a solver may prove, not part of the definition. Strategy sets are assumed nonempty in the capstone; the player set need not be. In the zero-sum milestone both dimensions are positive (Fin (m+1), Fin (n+1)), payoffs flow from the column player to the row player, stdSimplex plays the role of the mixed-strategy space, and the Nash-equilibrium conjunct is stated for the Boolean-indexed two-player game built by matrixGameStrat/zeroSumPayoff/matrixGameProfile from the definitions bundle. In the market milestone all supplies and budgets are positive, every buyer's interest set is nonempty, and every good has an interested buyer, matching the standing assumptions of §1.8.1; allocations are recorded as money spent, so the clearing condition is ∑jxja=pasa\sum_j x_{ja} = p_a s_a∑j​xja​=pa​sa​ with no division anywhere.

Trivializing readings are ruled out: the empty simplex has no lotteries, so nonemptiness hypotheses appear exactly where their absence would make an existence claim false (Brouwer on the empty set, games with an empty strategy set, zero-dimensional matrix games).

Selected references

  • J. F. Nash, Non-cooperative games, Annals of Mathematics 54 (1951), 286–295. DOI
  • J. von Neumann, Zur Theorie der Gesellschaftsspiele, Mathematische Annalen 100 (1928), 295–320. DOI
  • N. Nisan, T. Roughgarden, É. Tardos, V. V. Vazirani (eds.), Algorithmic Game Theory, Cambridge University Press, 2007, Chapter 1. DOI
  • C. Daskalakis, P. W. Goldberg, C. H. Papadimitriou, The complexity of computing a Nash equilibrium, SIAM J. Computing 39 (2009), 195–259. DOI
10 thms4 active usersReviewed
🏆Completed
Captain: marwahaha

Schönhage–Pan–Winograd Bound: omega < 2.522Research Paper

Motivation

The matrix-multiplication exponent measures the asymptotic arithmetic cost of multiplying square matrices. An upper bound ω<c\omega<cω<c means that, over the field under consideration, N×NN\times NN×N matrices can be multiplied using O(Nc+ε)O(N^{c+\varepsilon})O(Nc+ε) arithmetic operations for every ε>0\varepsilon>0ε>0. Improvements to ω\omegaω are a central benchmark in algebraic complexity because matrix multiplication is also a basic subroutine in linear algebra, graph algorithms, and symbolic computation.

The existing Prove2Me mission formalizes Schönhage's bound ω<2.55\omega<2.55ω<2.55 from a concrete two-summand tensor degeneration. The present mission advances the same formal development to the next clean historical construction. Pan and Winograd found a simultaneous approximate algorithm for three matrix products; Romani recorded its tensor form and the parameter choice n=11n=11n=11, k=5k=5k=5, which gives ω≤2.5218127…\omega\le 2.5218127\ldotsω≤2.5218127…. Schönhage's 1981 paper reports the equivalent bound 3log⁡52/log⁡1103\log 52/\log 1103log52/log110 in the arbitrary-field setting. The exact formal target here is the slightly weaker rational inequality ω<1261/500=2.522\omega<1261/500=2.522ω<1261/500=2.522.

Setting

For a field KKK, the matrix-multiplication tensor ⟨a,b,c⟩K\langle a,b,c\rangle_K⟨a,b,c⟩K​ encodes multiplication of an a×ba\times ba×b matrix by a b×cb\times cb×c matrix:

⟨a,b,c⟩K=∑i<a∑j<b∑ℓ<ceij⊗ejℓ⊗eℓi.\langle a,b,c\rangle_K =\sum_{i<a}\sum_{j<b}\sum_{\ell<c} e_{ij}\otimes e_{j\ell}\otimes e_{\ell i}.⟨a,b,c⟩K​=i<a∑​j<b∑​ℓ<c∑​eij​⊗ejℓ​⊗eℓi​.

A direct sum places several such tensors in disjoint coordinate blocks. A tensor TTT has border rank at most rrr when it is a polynomial degeneration of the diagonal tensor Ir=∑s<res⊗es⊗esI_r=\sum_{s<r}e_s\otimes e_s\otimes e_sIr​=∑s<r​es​⊗es​⊗es​. In the Lean development this relation is Degenerates T (TensorObj.diagObj K 3 r). The argument order matters: the first tensor is the target and the diagonal tensor is the source.

The platform already defines ordinary tensor rank, asymptotic tensor rank, the tensor-rank exponent matMulExp K, the equivalent Strassen-preorder exponent matMulExp_strassen K, and Schönhage's asymptotic sum inequality. This mission reuses those declarations. No alternative definition of ω\omegaω is introduced.

Formalization targets

The goal has exactly the same quantified proposition as the existing 2.552.552.55 mission, with only the rational endpoint changed:

∀K  [Field(K)],matMulExp⁡(K)<1261500.\forall K\;[\mathrm{Field}(K)],\qquad \operatorname{matMulExp}(K)<\frac{1261}{500}.∀K[Field(K)],matMulExp(K)<5001261​.

The source construction to be formalized is

R‾ ⁣(⟨1,5,22⟩K⊕⟨11,2,5⟩K⊕⟨10,11,1⟩K)≤156.\underline R\!\left( \langle1,5,22\rangle_K\oplus \langle11,2,5\rangle_K\oplus \langle10,11,1\rangle_K \right)\le156.R​(⟨1,5,22⟩K​⊕⟨11,2,5⟩K​⊕⟨10,11,1⟩K​)≤156.

Each summand has volume 110110110:

1⋅5⋅22=11⋅2⋅5=10⋅11⋅1=110.1\cdot5\cdot22=11\cdot2\cdot5=10\cdot11\cdot1=110.1⋅5⋅22=11⋅2⋅5=10⋅11⋅1=110.

The milestone chain records the degeneration, its asymptotic-rank consequence, the exact numerical implication

3⋅110ωKStr/3≤156⟹ωKStr<1261500,3\cdot110^{\omega^{\mathrm{Str}}_K/3}\le156 \quad\Longrightarrow\quad \omega^{\mathrm{Str}}_K<\frac{1261}{500},3⋅110ωKStr​/3≤156⟹ωKStr​<5001261​,

and the resulting Strassen-form exponent bound. The public goal then transfers the bound to matMulExp K through the already established equality of the two exponent definitions.

Significance

Mathematically, this construction improves the concrete exponent certified by the existing mission from 2.552.552.55 to 2.5222.5222.522 without changing the surrounding theory. It isolates the first genuinely new ingredient after the accepted Schönhage example: a larger simultaneous tensor degeneration rather than a sharper numerical estimate for the old witness.

For formalization, the mission tests whether the current polynomial-degeneration API can express a historically important trilinear aggregation at realistic scale. Once the explicit witness is available, the remaining declarations form a reusable template for later bounds: a source tensor degeneration, an asymptotic-rank bound, a specialization of the asymptotic sum inequality, and a final exponent transfer. This creates a trustworthy stepping stone toward the Coppersmith--Winograd tensor and later laser-method analyses.

The 2.5222.5222.522 theorem is known mathematically; the open work is its machine-checked Lean formalization. The exact numerical endpoint and every downstream bridge from the degeneration have already been checked locally. The explicit Pan--Winograd degeneration remains the substantive open milestone.

Difficulty

The central difficulty is not the logarithmic comparison. It is constructing and verifying the polynomial family whose leading nonzero coefficient is exactly the tagged direct sum of the three matrix-multiplication tensors and whose earlier coefficients vanish. The family has 156156156 diagonal source slots and many indexed target coordinates. A proof must account for all mixed-coordinate terms and all cancellations uniformly over an arbitrary field.

Romani's published summary states the approximate-rank inequality but does not spell out a Lean-ready map between its trilinear forms and the platform's TensorObj.bigAdd coordinate spaces. A solver must therefore recover the source indexing carefully and prove that the resulting modewise linear maps have the required coefficients. Reversing the degeneration direction, conflating tensor rank with asymptotic rank, or silently assuming a characteristic-zero scalar identity would invalidate the result.

Formalization scope

All theorems quantify over an arbitrary type KKK with [Field K], matching the existing Schönhage goal and the arbitrary-field statement of the source bound. Tensor spaces are finite-dimensional function spaces already packaged by MMObj; the three products are combined with TensorObj.bigAdd. Border rank is represented by the existing finitely supported polynomial-family predicate Degenerates. Because the source summary specifies approximate rank but not a leading order, the main degeneration milestone existentially quantifies that order instead of hard-coding one.

The mission includes no placeholder laser-value definition and makes no claim about the later 2.3762.3762.376 analysis. It also excludes Schönhage's additional microscopic symmetrization improvement beyond 3log⁡52/log⁡1103\log52/\log1103log52/log110. A valid solution must construct the stated degeneration itself; a vacuous hypothesis or a redefinition of matMulExp is outside scope.

Reusable contributions include coefficient lemmas for polynomial tensor families, finite-index equivalences for direct sums, and generic aggregation identities that specialize to the n=11n=11n=11, k=5k=5k=5 witness. Contributions that merely restate the target under stronger field hypotheses do not close the arbitrary-field milestone.

Selected references

  • A. Schönhage, Partial and Total Matrix Multiplication, SIAM Journal on Computing 10(3), 1981, pp. 434--455. DOI 10.1137/0210032.
  • Francesco Romani, Some Properties of Disjoint Sums of Tensors Related to Matrix Multiplication, CNR Nota Interna B80-4, February 1980, printed p. 6; journal version, SIAM Journal on Computing 11(2), 1982. Archived preprint and DOI 10.1137/0211020.
  • Avi Wigderson and Jeroen Zuiddam, Asymptotic Spectra: Theory, Applications and Extensions, 2023, for the tensor-preorder and asymptotic-rank framework reused by the Lean development. Author manuscript.
27 thms4 active usersReviewed
🏆Completed
Algorithmic Game TheoryLinear OptimizationOperations Research·Captain: mikedeng1

Online Primal-Dual Algorithms for Maximizing Ad-Auctions Revenue: The Competitive Ratio of the Primal-Dual Allocation AlgorithmResearch Paper

Motivation

Search engines sell advertisement slots next to their results through ad-auctions. Advertisers bid on keywords, and each advertiser also sets a daily budget: the most it is willing to pay in a day. Queries arrive one at a time and each must be assigned to an advertiser at once, with no knowledge of the queries still to come. The seller's revenue from an advertiser is capped by its budget, so an allocation rule that ignores budgets can exhaust a high bidder early and forgo revenue that a more even allocation would have collected. The question is how much of the offline optimum an online rule can guarantee against every arrival sequence.

Mehta, Saberi, Vazirani and Vazirani (FOCS 2005 / J. ACM 2007) gave a deterministic algorithm whose competitive ratio tends to 1−1/e1 - 1/e1−1/e when bids are small compared with budgets, and showed that no deterministic algorithm does better. Their algorithm builds on online bipartite matching (Karp, Vazirani and Vazirani, STOC 1990) and online bbb-matching (Kalyanasundaram and Pruhs, 2000). Buchbinder, Jain and Naor (ESA 2007) rederived the 1−1/e1 - 1/e1−1/e bound with an online primal-dual algorithm, which gives the ratio in closed form for every value of the bid-to-budget ratio and extends to multiple slots, stochastic information, bounded degree and budget flexibility. This mission formalizes the basic algorithm of that paper and its Theorem 1.

Setting

There is a finite nonempty set III of buyers. Buyer iii has a known budget B(i)>0B(i) > 0B(i)>0. Products j=1,…,mj = 1, \dots, mj=1,…,m arrive one by one; when product jjj arrives, every buyer's bid b(i,j)≥0b(i,j) \ge 0b(i,j)≥0 on it is revealed. The bid-to-budget ratio is

Rmax⁡=max⁡i∈I, jb(i,j)B(i).R_{\max} = \max_{i \in I,\, j} \frac{b(i,j)}{B(i)} .Rmax​=i∈I,jmax​B(i)b(i,j)​.

A fractional allocation y(i,j)≥0y(i,j) \ge 0y(i,j)≥0 assigns fractions of products to buyers; the revenue from buyer iii is the minimum of ∑jb(i,j) y(i,j)\sum_j b(i,j)\,y(i,j)∑j​b(i,j)y(i,j) and B(i)B(i)B(i).

The offline fractional problem is the packing LP, which the paper calls the dual:

max⁡∑j∑ib(i,j) y(i,j)s.t.∑iy(i,j)≤1  ∀j,∑jb(i,j) y(i,j)≤B(i)  ∀i,y≥0.\max \sum_{j}\sum_{i} b(i,j)\,y(i,j) \quad\text{s.t.}\quad \sum_i y(i,j) \le 1 \ \ \forall j,\qquad \sum_j b(i,j)\,y(i,j) \le B(i)\ \ \forall i,\qquad y \ge 0 .maxj∑​i∑​b(i,j)y(i,j)s.t.i∑​y(i,j)≤1  ∀j,j∑​b(i,j)y(i,j)≤B(i)  ∀i,y≥0.

Its LP dual, the paper's primal, is the covering LP:

min⁡∑iB(i) x(i)+∑jz(j)s.t.b(i,j) x(i)+z(j)≥b(i,j)  ∀i,j,x,z≥0.\min \sum_i B(i)\,x(i) + \sum_j z(j) \quad\text{s.t.}\quad b(i,j)\,x(i) + z(j) \ge b(i,j)\ \ \forall i,j,\qquad x, z \ge 0 .mini∑​B(i)x(i)+j∑​z(j)s.t.b(i,j)x(i)+z(j)≥b(i,j)  ∀i,j,x,z≥0.

The Allocation Algorithm has a parameter c>1c > 1c>1 and starts from x≡0x \equiv 0x≡0. When product jjj arrives it takes a buyer iii maximizing b(i,j)(1−x(i))b(i,j)(1 - x(i))b(i,j)(1−x(i)). If x(i)≥1x(i) \ge 1x(i)≥1, the product is not sold. Otherwise it charges iii the minimum of b(i,j)b(i,j)b(i,j) and iii's remaining budget, sets y(i,j)←1y(i,j) \leftarrow 1y(i,j)←1 and z(j)←b(i,j)(1−x(i))z(j) \leftarrow b(i,j)(1 - x(i))z(j)←b(i,j)(1−x(i)), and updates

x(i)←x(i)(1+b(i,j)B(i))+b(i,j)(c−1) B(i).x(i) \leftarrow x(i)\Big(1 + \frac{b(i,j)}{B(i)}\Big) + \frac{b(i,j)}{(c-1)\,B(i)} .x(i)←x(i)(1+B(i)b(i,j)​)+(c−1)B(i)b(i,j)​.

Its revenue is the total amount charged.

Formalization targets

Goal: Theorem 1

For every instance and every bound R>0R > 0R>0 with b(i,j)≤R B(i)b(i,j) \le R\,B(i)b(i,j)≤RB(i) for all i,ji, ji,j, the Allocation Algorithm run with c=(1+R)1/Rc = (1+R)^{1/R}c=(1+R)1/R, under any tie-breaking of the maximum, satisfies for every feasible y′y'y′ of the packing LP

Revenue  ≥  (1−1c)(1−R)∑j∑ib(i,j) y′(i,j).\mathrm{Revenue} \;\ge\; \Big(1 - \frac1c\Big)(1 - R)\sum_{j}\sum_{i} b(i,j)\,y'(i,j).Revenue≥(1−c1​)(1−R)j∑​i∑​b(i,j)y′(i,j).

With R=Rmax⁡R = R_{\max}R=Rmax​ this is the paper's statement that the algorithm is (1−1/c)(1−Rmax⁡)(1 - 1/c)(1 - R_{\max})(1−1/c)(1−Rmax​)-competitive; the fractional optimum bounds every integral offline allocation.

Milestones

The proof of Theorem 1 rests on three claims and three auxiliary facts, each a milestone:

  1. the inequality ln⁡(1+x)/x≥ln⁡(1+y)/y\ln(1+x)/x \ge \ln(1+y)/yln(1+x)/x≥ln(1+y)/y for 0<x≤y≤10 < x \le y \le 10<x≤y≤1;
  2. Claim (1): the final (x,z)(x, z)(x,z) is feasible for the covering LP;
  3. Claim (2): the covering cost of the run equals (1+1/(c−1))(1 + 1/(c-1))(1+1/(c−1)) times the packing value of the run's own yyy;
  4. Inequality (1): x(i)≥1c−1(c∑jb(i,j)y(i,j)/B(i)−1)x(i) \ge \frac{1}{c-1}\big(c^{\sum_j b(i,j) y(i,j)/B(i)} - 1\big)x(i)≥c−11​(c∑j​b(i,j)y(i,j)/B(i)−1) at every stage of the run;
  5. Claim (3): ∑jb(i,j) y(i,j)≤B(i)+max⁡jb(i,j)\sum_j b(i,j)\,y(i,j) \le B(i) + \max_j b(i,j)∑j​b(i,j)y(i,j)≤B(i)+maxj​b(i,j), and the amount charged to iii is at least (1−R)∑jb(i,j) y(i,j)(1 - R)\sum_j b(i,j)\,y(i,j)(1−R)∑j​b(i,j)y(i,j);
  6. weak duality for the LP pair above;

and, separately, the second sentence of Theorem 1,

lim⁡R→0+(1−1(1+R)1/R)(1−R)=1−1e.\lim_{R\to 0^+}\Big(1 - \frac{1}{(1+R)^{1/R}}\Big)(1-R) = 1 - \frac1e .R→0+lim​(1−(1+R)1/R1​)(1−R)=1−e1​.

Significance

Theorem 1 gives an explicit ratio for every value of Rmax⁡R_{\max}Rmax​, not only in the limit. It tends to the optimal deterministic ratio 1−1/e1 - 1/e1−1/e as bids become small, and it quantifies how the guarantee degrades as single bids become a larger share of a budget. The primal-dual analysis is the template for the paper's later sections and for a line of work on online packing and covering problems, surveyed in Buchbinder and Naor's monograph The Design of Competitive Online Algorithms via a Primal-Dual Approach (Foundations and Trends in TCS, 2009).

The result is proved in the paper, and the proof is short. What this mission adds is a machine-checked proof about an algorithm that is defined, not described: the run is computed by recursion from the instance, and the guarantee is proved for that run and every tie-breaking. A related private mission on the platform, The Design of Competitive Online Algorithms via a Primal-Dual Approach VI: Maximizing Ad-Auctions Revenue, states the monograph's Theorem 10.1, which is this theorem, in a form that takes the analysis's intermediate inequalities as hypotheses over arbitrary lists of won bids; the present mission states it for the algorithm itself. No machine-checked proof of Theorem 1 is known to this mission.

Difficulty

Each step of the proof is elementary; the difficulty is the bookkeeping of an online process. Claims (1) and (2) are statements about a single iteration that must be lifted to the whole run: Claim (1) uses that xxx only increases, and Claim (2) that each product is processed once. Inequality (1) is an induction over the iterations that allocate to one buyer, interleaved with iterations that allocate to others and is the only place where the value of ccc matters. Claim (3) needs a further invariant: the amount charged equals the minimum of the allocated bids and the budget.

A tempting shortcut is to take Inequality (1) and the "at most one undercharge" fact as hypotheses about some list of bids. That does not describe the algorithm and is not the theorem; here the only hypotheses are on the instance and on the tie-breaking rule.

Formalization scope

Buyers are a type I with [Fintype I] and [Nonempty I]; products are Fin m, whose order is the arrival order. Bids and budgets are real, with B(i)>0B(i) > 0B(i)>0 and b(i,j)≥0b(i,j) \ge 0b(i,j)≥0. The state of the algorithm records xxx, the amounts charged, yyy and zzz; one iteration is step, the run after kkk products is runPrefix, and revenue sums the charges of the final state. The tie-breaking rule is a function sel of the current xxx and the product, required to return a maximizer of b(i,j)(1−x(i))b(i,j)(1-x(i))b(i,j)(1−x(i)); the theorem holds for every such rule. The constant c=(1+R)1/Rc = (1+R)^{1/R}c=(1+R)1/R is a real power and requires R>0R > 0R>0. The theorem is stated for any bound RRR on the ratios, of which the exact maximum is one instance. Claims (1) and (2) are stated for every c>1c > 1c>1, which covers the paper's choice. The paper's inequality for ln⁡(1+x)/x\ln(1+x)/xln(1+x)/x allows x=0x = 0x=0, read as a limit; the Lean statement requires x>0x > 0x>0.

A statement over an unconstrained allocation, or one conditioned on the proof's own intermediate inequalities, would be trivially true or false; the targets here concern only the run the definitions compute.

The development needs finite sums, real powers and logarithms from Mathlib and an induction principle for the run. The LP pair and weak duality are reusable for the paper's extensions, and the run invariants for any primal-dual online algorithm with multiplicative updates. Proofs of any milestone are welcome, as are sharper variants, such as the exact-Rmax⁡R_{\max}Rmax​ form or the bound against integral allocations.

Selected references

  • N. Buchbinder, K. Jain, J. Naor, Online Primal-Dual Algorithms for Maximizing Ad-Auctions Revenue, Algorithms – ESA 2007, LNCS 4698, 2007. https://doi.org/10.1007/978-3-540-75520-3_24
  • A. Mehta, A. Saberi, U. Vazirani, V. Vazirani, AdWords and Generalized Online Matching, Journal of the ACM 54(5), 2007. https://doi.org/10.1145/1284320.1284321
  • R. M. Karp, U. V. Vazirani, V. V. Vazirani, An Optimal Algorithm for On-line Bipartite Matching, STOC 1990. https://doi.org/10.1145/100216.100262
  • B. Kalyanasundaram, K. R. Pruhs, An Optimal Deterministic Algorithm for Online b-Matching, Theoretical Computer Science 233(1–2), 2000. https://doi.org/10.1016/S0304-3975(99)00140-1
  • N. Buchbinder, J. Naor, The Design of Competitive Online Algorithms via a Primal-Dual Approach, Foundations and Trends in Theoretical Computer Science 3(2–3), 2009. https://doi.org/10.1561/0400000024
10 thms3 active usersReviewed
🏆Completed
Number TheoryProbabilityQuantum Information·Captain: mikedeng1

Polynomial-Time Algorithms for Prime Factorization and Discrete Logarithms on a Quantum Computer 3: The Success Probability of Quantum Order FindingResearch Paper

Motivation

The security of the RSA cryptosystem rests on the assumed difficulty of factoring large integers, and the best known classical algorithms for factoring run in super-polynomial time. In 1994 Peter Shor showed that a quantum computer can factor an nnn-digit integer in time polynomial in nnn (Shor, SIAM J. Comput. 1997; conference version FOCS 1994). The algorithm has two parts. A classical reduction, due to Miller (1976), turns factoring into order finding: given xxx coprime to nnn, find the least r≥1r \ge 1r≥1 with xr≡1(modn)x^r \equiv 1 \pmod nxr≡1(modn). The quantum part solves order finding.

This mission formalizes the quantum part as Shor analyzes it in §5 of the journal paper: the construction of the quantum state, the probability of each measurement outcome, and the classical post-processing that reads rrr off the measured value. The paper's claim is that one run of this procedure returns rrr with probability at least φ(r)/3r\varphi(r)/3rφ(r)/3r.

Timeline:

  • 1976: Miller reduces factoring to order finding (with randomization).
  • 1985–1994: Deutsch, Bernstein–Vazirani and Simon give the quantum Fourier sampling ideas the algorithm builds on.
  • 1994: Shor's FOCS paper introduces the factoring and discrete logarithm algorithms.
  • 1997: the SIAM J. Comput. version gives the analysis formalized here, with qqq the power of 222 in [n2,2n2)[n^2, 2n^2)[n2,2n2).

Setting

Fix an integer n≥2n \ge 2n≥2 and an integer xxx coprime to nnn. Its order rrr is the least r≥1r \ge 1r≥1 with xr≡1(modn)x^r \equiv 1 \pmod nxr≡1(modn); since xxx is a unit, r≤φ(n)<nr \le \varphi(n) < nr≤φ(n)<n. Let q=2lq = 2^lq=2l be the power of 222 with n2≤q<2n2n^2 \le q < 2n^2n2≤q<2n2.

A quantum state on two registers, the first holding 0≤a<q0 \le a < q0≤a<q and the second a residue y∈Z/ny \in \mathbb{Z}/ny∈Z/n, is a complex vector ψ(a,y)\psi(a, y)ψ(a,y) indexed by the basis states ∣a,y⟩|a, y\rangle∣a,y⟩. Measuring it returns ∣a,y⟩|a, y\rangle∣a,y⟩ with probability ∣ψ(a,y)∣2|\psi(a, y)|^2∣ψ(a,y)∣2.

The Fourier matrix AqA_qAq​ is the q×qq \times qq×q matrix with entries (Aq)a,c=q−1/2exp⁡(2πiac/q)(A_q)_{a,c} = q^{-1/2}\exp(2\pi i a c/q)(Aq​)a,c​=q−1/2exp(2πiac/q), with rows indexing inputs and columns outputs. The algorithm

  1. prepares 1q1/2∑a=0q−1∣a⟩∣xa mod n⟩\frac{1}{q^{1/2}}\sum_{a=0}^{q-1}|a\rangle|x^a \bmod n\rangleq1/21​∑a=0q−1​∣a⟩∣xamodn⟩ (eq. (5.2)),
  2. applies AqA_qAq​ to the first register, obtaining 1q∑a,cexp⁡(2πiac/q)∣c⟩∣xa mod n⟩\frac1q\sum_{a,c}\exp(2\pi iac/q)|c\rangle|x^a \bmod n\rangleq1​∑a,c​exp(2πiac/q)∣c⟩∣xamodn⟩ (eq. (5.4)),
  3. measures, obtaining some ∣c,y⟩|c, y\rangle∣c,y⟩,
  4. rounds c/qc/qc/q to the nearest fraction with denominator smaller than nnn.

The observed ccc gives us rrr if some fraction with lowest-terms denominator below nnn is within 1/2q1/2q1/2q of c/qc/qc/q, and every such fraction has lowest-terms denominator exactly rrr. In the Lean development these objects are preFourierState, finalState, outcomeProb and yieldsOrder, in the namespace ShorAlgorithms.OrderFinding, and the shared definition ShorAlgorithms.Shared.fourierMatrix.

Formalization targets

Goal: success probability at least φ(r)/3r\varphi(r)/3rφ(r)/3r

For all sufficiently large nnn, with xxx, rrr and qqq as above,

Pr⁡[the observed c gives us r]  =  ∑c gives r ∑y∈Z/n∣Ψ(c,y)∣2  ≥  φ(r)3r,\Pr\bigl[\text{the observed } c \text{ gives us } r\bigr] \;=\; \sum_{c\ \text{gives}\ r}\ \sum_{y \in \mathbb{Z}/n} |\Psi(c, y)|^2 \;\ge\; \frac{\varphi(r)}{3r},Pr[the observed c gives us r]=c gives r∑​ y∈Z/n∑​∣Ψ(c,y)∣2≥3rφ(r)​,

where Ψ\PsiΨ is the state (5.4). The threshold on nnn is uniform in xxx and qqq; it is the paper's "for sufficiently large nnn" from the per-state bound.

Milestones

  1. Eqs. (5.5)–(5.6). For 0≤k<r0 \le k < r0≤k<r, the probability of ∣c,xk⟩|c, x^k\rangle∣c,xk⟩ equals ∣1q∑b=0⌊(q−k−1)/r⌋exp⁡(2πi(br+k)c/q)∣2\left|\frac1q\sum_{b=0}^{\lfloor (q-k-1)/r\rfloor}\exp(2\pi i(br+k)c/q)\right|^2​q1​∑b=0⌊(q−k−1)/r⌋​exp(2πi(br+k)c/q)​2.
  2. Eq. (5.11). For nnn past a threshold, every ∣c,xk⟩|c, x^k\rangle∣c,xk⟩ with −r/2≤rc−dq≤r/2-r/2 \le rc - dq \le r/2−r/2≤rc−dq≤r/2 for some integer ddd has probability at least 1/3r21/3r^21/3r2.
  3. Eq. (5.13). If n2≤qn^2 \le qn2≤q, at most one fraction with denominator below nnn lies within 1/2q1/2q1/2q of c/qc/qc/q.
  4. p. 1500. Such a fraction is a convergent of the continued fraction of c/qc/qc/q.
  5. p. 1501. At least φ(r)\varphi(r)φ(r) values of ccc are within 1/2q1/2q1/2q of some d/rd/rd/r with gcd⁡(d,r)=1\gcd(d, r) = 1gcd(d,r)=1; with the rrr distinct values of xkx^kxk this gives at least rφ(r)r\varphi(r)rφ(r) states ∣c,xk⟩|c, x^k\rangle∣c,xk⟩, and each such ccc gives us rrr.

Significance

The goal is the quantitative statement behind "order finding is in bounded-error quantum polynomial time": since φ(r)/r≥δ/log⁡log⁡r\varphi(r)/r \ge \delta/\log\log rφ(r)/r≥δ/loglogr for a constant δ\deltaδ (Hardy and Wright, Thm. 328), O(log⁡log⁡r)O(\log\log r)O(loglogr) repetitions find rrr with high probability, and Miller's reduction then factors nnn. Without the bound, the algorithm is a procedure with no guarantee.

The result is proved, in the paper and in textbooks (Nielsen and Chuang, 2000, §5.3), usually with a phase-estimation analysis rather than Shor's direct count. What this mission adds is a machine-checked proof of Shor's own argument, with his choice of qqq and his constants, starting from the state built by applying AqA_qAq​ to (5.2). Formal proofs of idealized versions exist elsewhere, for instance in the exact-period model where rrr divides qqq and the output is uniform on rrr peaks, but that model removes the approximation that the 1/3r21/3r^21/3r2 bound is about. Legendre's theorem on continued fractions is already on the platform (FamousTheorems.legendre_continued_fraction_theorem) and is included as a reference item.

Difficulty

The obvious route is to compute the output distribution in closed form. That works only when rrr divides qqq; here qqq is a power of 222 and rrr is arbitrary, so the amplitudes are geometric sums of ⌊(q−k−1)/r⌋+1\lfloor (q-k-1)/r\rfloor + 1⌊(q−k−1)/r⌋+1 terms whose phases do not cancel exactly. The per-state bound 1/3r21/3r^21/3r2 requires a lower bound on such a sum that is uniform in rrr, ccc and kkk, with error terms of order 1/q1/q1/q controlled against a main term of order 1/r21/r^21/r2. The constant 1/31/31/3 leaves only a small margin below the limiting value 4/π2≈0.4054/\pi^2 \approx 0.4054/π2≈0.405, so the errors must be bounded explicitly, not merely shown to vanish.

The second difficulty is the counting: distinct coprime numerators ddd must give distinct outcomes ccc in [0,q)[0, q)[0,q), and each good ccc must determine rrr uniquely, which uses r<nr < nr<n and n2≤qn^2 \le qn2≤q.

Formalization scope

Conventions the statements commit to:

  • States are functions Fin q × ZMod n → ℂ; the matrix convention is row = input, so applying AqA_qAq​ to the first register gives the amplitude ∑aψ(a,y)(Aq)a,c\sum_a \psi(a, y)(A_q)_{a,c}∑a​ψ(a,y)(Aq​)a,c​ at (c,y)(c, y)(c,y).
  • The final state is built by applying AqA_qAq​ to the state (5.2); the closed forms (5.5) and (5.6) are theorems, not definitions. No normalization hypothesis is assumed.
  • Probabilities are squared moduli; the probability of the event "ccc gives us rrr" sums over all y∈Z/ny \in \mathbb{Z}/ny∈Z/n, which is exact because yyy that are not powers of xxx have probability zero.
  • xxx is a natural number with gcd⁡(x,n)=1\gcd(x, n) = 1gcd(x,n)=1; rrr is orderOf (x : ZMod n). qqq enters through the three hypotheses q=2lq = 2^lq=2l, n2≤qn^2 \le qn2≤q, q<2n2q < 2n^2q<2n2, not through a function of nnn.
  • Fractions are rationals, and "in lowest terms" is Rat.den.
  • Thresholds "for sufficiently large nnn" are ∃N, ∀n≥N\exists N,\ \forall n \ge N∃N, ∀n≥N, with NNN quantified before xxx, qqq, ccc and kkk.
  • Condition (5.11) is stated in its equivalent form (5.12), with an integer ddd.
  • Printed slip. Eq. (5.13)'s justification says "Because q>n2q > n^2q>n2", but qqq was chosen with n2≤qn^2 \le qn2≤q, and q=n2q = n^2q=n2 when nnn is a power of 222. The uniqueness claim holds under n2≤qn^2 \le qn2≤q, and that is what is stated.

Typing the closed form (5.4)–(5.6) in as the definition of the final state would make milestone 1 trivial and hide whether the probability model is the paper's; the definitions exclude this by construction.

Not stated: the polynomial running time of any step, the O(log⁡log⁡r)O(\log\log r)O(loglogr) repetition count (no explicit constant), the reversible modular exponentiation of §3, and the post-processing heuristics on p. 1501. Needed infrastructure: bounds on geometric exponential sums, Euler's totient, Diophantine approximation by fractions with bounded denominator, and Mathlib's continued fractions. Lemmas on geometric sums of roots of unity and on the order of units mod nnn are reusable in the companion discrete logarithm mission.

Selected references

  • P. W. Shor, Polynomial-Time Algorithms for Prime Factorization and Discrete Logarithms on a Quantum Computer, SIAM J. Comput. 26(5):1484–1509, 1997. https://doi.org/10.1137/S0097539795293172
  • P. W. Shor, Algorithms for quantum computation: discrete logarithms and factoring, Proc. 35th FOCS, 1994. https://doi.org/10.1109/SFCS.1994.365700
  • G. L. Miller, Riemann's hypothesis and tests for primality, J. Comput. System Sci. 13(3):300–317, 1976. https://doi.org/10.1016/S0022-0000(76)80043-8
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford, 1979 (Ch. X, continued fractions; Thm. 328).
  • M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, Cambridge, 2000. https://doi.org/10.1017/CBO9780511976667
12 thms3 active usersReviewed
🏆Completed
CombinatoricsComplexity TheoryOperations Research+2·Captain: mikedeng1

Maximizing Non-Monotone Submodular Functions V: Beating 1/2 for Symmetric Functions Requires Exponentially Many Value QueriesResearch Paper

Motivation

Maximizing a nonnegative submodular set function without constraints contains Max Cut, Max Directed Cut and facility-location problems as special cases. In the value-oracle model an algorithm knows nothing about the function except the values f(S)f(S)f(S) of the sets SSS it queries, and it is judged by the number of queries it makes. Feige, Mirrokni and Vondrák (SIAM J. Comput. 40(4), 2011) gave constant-factor algorithms in this model and matching limits on what any algorithm can do. For symmetric functions, such as cut functions of undirected graphs, a uniformly random set already achieves 12\tfrac1221​ of the optimum in expectation (Theorem 2.1 of the paper). The question this mission formalizes is whether any algorithm can do better, and the answer given by Theorem 4.5 is: not without exponentially many value queries. The same factor 12\tfrac1221​ was later shown to be achievable for general (non-symmetric) nonnegative submodular functions by Buchbinder, Feldman, Naor and Schwartz (FOCS 2012 / SIAM J. Comput. 2015), so the bound of Theorem 4.5 is the tight limit of the whole problem in the value-oracle model.

Timeline:

  • 2007 (FOCS) / 2011 (SIAM J. Comput.): Feige, Mirrokni and Vondrák prove that no algorithm with subexponentially many value queries achieves (12+ϵ)(\tfrac12 + \epsilon)(21​+ϵ) of the optimum on symmetric nonnegative submodular functions, and give 25\tfrac2552​ for general functions.
  • 2011: Vondrák's symmetry-gap framework (SIAM J. Comput. 42(1), 2013) generalizes the construction to constrained problems.
  • 2012: Buchbinder, Feldman, Naor and Schwartz give a randomized 12\tfrac1221​-approximation for general nonnegative submodular functions, matching the bound.

Setting

Let [n]={0,…,n−1}[n] = \{0, \dots, n-1\}[n]={0,…,n−1} be the ground set, with nnn even. A set function f:2[n]→Rf : 2^{[n]} \to \mathbb{R}f:2[n]→R is submodular if f(S∪T)+f(S∩T)≤f(S)+f(T)f(S \cup T) + f(S \cap T) \le f(S) + f(T)f(S∪T)+f(S∩T)≤f(S)+f(T) for all S,TS, TS,T, symmetric if f([n]∖S)=f(S)f([n]\setminus S) = f(S)f([n]∖S)=f(S) for all SSS, and OPT(f)=max⁡Sf(S)\mathrm{OPT}(f) = \max_{S} f(S)OPT(f)=maxS​f(S).

Fix an integer mmm with 1≤m≤n/21 \le m \le n/21≤m≤n/2 and write ϵ=m/n\epsilon = m/nϵ=m/n, so that ϵn\epsilon nϵn is an integer. For integers k,ℓk, \ellk,ℓ put

f(k,ℓ)={(k+ℓ)(n−k−ℓ)∣k−ℓ∣≤m,k(n−2ℓ)+(n−2k)ℓ+m2−2m∣k−ℓ∣∣k−ℓ∣>m.f(k,\ell) = \begin{cases} (k+\ell)(n-k-\ell) & |k-\ell| \le m,\\ k(n-2\ell) + (n-2k)\ell + m^2 - 2m|k-\ell| & |k-\ell| > m. \end{cases}f(k,ℓ)={(k+ℓ)(n−k−ℓ)k(n−2ℓ)+(n−2k)ℓ+m2−2m∣k−ℓ∣​∣k−ℓ∣≤m,∣k−ℓ∣>m.​

For a set C⊆[n]C \subseteq [n]C⊆[n] with ∣C∣=n/2|C| = n/2∣C∣=n/2 and D=[n]∖CD = [n] \setminus CD=[n]∖C, the hard instance is fC(S)=f(∣S∩C∣,∣S∩D∣)f_C(S) = f(|S\cap C|, |S\cap D|)fC​(S)=f(∣S∩C∣,∣S∩D∣). The cut function of the complete graph is g(S)=∣S∣(n−∣S∣)g(S) = |S|(n-|S|)g(S)=∣S∣(n−∣S∣), with maximum 14n2\tfrac14 n^241​n2. A set QQQ is balanced for CCC if ∣∣Q∩C∣−∣Q∩D∣∣≤m\bigl||Q\cap C| - |Q\cap D|\bigr| \le m​∣Q∩C∣−∣Q∩D∣​≤m; on balanced sets fC=gf_C = gfC​=g.

A deterministic adaptive qqq-query algorithm AAA chooses each query from the answers received so far, and after qqq answers outputs a set A(h)A(h)A(h) when run against an oracle hhh. A randomized algorithm is a distribution μ\muμ over deterministic ones, with expected value EA∼μ[h(A(h))]\mathbb{E}_{A\sim\mu}[h(A(h))]EA∼μ​[h(A(h))].

Formalization targets

Goal: Theorem 4.5 with the constants of its proof

For every such n,mn, mn,m:

  1. every fCf_CfC​ with ∣C∣=n/2|C| = n/2∣C∣=n/2 is nonnegative, symmetric and submodular, with
OPT(fC)=12n2(1−2ϵ+2ϵ2);\mathrm{OPT}(f_C) = \tfrac12 n^2 (1 - 2\epsilon + 2\epsilon^2);OPT(fC​)=21​n2(1−2ϵ+2ϵ2);
  1. for every q<eϵ2n/8q < e^{\epsilon^2 n/8}q<eϵ2n/8 and every randomized qqq-query algorithm μ\muμ there is a CCC with ∣C∣=n/2|C| = n/2∣C∣=n/2 and
EA∼μ[fC(A(fC))]≤14n2+(2e−ϵ2n/8+2e−ϵ2n/4) OPT(fC).\mathbb{E}_{A\sim\mu}\bigl[f_C(A(f_C))\bigr] \le \tfrac14 n^2 + \bigl(2e^{-\epsilon^2 n/8} + 2e^{-\epsilon^2 n/4}\bigr)\,\mathrm{OPT}(f_C).EA∼μ​[fC​(A(fC​))]≤41​n2+(2e−ϵ2n/8+2e−ϵ2n/4)OPT(fC​).

Hence the ratio attained is at most 12(1−2ϵ+2ϵ2)+4e−ϵ2n/8=12+ϵ+O(ϵ2)+4e−ϵ2n/8\frac{1}{2(1-2\epsilon+2\epsilon^2)} + 4e^{-\epsilon^2 n/8} = \tfrac12 + \epsilon + O(\epsilon^2) + 4e^{-\epsilon^2 n/8}2(1−2ϵ+2ϵ2)1​+4e−ϵ2n/8=21​+ϵ+O(ϵ2)+4e−ϵ2n/8.

Milestones

  • Theorem 1.2, the Chernoff bound for independent variables in [−1,1][-1,1][−1,1].
  • Submodularity of fCf_CfC​.
  • The value OPT(fC)=12n2(1−2ϵ+2ϵ2)\mathrm{OPT}(f_C) = \tfrac12 n^2(1 - 2\epsilon + 2\epsilon^2)OPT(fC​)=21​n2(1−2ϵ+2ϵ2), attained at S=CS = CS=C.
  • A fixed query is unbalanced for at most a 2e−ϵ2n/42e^{-\epsilon^2 n/4}2e−ϵ2n/4 fraction of the half-size sets CCC.
  • If all queries are balanced, the algorithm cannot distinguish fCf_CfC​ from ggg.
  • The deterministic case of the bound, averaged over CCC.

Significance

The theorem shows that the factor 12\tfrac1221​ for symmetric submodular maximization, and hence for unconstrained submodular maximization in general, cannot be improved by any algorithm that uses a subexponential number of value queries, whatever its running time. It is an information-theoretic bound and needs no complexity assumption. Along with the later matching 12\tfrac1221​-approximation, it settles the value-oracle approximability of the problem. The construction, a function equal to a symmetric function on "balanced" sets and larger elsewhere, is the prototype of the symmetry-gap technique used for many later oracle lower bounds.

The result is proved in the paper. No machine-checked version is known to exist: the platform has no value-oracle or query-lower-bound statement. Formalizing it requires a precise model of adaptive randomized query algorithms, a concentration bound for the hypergeometric distribution, and a finite verification of submodularity of an explicit two-regime function, and it fixes the constants that the printed statement leaves as O(⋅)O(\cdot)O(⋅) terms.

Difficulty

Two steps of the printed argument do not go through as written. First, the proof bounds the probability that a fixed query is unbalanced by citing the Chernoff bound for independent variables, but for a uniformly random half-size set CCC the count ∣Q∩C∣|Q\cap C|∣Q∩C∣ is hypergeometric, and the summands are not independent. A bound for sampling without replacement is needed instead. Replacing the balanced partition by independent coin flips is not an option: then ∣C∣≠n/2|C| \ne n/2∣C∣=n/2 in general, and the function is no longer the paper's instance.

Second, the argument counts only the queries, but the value an algorithm receives is fCf_CfC​ of its output, which equals ggg of the output only if the output is balanced as well. That event has to be controlled too.

Finally, submodularity of fCf_CfC​ must be checked across the boundary ∣k−ℓ∣=ϵn|k-\ell| = \epsilon n∣k−ℓ∣=ϵn between the two regimes, where the formula changes.

Formalization scope

  • The ground set is Fin n with nnn even; ϵn\epsilon nϵn is an integer mmm with 1≤m1 \le m1≤m and 2m≤n2m \le n2m≤n, following the paper's "assume that ϵn\epsilon nϵn is an integer". Sets are Finset (Fin n), and all values are real.
  • OPT\mathrm{OPT}OPT is Finset.sup' over all subsets. There is no junk value.
  • The partition (C,D)(C, D)(C,D) is uniform over half-size sets; probabilities over it are counts of n/2-subsets divided by (nn/2)\binom{n}{n/2}(n/2n​), written multiplied out.
  • A deterministic algorithm is a pair of decision rules query, output : List ℝ → Finset (Fin n) making exactly qqq adaptive queries with arbitrary real answers. A randomized algorithm is a PMF over deterministic algorithms, which covers every randomization with countable support. The algorithm sees fff only through query answers; it never receives CCC.
  • Pinned-down constants. The printed theorem, "fewer than eϵ2n/8e^{\epsilon^2 n/8}eϵ2n/8 queries" and "expected value at least (12+ϵ)OPT(\tfrac12+\epsilon)\mathrm{OPT}(21​+ϵ)OPT", is not what the proof gives for one and the same ϵ\epsilonϵ. On the proof's instances OPT=12n2(1−2ϵ+2ϵ2)\mathrm{OPT} = \tfrac12 n^2(1-2\epsilon+2\epsilon^2)OPT=21​n2(1−2ϵ+2ϵ2), and the ratio held is 12(1−2ϵ+2ϵ2)>12+ϵ\frac{1}{2(1-2\epsilon+2\epsilon^2)} > \tfrac12 + \epsilon2(1−2ϵ+2ϵ2)1​>21​+ϵ. The formal goal states the explicit bound the proof establishes. The literal printed pair, stated for the proof's family with the same ϵ\epsilonϵ, is false: the zero-query algorithm that outputs a fixed half-size set gets at least 14n2>(12+ϵ)OPT\tfrac14 n^2 > (\tfrac12+\epsilon)\mathrm{OPT}41​n2>(21​+ϵ)OPT.
  • Added term. The error term 2e−ϵ2n/42e^{-\epsilon^2 n/4}2e−ϵ2n/4 for the output set is added to the paper's 2e−ϵ2n/82e^{-\epsilon^2 n/8}2e−ϵ2n/8.
  • Ruled-out trivializations. A restricted algorithm class (non-adaptive, deterministic, or one that must return a queried set) would give a different, weaker theorem. So would a bound that lets the algorithm read CCC, which would make the statement false. Both the instance's properties (nonnegativity, symmetry, submodularity, the value of OPT) and the bound are part of the goal, so an empty or degenerate family cannot satisfy it. The quantifier order is: for every algorithm there is an instance.
  • Needed infrastructure: a value-oracle algorithm model; tail bounds for the hypergeometric distribution (Hoeffding's inequality for sampling without replacement), which Mathlib lacks; averaging over a PMF of algorithms. The algorithm model and the hypergeometric bound are reusable for other oracle lower bounds. Proofs of any milestone, and alternative derivations of the balance bound, are welcome.

Selected references

  • U. Feige, V. S. Mirrokni, J. Vondrák, Maximizing Non-Monotone Submodular Functions, SIAM J. Comput. 40(4):1133–1153, 2011. https://doi.org/10.1137/090779346
  • N. Alon, J. H. Spencer, The Probabilistic Method, Wiley (source of Theorem 1.2).
  • W. Hoeffding, Probability Inequalities for Sums of Bounded Random Variables, J. Amer. Statist. Assoc. 58(301):13–30, 1963. https://doi.org/10.1080/01621459.1963.10500830
  • J. Vondrák, Symmetry and Approximability of Submodular Maximization Problems, SIAM J. Comput. 42(1):265–304, 2013. https://doi.org/10.1137/110832318
  • N. Buchbinder, M. Feldman, J. Naor, R. Schwartz, A Tight Linear Time (1/2)-Approximation for Unconstrained Submodular Maximization, SIAM J. Comput. 44(5):1384–1402, 2015. https://doi.org/10.1137/130929205
12 thms3 active usersReviewed
🏆Completed
CombinatoricsOperations ResearchOptimization+1·Captain: mikedeng1

Maximizing Non-Monotone Submodular Functions IV: Smooth Local Search Achieves 2/5 of the OptimumResearch Paper

Motivation

Many optimization problems ask for a subset of a finite ground set that maximizes a submodular function, a set function with diminishing marginal returns. Max Cut and Max Directed Cut in graphs, facility location with fixed costs, and the maximization of mutual information or entropy of a subset of random variables are all of this form. Unlike the monotone case, where a greedy algorithm achieves 1−1/e1 - 1/e1−1/e, a general nonnegative submodular function may decrease when elements are added, and the empty set and the full set can both be poor. The question is how large a constant fraction of the optimum a polynomial-time algorithm can guarantee when the function is given only through an oracle that returns f(S)f(S)f(S) for a queried set SSS.

Feige, Mirrokni and Vondrák (SIAM J. Comput. 40(4), 2011) gave the first constant-factor algorithms for this problem. A uniformly random set achieves 1/41/41/4 of the optimum, a deterministic local search achieves 1/3−ϵ/n1/3 - \epsilon/n1/3−ϵ/n, and a randomized smooth local search achieves 2/5−o(1)2/5 - o(1)2/5−o(1). The last result is the paper's best approximation for general nonnegative submodular functions (Table 1, p. 1136), and it is the subject of this mission.

Timeline. Feige, Mirrokni and Vondrák: 1/41/41/4, 1/31/31/3 and 2/52/52/5 (FOCS 2007; journal version 2011). Gharan and Vondrák (SODA 2011): about 0.410.410.41 by simulated annealing. Buchbinder, Feldman, Naor and Schwartz (FOCS 2012; SIAM J. Comput. 2015): a randomized double greedy algorithm achieving 1/21/21/2, which matches the 1/21/21/2 hardness in the value oracle model proved in the same paper by Feige, Mirrokni and Vondrák.

Setting

Let XXX be a finite ground set with n=∣X∣≥1n = |X| \ge 1n=∣X∣≥1 elements and f:2X→Rf : 2^X \to \mathbb{R}f:2X→R a function with f(S)≥0f(S) \ge 0f(S)≥0 for all SSS and

f(S∪T)+f(S∩T)≤f(S)+f(T)(S,T⊆X).f(S \cup T) + f(S \cap T) \le f(S) + f(T) \quad (S, T \subseteq X).f(S∪T)+f(S∩T)≤f(S)+f(T)(S,T⊆X).

Write OPT=max⁡S⊆Xf(S)OPT = \max_{S \subseteq X} f(S)OPT=maxS⊆X​f(S). The multilinear extension of fff is

F(x)=∑S⊆Xf(S)∏i∈Sxi∏j∉S(1−xj),F(x) = \sum_{S \subseteq X} f(S) \prod_{i \in S} x_i \prod_{j \notin S} (1 - x_j),F(x)=S⊆X∑​f(S)i∈S∏​xi​j∈/S∏​(1−xj​),

the expected value of fff on a random set containing each iii independently with probability xix_ixi​.

For A⊆XA \subseteq XA⊆X and δ∈[−1,1]\delta \in [-1,1]δ∈[−1,1], the random set R(A,δ)\mathcal{R}(A,\delta)R(A,δ) is sampled with bias δ\deltaδ based on AAA: each element of AAA is included independently with probability p=(1+δ)/2p = (1+\delta)/2p=(1+δ)/2, each element of B=X∖AB = X \setminus AB=X∖A with probability q=(1−δ)/2q = (1-\delta)/2q=(1−δ)/2. The potential is Φ(A)=E[f(R(A,δ))]\Phi(A) = \mathbf{E}[f(\mathcal{R}(A,\delta))]Φ(A)=E[f(R(A,δ))] and the smoothed marginal value of xxx is

ωA,δ(x)=E[f(R(A,δ)∪{x})]−E[f(R(A,δ)∖{x})].\omega_{A,\delta}(x) = \mathbf{E}[f(\mathcal{R}(A,\delta) \cup \{x\})] - \mathbf{E}[f(\mathcal{R}(A,\delta) \setminus \{x\})].ωA,δ​(x)=E[f(R(A,δ)∪{x})]−E[f(R(A,δ)∖{x})].

Algorithm SLS starts from A=∅A = \emptysetA=∅. At each iteration it obtains estimates ω~A,δ(x)\tilde\omega_{A,\delta}(x)ω~A,δ​(x) within ±1n2OPT\pm\frac{1}{n^2}OPT±n21​OPT of ωA,δ(x)\omega_{A,\delta}(x)ωA,δ​(x). If some x∉Ax \notin Ax∈/A has ω~A,δ(x)>2n2OPT\tilde\omega_{A,\delta}(x) > \frac{2}{n^2}OPTω~A,δ​(x)>n22​OPT it adds xxx; otherwise, if some x∈Ax \in Ax∈A has ω~A,δ(x)<−2n2OPT\tilde\omega_{A,\delta}(x) < -\frac{2}{n^2}OPTω~A,δ​(x)<−n22​OPT it removes xxx; otherwise it stops and returns a random set R(A,δ′)\mathcal{R}(A, \delta')R(A,δ′).

Formalization targets

Goal: Theorem 3.6 in the explicit form of its proof

With δ=1/3\delta = 1/3δ=1/3, and δ′=1/3\delta' = 1/3δ′=1/3 with probability 0.90.90.9 or δ′=−1\delta' = -1δ′=−1 with probability 0.10.10.1: for every run from ∅\emptyset∅ whose estimates are all accurate and which has terminated at AAA,

910 E[f(R(A,13))]+110 f(X∖A)≥(25−95n)OPT,\tfrac{9}{10}\,\mathbf{E}[f(\mathcal{R}(A,\tfrac13))] + \tfrac{1}{10}\,f(X \setminus A) \ge \Big(\frac{2}{5} - \frac{9}{5n}\Big) OPT,109​E[f(R(A,31​))]+101​f(X∖A)≥(52​−5n9​)OPT,

and, for every δ∈(0,1]\delta \in (0,1]δ∈(0,1], every run of kkk iterations with accurate estimates has k<n2/δk < n^2/\deltak<n2/δ (fewer than 3n23n^23n2 for δ=1/3\delta = 1/3δ=1/3).

Milestones, in attack order

  • Lemma 2.2: E[g(A(p))]≥(1−p)g(∅)+p g(A)\mathbf{E}[g(A(p))] \ge (1-p)g(\emptyset) + p\,g(A)E[g(A(p))]≥(1−p)g(∅)+pg(A).
  • Display (∗): for three independently sampled sets, E[f(A1(p1)∪A2(p2)∪A3(p3))]≥∑I⊆{1,2,3}∏i∈Ipi∏i∉I(1−pi)f(⋃i∈IAi)\mathbf{E}[f(A_1(p_1) \cup A_2(p_2) \cup A_3(p_3))] \ge \sum_{I \subseteq \{1,2,3\}} \prod_{i\in I} p_i \prod_{i \notin I}(1-p_i) f(\bigcup_{i \in I} A_i)E[f(A1​(p1​)∪A2​(p2​)∪A3​(p3​))]≥∑I⊆{1,2,3}​∏i∈I​pi​∏i∈/I​(1−pi​)f(⋃i∈I​Ai​).
  • The increment identity Φ(A∪{x})−Φ(A)=δ ωA,δ(x)\Phi(A \cup \{x\}) - \Phi(A) = \delta\,\omega_{A,\delta}(x)Φ(A∪{x})−Φ(A)=δωA,δ​(x) for x∉Ax \notin Ax∈/A, and its removal counterpart.
  • 0≤Φ(A)≤OPT0 \le \Phi(A) \le OPT0≤Φ(A)≤OPT.
  • The terminal upper estimates E[f(R∪(B∩C))], E[f(R∩(B∪C))]≤E[f(R)]+2nOPT\mathbf{E}[f(R \cup (B\cap C))],\ \mathbf{E}[f(R \cap (B \cup C))] \le \mathbf{E}[f(R)] + \frac{2}{n}OPTE[f(R∪(B∩C))], E[f(R∩(B∪C))]≤E[f(R)]+n2​OPT.
  • The two lower bounds in 272727ths on the same two expectations.
  • The final chain E[f(R)]+19f(B)+2nOPT≥49OPT\mathbf{E}[f(R)] + \frac19 f(B) + \frac2n OPT \ge \frac49 OPTE[f(R)]+91​f(B)+n2​OPT≥94​OPT.

Significance

The 2/52/52/5 bound showed that local search on a smoothed objective, the multilinear extension restricted to points with two coordinate values, beats both uniform sampling and plain local search for non-monotone submodular maximization. The multilinear extension later became the standard tool for submodular maximization under constraints, through continuous greedy methods, contention resolution schemes and the analysis of randomized rounding. Display (∗) and Lemma 2.2 are the basic sampling inequalities for submodular functions and are reused throughout that literature.

The result is proved in the paper; it has been superseded in ratio by later algorithms reaching 1/21/21/2. To our knowledge none of it is machine-checked: Mathlib has no multilinear extension and no submodular maximization results. This mission produces a checked form of the analysis with every constant explicit: the o(1)o(1)o(1) as 95n\frac{9}{5n}5n9​, "polynomial time" as n2/δn^2/\deltan2/δ iterations, and the dependence on the accuracy of the sampled estimates as an explicit hypothesis.

Difficulty

The iteration bound and the increment identity are routine once the multilinear extension is set up. The substance lies in the lower bounds. The returned set RRR is random, so the comparison with the optimal set CCC cannot be made through a single local-optimality inequality as in deterministic local search; and approximate local optimality holds only for the smoothed marginals ωA,δ\omega_{A,\delta}ωA,δ​, which are averages over the random set, not for fff at any fixed set. Sampling inequalities such as (∗) are stated for independent samples of arbitrary, possibly overlapping sets, and their expectations are sums over products of subsets; the bookkeeping of such sums is the main formalization burden. The constants must also balance exactly: with δ=1/3\delta = 1/3δ=1/3 the 272727ths add up so that the 910/110\frac{9}{10}/\frac{1}{10}109​/101​ mixture yields 2/52/52/5. A different split or a different δ\deltaδ gives a different constant.

Formalization scope

The ground set is a Fintype X with decidable equality; sets are Finset X; fff is real valued, with nonnegativity and submodularity as hypotheses. The standing assumptions of the paper are made explicit: f≥0f \ge 0f≥0 (§3), value-oracle access (modelled by fff itself), n=∣X∣n = |X|n=∣X∣, and n≥1n \ge 1n≥1 (Nonempty X), so that 1n2\frac{1}{n^2}n21​ and 95n\frac{9}{5n}5n9​ are not Lean's junk value of division by zero. OPTOPTOPT is Finset.sup' over all subsets, which has no junk value. Every expectation over independently sampled sets is an exact finite sum: the multilinear extension for R(A,δ)\mathcal{R}(A,\delta)R(A,δ), and iterated sums over subsets for the several independent samples in Lemma 2.2 and (∗). Sampling probabilities carry 0≤p≤10 \le p \le 10≤p≤1.

The algorithm is a relation, not a choice: any element meeting the step-3 condition may be added, and removal is allowed only when no addition applies. The goal quantifies over every run from ∅\emptyset∅, every choice of accurate estimates, recomputed at every iteration, and every termination point. Accuracy is non-strict ("within ±\pm±"); the thresholds are strict. The thresholds and accuracy use OPTOPTOPT itself, as the proof does, although step 1 of the algorithm says an estimate of OPTOPTOPT is used. The sampling that produces the estimates and its "with high probability" are not modelled, and the goal is conditional on accurate estimates. The value of the δ′=−1\delta' = -1δ′=−1 branch is written as E[f(R(A,−1))]\mathbf{E}[f(\mathcal{R}(A,-1))]E[f(R(A,−1))], which equals f(X∖A)f(X \setminus A)f(X∖A).

A statement "every AAA satisfying the terminal conditions gives 2/5−9/(5n)2/5 - 9/(5n)2/5−9/(5n)" would be the final milestone plus arithmetic and is not the goal. The goal fixes the start at ∅\emptyset∅, the thresholds, the step order, the accuracy of every estimate, termination and the 0.9/0.10.9/0.10.9/0.1 mixture.

A complete development needs basic calculus of the multilinear extension: affinity in one coordinate, translation f(⋅∪D)f(\cdot \cup D)f(⋅∪D) and restriction f(⋅∩D)f(\cdot \cap D)f(⋅∩D), and splitting a sample into disjoint pieces. These lemmas are reusable for any work on submodular maximization, and contributions of them as separate theorems are welcome. The golden-ratio variant δ=δ′\delta = \delta'δ=δ′ (proof omitted in the paper), the tight example and the hardness results of §4 are out of scope.

Selected references

  • U. Feige, V. S. Mirrokni, J. Vondrák, Maximizing Non-Monotone Submodular Functions, SIAM J. Comput. 40(4):1133–1153, 2011. https://doi.org/10.1137/090779346
  • S. O. Gharan, J. Vondrák, Submodular Maximization by Simulated Annealing, SODA 2011. https://doi.org/10.1137/1.9781611973082.83
  • N. Buchbinder, M. Feldman, J. Naor, R. Schwartz, A Tight Linear Time (1/2)-Approximation for Unconstrained Submodular Maximization, SIAM J. Comput. 44(5):1384–1402, 2015. https://doi.org/10.1137/130929205
  • G. Calinescu, C. Chekuri, M. Pál, J. Vondrák, Maximizing a Monotone Submodular Function Subject to a Matroid Constraint, SIAM J. Comput. 40(6):1740–1766, 2011. https://doi.org/10.1137/080733991
14 thms3 active usersReviewed
🏆Completed
Combinatorics·Captain: mikedeng1

Three Partition Refinement Algorithms 1: Distinguishing-Prefix Refinement Finds Every Distinguishing Prefix Within m′ Refinement StepsResearch Paper

Motivation

Sorting a collection of strings in lexicographic order is a basic subroutine in compilers, string indexing, suffix sorting and the construction of tries. The classical method, due to Aho, Hopcroft and Ullman (The Design and Analysis of Computer Algorithms, 1974), is a multipass radix sort that processes the strings from the last position to the first and runs in time proportional to the total length mmm of the input plus the alphabet size kkk. Mehlhorn showed that a straightforward first-to-last scan of equal-length strings needs Ω(km)\Omega(km)Ω(km) time.

Paige and Tarjan (Three Partition Refinement Algorithms, SIAM J. Comput. 16(6):973–989, 1987, doi:10.1137/0216062) observed that most of the input is usually irrelevant to the sorted order: only the shortest prefix of each string that tells it apart from the others matters. Their algorithm separates the problem into two steps: (1) find this distinguishing prefix of every string, and (2) sort the distinguishing prefixes. The first step is carried out by partition refinement, the same technique that the paper then applies to the relational coarsest partition problem (the second mission of this series) and to double lexical ordering. This mission formalizes the correctness and the termination bound of the first step.

Setting

Fix k≥1k \ge 1k≥1 and the alphabet Σ={1,2,…,k}\Sigma = \{1, 2, \dots, k\}Σ={1,2,…,k}, together with an end marker 000 that is smaller than every symbol. A string is a finite sequence over Σ∪{0}\Sigma \cup \{0\}Σ∪{0}; λ\lambdaλ is the empty string, ∣x∣|x|∣x∣ is the length of xxx, and x(i)x(i)x(i) is its iii-th symbol (positions start at 111). A string α\alphaα is a prefix of yyy if y=αzy = \alpha zy=αz for some string zzz; every string is a prefix of itself. Σ∗0\Sigma^*0Σ∗0 is the set of strings over Σ\SigmaΣ followed by one 000.

The input is a multiset U={x1,…,xn}⊆Σ∗0U = \{x_1, \dots, x_n\} \subseteq \Sigma^*0U={x1​,…,xn​}⊆Σ∗0 with n≥1n \ge 1n≥1; repeated strings are allowed. The distinguishing prefix xi′x'_ixi′​ of xix_ixi​ in UUU is

  1. the shortest prefix of xix_ixi​ that is not a prefix of any other string of UUU, if xix_ixi​ occurs only once in UUU;
  2. xix_ixi​ itself, if xix_ixi​ occurs more than once.

Write m′=∑i=1n∣xi′∣m' = \sum_{i=1}^n |x'_i|m′=∑i=1n​∣xi′​∣.

For a string α\alphaα, the labeled block BαB_\alphaBα​ is the multiset of strings of UUU having α\alphaα as a prefix, and α\alphaα is its associated prefix. The block is finished if α=xi′\alpha = x'_iα=xi′​ for some iii, and unfinished otherwise. A state PPP is a set of labeled blocks. For an unfinished block Bα∈PB_\alpha \in PBα​∈P,

split(Bα,P)=(P∖{Bα})∪{ Bαu:u∈Σ∪{0}, ∃x∈Bα, x(∣α∣+1)=u }.\mathrm{split}(B_\alpha, P) = \bigl(P \setminus \{B_\alpha\}\bigr) \cup \{\, B_{\alpha u} : u \in \Sigma \cup \{0\},\ \exists x \in B_\alpha,\ x(|\alpha| + 1) = u \,\}.split(Bα​,P)=(P∖{Bα​})∪{Bαu​:u∈Σ∪{0}, ∃x∈Bα​, x(∣α∣+1)=u}.

The refinement algorithm starts from P0={Bλ}P_0 = \{B_\lambda\}P0​={Bλ​} and repeatedly applies the step Refine: pick any unfinished block Bα∈PB_\alpha \in PBα​∈P and replace PPP by split(Bα,P)\mathrm{split}(B_\alpha, P)split(Bα​,P). A run with KKK steps is a sequence P0,P1,…,PKP_0, P_1, \dots, P_KP0​,P1​,…,PK​ produced this way; any choice of unfinished block is allowed at every step.

Formalization targets

Goal: Theorem 1 with its explicit bound

For every run P0,…,PKP_0, \dots, P_KP0​,…,PK​ of the refinement algorithm,

K≤m′and(no block of PK is unfinished)  ⟹  PK={Bx1′,…,Bxn′}.K \le m' \qquad\text{and}\qquad \bigl(\text{no block of } P_K \text{ is unfinished}\bigr) \implies P_K = \{B_{x'_1}, \dots, B_{x'_n}\}.K≤m′and(no block of PK​ is unfinished)⟹PK​={Bx1′​​,…,Bxn′​​}.

The paper states Theorem 1 as "The algorithm terminates and is correct"; the bound K≤m′K \le m'K≤m′ is the explicit count proved in the last sentence of its proof (p. 975). The goal leaves the choice of unfinished block free, so it holds for every refinement order.

Milestones

  1. End markers (§2, p. 974). No string of UUU is a proper prefix of another string of UUU.
  2. Lemma 1 (p. 975). Along every run, every finished block BβB_\betaBβ​ is contained in a block of the current state, and there is Bα∈PjB_\alpha \in P_jBα​∈Pj​ with α\alphaα a prefix of β\betaβ.
  3. Proof of Theorem 1, second sentence. For every state of every run, ∑Bα∈Pj∣α∣≤m′\sum_{B_\alpha \in P_j} |\alpha| \le m'∑Bα​∈Pj​​∣α∣≤m′.
  4. Proof of Theorem 1, third sentence. Every Refine step strictly increases ∑Bα∈P∣α∣\sum_{B_\alpha \in P} |\alpha|∑Bα​∈P​∣α∣.

A supplementary item states the fact on p. 974 that motivates the two-step design: distinct strings have distinct distinguishing prefixes, and xi≤xjx_i \le x_jxi​≤xj​ iff xi′≤xj′x'_i \le x'_jxi′​≤xj′​ in lexicographic order.

Significance

Theorem 1 is the correctness half of the lexicographic sorting algorithm: once the distinguishing prefixes are known, sorting UUU reduces to sorting strings of total length m′m'm′, which is how the paper obtains its O(m′+k)O(m' + k)O(m′+k) time bound in place of O(m+k)O(m + k)O(m+k). The paper notes that under a natural probability model m′m'm′ is of order nlog⁡knn \log_k nnlogk​n, so the gain is large whenever the strings are long. The invariant of Lemma 1 is also the pattern on which the later partition refinement algorithms of the paper are built: a target partition is shown to refine every intermediate partition, and a potential function bounds the number of refinement steps.

The result has been proved since 1987. What this mission adds is a machine-checked account of the algorithm at the level of its abstract refinement steps, with the explicit bound m′m'm′ rather than an asymptotic statement, and with the standing assumptions of §2 (non-empty input, end markers) made explicit. No formal proof of this algorithm is present in Mathlib or on the platform.

Difficulty

The obvious argument, "each step makes the labels longer, and labels never grow past the distinguishing prefixes", needs two facts that are not immediate from the definitions. First, the labels of a reached state must form a partition of UUU into non-empty blocks whose labels are pairwise incomparable under the prefix order; this is an invariant of the algorithm, not part of the definition of a state, and it fails for arbitrary sets of labels. Second, the label of an unfinished block must be a proper prefix of every finished label below it, which rests on the end marker: without end markers a string can be a proper prefix of another, a block can be unfinished yet have no strictly longer children, and the algorithm can stall. Bounding the sum of label lengths by m′m'm′ is not a label-by-label comparison: a state can have fewer labels than strings, and the distinguishing prefixes of different strings can share a label as a common prefix.

Formalization scope

Strings are List (Fin (k + 1)), with 0 : Fin (k + 1) the end marker and prefix the Mathlib relation <+:. The multiset UUU is a family x : Fin n → List (Fin (k + 1)), so repetitions are distinct indices. The hypotheses 0 < n and EndMarked x (U⊆Σ∗0U \subseteq \Sigma^*0U⊆Σ∗0) are the paper's standing assumptions. A block is identified by its label, not by its set of members: two different labels can carry the same strings (for instance Bλ=B1B_\lambda = B_1Bλ​=B1​ when every string begins with 111), and they are different blocks. A state is a Finset of labels; a run is a map Fin (K + 1) → Finset (List (Fin (k + 1))) starting at {[]}. Positions are 1-based in the paper and 0-based in Lean, so x(∣α∣+1)x(|\alpha|+1)x(∣α∣+1) is (x i)[α.length]?. The distinguishing prefix follows the literal definition; for n=1n = 1n=1 it is the empty string.

The running times O(m′+k)O(m' + k)O(m′+k) and O(n+k)O(n + k)O(n+k) space, the implementation with a queue and a global index, and step two (sorting the prefixes via the refinement tree) are RAM-model statements and are not formalized. Only the explicit step count m′m'm′ is. A formalization in which split added all k+1k + 1k+1 children, added none, or allowed refining a finished block would change the theorem (the bound fails or the goal becomes vacuous); the definitions add exactly the children realized by some string of the block and refine only unfinished blocks.

Contributions welcome: proofs of the milestones, a general API for prefix-closed partition refinement on List, and a proof of the order-preservation item via Mathlib's List.Lex.

Selected references

  • R. Paige, R. E. Tarjan, Three Partition Refinement Algorithms, SIAM Journal on Computing 16(6):973–989, 1987. https://doi.org/10.1137/0216062
  • A. V. Aho, J. E. Hopcroft, J. D. Ullman, The Design and Analysis of Computer Algorithms, Addison-Wesley, 1974.
  • K. Mehlhorn, Data Structures and Algorithms 1: Sorting and Searching, Springer, 1984. https://doi.org/10.1007/978-3-642-69672-5
7 thms3 active usersReviewed
🏆Completed
CombinatoricsGraph TheoryOperations Research·Captain: mikedeng1

A Linear-Time Algorithm for Finding a Sparse k-Connected Spanning Subgraph of a k-Connected Graph 2: FOREST's Forests E_i Preserve Local Node-Connectivity up to i in a Simple GraphResearch Paper

Motivation

Given a kkk-connected graph, many connectivity algorithms run in time that grows with the number of edges ∣E∣|E|∣E∣. A sparse certificate is a spanning subgraph with only O(k∣V∣)O(k|V|)O(k∣V∣) edges that is still kkk-connected; computing one first and running the expensive algorithm on it replaces ∣E∣|E|∣E∣ by k∣V∣k|V|k∣V∣ in the bound. Finding a kkk-connected spanning subgraph with the minimum number of edges is NP-complete for every fixed k≥2k \ge 2k≥2 (Garey and Johnson, problem GT31), so the question is how cheaply a sparse, not necessarily minimum, certificate can be found.

Nagamochi and Ibaraki (Algorithmica 7 (1992) 583–596) answered this with a single linear-time scanning procedure, FOREST, which partitions the edges into classes E1,E2,…,E∣E∣E_1, E_2, \dots, E_{|E|}E1​,E2​,…,E∣E∣​. They showed that the prefix unions E1∪⋯∪EkE_1 \cup \dots \cup E_kE1​∪⋯∪Ek​ are certificates for edge-connectivity and, for simple graphs, for node-connectivity. The node-connectivity result is the subject of this mission; the edge-connectivity result is the preceding mission of this series.

Timeline:

  • 1980: Galil gives an algorithm testing κ(G)≥k\kappa(G) \ge kκ(G)≥k whose running time depends on ∣E∣|E|∣E∣ (SIAM J. Comput. 9).
  • Before 1992 (as cited on p. 583): Suzuki et al. give O(∣E∣)O(|E|)O(∣E∣)-time algorithms for sparse 2- and 3-node-connected spanning subgraphs; Nishizeki and Poljak find, for general kkk, a kkk-node-connected spanning subgraph with at most k(∣V∣−1)k(|V|-1)k(∣V∣−1) edges in O(∣V∣1/2∣E∣2)O(|V|^{1/2}|E|^2)O(∣V∣1/2∣E∣2) time.
  • 1992: Nagamochi and Ibaraki prove that FOREST, which runs in O(∣V∣+∣E∣)O(|V| + |E|)O(∣V∣+∣E∣) time, yields a kkk-node-connected spanning subgraph GkG_kGk​ of every simple kkk-node-connected graph, with ∣E(Gk)∣≤k∣V∣−k(k+1)/2|E(G_k)| \le k|V| - k(k+1)/2∣E(Gk​)∣≤k∣V∣−k(k+1)/2. Their Theorem 3.1 states a stronger, local form.
  • 1993: Cheriyan, Kao and Thurimella isolate "scan-first search" as the general principle behind such certificates (SIAM J. Comput. 22 (1993)).

Setting

A graph G=(V,E)G = (V, E)G=(V,E) has a finite node set VVV with ∣V∣≥2|V| \ge 2∣V∣≥2 and a finite edge set EEE; each edge has an unordered pair of two distinct end nodes. In this mission the graph is simple: no two edges have the same end nodes. For F⊆EF \subseteq EF⊆E, (V,F)(V, F)(V,F) is the spanning subgraph with edge set FFF.

The local node-connectivity κ(x,y;H)\kappa(x, y; H)κ(x,y;H) of nodes x,yx, yx,y in a graph HHH on VVV is ∣V∣−1|V| - 1∣V∣−1 if xxx and yyy are adjacent in HHH, and otherwise the minimum size of a node set W⊆V−{x,y}W \subseteq V - \{x, y\}W⊆V−{x,y} whose deletion leaves no xxx–yyy path. The node connectivity is κ(G)=min⁡x,yκ(x,y;G)\kappa(G) = \min_{x, y} \kappa(x, y; G)κ(G)=minx,y​κ(x,y;G).

Procedure FOREST keeps a label r(v)≥0r(v) \ge 0r(v)≥0 on each node, initially 000. While some node is unscanned, it chooses an unscanned node xxx of largest label; for each unscanned edge e=(x,y)e = (x, y)e=(x,y) it puts eee into the class Er(y)+1E_{r(y)+1}Er(y)+1​, increases r(x)r(x)r(x) by one if r(x)=r(y)r(x) = r(y)r(x)=r(y), and increases r(y)r(y)r(y) by one; then it marks xxx scanned. Ties are broken arbitrarily. The time instants are the states between these elementary operations; Ei∗E^*_iEi∗​ denotes the class iii at an instant, and EiE_iEi​ its final value. Put

Gi=(V, E1∪E2∪⋯∪Ei).G_i = (V,\ E_1 \cup E_2 \cup \dots \cup E_i).Gi​=(V, E1​∪E2​∪⋯∪Ei​).

Formalization targets

Goal: Theorem 3.1

For a simple graph GGG and the classes of any completed run of FOREST, for 1≤i≤∣E∣1 \le i \le |E|1≤i≤∣E∣,

κ(x,y;Gi) ≥ min⁡{κ(x,y;G), i}for any x,y∈V.(3.1)\kappa(x, y; G_i) \ \ge\ \min\{\kappa(x, y; G),\ i\} \qquad \text{for any } x, y \in V. \tag{3.1}κ(x,y;Gi​) ≥ min{κ(x,y;G), i}for any x,y∈V.(3.1)

The statement is local: it holds pair by pair, not only for the global minimum, and for every tie-breaking of the procedure.

Milestones, in the order the proof uses them

  1. Lemma 2.2: at every instant, a node vvv meets EiE_iEi​ exactly for i=1,…,r(v)i = 1, \dots, r(v)i=1,…,r(v).
  2. Lemma 2.4(b): at every instant, a uuu–vvv path in Ej∗E^*_jEj∗​ yields uuu–vvv paths in every Ei∗E^*_iEi∗​, i<ji < ji<j.
  3. In-degree at most one (§2, p. 588): orienting each edge from the earlier-scanned to the later-scanned end, every node has at most one entering arc in each class.
  4. Lemma 3.1: if an xxx–yyy path of Ej∗E^*_jEj∗​ has the form x,u1,…,uk=w,yx, u_1, \dots, u_k = w, yx,u1​,…,uk​=w,y with k=1k = 1k=1 or u1u_1u1​ scanned before www, then any www–xxx and www–yyy paths in Ei∗E^*_iEi∗​ (i<ji < ji<j) share a node other than www.
  5. Lemma 3.2: for a node cut set W={w1,…,wi}W = \{w_1, \dots, w_i\}W={w1​,…,wi​} of Gi+1G_{i+1}Gi+1​ (in scan order) separating a component XXX from the rest YYY, immediately after wtw_twt​ is scanned every XXX–YYY path of Et∗E^*_tEt∗​ passes through wtw_twt​, and Ej∗E^*_jEj∗​ has no XXX–YYY path for t+1≤j≤i+1t + 1 \le j \le i + 1t+1≤j≤i+1.

A companion item states the paper's announcement in §3: GkG_kGk​ is kkk-node-connected for every 1≤k≤κ(G)1 \le k \le \kappa(G)1≤k≤κ(G).

Significance

Theorem 3.1 at i=ki = ki=k shows that the first kkk classes of FOREST form a kkk-node-connected spanning subgraph whenever GGG is, and the edge-count analysis of the companion mission bounds its size by k∣V∣−k(k+1)/2k|V| - k(k+1)/2k∣V∣−k(k+1)/2. Since FOREST runs in linear time, any algorithm testing κ(G)≥k\kappa(G) \ge kκ(G)≥k can be run on GkG_kGk​ instead of GGG; the paper uses this to improve the bound for testing κ(G)≥k\kappa(G) \ge kκ(G)≥k from O(max⁡{k2∣V∣1/2,k∣V∣}∣E∣)O(\max\{k^2|V|^{1/2}, k|V|\}|E|)O(max{k2∣V∣1/2,k∣V∣}∣E∣) to O(max⁡{k3∣V∣3/2,k2∣V∣2})O(\max\{k^3|V|^{3/2}, k^2|V|^2\})O(max{k3∣V∣3/2,k2∣V∣2}), and similar gains for computing the number of node-disjoint paths between two nodes. The local form (3.1) is what makes the sss–ttt applications possible.

The result is proved on paper. As far as a search of the platform shows, neither FOREST nor local node-connectivity has a machine-checked treatment there; Mathlib has no notion of vertex connectivity of a pair of nodes. This mission produces a formal model of FOREST as a nondeterministic transition system and the statements needed to verify the paper's proof step by step.

Difficulty

For edge-connectivity the analogous statement follows from a general principle: any sequence of maximal spanning forests, each taken in what remains of the graph, preserves local edge-connectivity up to its length. The obvious attempt is to prove (3.1) the same way, from the fact that each EiE_iEi​ is a maximal spanning forest of what the earlier classes leave. The paper gives no such argument for node-connectivity: its proof uses the specific scan order of FOREST in an essential way, through the orientation of edges from earlier- to later-scanned nodes and the in-degree bound of that orientation (Lemmas 3.1 and 3.2). The argument tracks, for a hypothetical node cut WWW of size iii in Gi+1G_{i+1}Gi+1​, the classes at the moments the nodes of WWW are scanned, which requires reasoning about intermediate states of the algorithm and about paths in several classes at once. None of this reduces to a static property of the output partition.

Formalization scope

  • Graphs. A node type V and an edge type E, both finite, with ends : E → Sym2 V; loop-freeness is ∀ e, ¬ (ends e).IsDiag and simplicity is Function.Injective ends. The standing assumptions of p. 583 and p. 589 (∣V∣≥2|V| \ge 2∣V∣≥2, no self-loop, a simple graph when node-connectivity is discussed) appear as hypotheses; §2 items are stated for loopless graphs, as on the page.
  • Connectivity. κ(x,y;(V,F))\kappa(x, y; (V, F))κ(x,y;(V,F)) is valued in N∞\mathbb N_\inftyN∞​: ∣V∣−1|V| - 1∣V∣−1 on adjacent pairs, the minimum node cut otherwise, and ⊤\top⊤ when x=yx = yx=y, where (3.1) holds trivially.
  • FOREST. A nondeterministic step relation with three steps (select, scan, finish), a run of length KKK from the initial state, and completion when every node is scanned. Every tie-breaking is allowed, so the theorems quantify over all completed runs. A time instant is a state of a run; "scanned before" compares positions in the run's selection order; "immediately after wtw_twt​ has been scanned" is the state right after the finish step of wtw_twt​.
  • Excluded. The running time "O(∣V∣+∣E∣)O(|V| + |E|)O(∣V∣+∣E∣)" and everything in §4 (the connectivity-testing algorithms and their bounds) are not stated: the paper fixes no machine model. The edge bounds on ∣Ei∣|E_i|∣Ei​∣ belong to the edge-connectivity mission.
  • Ruled out. Stating (3.1) for an arbitrary partition into maximal spanning forests, or reading the classes Ej∗E^*_jEj∗​ of Lemmas 3.1–3.2 off the final state, would state a different theorem from the one the paper proves; the classes are those of a run of FOREST at the instant the page specifies.
  • Infrastructure. Reachability avoiding a node set, walks and paths in SimpleGraph, and invariants of the FOREST transition system. The definitions duplicate those of the edge-connectivity mission by design and are candidates for a shared layer. Contributions of general lemmas about the run (label invariants, monotonicity of classes along a run) are welcome.

Selected references

  • H. Nagamochi, T. Ibaraki, A linear-time algorithm for finding a sparse kkk-connected spanning subgraph of a kkk-connected graph, Algorithmica 7 (1992), 583–596. https://doi.org/10.1007/BF01758778
  • Z. Galil, Finding the vertex connectivity of graphs, SIAM J. Comput. 9 (1980), 197–199. https://doi.org/10.1137/0209016
  • J. Cheriyan, M.-Y. Kao, R. Thurimella, Scan-first search and sparse certificates: an improved parallel algorithm for kkk-vertex connectivity, SIAM J. Comput. 22 (1993), 157–174. https://doi.org/10.1137/0222013
  • M. R. Garey, D. S. Johnson, Computers and Intractability: A Guide to the Theory of NP-Completeness, Freeman, 1979.
9 thms3 active usersReviewed
🏆Completed
CombinatoricsGraph TheoryOperations Research·Captain: mikedeng1

A Linear-Time Algorithm for Finding a Sparse k-Connected Spanning Subgraph of a k-Connected Graph 1: The FOREST Decomposition Preserves Local Edge-ConnectivityResearch Paper

Motivation

Many graph algorithms for connectivity questions run in time proportional to the number of edges. When the question is only whether a graph is kkk-edge-connected, or what its local edge-connectivities are up to a threshold kkk, most edges are irrelevant: a spanning subgraph with O(k∣V∣)O(k|V|)O(k∣V∣) edges already carries the answer. Such a subgraph is called a sparse certificate. Computing one first and running the expensive algorithm on it replaces ∣E∣|E|∣E∣ by k∣V∣k|V|k∣V∣ in the running time of connectivity testing, of Matula-type edge-connectivity algorithms, and of sss–ttt flow computations used as connectivity oracles.

Nagamochi and Ibaraki (Algorithmica 7, 1992) gave a procedure, FOREST, that computes such a certificate for edge-connectivity and, on simple graphs, for node-connectivity, with a single graph search. The same partition of the edges into forests is the engine of their deterministic minimum-cut algorithm for multigraphs (SIAM J. Discrete Math. 5, 1992), which later became the maximum-adjacency ordering of the Stoer–Wagner minimum-cut algorithm (J. ACM 44, 1997).

Timeline:

  • 1927: Menger identifies the minimum number of edges separating two nodes with the maximum number of edge-disjoint paths between them.
  • 1992: Nagamochi and Ibaraki publish Procedure FOREST and prove that its iii-th prefix preserves local edge-connectivity up to iii in multigraphs, and local node-connectivity up to iii in simple graphs.
  • 1993: Cheriyan, Kao and Thurimella (SIAM J. Comput. 22) obtain sparse certificates by scan-first search; Frank, Ibaraki and Nagamochi (J. Graph Theory 17) give a shorter proof for the node-connectivity case.
  • 1994: Nishizeki and Poljak (Discrete Appl. Math. 55) publish the forest-decomposition lemma (Lemma 2.1 below), found independently.

Setting

A graph G=(V,E)G = (V, E)G=(V,E) is finite and undirected, has ∣V∣≥2|V| \ge 2∣V∣≥2 nodes, may have multiple edges (several edges with the same pair of end nodes), and has no self-loop. It is simple if no two edges have the same end nodes. For F⊆EF \subseteq EF⊆E, (V,F)(V, F)(V,F) is the spanning subgraph with edge set FFF. It is a forest if it has no cycle; two parallel edges form a cycle. It is a maximal spanning forest in (V,H)(V, H)(V,H), for F⊆HF \subseteq HF⊆H, if adding any edge of H∖FH \setminus FH∖F to FFF creates a cycle.

The local edge-connectivity λ(x,y;H)\lambda(x, y; H)λ(x,y;H) is the minimum number of edges of HHH whose removal leaves no path from xxx to yyy; parallel edges count separately. It is ∞\infty∞ when x=yx = yx=y.

Procedure FOREST keeps a label r(v)∈Nr(v) \in \mathbb{N}r(v)∈N on every node, initially 000, and classes E1,E2,…,E∣E∣E_1, E_2, \dots, E_{|E|}E1​,E2​,…,E∣E∣​, initially empty. While an unscanned node exists, it picks an unscanned node xxx of largest label; for every unscanned edge eee from xxx to a node yyy, it puts eee into Er(y)+1E_{r(y)+1}Er(y)+1​, increases r(x)r(x)r(x) by one if r(x)=r(y)r(x) = r(y)r(x)=r(y), increases r(y)r(y)r(y) by one, and marks eee scanned; then it marks xxx scanned. Ties among nodes and the order of edges are free. On termination, Gi=(V,E1∪⋯∪Ei)G_i = (V, E_1 \cup \cdots \cup E_i)Gi​=(V,E1​∪⋯∪Ei​).

Formalization targets

Goal: Theorem 2.1 (pp. 588–589), without the running time

For every graph GGG and every completed execution of FOREST on GGG:

  1. every edge lies in exactly one class EiE_iEi​, 1≤i≤∣E∣1 \le i \le |E|1≤i≤∣E∣;
  2. for i=1,…,∣E∣i = 1, \dots, |E|i=1,…,∣E∣,
λ(x,y;Gi)≥min⁡{λ(x,y;G), i}for all x,y∈V;(2.1)\lambda(x, y; G_i) \ge \min\{\lambda(x, y; G),\ i\} \qquad \text{for all } x, y \in V; \tag{2.1}λ(x,y;Gi​)≥min{λ(x,y;G), i}for all x,y∈V;(2.1)
  1. ∣Ei∣≤∣V∣−1|E_i| \le |V| - 1∣Ei​∣≤∣V∣−1 for all iii;
  2. if GGG is simple, ∣Ei∣≤∣V∣−i|E_i| \le |V| - i∣Ei​∣≤∣V∣−i for i≤∣V∣−1i \le |V| - 1i≤∣V∣−1 and Ei=∅E_i = \emptysetEi​=∅ for i≥∣V∣i \ge |V|i≥∣V∣.

Milestones

  • Lemma 2.2 (p. 587): during the execution, a node vvv has incident edges in exactly the classes E1,…,Er(v)E_1, \dots, E_{r(v)}E1​,…,Er(v)​.
  • Lemma 2.3 (p. 587): each (V,Ei)(V, E_i)(V,Ei​) is a forest at every instant.
  • Lemma 2.4 (p. 588): (a) an edge (u,v)(u, v)(u,v) added to EiE_iEi​ has its end nodes joined by a path in Ei−1E_{i-1}Ei−1​; (b) a path in EjE_jEj​ between uuu and vvv yields a path in every EiE_iEi​, i<ji < ji<j.
  • Lemma 2.5 (p. 588): each output (V,Ei)(V, E_i)(V,Ei​) is a maximal spanning forest in G−E1∪⋯∪Ei−1G - E_1 \cup \cdots \cup E_{i-1}G−E1​∪⋯∪Ei−1​.
  • Lemma 2.1 (p. 584): any sequence of successive maximal spanning forests satisfies (2.1).

Companions

  • the sparse certificate (p. 589): if λ(x,y;G)≥k\lambda(x, y; G) \ge kλ(x,y;G)≥k for all x,yx, yx,y, then GkG_kGk​ is kkk-edge-connected with ∣E(Gk)∣≤k(∣V∣−1)|E(G_k)| \le k(|V| - 1)∣E(Gk​)∣≤k(∣V∣−1), and ∣E(Gk)∣≤k∣V∣−k(k+1)/2|E(G_k)| \le k|V| - k(k+1)/2∣E(Gk​)∣≤k∣V∣−k(k+1)/2 for simple GGG;
  • Lemma 2.6 (p. 589): for k≤δ(G)k \le \delta(G)k≤δ(G), GkG_kGk​ has a node of degree exactly kkk.

Significance

(2.1) says that one search produces, for every threshold kkk at once, a subgraph with at most k(∣V∣−1)k(|V|-1)k(∣V∣−1) edges that keeps every local edge-connectivity up to kkk. Any algorithm whose running time grows with ∣E∣|E|∣E∣ can then be run on GkG_kGk​ in place of GGG; §4 of the paper uses this to speed up kkk-connectivity tests and the computation of local connectivities. The same forest partition is the structural fact behind the Nagamochi–Ibaraki and Stoer–Wagner minimum-cut algorithms. Lemma 2.6 shows that the certificate is tight: its edge-connectivity is exactly kkk when λ(G)≥k\lambda(G) \ge kλ(G)≥k.

The results are proved in the paper. No machine-checked proof of them is known. Formalizing them means formalizing a graph search with free tie-breaking as a transition system, reasoning about invariants of all its executions, and proving a cut-counting statement for multigraphs. Mathlib's connectivity notions, such as SimpleGraph.IsEdgeReachable, do not see parallel edges, so the multigraph cut theory here is new.

Difficulty

Lemma 2.1 is a short cut argument once maximality is available. The difficulty is showing that FOREST, which assigns each edge to a class by looking only at the label of one end node, produces maximal forests in the successive residual graphs (Lemma 2.5). The obvious invariant, that the class of an edge is the first forest it does not close a cycle in, is not what line 7 computes. The label r(y)r(y)r(y) records only which classes touch yyy, not which component of each class contains yyy. The paper's argument needs Lemma 2.4(a): at the moment an edge is added to EiE_iEi​ its ends already lie in one tree of Ei−1E_{i-1}Ei−1​. That relies on the choice of the unscanned node of largest label, on the order of lines 8 and 9, and on an argument about the scan order of tree roots.

Formalization scope

  • Graphs. A graph is a finite node type V with ∣V∣≥2|V| \ge 2∣V∣≥2, a finite edge type E, and ends : E → Sym2 V with no diagonal value (no self-loops). Parallel edges are distinct elements of E. Simplicity is injectivity of ends, and edge subsets are Finset E. A forest is an edge set in which every edge is a bridge, a condition that sees parallel edges.
  • Connectivity. λ\lambdaλ is an infimum in ℕ∞ over separating edge sets, ∞\infty∞ at x=yx = yx=y. (2.1) is kept "for all x,yx, yx,y", as printed.
  • FOREST. FOREST is a nondeterministic step relation (select, scan, finish) on explicit states: labels, class index per edge (000 = unscanned), scanned nodes, current node and selection order. The theorems quantify over every run from the initial state, so no tie-breaking rule is fixed. "At some time instant" is a state of the run; "upon completion" is a run whose last state has every node scanned. Lemma 2.2 is stated at every state, not only after a scan block (the other steps change neither labels nor classes). Lemma 2.4(a) assumes i≥2i \ge 2i≥2, since E0E_0E0​ does not exist.
  • Exclusions. Theorem 2.1's clause "is found in O(∣V∣+∣E∣)O(|V| + |E|)O(∣V∣+∣E∣) time", the bucket implementation, and the time bound of the certificate are not formalized: the paper fixes no machine model. The goal consists of the structural conclusions only. The bound printed "if GGG is multiple" is stated for every loopless graph.
  • Non-triviality. The goal is about the classes of a run of FOREST. An arbitrary partition of EEE into maximal spanning forests is Lemma 2.1's hypothesis, not a formalization of Theorem 2.1. A statement in which the classes are unconstrained variables, or in which the run hypotheses cannot be met, would be trivial. A separate sanity file checks that a complete run on the triangle K3K_3K3​ exists and attains ∣E1∣=∣V∣−1|E_1| = |V| - 1∣E1​∣=∣V∣−1, ∣E2∣=∣V∣−2|E_2| = |V| - 2∣E2​∣=∣V∣−2.
  • Welcome contributions. Useful reusable infrastructure includes:
    • a cut and Menger layer for finite multigraphs;
    • forest and bridge lemmas for edge-indexed graphs;
    • invariant-style reasoning over runs.

Selected references

  • H. Nagamochi, T. Ibaraki, A linear-time algorithm for finding a sparse kkk-connected spanning subgraph of a kkk-connected graph, Algorithmica 7 (1992) 583–596. https://doi.org/10.1007/BF01758778
  • H. Nagamochi, T. Ibaraki, Computing edge-connectivity in multigraphs and capacitated graphs, SIAM J. Discrete Math. 5 (1992) 54–66. https://doi.org/10.1137/0405004
  • T. Nishizeki, S. Poljak, kkk-connectivity and decomposition of graphs into forests, Discrete Appl. Math. 55 (1994) 295–301. https://doi.org/10.1016/0166-218X(94)90014-0
  • J. Cheriyan, M.-Y. Kao, R. Thurimella, Scan-first search and sparse certificates: an improved parallel algorithm for kkk-vertex connectivity, SIAM J. Comput. 22 (1993) 157–174. https://doi.org/10.1137/0222013
  • A. Frank, T. Ibaraki, H. Nagamochi, On sparse subgraphs preserving connectivity properties, J. Graph Theory 17 (1993) 275–281. https://doi.org/10.1002/jgt.3190170302
  • M. Stoer, F. Wagner, A simple min-cut algorithm, J. ACM 44 (1997) 585–591. https://doi.org/10.1145/263867.263872
10 thms3 active usersReviewed
🏆Completed
Control TheoryOperations Research·Captain: mikedeng1

Supervisory Control of a Class of Discrete Event Processes I: Minimally Restrictive Supervisors Exist iff the Supremal Controllable Legal Sublanguage Contains the Minimal Acceptable LanguageResearch Paper

Motivation

Manufacturing cells, communication protocols, traffic systems and database transaction managers are naturally described not by differential equations but by sequences of discrete events: a machine starts, a part arrives, a message is lost. Ramadge and Wonham's 1987 paper (SIAM J. Control Optim. 25(1)) set up a control theory for such systems in which the plant is an automaton, the controller is another automaton that may disable some events, and specifications are formal languages. The framework, now called supervisory control theory or the Ramadge–Wonham framework, is the standard model for the logical control of discrete event systems and underlies the textbook treatment in Cassandras and Lafortune (Introduction to Discrete Event Systems, 2008) and Wonham and Cai (Supervisory Control of Discrete-Event Systems, 2019).

The question the paper answers is the basic synthesis question of the theory: given a plant, a set of legal behaviours and a set of minimally acceptable behaviours, when does a controller exist that keeps the plant legal, achieves at least the acceptable behaviour, and never deadlocks, and what is the least restrictive such controller?

Setting

A generator is G=(Q,Σ,δ,q0,Qm)\mathcal G = (Q, \Sigma, \delta, q_0, Q_m)G=(Q,Σ,δ,q0​,Qm​) with a state set QQQ, a finite alphabet Σ\SigmaΣ of events, a partial transition function δ:Σ×Q→Q\delta : \Sigma \times Q \to Qδ:Σ×Q→Q, an initial state q0q_0q0​ and marker states Qm⊆QQ_m \subseteq QQm​⊆Q. Extending δ\deltaδ to strings, the generated language L(G)L(\mathcal G)L(G) is the set of strings www for which δ(w,q0)\delta(w, q_0)δ(w,q0​) is defined, and the marked language Lm(G)L_m(\mathcal G)Lm​(G) is the subset of those that end in QmQ_mQm​. The closure Kˉ\bar KKˉ of a language KKK is its set of prefixes; KKK is closed if K=KˉK = \bar KK=Kˉ. Throughout, G\mathcal GG is assumed trim in the sense L(G)=Lˉm(G)L(\mathcal G) = \bar L_m(\mathcal G)L(G)=Lˉm​(G): every generated string can be completed to a marked one.

The alphabet is split into controllable events Σc\Sigma_cΣc​ and uncontrollable events Σu=Σ−Σc\Sigma_u = \Sigma - \Sigma_cΣu​=Σ−Σc​. A supervisor S=(S,ϕ)\mathcal S = (S, \phi)S=(S,ϕ) consists of a deterministic, accessible automaton S=(X,Σ,ξ,x0,Xm)S = (X, \Sigma, \xi, x_0, X_m)S=(X,Σ,ξ,x0​,Xm​), whose state set XXX may be infinite, and a map ϕ\phiϕ assigning to each state xxx the set of controllable events it enables; uncontrollable events are always enabled. The closed loop S/G\mathcal S/\mathcal GS/G runs SSS and G\mathcal GG in lockstep: an event occurs when the plant can execute it, the supervisor enables it, and the supervisor's automaton can follow it. This defines the languages L(S/G)L(\mathcal S/\mathcal G)L(S/G), Lm(S/G)L_m(\mathcal S/\mathcal G)Lm​(S/G) and the controlled language Lc(S/G)=L(S/G)∩Lm(G)L_c(\mathcal S/\mathcal G) = L(\mathcal S/\mathcal G) \cap L_m(\mathcal G)Lc​(S/G)=L(S/G)∩Lm​(G).

S\mathcal SS is complete if its automaton never refuses an event that the plant can execute and ϕ\phiϕ enables; it is proper if it is complete and

Lˉm(S/G)=Lˉc(S/G)=L(S/G),\bar L_m(\mathcal S/\mathcal G) = \bar L_c(\mathcal S/\mathcal G) = L(\mathcal S/\mathcal G),Lˉm​(S/G)=Lˉc​(S/G)=L(S/G),

that is, every closed-loop string can be completed to a marked task. A language KKK is controllable if K⊆L(G)K \subseteq L(\mathcal G)K⊆L(G) and KˉΣu∩L(G)⊆Kˉ\bar K \Sigma_u \cap L(\mathcal G) \subseteq \bar KKˉΣu​∩L(G)⊆Kˉ. For L⊆L(G)L \subseteq L(\mathcal G)L⊆L(G), CG(L)\mathbf C_{\mathcal G}(L)CG​(L) is the class of controllable sublanguages of LLL and FG(L)\mathbf F_{\mathcal G}(L)FG​(L) the class of sublanguages KKK of LLL with K=Kˉ∩Lm(G)K = \bar K \cap L_m(\mathcal G)K=Kˉ∩Lm​(G).

Given ∅≠La⊆Lg⊆Lm(G)\emptyset \neq L_a \subseteq L_g \subseteq L_m(\mathcal G)∅=La​⊆Lg​⊆Lm​(G), the Supervisory Marking Problem (SMP) asks for a proper S\mathcal SS with La⊆Lm(S/G)⊆LgL_a \subseteq L_m(\mathcal S/\mathcal G) \subseteq L_gLa​⊆Lm​(S/G)⊆Lg​, and the Supervisory Control Problem (SCP) for a proper S\mathcal SS with La⊆Lc(S/G)⊆LgL_a \subseteq L_c(\mathcal S/\mathcal G) \subseteq L_gLa​⊆Lc​(S/G)⊆Lg​.

Formalization targets

Goal: Theorem 7.1 (pp. 218–219)

SMP solvable  ⟺  sup⁡CG(Lg)⊇La,SCP solvable  ⟺  sup⁡{CG(Lg)∩FG(Lg)}⊇La,\text{SMP solvable} \iff \sup \mathbf C_{\mathcal G}(L_g) \supseteq L_a, \qquad \text{SCP solvable} \iff \sup\{\mathbf C_{\mathcal G}(L_g) \cap \mathbf F_{\mathcal G}(L_g)\} \supseteq L_a,SMP solvable⟺supCG​(Lg​)⊇La​,SCP solvable⟺sup{CG​(Lg​)∩FG​(Lg​)}⊇La​,

and in each case the solving supervisor can be taken minimally restrictive: its marked (respectively controlled) language equals the supremal element and contains that of every proper supervisor whose language lies in LgL_gLg​.

Milestones

  1. Proposition 4.1 (i), (ii): marking is independent of control; every K⊆Lm(G)K \subseteq L_m(\mathcal G)K⊆Lm​(G), or K⊆L∩Lm(G)K \subseteq L \cap L_m(\mathcal G)K⊆L∩Lm​(G) for an achievable closed LLL, is the marked language of a complete supervisor.
  2. Proposition 5.1: a complete supervisor realizes (Lm,Lc,L)=(K1,K2,K3)(L_m, L_c, L) = (K_1, K_2, K_3)(Lm​,Lc​,L)=(K1​,K2​,K3​) iff K1⊆K2K_1 \subseteq K_2K1​⊆K2​, K2=K3∩Lm(G)K_2 = K_3 \cap L_m(\mathcal G)K2​=K3​∩Lm​(G) and K3K_3K3​ is closed and controllable.
  3. Theorem 6.1 (i), (ii): a proper supervisor with Lm(S/G)=KL_m(\mathcal S/\mathcal G) = KLm​(S/G)=K exists iff KKK is controllable; one with Lc(S/G)=KL_c(\mathcal S/\mathcal G) = KLc​(S/G)=K exists iff KKK is controllable and Lm(G)L_m(\mathcal G)Lm​(G)-closed.
  4. Proposition 7.1: CG(L)\mathbf C_{\mathcal G}(L)CG​(L) and FG(L)\mathbf F_{\mathcal G}(L)FG​(L) contain ∅\emptyset∅ and are closed under arbitrary unions.
  5. The supremal elements (p. 218): sup⁡CG(L)\sup \mathbf C_{\mathcal G}(L)supCG​(L), sup⁡FG(L)\sup \mathbf F_{\mathcal G}(L)supFG​(L) and sup⁡{CG(L)∩FG(L)}\sup\{\mathbf C_{\mathcal G}(L) \cap \mathbf F_{\mathcal G}(L)\}sup{CG​(L)∩FG​(L)} belong to their classes.

Significance

Theorem 7.1 reduces the existence of a correct, non-blocking controller to a single language inclusion, and identifies the supremal controllable sublanguage as the behaviour of the least restrictive solution. That object is the backbone of the later theory: modular and decentralized control, control under partial observation, and the computational results that sup⁡CG(L)\sup \mathbf C_{\mathcal G}(L)supCG​(L) is regular and computable when G\mathcal GG is finite and LLL regular all start from it.

The result is proved in the paper and has been taught for decades; it is not open. Mathlib has no model of generators with partial transitions, supervisors or controllability (its DFA has a total transition function and a single accepted language), and no formalization of this theory exists on the platform. This mission provides one: a reusable Lean model of generators with partial transitions, supervisors with possibly infinite state, closed loops and controllability, together with the paper's existence theorems stated against it. A second mission on the same paper (quotients of supervisors, Theorem 10.1) builds on the same objects.

Difficulty

The combinatorial core of Proposition 7.1 is a short prefix-closure computation. The work lies in the constructions: to show existence, a supervisor must be built for an arbitrary controllable language, which in general is not regular, so the supervisor needs an infinite state set (for example strings of the target language) together with a proof that the closed loop generates exactly the intended language, is complete, and is proper. The converse directions require relating the closed-loop run to separate runs of the plant and of the supervisor's automaton. The naive shortcut of reading the "sup" as an arbitrary member of CG(Lg)\mathbf C_{\mathcal G}(L_g)CG​(Lg​) containing LaL_aLa​ skips the content of the supremal-element milestone; the goal is stated with the actual union.

Formalization scope

  • The alphabet is a type α with [Fintype α]; strings are List α, the empty string is [], and sσs\sigmasσ is s ++ [σ]. Languages are Set (List α); the closure is pre K = {s | ∃ t, s ++ t ∈ K}.
  • A generator is a structure with a state type Q : Type, a partial transition δ : α → Q → Option Q, an initial state and a marker set. No finiteness is assumed on states, of the plant or of the supervisor. Supervisors and generators live in Type 1.
  • ϕ\phiϕ maps states to Ec → Bool; an event outside Σc\Sigma_cΣc​ is enabled by definition, so uncontrollable events cannot be disabled.
  • The closed loop is the product run from (x0,q0)(x_0, q_0)(x0​,q0​); the accessible part in the paper's display (2.1) changes no language and is not built.
  • Standing assumptions carried by every theorem: Σ\SigmaΣ finite, L(G)=Lˉm(G)L(\mathcal G) = \bar L_m(\mathcal G)L(G)=Lˉm​(G), supervisor automata accessible (as a hypothesis on every input supervisor and a conjunct of every "there exists a supervisor").
  • sup⁡\supsup is sSup in the complete lattice Set (List α).
  • A formalization in which the closed loop ignores ϕ\phiϕ or the plant, in which completeness is dropped from properness, or in which the supervisor is restricted to finitely many states, is not the paper's theorem and is ruled out by the definitions above.

Welcome contributions: the basic run lemmas (closed-loop runs project to plant and supervisor runs), the string-state supervisor construction, and proofs of the milestones in the given order.

Selected references

  • P. J. Ramadge and W. M. Wonham, Supervisory Control of a Class of Discrete Event Processes, SIAM J. Control Optim. 25(1):206–230, 1987. https://doi.org/10.1137/0325013
  • W. M. Wonham and P. J. Ramadge, On the Supremal Controllable Sublanguage of a Given Language, SIAM J. Control Optim. 25(3):637–659, 1987. https://doi.org/10.1137/0325036
  • C. G. Cassandras and S. Lafortune, Introduction to Discrete Event Systems, 2nd ed., Springer, 2008. https://doi.org/10.1007/978-0-387-68612-7
  • W. M. Wonham and K. Cai, Supervisory Control of Discrete-Event Systems, Springer, 2019. https://doi.org/10.1007/978-3-319-77452-7
12 thms3 active usersReviewed
PreviousPage 1 of 5Next

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