AFTD Auto-Formalizing Theoretical Domains

gapped_three_point_vulnerability

def

The one-guess vulnerability of an additive integer mask q against a secret uniformly distributed on {0, 1, d} is (1/3) ∑_{s ∈ ℤ} max(q(s), max(q(s-1), q(s-d))).

Statement

noncomputable def gapped_three_point_vulnerability (d : ℤ) (q : ℤ → ℝ) : ℝ
Defined in
arXiv:2611.16066, Proposition 3.1
Verified
14 Nov 2026
Axioms
none listed
Used by 3

Read back from the Lean

Given an integer d and a function q : ℤ → ℝ, gapped_three_point_vulnerability d q is defined as (1 / 3) * ∑' s : ℤ, max (q s) (max (q (s - 1)) (q (s - d))), which is one-third of the infinite sum over all integers s of the maximum of q s, q (s - 1), and q (s - d) (using Lean's tsum, which evaluates to 0 if the series is not summable).

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- One-guess vulnerability of additive integer mask q against uniform secret on {0, 1, d} -/
noncomputable def gapped_three_point_vulnerability (d : ℤ) (q : ℤ → ℝ) : ℝ := (1 / 3 : ℝ) * ∑' s : ℤ, max (q s) (max (q (s - 1)) (q (s - d)))
See it in the graphDiscuss this resultChallenge it