Theorem 3, p. 427 — k-longest-first makespan ratio
ProvedGrahamAnomaly.KLongest.theorem_3Let independent tasks have positive lengths , and let identical processors execute them. Choose tasks of greatest length as the first positions of a priority list , in an order whose list assignment has the smallest possible prefix finishing time . Append the other tasks in any order, assigning each next task to a least-loaded processor. If is the resulting finishing time and is the minimum finishing time for all tasks, then
This is the approximation guarantee of Graham's Theorem 3. Its best-possible example for is a separate companion item.
Formalization Note The first tasks must be longest, and their assignment must be optimal for those tasks alone; neither condition is replaced by an assumption of the intermediate inequalities. The integer quotient is the floor. Assignments are equivalent to the paper's lists for the optimum in this independent-task setting, and least-load ties are unrestricted.
import Mathlib import Definitions.Def_GrahamAnomaly_KLongest_Model
namespace GrahamAnomaly.KLongest
theorem theorem_3 {r n k : ℕ} (hr : 0 < r) (hn : 0 < n) (hk : k ≤ r)
(μ : Fin r → ℝ) (hμ : ∀ j, 0 < μ j)
(L : Fin r ≃ Fin r) (σ : Fin r → Fin n)
(hlong : ∀ i j, (L.symm i : ℕ) < k → k ≤ (L.symm j : ℕ) → μ j ≤ μ i)
(hσ : IsListAssignment μ L σ)
(hopt : ∀ τ : Fin r → Fin n, prefixFinish μ L σ k ≤ prefixFinish μ L τ k) :
WilliamsonShmoys.makespan μ σ / optFinish μ n ≤
1 + (1 - 1 / (n : ℝ)) / (1 + ((k / n : ℕ) : ℝ)) := by sorry
end GrahamAnomaly.KLongest
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.