AFTD Auto-Formalizing Theoretical Domains

CommunicationComplexity.Deterministic.FiniteMessage.Protocol.toProtocol_run

theoremverifiedimported Lean

Conversion to binary protocol preserves output. Let $p$ be a finite-message deterministic two-party protocol over input types $X$ and $Y$ with output type $\alpha$, and let $q$ be the binary protocol obtained by converting $p$ (encoding each message drawn from a finite nonempty type $\beta$ as $\lceil \log_2 \abs{\beta} \rceil$ bits). Then $q$ computes the same function as $p$: for every pair of inputs $x \in X$ and $y \in Y$, running $q$ on $(x, y)$ returns the same value in $\alpha$ as running $p$ on $(x, y)$.

Statement

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
variable {X Y α : Type*} in
@[simp]
theorem CommunicationComplexity.Deterministic.FiniteMessage.Protocol.toProtocol_run (p : Protocol X Y α) :
    (toProtocol p).run = p.run
Source
TCSlib, `CommunicationComplexity.Deterministic.FiniteMessage.Protocol.toProtocol_run`
Lean proof
By Lucy Horowitz, Timothe Kasriel, Mihir Singhal, from github.com/Shilun-Allan-Li/tcslib at c8a02591b1e5 (Copyright (c) 2026 Lucy Horowitz, Timothe Kasriel, and Mihir Singhal. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.25.0.
Verified
07 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Built on 8
Used by 35

Lean source view module on GitHub

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
variable {X Y α : Type*} in
/-- The binary protocol obtained from a finite-message protocol has the same outcome function. -/
@[simp]
theorem CommunicationComplexity.Deterministic.FiniteMessage.Protocol.toProtocol_run (p : Protocol X Y α) :
    (toProtocol p).run = p.run :=
  (toProtocol_exists p).choose_spec.1
See it in the graphDiscuss this resultChallenge it