Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Proof of Theorem 4 — under saturation, P3∣res1⋅⋅,pj=1∣Cmax⁡P3\mid res1\cdot\cdot, p_j=1\mid C_{\max}P3∣res1⋅⋅,pj​=1∣Cmax​ is equivalent to 3-PARTITION

Proved
ResourceScheduling.Chain.threePartition_iff_p3Schedule

by mikedeng1 · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

3-partitionp2o-batch-p100bp2o-gran-per-chapterp2o-plan-paperp2o-v1reductionsscheduling

Let t∈Nt \in \mathbb{N}t∈N, let bbb be a positive integer and a1,…,a3ta_1,\dots,a_{3t}a1​,…,a3t​ positive integers with ∑j=13taj=tb\sum_{j=1}^{3t} a_j = tb∑j=13t​aj​=tb. Consider the instance of P3∣res1⋅⋅,pj=1∣Cmax⁡P3\mid res1\cdot\cdot, p_j = 1\mid C_{\max}P3∣res1⋅⋅,pj​=1∣Cmax​ with 3t3t3t unit-time jobs J1,…,J3tJ_1,\dots,J_{3t}J1​,…,J3t​, three identical machines, one resource of size bbb, requirements r1j=ajr_{1j} = a_jr1j​=aj​ and no precedence constraints. Then

{1,…,3t} can be partitioned into t disjoint 3-element sets Si with ∑j∈Siaj=b  ⟺  some feasible schedule has Cmax⁡≤t.\{1,\dots,3t\} \text{ can be partitioned into } t \text{ disjoint 3-element sets } S_i \text{ with } \sum_{j\in S_i} a_j = b \iff \text{some feasible schedule has } C_{\max} \le t.{1,…,3t} can be partitioned into t disjoint 3-element sets Si​ with j∈Si​∑​aj​=b⟺some feasible schedule has Cmax​≤t.

With 3t3t3t unit jobs on three machines in time ttt, and total requirement tbtbtb against a resource of size bbb, both the machines and the resource are saturated; this is the paper's statement "When the machines and resources are all saturated, P3∣res1⋅⋅,pj=1∣Cmax⁡P3\mid res1\cdot\cdot, p_j = 1\mid C_{\max}P3∣res1⋅⋅,pj​=1∣Cmax​ is equivalent to the following problem: 3-PARTITION". It is the reduction behind Theorem 4.

Formalization Note. Schedules have real start times and the resource constraint is checked at every real time. The page's version of 3-PARTITION has no bounds on the aja_jaj​, so none are assumed here.

Preamble
import Mathlib
import Definitions.Def_ResourceScheduling_Chain_Constructions
Formal statement
namespace ResourceScheduling.Chain
theorem threePartition_iff_p3Schedule (P : ThreePartition) (hb : 0 < P.b)
    (ha : ∀ j, 0 < P.a j) (hsum : ∑ j, P.a j = P.t * P.b) :
    P.HasSolution ↔ P.p3Instance.HasScheduleWithin P.t := by sorry
end ResourceScheduling.Chain
Source
Błażewicz, Lenstra & Rinnooy Kan, Scheduling subject to resource constraints: classification and complexity, Discrete Appl. Math. 5 (1983), p. 16, proof of Theorem 4
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

Let PPP consist of natural numbers ttt and bbb and numbers aj∈Na_j \in \mathbb{N}aj​∈N for j∈S={0,…,3t−1}j \in S = \{0,\dots,3t-1\}j∈S={0,…,3t−1}. Assume:

  • b>0b > 0b>0;
  • aj>0a_j > 0aj​>0 for every jjj;
  • ∑j∈Saj=t b\displaystyle\sum_{j \in S} a_j = t\,bj∈S∑​aj​=tb.

The bounds 14b<aj<12b\tfrac14 b < a_j < \tfrac12 b41​b<aj​<21​b are not assumed.

The theorem asserts that the following two statements are equivalent (if and only if).

(A) A partition exists. There is a map σ:S→{0,…,t−1}\sigma: S \to \{0,\dots,t-1\}σ:S→{0,…,t−1} such that, for every iii, the set σ−1(i)\sigma^{-1}(i)σ−1(i) has exactly three elements and its aja_jaj​ sum to bbb.

(B) A schedule of makespan at most ttt exists for the following instance:

  • 3t3t3t unit-time jobs indexed by SSS;
  • 333 machines;
  • one resource of size bbb, with job jjj requiring aja_jaj​;
  • no precedence constraints.

Concretely, (B) says there are a machine μ(j)∈{0,1,2}\mu(j) \in \{0,1,2\}μ(j)∈{0,1,2} and a real start time SjS_jSj​ for each job such that:

  1. Sj≥0S_j \ge 0Sj​≥0 for all jjj.
  2. Distinct jobs on the same machine satisfy Sj+1≤SkS_j + 1 \le S_kSj​+1≤Sk​ or Sk+1≤SjS_k + 1 \le S_jSk​+1≤Sj​.
  3. For every real τ\tauτ,
∑j : Sj≤τ<Sj+1aj≤b.\sum_{j \,:\, S_j \le \tau < S_j+1} a_j \le b.j:Sj​≤τ<Sj​+1∑​aj​≤b.
  1. max⁡j(Sj+1)≤t\max_j (S_j+1) \le tmaxj​(Sj​+1)≤t, where the maximum is taken as 000 when there are no jobs.

Start times may be arbitrary nonnegative reals, not necessarily integers.

Degenerate cases. When t=0t = 0t=0, both sides hold:

  • (A) is witnessed by the empty map;
  • (B) is witnessed by the empty schedule, whose makespan is 0≤00 \le 00≤0.

So the equivalence is trivially true in that case. The hypotheses are satisfiable (for example t=1t=1t=1, b=3b=3b=3, a=(1,1,1)a=(1,1,1)a=(1,1,1)), so the theorem is not vacuous.

Human review
  • Endorsed by Shuze Chen · Sep 27, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 27, 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 paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me