Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

§5, pp. 10–11 — series composition by Steps 1–3 yields a set representing an optimal sequence

Proved
LawlerWCT.SeriesPar.series_composition_procedure

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

algorithm-correctnessp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1schedulingseries-parallel

Throughout, NNN is a finite set of jobs to be sequenced on a single machine, G=(N,A)G=(N,A)G=(N,A) is an acyclic digraph on NNN (job iii must precede job jjj when there is a directed path from iii to jjj), job jjj has a processing time pj>0p_j>0pj​>0 and a real weight wjw_jwj​, and the cost of a feasible sequence is ∑jwjCj\sum_{j} w_j C_j∑j​wj​Cj​, where CjC_jCj​ is the completion time of jjj when the machine starts at time 000 and never idles.

Say that a set FFF of composite jobs represents an optimal sequence for a set of jobs MMM if every composite job of FFF is a nonempty sequence each of whose nonempty proper prefixes has ratio at most its own, the composite jobs of FFF partition MMM, and every arrangement of FFF in nonincreasing ratio order, expanded into a sequence of jobs, is an optimal sequence for MMM (under the constraints of GGG among the jobs of MMM).

Let M1,M2⊆NM_1,M_2\subseteq NM1​,M2​⊆N be disjoint modules of GGG whose union M1∪M2M_1\cup M_2M1​∪M2​ is also a module (the sons of a node of the decomposition tree and the node itself), with every job of M1M_1M1​ required to precede every job of M2M_2M2​, and let F1F_1F1​ and F2F_2F2​ represent optimal sequences for M1M_1M1​ and M2M_2M2​. Let FFF be the result of any run of the series procedure (Steps 1–3, p. 11) on F1F_1F1​ and F2F_2F2​: Step 1 compares a minimal-ratio i∈F1i\in F_1i∈F1​ with a maximal-ratio j∈F2j\in F_2j∈F2​ and halts with F1∪F2F_1\cup F_2F1​∪F2​ if ρ(i)>ρ(j)\rho(i)>\rho(j)ρ(i)>ρ(j), and otherwise forms k=(i,j)k=(i,j)k=(i,j); Step 2 repeatedly absorbs a minimal-ratio iii of the rest of F1F_1F1​ as k=(i,k)k=(i,k)k=(i,k) while ρ(i)≤ρ(k)\rho(i)\le\rho(k)ρ(i)≤ρ(k); Step 3 halts with F1∪F2∪{k}F_1\cup F_2\cup\{k\}F1​∪F2​∪{k} if a maximal-ratio jjj of the rest of F2F_2F2​ has ρ(k)>ρ(j)\rho(k)>\rho(j)ρ(k)>ρ(j), and otherwise absorbs it as k=(k,j)k=(k,j)k=(k,j) and returns to Step 2. Then

F represents an optimal sequence for M1∪M2.F\ \text{represents an optimal sequence for}\ M_1\cup M_2 .F represents an optimal sequence for M1​∪M2​.

This is the heart of the series parallel algorithm: the series step, which forms composite jobs, preserves optimality of the ratio order.

Formalization Note The procedure is the inductive relation SeriesMerge / SeriesLoop; every tie-breaking among minimal or maximal elements is allowed. The dummies of ratio ±∞\pm\infty±∞ are encoded by vacuous conditions on empty sets. The page's M1M_1M1​, M2M_2M2​ and M=M1∪M2M=M_1\cup M_2M=M1​∪M2​ are modules (§5, p. 9: "an optimal sequence for a module MMM from previously determined optimal sequences for its sons, M1M_1M1​ and M2M_2M2​"); the module hypotheses are needed, since otherwise a path i→x→ji\to x\to ji→x→j through a job x∉Mx\notin Mx∈/M would constrain MMM without being visible to feasibility on MMM.

Preamble
import Mathlib
import Definitions.Def_LawlerWCT_SeriesPar_Model
Formal statement
namespace LawlerWCT.SeriesPar

theorem series_composition_procedure {ι : Type*} [DecidableEq ι] (N : Finset ι) (G : ι → ι → Prop)
    (hGN : ∀ i j, G i j → i ∈ N ∧ j ∈ N) (hacyc : ∀ j, ¬ Relation.TransGen G j j)
    (p w : ι → ℝ) (hp : ∀ j ∈ N, 0 < p j)
    (M₁ M₂ : Finset ι) (hdisj : Disjoint M₁ M₂)
    (hM₁ : IsModule G N M₁) (hM₂ : IsModule G N M₂) (hM : IsModule G N (M₁ ∪ M₂))
    (hser : ∀ i ∈ M₁, ∀ j ∈ M₂, Relation.TransGen G i j)
    (F₁ F₂ : List (List ι)) (h₁ : Represents G p w M₁ F₁) (h₂ : Represents G p w M₂ F₂)
    (F : List (List ι)) (hmerge : SeriesMerge p w F₁ F₂ F) :
    Represents G p w (M₁ ∪ M₂) F := by sorry

end LawlerWCT.SeriesPar
Source
Lawler, Sequencing jobs to minimize total weighted completion time subject to precedence constraints, IRIA-LABORIA Rapport de Recherche No. 205 (Dec. 1976), HAL hal-04716371v1, pp. 10–11, §5, paragraphs "Now suppose ρ(i) ≤ ρ(j)" and "Now let us find the next minimal element", and Steps 1–3
Human review
  • Endorsed by Shuze Chen · Oct 6, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 6, 2026

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

View graph

Get started

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

About Prove2Me

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

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me