Documentation

CslibFrontier.Computability.QueryComplexity.Quantum.AmbainisAdversary.Symmetric

Bounded-error parity, threshold functions and majority by the adversary method #

Ambainis's adversary bound across single bit flips (Cslib.Quantum.one_sub_mul_sqrt_le_two_mul_of_neighbors) gives the Ω(N) lower bounds for parity and majority that [Amb02], §5.3, derives from Theorem 2, and the threshold bound behind them.

For total functions the parity and threshold bounds would also follow from the spectral-sensitivity bound Cslib.Quantum.one_sub_mul_spectralSensitivity_le, since λ(PARITY_N) = N and λ(Th^N_k) = √(k (N - k + 1)); the library does not prove these values. The layer bound one_sub_mul_sqrt_le_two_mul_of_weight constrains the algorithm only on two weight layers. The constants are those of this proof. The source states Ω(N) bounds.

Main results #

References #

theorem Cslib.Quantum.one_sub_mul_card_le_two_mul_of_parity {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) {ε : ℝ} (h : ∀ (x : Fin N → Bool), |measureProb (run U ψ₀ x T) S - BitString.bitVal ℝ (parity N x)| ≤ ε) (hε : 2 * ε ≤ 1) :
(1 - 2 * √(ε * (1 - ε))) * ↑N ≤ 2 * ↑T

Bounded-error parity takes Ω(N) queries [Amb02], §5.3: if a T-query algorithm with a unit initial state accepts every input x, by an outcome in S, with probability within ε ≤ 1/2 of the parity of x, then (1 - 2√(ε(1-ε))) N ≤ 2T.

theorem Cslib.Quantum.card_le_thirty_six_mul_of_parity {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) (h : ∀ (x : Fin N → Bool), |measureProb (run U ψ₀ x T) S - BitString.bitVal ℝ (parity N x)| ≤ 1 / 3) :
N ≤ 36 * T

Bounded-error parity takes N / 36 queries: if a T-query algorithm with a unit initial state accepts every input x, by an outcome in S, with probability within 1/3 of the parity of x, then N ≤ 36 T.

theorem Cslib.Quantum.one_sub_mul_sqrt_le_two_mul_of_weight {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) {k : ℕ} {ε : ℝ} (h₁ : ∀ (x : BitString N), BitString.weight x = k → 1 - ε ≤ measureProb (run U ψ₀ x T) S) (h₂ : ∀ (y : BitString N), BitString.weight y + 1 = k → measureProb (run U ψ₀ y T) S ≤ ε) (hε : 2 * ε ≤ 1) :
(1 - 2 * √(ε * (1 - ε))) * √(↑k * (↑N + 1 - ↑k)) ≤ 2 * ↑T

Telling weight k from weight k - 1 [Amb02], §5.3: if a T-query algorithm with a unit initial state accepts every input of weight k, by an outcome in S, with probability at least 1 - ε and every input of weight k - 1 with probability at most ε ≤ 1/2, then (1 - 2√(ε(1-ε))) √(k (N + 1 - k)) ≤ 2T. The algorithm is constrained on no other input.

theorem Cslib.Quantum.one_sub_mul_sqrt_le_two_mul_of_threshold {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) {k : ℕ} {ε : ℝ} (h : ∀ (x : Fin N → Bool), |measureProb (run U ψ₀ x T) S - BitString.bitVal ℝ (threshold N k x)| ≤ ε) (hε : 2 * ε ≤ 1) :
(1 - 2 * √(ε * (1 - ε))) * √(↑k * (↑N + 1 - ↑k)) ≤ 2 * ↑T

Threshold functions [Amb02], §5.3: if a T-query algorithm with a unit initial state accepts every input x, by an outcome in S, with probability within ε ≤ 1/2 of Th^N_k(x), then (1 - 2√(ε(1-ε))) √(k (N + 1 - k)) ≤ 2T.

theorem Cslib.Quantum.one_sub_mul_card_le_four_mul_of_majority {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) {ε : ℝ} (h : ∀ (x : Fin N → Bool), |measureProb (run U ψ₀ x T) S - BitString.bitVal ℝ (majority N x)| ≤ ε) (hε : 2 * ε ≤ 1) :
(1 - 2 * √(ε * (1 - ε))) * ↑N ≤ 4 * ↑T

Bounded-error majority takes Ω(N) queries [Amb02], §5.3: if a T-query algorithm with a unit initial state accepts every input x, by an outcome in S, with probability within ε ≤ 1/2 of the majority of x, then (1 - 2√(ε(1-ε))) N ≤ 4T.

theorem Cslib.Quantum.card_le_seventy_two_mul_of_majority {N : ℕ} {W : Type u_1} [Fintype W] (U : ℕ → State N W →ₗᵢ[ℂ] State N W) {ψ₀ : State N W} (hψ₀ : ‖ψ₀‖ = 1) (T : ℕ) (S : Finset (Fin N × Bool × W)) (h : ∀ (x : Fin N → Bool), |measureProb (run U ψ₀ x T) S - BitString.bitVal ℝ (majority N x)| ≤ 1 / 3) :
N ≤ 72 * T

Bounded-error majority takes N / 72 queries: if a T-query algorithm with a unit initial state accepts every input x, by an outcome in S, with probability within 1/3 of the majority of x, then N ≤ 72 T.