Theorem 4.3: add/drop/swap local search for metric UFL has locality gap at most 3
ProvedLocalSearchFL.UFL.ufl_locality_gapLet be a finite set of clients and a finite set of facilities, with a distance on that is nonnegative, symmetric and satisfies the triangle inequality, and let be the cost of serving client by facility . Each facility has an opening cost . The cost of a nonempty set of open facilities is
is locally optimum for the neighbourhood
if no neighbour has smaller cost.
Theorem 4.3. If is locally optimum for , then for every nonempty ,
In words: the local search procedure that adds, drops or swaps one facility at a time has locality gap at most 3 for the metric uncapacitated facility location problem. The bound is tight (§4.3 of the paper).
Formalization Note The locality gap bound is stated as the inequality for every local optimum and every solution (not only an optimal one), multiplied out rather than as a ratio. Only nonempty sets are solutions; the drop move is considered only when a facility remains open.
import Mathlib import Definitions.Def_LocalSearchFL_UFL_captures
namespace LocalSearchFL.UFL
/-- Theorem 4.3, p. 557: local search for the metric UFL problem with the neighbourhood
`B(S) = {S + {s'}} ∪ {S − {s} | s ∈ S} ∪ {S − {s} + {s'} | s ∈ S}` has locality gap at most 3:
if `S` is locally optimum for `B`, then `cost(S) ≤ 3 · cost(O)` for every solution `O`. -/
theorem ufl_locality_gap {Cl Fa : Type} [Fintype Cl] [DecidableEq Cl]
[Fintype Fa] [DecidableEq Fa]
(I : MetricInstance Cl Fa) (f : Fa → ℝ) (hf : ∀ i, 0 ≤ f i)
(S : Finset Fa) (hS : S.Nonempty) (hloc : IsUFLLocalOpt I f S hS)
(O : Finset Fa) (hO : O.Nonempty) :
uflCost I f S hS ≤ 3 * uflCost I f O hO := by sorry
end LocalSearchFL.UFL
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Let and be arbitrary types, both finite and with decidable equality. The statement takes these as parameters:
- , a value of type
MetricInstancebuilt on and . This type comes from the imported bundleDefinitions.Def_LocalSearchFL_UFL_captures, and its definition is not included in the code under audit. Nothing here fixes what data holds (for example, distances between elements of and ) or what conditions it imposes (for example, non-negativity or a triangle inequality). - , a real-valued function on , with the hypothesis that for every .
- , a finite set with a proof that .
- A hypothesis that satisfies . This predicate comes from the same imported bundle and is not shown. The code does not reveal which neighbouring sets it compares against, how it compares them, or whether that comparison can involve empty sets.
- , a second finite set with a proof that .
The conclusion is
where is the imported function uflCost applied to , , the set and its non-emptiness proof. Its definition is also not shown, so the code does not reveal how it combines with the data in . The set is universally quantified: it can be any non-empty subset of , with no optimality condition on it. The inequality is non-strict (), and the constant is exactly .
Degenerate cases:
- is empty. Then no non-empty exists, and the statement holds vacuously.
- has exactly one element. Then is that single element, and the claim becomes . This is true exactly when that cost is non-negative, which depends on the unseen definitions of
uflCostandMetricInstance. - is empty. The statement does not exclude this. What the cost then equals depends on the unseen definition of
uflCost. - fails the local-optimality predicate. Then the statement asserts nothing about . It holds vacuously for every such , and in general if the predicate can never be satisfied.
- Total-function defaults. Whether division by zero, a minimum over an empty set, or another default value can occur inside
uflCostorIsUFLLocalOptcannot be determined from the code shown.
The only explicit hypothesis on is non-negativity. Nothing in the visible code requires to be positive or bounded above.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.