Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 3: every mechanism has rank MMM

Proved
ObjectCentric.mechanism_rank_eq_slot_dim

by Xeroth · Nov 23, 2026 · Mathlib 0df444a (Lean v4.33.1)

identifiabilityjacobian-rankobject-centric-learningrepresentation-learning

Let K≥0K\ge0K≥0 and M≥1M\ge1M≥1, let Z=(RM)K\mathcal Z=(\mathbb R^M)^KZ=(RM)K and let X⊆RN\mathcal X\subseteq\mathbb R^NX⊆RN. Let f:Z→X\mathbf f:\mathcal Z\to\mathcal Xf:Z→X be a diffeomorphism with inverse g\mathbf gg that is compositional. Then every mechanism has rank equal to the slot dimension: for all z∈Z\mathbf z\in\mathcal Zz∈Z and k∈[K]k\in[K]k∈[K],

rank⁡JfIk(z)=M.\operatorname{rank}\mathbf J\mathbf f_{I_k}(\mathbf z)=M.rankJfIk​​(z)=M.

Formalization Note The slot dimension is assumed to satisfy M≥1M\ge1M≥1, which the paper takes for granted (each slot encodes MMM object properties). This statement does not need it: for M=0M=0M=0 every rank in it is 000 and it still holds.

Preamble
import Mathlib
import Definitions.Def_ObjectCentric_Basic

open MeasureTheory
Formal statement
namespace ObjectCentric

theorem mechanism_rank_eq_slot_dim {K M N : ℕ} (hM : 0 < M)
    (X : Set (Obs N)) (f : Lat K M → Obs N) (g : Obs N → Lat K M) (hf : IsDiffeoWithInv f g X)
    (hfc : IsCompositional f) :
    ∀ (z : Lat K M) (k : Fin K), subRank f z (indexSet f z k) = M := by sorry

end ObjectCentric
Source
Brady, Zimmermann, Sharma, Schölkopf, von Kügelgen and Brendel, Provably Learning Object-Centric Representations, ICML 2023, arXiv:2305.14229v1 (2023), Appendix A, Lemma 3, p. 15
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

Fix natural numbers KKK (number of slots), MMM (dimension of each slot) and NNN (number of pixels), and assume M>0M > 0M>0. The latent space is

Z=(RM)K,Z = (\mathbb{R}^M)^K,Z=(RM)K,

whose elements zzz assign to each slot k∈{1,…,K}k \in \{1,\dots,K\}k∈{1,…,K} a vector zk∈RMz_k \in \mathbb{R}^Mzk​∈RM. The pixel space is RN\mathbb{R}^NRN, with pixel nnn of xxx written xnx_nxn​.

Let X⊆RNX \subseteq \mathbb{R}^NX⊆RN be any set, and let f:Z→RNf : Z \to \mathbb{R}^Nf:Z→RN and g:RN→Zg : \mathbb{R}^N \to Zg:RN→Z be arbitrary functions satisfying two hypotheses.

Hypothesis 1: diffeomorphism with inverse. This means all of the following hold:

  • fff is continuously differentiable (C1C^1C1) on all of ZZZ;
  • ggg is C1C^1C1 on the set XXX (in the "within XXX" sense; nothing is required of ggg outside XXX);
  • the image of fff is exactly XXX, i.e. f(Z)=Xf(Z) = Xf(Z)=X;
  • g(f(z))=zg(f(z)) = zg(f(z))=z for every z∈Zz \in Zz∈Z. In particular, fff is injective.

Hypothesis 2: compositionality. For every z∈Zz \in Zz∈Z and every pair of distinct slots k≠jk \neq jk=j, the index sets Ik(z)I_k(z)Ik​(z) and Ij(z)I_j(z)Ij​(z) are disjoint. Here

Ik(z)={ n∈{1,…,N}  :  ∂fn∂zk(z)≠0∈RM }.I_k(z) = \Big\{\, n \in \{1,\dots,N\} \;:\; \tfrac{\partial f_n}{\partial z_k}(z) \neq 0 \in \mathbb{R}^M \,\Big\}.Ik​(z)={n∈{1,…,N}:∂zk​∂fn​​(z)=0∈RM}.

This is the set of pixels whose vector of partial derivatives with respect to the MMM coordinates of slot kkk, evaluated at zzz, is not identically zero.

The partial derivatives come from the Jacobian Jf(z)J f(z)Jf(z). This is the N×KMN \times KMN×KM real matrix whose row nnn and column (i,m)(i, m)(i,m) is

∂fn∂zi,m(z),\frac{\partial f_n}{\partial z_{i,m}}(z),∂zi,m​∂fn​​(z),

the derivative of fff at zzz applied to the standard basis vector for coordinate mmm of slot iii, read off at pixel nnn.

Conclusion. For every z∈Zz \in Zz∈Z and every slot kkk, consider the submatrix JfIk(z)(z)J f_{I_k(z)}(z)JfIk​(z)​(z). It is formed by keeping only the rows of Jf(z)J f(z)Jf(z) indexed by pixels in Ik(z)I_k(z)Ik​(z), and keeping all KMKMKM columns, i.e. columns for every slot, not only slot kkk. The theorem asserts that this submatrix has rank exactly MMM:

rank⁡JfIk(z)(z)=Mfor all z∈Z, k∈{1,…,K}.\operatorname{rank} J f_{I_k(z)}(z) = M \quad \text{for all } z \in Z,\ k \in \{1,\dots,K\}.rankJfIk​(z)​(z)=Mfor all z∈Z, k∈{1,…,K}.

Edge cases.

  • If K=0K = 0K=0, there are no slots and the conclusion holds vacuously.
  • If N=0N = 0N=0, injectivity of fff forces ZZZ to be a single point. Since M>0M > 0M>0, this can only happen when K=0K = 0K=0.
  • The function ggg does not appear in the conclusion. It enters only through the requirement that fff has a left inverse that is C1C^1C1 on X=f(Z)X = f(Z)X=f(Z).
Human review
  • Endorsed by Shuze Chen · Nov 23, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Xeroth · Nov 23, 2026

    Confirmed by the mission captain (proposal self-audit).

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