queries locate relative to all hyperplanes in
ProvedMegiddoLP.FixedDim.log_queries_allLet . There is a constant , independent of , with the following property. For every and all hyperplanes with , there is a query strategy which, for every unknown point , outputs the positions of relative to all hyperplanes and makes
queries.
This is the paper's multidimensional search theorem. Linear programming uses it through the oracle of §4, which answers each query by solving linear programs in one dimension fewer.
Formalization Note is chosen before and the data. is the natural logarithm, and another base changes only . The restriction is needed because while one hyperplane in general needs one query. The output is the full vector of positions (Fin n → Ordering), and it must be correct for every .
import Mathlib import Definitions.Def_MegiddoLP_FixedDim_QueryTree
/-!
Megiddo, J. ACM 31 (1984), §3.1–§3.2 p. 118: for every dimension `d` there is a constant
`C = C(d)`, independent of `n`, such that `C · log n` queries suffice to determine the
position of `x*` relative to all `n` given hyperplanes in `ℝ^d`.
-/
namespace MegiddoLP.FixedDim
/-- **Multidimensional search with `C(d) log n` queries.** For `d ≥ 1` there is a constant `C`
such that for every `n ≥ 2` and all hyperplanes `{aᵢ ⬝ᵥ x = bᵢ}` (`i < n`) in `ℝ^d` with
`aᵢ ≠ 0`, some strategy determines, for every unknown point `x`, the positions of `x` relative
to all `n` hyperplanes using at most `C log n` queries (natural logarithm). -/
theorem log_queries_all (d : ℕ) (hd : 1 ≤ d) :
∃ C : ℝ, ∀ n : ℕ, 2 ≤ n → ∀ (a : Fin n → Fin d → ℝ) (b : Fin n → ℝ), (∀ i, a i ≠ 0) →
∃ T : QTree d (Fin n → Ordering), ∀ x : Fin d → ℝ,
T.eval x = (fun i => compare (a i ⬝ᵥ x) (b i)) ∧
(T.numQueries x : ℝ) ≤ C * Real.log n := by sorry
end MegiddoLP.FixedDim
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Setting. Let with .
Claim. There exists a real constant , chosen depending only on , with the following property. For every natural number , and all vectors and reals with every , there exists a query tree in whose leaves carry functions assigning to each a value in . For every :
- Complete and correct: for all , assigns to exactly the relation of to .
- Query bound:
where is the number of queries on the path of and is the natural logarithm.
Degenerate cases.
- . Excluded by the hypothesis .
- For , , so no default value of the logarithm arises.
- . Excluded by hypothesis.
- The constant is an arbitrary real a priori. Its existence is asserted uniformly over all and all admissible data.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.