Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

The finite adaptive code identifies exactly the adaptive atoms

Proved
NarrowDNF.ConditionalExpectation.adaptiveCode_eq_iff

by chenghua.liu · Nov 13, 2026 · Mathlib 0df444a (Lean v4.33.1)

combinatoricsnarrow-dnf-authors-importprobabilitystoc-2027

Let III be finite and JJJ a local activation family: whether a subset SSS fires depends only on the input coordinates in SSS. For an input xxx, let AJ(x)A_J(x)AJ​(x) be the union of all firing subsets. Define zJ(x)z_J(x)zJ​(x) to equal xxx on AJ(x)A_J(x)AJ​(x) and zero outside it, and encode the input as cJ(x)=(AJ(x),zJ(x))c_J(x)=(A_J(x),z_J(x))cJ​(x)=(AJ​(x),zJ​(x)). For all inputs x,yx,yx,y,

cJ(x)=cJ(y)  ⟺  AJ(x)=AJ(y) and x∣AJ(x)=y∣AJ(x).c_J(x)=c_J(y)\iff A_J(x)=A_J(y)\ \text{and}\ x|_{A_J(x)}=y|_{A_J(x)}.cJ​(x)=cJ​(y)⟺AJ​(x)=AJ​(y) and x∣AJ​(x)​=y∣AJ​(x)​.

Thus this finite code realizes exactly the adaptive partition specified by the active set and its observed labels.

Preamble
import Mathlib.Algebra.BigOperators.Ring.Finset
import Mathlib.Algebra.Order.BigOperators.Ring.Finset
import Mathlib.Data.Bool.Basic
import Mathlib.Data.Finset.Lattice.Fold
import Mathlib.Data.Fintype.BigOperators
import Mathlib.Data.Fintype.Pi
import Mathlib.Data.Real.Basic
import Mathlib.Logic.Equiv.Prod
import Mathlib.Order.Monotone.Basic
import Mathlib.Tactic.FieldSimp
import Mathlib.Tactic.Linarith
import Mathlib.Tactic.Ring
import Definitions.Def_NarrowDNF_Adaptive
import Definitions.Def_NarrowDNF_ConditionalExpectation
import Definitions.Def_NarrowDNF_ProductMeasure

namespace NarrowDNF.ConditionalExpectation
end NarrowDNF.ConditionalExpectation

namespace NarrowDNF.ProductMeasure
end NarrowDNF.ProductMeasure
noncomputable section
open scoped BigOperators
open NarrowDNF
open NarrowDNF.ConditionalExpectation
variable {α β : Type*} [Fintype α] [Fintype β] [DecidableEq β]
section Adaptive
variable {ι : Type*} [Fintype ι] [DecidableEq ι]
omit [DecidableEq ι]
Formal statement
theorem NarrowDNF.ConditionalExpectation.adaptiveCode_eq_iff (J : Activation ι) (x y : Cube ι) :
    adaptiveCode J x = adaptiveCode J y ↔ J.SameAtom x y := by sorry
Source
https://github.com/liuchliuch/narrow-dnf-lean/blob/eecadd6a5ea0a331d6cf9fd5cb39fc6ec854b372/NarrowDNF/ConditionalExpectation.lean#L255-L282

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me