The dual of the general adversary bound
ProvedQAlgorithms.Childs.adversary_dualLet and let be a (possibly partial) Boolean function. An adversary matrix for is a real symmetric matrix with whenever ; for , is the matrix with if and otherwise. The general (negative-weights) adversary bound is
with spectral norms. For a positive integer and vectors (, ), define the -complexity for . Call the family feasible if
Then
the minimum over all positive integers and all feasible families; in particular the minimum is attained.
This strong-duality statement turns the adversary lower bound into a minimization, so that explicit dual solutions give upper bounds on and, via the algorithm of §24.6, on quantum query complexity.
Formalization Note The index set is an arbitrary finite type. is the supremum, in , of the ratio over nonzero adversary matrices, and is when is constant on (then is the only adversary matrix and the source's ratio is ). An empty maximum is . The minimum is stated as: the value is attained by a feasible family and bounds every feasible objective from below.
import Definitions.Def_QAlgorithms_Defs_Adversary set_option autoImplicit false
namespace QAlgorithms.Childs
open scoped NNReal ENNReal
/-- Childs, Theorem 24.1 (PDF p. 124): the dual of the general adversary bound. For any
`f : S → {0,1}` with `S ⊆ {0,1}^n`, `Adv±(f) = min max{C₀, C₁}`, the minimum over all positive
integers `d` and all families of vectors `|v_{x,i}⟩ ∈ ℂ^d` (`x ∈ S`, `i ∈ [n]`) satisfying
(24.3): `∑_{i : x_i ≠ y_i} ⟨v_{x,i}|v_{y,i}⟩ = 1 − δ_{f(x),f(y)}` for all `x ≠ y`, where
`C_b = max_{x ∈ f⁻¹(b)} ∑_i ‖|v_{x,i}⟩‖²`. "Min" is rendered as `IsLeast`: the value is attained
by a feasible family and is a lower bound on every feasible objective. -/
theorem adversary_dual {ι : Type*} [Fintype ι] [DecidableEq ι] (f : (ι → Bool) → Bool)
(D : Finset (ι → Bool)) :
IsLeast {r : ℝ≥0∞ | ∃ (d : ℕ) (v : D → ι → EuclideanSpace ℂ (Fin d)), 0 < d ∧
DualFeasibleChilds f D d v ∧ r = (childsDualObjective f D v : ℝ≥0∞)}
(advPm f D) := by
sorry
end QAlgorithms.Childs
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Fix a finite index set with decidable equality. Let be any Boolean function and any finite set of inputs (the domain). Only the values of on matter. The theorem states that the quantity , defined below as an element of , is the least element of a set , also defined below. This means two things:
- , so the minimum is attained;
- for every .
The primal quantity. is defined as a supremum in :
- Which . The supremum ranges over real matrices that satisfy three conditions:
- is symmetric;
- whenever ;
- .
- The norms. is the spectral norm (the operator norm).
- The masked matrix. is the matrix whose entry is if and otherwise.
- Degenerate maximum. The maximum over is a real supremum. If is empty, it equals .
- Division by zero. If the denominator is , the quotient is taken to be .
- Empty supremum. If no admissible exists, the supremum is . This happens, for example, when , or when is constant on .
The dual set. The set consists of all values for which there exist the following:
- a natural number with ;
- a family of vectors , one for each and .
These must satisfy two conditions.
- Feasibility. For all in :
Here is the standard inner product on , conjugate-linear in its first argument. Pairs with are not constrained. 2. Objective value. equals the (finite) number
An inner maximum over an empty set of is .
In particular, the theorem asserts that is finite, and that it equals the objective value of some feasible family of vectors in some with .
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.