AFTD Auto-Formalizing Theoretical Domains

CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval

theoremverifiedimported Lean

Marginal of a coordinate integral over a product space. Let $\iota$ be a finite index type and let $\Omega$ be a finite probability space, so that the product $\Omega^{\iota}$ of copies of $\Omega$ indexed by $\iota$ carries the corresponding product probability measure. Fix an index $i \in \iota$ and a function $f : \Omega \to \bbr$. Then integrating the map $\omega_{\bullet} \mapsto f(\omega_i)$ against the product measure on $\Omega^{\iota}$ gives the same value as integrating $f$ against the measure on $\Omega$: \[ \int_{\Omega^{\iota}} f(\omega_i) \, d\omega_{\bullet} \;=\; \int_{\Omega} f(\omega)\, d\omega. \]

Statement

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
open MeasureTheory in
open scoped ProbabilityTheory in
theorem CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval
    {ι Ω : Type*} [Fintype ι] [FiniteProbabilitySpace Ω]
    (i : ι) (f : Ω → ℝ) :
    ∫ ωs : (j : ι) → Ω, f (ωs i) = ∫ ω, f ω
Source
TCSlib, `CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval`
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.
What was changed in CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval
--- TCSlib/CommunicationComplexity/NewmanTheorem/FiniteProbabilitySpace.lean:451 (CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval)
+++ as compiled here
@@ -1,4 +1,6 @@
-/-- Integrating a function over a coordinate of a finite product space is the same as
-integrating it over the original finite probability space. -/
-theorem integral_comp_eval
+set_option relaxedAutoImplicit false in
+set_option autoImplicit false in
+open MeasureTheory in
+open scoped ProbabilityTheory in
+theorem CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval
     {ι Ω : Type*} [Fintype ι] [FiniteProbabilitySpace Ω]
@@ -13,2 +15,2 @@
       Measurable.of_discrete.aestronglyMeasurable).symm
-  simpa [ν, hmap.map_eq] using h1
+  simpa [ν, hmap.map_eq, MeasureTheory.volume_pi] using h1
Verified
07 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Built on 1
Used by 1

Lean source view module on GitHub

set_option relaxedAutoImplicit false inset_option autoImplicit false inopen MeasureTheory inopen scoped ProbabilityTheory in/-- Integrating a function over a coordinate of a finite product space is the same as integrating it over the original finite probability space. -/theorem CommunicationComplexity.FiniteProbabilitySpace.integral_comp_eval    {ι Ω : Type*} [Fintype ι] [FiniteProbabilitySpace Ω]    (i : ι) (f : Ω → ℝ) :    ∫ ωs : (j : ι) → Ω, f (ωs i) = ∫ ω, f ω := by  let ν : Measure ((j : ι) → Ω) := Measure.pi fun _ : ι => (volume : Measure Ω)  have hmap := measurePreserving_eval (μ := fun (_ : ι) => (volume : Measure Ω)) i  have h1 :      ∫ ωs : (j : ι) → Ω, f (ωs i) ∂ν =        ∫ ω, f ω ∂(Measure.map (Function.eval i) ν) :=    (integral_map (measurable_pi_apply i).aemeasurable      Measurable.of_discrete.aestronglyMeasurable).symm  simpa [ν, hmap.map_eq, MeasureTheory.volume_pi] using h1
See it in the graphDiscuss this resultChallenge it