Duality theory in linear optimization and its extensions – formally verified
Farkas-type theorems of alternatives and strong LP duality are foundational in linear optimization. The goal is to formally verify them over general linearly ordered fields and to extend duality theory to coefficients that may take infinite values.
Using Lean 4.18.0 and Mathlib, the authors first prove a Farkas–Bartl theorem over linearly ordered division rings and modules by induction. They derive equality and inequality Farkas lemmas and strong LP duality from it as corollaries. They define extended linearly ordered fields with ⊥ and ⊤ and prove an extended Farkas theorem and extended weak and strong LP duality under side conditions on where infinities may appear.
All theorems are machine-checked, using only the axioms propext, Classical.choice and Quot.sound. Counterexamples show that each precondition of the extended Farkas theorem is necessary.
