@[reducible, inline]
Count vectors for m+1 actions and denominator Q, including the
last remainder coordinate. Every coordinate is nonnegative by its type.
Instances For
@[instance_reducible]
Equations
- MindFormal.Security.gridFintype m Q = Fintype.ofEquiv (Sym (Fin (m + 1)) Q) (Sym.equivNatSumOfFintype (Fin (m + 1)) Q)
SD29's candidate count, including the one-action case.
Equations
- MindFormal.Security.gridMixture g i = ↑(↑g i) / ↑Q
Instances For
noncomputable def
MindFormal.Security.roundedGrid
{m : ℕ}
(Q : ℕ)
(p : Fin (m + 1) → ℝ)
(hp : FiniteDecision.Probability p)
:
Grid m Q
Equations
Instances For
theorem
MindFormal.Security.rounding_tv
{m Q : ℕ}
(p : Fin (m + 1) → ℝ)
(hp : FiniteDecision.Probability p)
(hQ : 1 ≤ Q)
:
SD29's prescribed rounding: round down the first m coordinates,
give all remaining mass to the last, and pay TV at most m/Q.
theorem
MindFormal.Security.enumeration_security
{m Q : ℕ}
{B : Type u_1}
[Fintype B]
[Nonempty B]
(pay : Fin (m + 1) → B → ℝ)
(hQ : 1 ≤ Q)
(R : ℝ)
(hR : 0 ≤ R)
(oscillation : ∀ (b : B) (a c : Fin (m + 1)), |pay a b - pay c b| ≤ R)
:
SD29: the enumerated winner loses at most R*m/Q on the supplied
exact table. Real tables satisfy the same bound; rational tables permit
exact finite arithmetic in a separately constructed implementation.
theorem
MindFormal.Security.grid_security
{m Q : ℕ}
{B : Type u_1}
[Fintype B]
[Nonempty B]
(pay : Fin (m + 1) → B → ℝ)
(hQ : 1 ≤ Q)
(R : ℝ)
(hR : 0 ≤ R)
(oscillation : ∀ (b : B) (a c : Fin (m + 1)), |pay a b - pay c b| ≤ R)
:
Fintype.card (Grid m Q) = (Q + m).choose m ∧ (∀ (p : Fin (m + 1) → ℝ) (hp : FiniteDecision.Probability p),
FiniteDecision.Probability (gridMixture (roundedGrid Q p hp)) ∧ tv (gridMixture (roundedGrid Q p hp)) p ≤ ↑m / ↑Q) ∧ FiniteDecision.Probability (gridMixture (enumerated pay)) ∧ (∀ (g : Grid m Q), worst pay (gridMixture g) ≤ worst pay (gridMixture (enumerated pay))) ∧ value pay - R * (↑m / ↑Q) ≤ worst pay (gridMixture (enumerated pay))
The entire SD29 finite mathematical test: exact candidate count, the prescribed TV rounding for every distribution, a normalized grid winner that dominates all candidates, and its security-defect bound.