Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Conditionally factorial exponential-family latent model, observed law and the relations ∼\sim∼, ∼A\sim_A∼A​, ∼P\sim_P∼P​

Definition
IdentifiableVAE_Basic

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

exponential-familiesidentifiabilitynonlinear-icavariational-autoencoders

Objects of Sections 3.1 and 4 of Khemakhem, Kingma, Monti and Hyvärinen (AISTATS 2020).

  1. Parameters. A parameter θ=(f,Q,T,λ)\theta=(f,Q,T,\lambda)θ=(f,Q,T,λ) consists of a mixing function f:Rn→Rdf:\mathbb{R}^n\to\mathbb{R}^df:Rn→Rd, base measures Qi:R→RQ_i:\mathbb{R}\to\mathbb{R}Qi​:R→R, sufficient statistics Ti,j:R→RT_{i,j}:\mathbb{R}\to\mathbb{R}Ti,j​:R→R and natural parameters λi,j:Rm→R\lambda_{i,j}:\mathbb{R}^m\to\mathbb{R}λi,j​:Rm→R, for 1≤i≤n1\le i\le n1≤i≤n and 1≤j≤k1\le j\le k1≤j≤k. The paper writes θ=(f,T,λ)\theta=(f,T,\lambda)θ=(f,T,λ).
  2. Prior (eq. 7). Zi(u)=∫RQi(t)exp⁡(∑jTi,j(t)λi,j(u)) dtZ_i(u)=\int_{\mathbb{R}}Q_i(t)\exp\big(\sum_jT_{i,j}(t)\lambda_{i,j}(u)\big)\,dtZi​(u)=∫R​Qi​(t)exp(∑j​Ti,j​(t)λi,j​(u))dt and pT,λ(z∣u)=∏i=1nQi(zi)Zi(u)exp⁡(∑j=1kTi,j(zi)λi,j(u))p_{T,\lambda}(z\mid u)=\prod_{i=1}^n\frac{Q_i(z_i)}{Z_i(u)}\exp\big(\sum_{j=1}^kT_{i,j}(z_i)\lambda_{i,j}(u)\big)pT,λ​(z∣u)=∏i=1n​Zi​(u)Qi​(zi​)​exp(∑j=1k​Ti,j​(zi​)λi,j​(u)). The prior law of zzz given uuu is Lebesgue measure on Rn\mathbb{R}^nRn with this density.
  3. Observations (eqs. 5, 6). x=f(z)+εx=f(z)+\varepsilonx=f(z)+ε, where the noise ε∼Pε\varepsilon\sim P_\varepsilonε∼Pε​ is independent of zzz. The conditional law pθ(x∣u)p_\theta(x\mid u)pθ​(x∣u) is the convolution of the push-forward of the prior by fff with PεP_\varepsilonPε​.
  4. Admissible parameters. Let U⊂RmU\subset\mathbb{R}^mU⊂Rm be the support of uuu. Then θ\thetaθ describes a model on UUU if fff is measurable and injective, every QiQ_iQi​ is measurable and positive, every Ti,jT_{i,j}Ti,j​ is measurable, and every factor of the prior is integrable, so that Zi(u)<∞Z_i(u)<\inftyZi​(u)<∞ for every u∈Uu\in Uu∈U.
  5. Relations (Definition 2, eq. 13). Write T(z)=(T1,1(z1),…,Tn,k(zn))∈Rnk\mathbf T(z)=(T_{1,1}(z_1),\dots,T_{n,k}(z_n))\in\mathbb{R}^{nk}T(z)=(T1,1​(z1​),…,Tn,k​(zn​))∈Rnk. Then θ∼θ~\theta\sim\tilde\thetaθ∼θ~ if there are an nk×nknk\times nknk×nk matrix AAA and c∈Rnkc\in\mathbb{R}^{nk}c∈Rnk such that for every zzz there is z~\tilde zz~ with f~(z~)=f(z)\tilde f(\tilde z)=f(z)f~​(z~)=f(z) and T(z)=AT~(z~)+c\mathbf T(z)=A\tilde{\mathbf T}(\tilde z)+cT(z)=AT~(z~)+c. This is T(f−1(x))=AT~(f~−1(x))+c\mathbf T(f^{-1}(x))=A\tilde{\mathbf T}(\tilde f^{-1}(x))+cT(f−1(x))=AT~(f~​−1(x))+c for all x∈f(Rn)x\in f(\mathbb{R}^n)x∈f(Rn). The relation ∼A\sim_A∼A​ requires AAA invertible. The relation ∼P\sim_P∼P​ requires AAA invertible and block-permutation: for some permutation σ\sigmaσ, the rows of block iii vanish outside the columns of block σ(i)\sigma(i)σ(i). The almost-everywhere versions of ∼,∼A,∼P\sim,\sim_A,\sim_P∼,∼A​,∼P​ ask the same for Lebesgue-almost every zzz only.
  6. Identifiability (Definition 1). θ\thetaθ is identifiable up to a relation RRR within a class Θ\ThetaΘ if every θ~∈Θ\tilde\theta\in\Thetaθ~∈Θ with pθ(⋅∣u)=pθ~(⋅∣u)p_\theta(\cdot\mid u)=p_{\tilde\theta}(\cdot\mid u)pθ​(⋅∣u)=pθ~​(⋅∣u) for all u∈Uu\in Uu∈U satisfies θRθ~\theta\mathrel R\tilde\thetaθRθ~.
  7. Assumptions.
    • (i): {ω∈Rd:φε(ω)=0}\{\omega\in\mathbb{R}^d:\varphi_\varepsilon(\omega)=0\}{ω∈Rd:φε​(ω)=0} is Lebesgue-null, where φε\varphi_\varepsilonφε​ is the characteristic function of the noise.
    • (iii): each Ti,jT_{i,j}Ti,j​ is differentiable almost everywhere, and no nonzero α∈Rk\alpha\in\mathbb{R}^kα∈Rk makes ∑jαjTi,j\sum_j\alpha_jT_{i,j}∑j​αj​Ti,j​ constant on a set of positive measure.
    • (iv), eq. (14): there are distinct u0,…,unk∈Uu^0,\dots,u^{nk}\in Uu0,…,unk∈U such that L=(λ(u1)−λ(u0),…,λ(unk)−λ(u0))L=(\lambda(u^1)-\lambda(u^0),\dots,\lambda(u^{nk})-\lambda(u^0))L=(λ(u1)−λ(u0),…,λ(unk)−λ(u0)) is invertible.
    • (2.i): each Ti,jT_{i,j}Ti,j​ is twice differentiable.
    • (2.ii): fff has all first partial derivatives and all second cross derivatives ∂2f/∂zs∂zt\partial^2f/\partial z_s\partial z_t∂2f/∂zs​∂zt​, s≠ts\ne ts=t.
    • (3.i): no Ti,1T_{i,1}Ti,1​ is strictly increasing or strictly decreasing.
    • (3.ii): all partial derivatives of fff exist and are continuous.
    • Proof of Theorem 3: fff is a C1C^1C1 embedding with injective differential at every point. A function g:R→Rg:\mathbb{R}\to\mathbb{R}g:R→R has isolated turning points if every ttt has a punctured neighbourhood on each side of which ggg is strictly monotonic.

Formalization Note The latent domain is Rn\mathbb{R}^nRn, the default domain of Appendix A. Observations live in EuclideanSpace ℝ (Fin d) so that Mathlib's characteristic function applies. The base measures QiQ_iQi​ are part of the parameter because the proofs let Q~i\tilde Q_iQ~​i​ differ from QiQ_iQi​. Assumption (iii) is read as linear independence of Ti,1,…,Ti,kT_{i,1},\dots,T_{i,k}Ti,1​,…,Ti,k​ together with the constant function, on subsets of the latent coordinate line. The almost-everywhere relations are what the proofs establish.

Definition code
import Mathlib

/-!
Khemakhem, Kingma, Monti and Hyvärinen, *Variational Autoencoders and Nonlinear ICA: A Unifying
Framework*, AISTATS 2020, arXiv:1907.04809v4: the conditional generative model (5)-(7) of
Section 3.1, its observed conditional law, the assumptions of Theorems 1-3 and 6, identifiability
up to an equivalence relation (Definition 1) and the relations `∼`, `∼_A`, `∼_P` of Definition 2
(Section 4.1).

Latent vectors are `z : Fin n → ℝ` (the latent domain is `ℝⁿ`, the default domain of
Appendix A), observations live in `EuclideanSpace ℝ (Fin d)`, auxiliary variables are
`u : Fin m → ℝ`, and the vector of sufficient statistics is indexed by `Fin n × Fin k`.
-/

open MeasureTheory

noncomputable section

namespace IdentifiableVAE

/-- Section 3.1, eqs. (5)-(7), and Section 4 "Notations": the parameters of the conditional
generative model `p_θ(x, z | u) = p_f(x | z) p_{T,λ}(z | u)`: the mixing function
`f : ℝⁿ → ℝᵈ`, the base measures `Q_i`, the sufficient statistics `T_{i,j}` and the natural
parameters `λ_{i,j}(u)`. The paper writes `θ = (f, T, λ)`; the base measures `Q_i` of eq. (7)
are carried with the parameter because the proofs (eq. (29)) allow `Q̃_i ≠ Q_i`. -/
structure Param (n d m k : ℕ) where
  /-- The mixing function `f` of eq. (6). -/
  f : (Fin n → ℝ) → EuclideanSpace ℝ (Fin d)
  /-- The base measures `Q_i` of eq. (7). -/
  Q : Fin n → ℝ → ℝ
  /-- The sufficient statistics `T_{i,j}` of eq. (7). -/
  T : Fin n → Fin k → ℝ → ℝ
  /-- The natural parameters `λ_{i,j}(u)` of eq. (7). -/
  lam : (Fin m → ℝ) → Fin n → Fin k → ℝ

variable {n d m k : ℕ}

/-- Eq. (7): the exponent `∑_j T_{i,j}(t) λ_{i,j}(u)` of the `i`-th latent factor. -/
def expoTerm (θ : Param n d m k) (u : Fin m → ℝ) (i : Fin n) (t : ℝ) : ℝ :=
  ∑ j, θ.T i j t * θ.lam u i j

/-- Eq. (7): the unnormalised `i`-th factor `Q_i(t) exp(∑_j T_{i,j}(t) λ_{i,j}(u))`. -/
def unnormFactor (θ : Param n d m k) (u : Fin m → ℝ) (i : Fin n) (t : ℝ) : ℝ :=
  θ.Q i t * Real.exp (expoTerm θ u i t)

/-- Eq. (7): the normalising constant `Z_i(u) = ∫ Q_i(t) exp(∑_j T_{i,j}(t) λ_{i,j}(u)) dt`. -/
def normConst (θ : Param n d m k) (u : Fin m → ℝ) (i : Fin n) : ℝ :=
  ∫ t, unnormFactor θ u i t

/-- Eq. (7): the conditionally factorial exponential-family prior density
`p_{T,λ}(z | u) = ∏_i Q_i(z_i) / Z_i(u) · exp(∑_j T_{i,j}(z_i) λ_{i,j}(u))`. -/
def priorDensity (θ : Param n d m k) (u : Fin m → ℝ) (z : Fin n → ℝ) : ℝ :=
  ∏ i, unnormFactor θ u i (z i) / normConst θ u i

/-- Eq. (7): the prior law of `z` given `u`, i.e. Lebesgue measure on `ℝⁿ` with density
`p_{T,λ}(z | u)`. -/
def priorMeasure (θ : Param n d m k) (u : Fin m → ℝ) : Measure (Fin n → ℝ) :=
  volume.withDensity fun z => ENNReal.ofReal (priorDensity θ u z)

/-- Eqs. (5), (6), (21) and (24): the conditional law `p_θ(x | u)` of the observation
`x = f(z) + ε`, with `z ∼ p_{T,λ}(· | u)` and the noise `ε ∼ P_ε` independent of `z`: the
convolution of the push-forward of the prior by `f` with the noise law. -/
def obsLaw (Pε : Measure (EuclideanSpace ℝ (Fin d))) (θ : Param n d m k) (u : Fin m → ℝ) :
    Measure (EuclideanSpace ℝ (Fin d)) :=
  Measure.conv ((priorMeasure θ u).map θ.f) Pε

/-- Section 3.1 and Section 4 "Notations": `θ` describes a model (5)-(7) when the auxiliary
variable ranges over its support `U`: `f` is measurable and injective, each `Q_i` is measurable
and positive (the proofs take `log Q_i` in eq. (29)), each `T_{i,j}` is measurable, and every
factor of eq. (7) is integrable, so that `Z_i(u)` is finite for every `u ∈ U`. -/
structure IsParam (θ : Param n d m k) (U : Set (Fin m → ℝ)) : Prop where
  measurable_f : Measurable θ.f
  injective_f : Function.Injective θ.f
  measurable_Q : ∀ i, Measurable (θ.Q i)
  pos_Q : ∀ i t, 0 < θ.Q i t
  measurable_T : ∀ i j, Measurable (θ.T i j)
  integrable_factor : ∀ u ∈ U, ∀ i, Integrable (unnormFactor θ u i)

/-- Section 4 "Notations": the vector of sufficient statistics
`T(z) = (T_{1,1}(z_1), …, T_{n,k}(z_n)) ∈ ℝ^{nk}`, indexed by `Fin n × Fin k`. -/
def suffStat (θ : Param n d m k) (z : Fin n → ℝ) : Fin n × Fin k → ℝ :=
  fun p => θ.T p.1 p.2 (z p.1)

/-- Definition 2, eq. (13): `T(f⁻¹(x)) = A T̃(f̃⁻¹(x)) + c` for every `x ∈ X = f(ℝⁿ)`,
written over `z = f⁻¹(x)`: for every latent `z` there is `z̃ = f̃⁻¹(f(z))` with
`T(z) = A T̃(z̃) + c`. -/
def LinRel (θ θ' : Param n d m k) (A : Matrix (Fin n × Fin k) (Fin n × Fin k) ℝ)
    (c : Fin n × Fin k → ℝ) : Prop :=
  ∀ z, ∃ z', θ'.f z' = θ.f z ∧ suffStat θ z = A.mulVec (suffStat θ' z') + c

/-- The almost-everywhere form of eq. (13), which is what the proofs of Theorems 1-3 and 6 in
Appendices B and E establish: for Lebesgue-almost every latent `z` there is `z̃ = f̃⁻¹(f(z))`
with `T(z) = A T̃(z̃) + c`. -/
def LinRelAE (θ θ' : Param n d m k) (A : Matrix (Fin n × Fin k) (Fin n × Fin k) ℝ)
    (c : Fin n × Fin k → ℝ) : Prop :=
  ∀ᵐ z ∂(volume : Measure (Fin n → ℝ)), ∃ z', θ'.f z' = θ.f z ∧
    suffStat θ z = A.mulVec (suffStat θ' z') + c

/-- Definition 2, footnote 4: `A` is a block permutation matrix, i.e. there is a permutation
`σ` of `{1, …, n}` such that the block of rows of `T_i` only has nonzero entries in the block of
columns of `T̃_{σ(i)}`. -/
def IsBlockPerm (A : Matrix (Fin n × Fin k) (Fin n × Fin k) ℝ) : Prop :=
  ∃ σ : Equiv.Perm (Fin n), ∀ i l a b, a ≠ σ i → A (i, l) (a, b) = 0

/-- Definition 2, eq. (13): the relation `∼` (an arbitrary `nk × nk` matrix `A`). -/
def Sim (θ θ' : Param n d m k) : Prop :=
  ∃ A c, LinRel θ θ' A c

/-- Definition 2: the relation `∼_A` (eq. (13) with `A` invertible). -/
def SimA (θ θ' : Param n d m k) : Prop :=
  ∃ A c, IsUnit A ∧ LinRel θ θ' A c

/-- Definition 2: the relation `∼_P` (eq. (13) with `A` an invertible block permutation
matrix). -/
def SimP (θ θ' : Param n d m k) : Prop :=
  ∃ A c, IsUnit A ∧ IsBlockPerm A ∧ LinRel θ θ' A c

/-- The relation `∼` of Definition 2 in the almost-everywhere form established by the proofs. -/
def SimAE (θ θ' : Param n d m k) : Prop :=
  ∃ A c, LinRelAE θ θ' A c

/-- The relation `∼_A` of Definition 2 in the almost-everywhere form established by the
proofs. -/
def SimAAE (θ θ' : Param n d m k) : Prop :=
  ∃ A c, IsUnit A ∧ LinRelAE θ θ' A c

/-- The relation `∼_P` of Definition 2 in the almost-everywhere form established by the
proofs. -/
def SimPAE (θ θ' : Param n d m k) : Prop :=
  ∃ A c, IsUnit A ∧ IsBlockPerm A ∧ LinRelAE θ θ' A c

/-- Definition 1, eq. (12), for one parameter: `θ` is identifiable up to `rel` within the
parameter class `Θ` if every `θ̃ ∈ Θ` with the same observed conditional laws
`p_θ(x | u) = p_θ̃(x | u)` for all `u ∈ U` is related to `θ`. -/
def IdentifiableUpTo (Pε : Measure (EuclideanSpace ℝ (Fin d))) (U : Set (Fin m → ℝ))
    (Θ : Set (Param n d m k)) (rel : Param n d m k → Param n d m k → Prop)
    (θ : Param n d m k) : Prop :=
  ∀ θ' ∈ Θ, (∀ u ∈ U, obsLaw Pε θ u = obsLaw Pε θ' u) → rel θ θ'

/-- Theorem 1, assumption (i): the zero set `{ω | φ_ε(ω) = 0}` of the characteristic function
of the noise has Lebesgue measure zero. -/
def CharFunZeroNull (Pε : Measure (EuclideanSpace ℝ (Fin d))) : Prop :=
  volume {ω : EuclideanSpace ℝ (Fin d) | charFun Pε ω = 0} = 0

/-- Theorem 1, assumption (iii): every `T_{i,j}` is differentiable almost everywhere, and for
every `i` the statistics `T_{i,1}, …, T_{i,k}` are linearly independent, together with the
constants, on every subset of `ℝ` of positive measure: no nonzero `α` makes
`∑_j α_j T_{i,j}` constant on such a set. -/
def SuffStatRegular (θ : Param n d m k) : Prop :=
  (∀ i j, ∀ᵐ t ∂(volume : Measure ℝ), DifferentiableAt ℝ (θ.T i j) t) ∧
    ∀ i (S : Set ℝ), 0 < volume S → ∀ (α : Fin k → ℝ) (α₀ : ℝ),
      (∀ t ∈ S, ∑ j, α j * θ.T i j t = α₀) → α = 0

/-- Theorem 1, assumption (iv), eq. (14): there are `nk + 1` distinct points
`u⁰, …, u^{nk}` of `U` such that the `nk × nk` matrix
`L = (λ(u¹) - λ(u⁰), …, λ(u^{nk}) - λ(u⁰))` is invertible. The points `u¹, …, u^{nk}` are
indexed by `Fin n × Fin k`, and so are the columns of `L`. -/
def HasInvertibleL (θ : Param n d m k) (U : Set (Fin m → ℝ)) : Prop :=
  ∃ (u₀ : Fin m → ℝ) (u : Fin n × Fin k → Fin m → ℝ), u₀ ∈ U ∧ (∀ p, u p ∈ U) ∧
    Function.Injective u ∧ (∀ p, u p ≠ u₀) ∧
    (Matrix.of fun r p : Fin n × Fin k => θ.lam (u p) r.1 r.2 - θ.lam u₀ r.1 r.2).det ≠ 0

/-- Theorem 2, assumption (2.i): every sufficient statistic `T_{i,j}` is twice
differentiable. -/
def TwiceDiffStats (θ : Param n d m k) : Prop :=
  ∀ i j, Differentiable ℝ (θ.T i j) ∧ Differentiable ℝ (deriv (θ.T i j))

/-- Theorem 2, assumption (2.ii): the mixing function `f` has all first partial derivatives
and all second-order cross derivatives `∂²f / ∂z_s ∂z_t`, `s ≠ t`, at every point. -/
def HasSecondCrossPartials (f : (Fin n → ℝ) → EuclideanSpace ℝ (Fin d)) : Prop :=
  (∀ t z, LineDifferentiableAt ℝ f z (Pi.single t 1)) ∧
    ∀ s t z, s ≠ t →
      LineDifferentiableAt ℝ (fun w => lineDeriv ℝ f w (Pi.single t 1)) z (Pi.single s 1)

/-- Theorem 3, assumption (3.ii): all partial derivatives `∂f / ∂z_t` of the mixing function
exist everywhere and are continuous. -/
def HasContinuousPartials (f : (Fin n → ℝ) → EuclideanSpace ℝ (Fin d)) : Prop :=
  ∀ t, (∀ z, LineDifferentiableAt ℝ f z (Pi.single t 1)) ∧
    Continuous fun z => lineDeriv ℝ f z (Pi.single t 1)

/-- Theorem 3, assumption (3.i) with footnote 5: no sufficient statistic `T_{i,1}` is monotonic,
where monotonic means strictly increasing or strictly decreasing. -/
def NotMonotoneStats (θ : Param n d m 1) : Prop :=
  ∀ i, ¬ StrictMono (θ.T i 0) ∧ ¬ StrictAnti (θ.T i 0)

/-- Proof of Theorem 3 (Appendix B.4: "by hypothesis, `v_i` is of class `C¹`, and its Jacobian
is non-zero everywhere"): `f` is a `C¹` embedding with injective differential. For two such
mixing functions with the same image, `f̃⁻¹ ∘ f` is a `C¹` diffeomorphism of `ℝⁿ`. -/
def IsC1Embedding (f : (Fin n → ℝ) → EuclideanSpace ℝ (Fin d)) : Prop :=
  ContDiff ℝ 1 f ∧ Topology.IsEmbedding f ∧ ∀ z, Function.Injective (fderiv ℝ f z)

/-- Proof of Theorem 3 (Appendix B.4: "we can choose `U` such that `T_i` has only one minimum"):
the turning points of `g` are isolated, i.e. every `t` has a punctured neighbourhood on each side
of which `g` is strictly monotone. -/
def IsolatedTurningPoints (g : ℝ → ℝ) : Prop :=
  ∀ t, ∃ δ > 0,
    (StrictMonoOn g (Set.Ioo (t - δ) t) ∨ StrictAntiOn g (Set.Ioo (t - δ) t)) ∧
    (StrictMonoOn g (Set.Ioo t (t + δ)) ∨ StrictAntiOn g (Set.Ioo t (t + δ)))

end IdentifiableVAE
Source
Khemakhem, Kingma, Monti and Hyvärinen, Variational Autoencoders and Nonlinear ICA: A Unifying Framework, AISTATS 2020, arXiv:1907.04809v4, Section 3.1 eqs. (5)-(7), Section 4 Notations, Definitions 1-2 eqs. (12)-(14), Theorems 1-3 assumptions, pp. 4-6; Appendix B.2 eqs. (20)-(24), p. 13
Read-back

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

Parameter θ=(f,Q,T,λ)\theta=(f,Q,T,\lambda)θ=(f,Q,T,λ). Fix natural numbers n,d,m,kn, d, m, kn,d,m,k, any of which may be 000. A parameter θ\thetaθ is an arbitrary quadruple with no constraints of any kind:

  • a function f:Rn→Rdf:\mathbb{R}^n\to\mathbb{R}^df:Rn→Rd, the "mixing function";
  • nnn functions Q1,…,Qn:R→RQ_1,\dots,Q_n:\mathbb{R}\to\mathbb{R}Q1​,…,Qn​:R→R, the "base measures";
  • nknknk functions Ti,j:R→RT_{i,j}:\mathbb{R}\to\mathbb{R}Ti,j​:R→R for 1≤i≤n1\le i\le n1≤i≤n, 1≤j≤k1\le j\le k1≤j≤k, the "sufficient statistics";
  • a function λ:Rm→Rn×k\lambda:\mathbb{R}^m\to\mathbb{R}^{n\times k}λ:Rm→Rn×k, written u↦(λi,j(u))i,ju\mapsto(\lambda_{i,j}(u))_{i,j}u↦(λi,j​(u))i,j​, the "natural parameters".

No measurability, positivity, injectivity or integrability is part of a parameter. When a second parameter appears, it is written θ~=(f~,Q~,T~,λ~)\tilde\theta=(\tilde f,\tilde Q,\tilde T,\tilde\lambda)θ~=(f~​,Q~​,T~,λ~).

Exponent. For θ\thetaθ, u∈Rmu\in\mathbb{R}^mu∈Rm, i∈{1,…,n}i\in\{1,\dots,n\}i∈{1,…,n} and t∈Rt\in\mathbb{R}t∈R:

Eiθ(u,t)=∑j=1kTi,j(t) λi,j(u).E^\theta_i(u,t)=\sum_{j=1}^k T_{i,j}(t)\,\lambda_{i,j}(u).Eiθ​(u,t)=j=1∑k​Ti,j​(t)λi,j​(u).

When k=0k=0k=0 the sum is empty and Eiθ(u,t)=0E^\theta_i(u,t)=0Eiθ​(u,t)=0.

Unnormalised factor. With the same inputs:

giθ(u,t)=Qi(t) exp⁡(Eiθ(u,t)).g^\theta_i(u,t)=Q_i(t)\,\exp\big(E^\theta_i(u,t)\big).giθ​(u,t)=Qi​(t)exp(Eiθ​(u,t)).

Since QiQ_iQi​ is unconstrained, this may be zero or negative.

Normalising constant. This is the Lebesgue integral over the real line:

Ziθ(u)=∫Rgiθ(u,t) dt.Z^\theta_i(u)=\int_{\mathbb{R}} g^\theta_i(u,t)\,dt.Ziθ​(u)=∫R​giθ​(u,t)dt.

By convention it equals 000 whenever t↦giθ(u,t)t\mapsto g^\theta_i(u,t)t↦giθ​(u,t) is not Lebesgue-integrable. It may also be 000 or negative for integrable ggg when QiQ_iQi​ takes negative values.

Prior density. For u∈Rmu\in\mathbb{R}^mu∈Rm and z=(z1,…,zn)∈Rnz=(z_1,\dots,z_n)\in\mathbb{R}^nz=(z1​,…,zn​)∈Rn:

pθ(z∣u)=∏i=1ngiθ(u,zi)Ziθ(u).p^\theta(z\mid u)=\prod_{i=1}^n \frac{g^\theta_i(u,z_i)}{Z^\theta_i(u)}.pθ(z∣u)=i=1∏n​Ziθ​(u)giθ​(u,zi​)​.

Division by zero is defined to give 000. So if some Ziθ(u)=0Z^\theta_i(u)=0Ziθ​(u)=0, including the non-integrable case above, then pθ(⋅∣u)≡0p^\theta(\cdot\mid u)\equiv 0pθ(⋅∣u)≡0. When n=0n=0n=0 the product is empty and pθ≡1p^\theta\equiv 1pθ≡1. The value may be negative.

Prior measure. For u∈Rmu\in\mathbb{R}^mu∈Rm, πuθ\pi^\theta_uπuθ​ is the measure on Rn\mathbb{R}^nRn having density max⁡(pθ(z∣u),0)\max\big(p^\theta(z\mid u),0\big)max(pθ(z∣u),0) with respect to Lebesgue measure. Negative density values are replaced by 000. Nothing forces πuθ\pi^\theta_uπuθ​ to be a probability measure: it may be the zero measure, or have any total mass. When n=0n=0n=0, R0\mathbb{R}^0R0 is a single point carrying mass 111.

Observed law. Given an arbitrary measure PεP_\varepsilonPε​ on Rd\mathbb{R}^dRd (not required to be a probability measure), a parameter θ\thetaθ and u∈Rmu\in\mathbb{R}^mu∈Rm:

Pε,uθ=(f#πuθ)∗Pε.P^{\theta}_{\varepsilon,u}=\big(f_\#\pi^\theta_u\big)*P_\varepsilon.Pε,uθ​=(f#​πuθ​)∗Pε​.

Here:

  • f#πuθf_\#\pi^\theta_uf#​πuθ​ is the push-forward of the prior measure by fff. By convention it is the zero measure if fff is not almost-everywhere measurable for πuθ\pi^\theta_uπuθ​.
  • ∗*∗ is convolution, i.e. the push-forward of the product measure (f#πuθ)⊗Pε(f_\#\pi^\theta_u)\otimes P_\varepsilon(f#​πuθ​)⊗Pε​ under (x,y)↦x+y(x,y)\mapsto x+y(x,y)↦x+y.

Admissible parameter on UUU. Given a set U⊆RmU\subseteq\mathbb{R}^mU⊆Rm, θ\thetaθ is admissible on UUU when all of the following hold:

  1. fff is (Borel) measurable;
  2. fff is injective;
  3. each QiQ_iQi​ is measurable;
  4. each QiQ_iQi​ is strictly positive at every point of R\mathbb{R}R;
  5. each Ti,jT_{i,j}Ti,j​ is measurable;
  6. for every u∈Uu\in Uu∈U and every iii, the function t↦giθ(u,t)t\mapsto g^\theta_i(u,t)t↦giθ​(u,t) is Lebesgue-integrable on R\mathbb{R}R.

Nothing is required of λ\lambdaλ (not even measurability), and nothing is required at points u∉Uu\notin Uu∈/U. If U=∅U=\varnothingU=∅, condition 6 is vacuous. Injectivity of fff with d=0d=0d=0 forces n=0n=0n=0.

Sufficient-statistic vector. For z∈Rnz\in\mathbb{R}^nz∈Rn, Tθ(z)T^\theta(z)Tθ(z) is the vector in Rn×k\mathbb{R}^{n\times k}Rn×k, indexed by pairs (i,j)(i,j)(i,j), with entries

Tθ(z)(i,j)=Ti,j(zi).T^\theta(z)_{(i,j)}=T_{i,j}(z_i).Tθ(z)(i,j)​=Ti,j​(zi​).

Linear relation (everywhere). For parameters θ,θ~\theta,\tilde\thetaθ,θ~, a real nk×nknk\times nknk×nk matrix AAA (rows and columns indexed by pairs (i,j)(i,j)(i,j)) and c∈Rn×kc\in\mathbb{R}^{n\times k}c∈Rn×k, the relation holds when, for every z∈Rnz\in\mathbb{R}^nz∈Rn, there exists z~∈Rn\tilde z\in\mathbb{R}^nz~∈Rn with

f~(z~)=f(z)andTθ(z)=A Tθ~(z~)+c.\tilde f(\tilde z)=f(z)\quad\text{and}\quad T^\theta(z)=A\,T^{\tilde\theta}(\tilde z)+c.f~​(z~)=f(z)andTθ(z)=ATθ~(z~)+c.

In particular this requires f(Rn)⊆f~(Rn)f(\mathbb{R}^n)\subseteq\tilde f(\mathbb{R}^n)f(Rn)⊆f~​(Rn). The point z~\tilde zz~ need not be unique, and neither fff nor f~\tilde ff~​ is assumed injective.

Linear relation (almost everywhere). This is the same condition, except that it is required only for Lebesgue-almost every z∈Rnz\in\mathbb{R}^nz∈Rn. For each such zzz there exists z~\tilde zz~ with f~(z~)=f(z)\tilde f(\tilde z)=f(z)f~​(z~)=f(z) and Tθ(z)=A Tθ~(z~)+cT^\theta(z)=A\,T^{\tilde\theta}(\tilde z)+cTθ(z)=ATθ~(z~)+c. The condition may fail on a Lebesgue-null set of zzz.

Block permutation matrix. An nk×nknk\times nknk×nk matrix AAA, indexed by pairs, has this property when there is a permutation σ\sigmaσ of {1,…,n}\{1,\dots,n\}{1,…,n} such that

A(i,l),(a,b)=0whenever a≠σ(i),A_{(i,l),(a,b)}=0\quad\text{whenever } a\neq\sigma(i),A(i,l),(a,b)​=0whenever a=σ(i),

for all i,a∈{1,…,n}i,a\in\{1,\dots,n\}i,a∈{1,…,n} and l,b∈{1,…,k}l,b\in\{1,\dots,k\}l,b∈{1,…,k}. The blocks (i,σ(i))(i,\sigma(i))(i,σ(i)) are not required to be nonzero. The zero matrix qualifies, and when n=0n=0n=0 or k=0k=0k=0 every matrix qualifies.

Relations ∼\sim∼, ∼A\sim_A∼A​, ∼P\sim_P∼P​ (everywhere).

  • θ∼θ~\theta\sim\tilde\thetaθ∼θ~ means there exist a real nk×nknk\times nknk×nk matrix AAA and c∈Rn×kc\in\mathbb{R}^{n\times k}c∈Rn×k satisfying the everywhere linear relation.
  • θ∼Aθ~\theta\sim_A\tilde\thetaθ∼A​θ~ additionally requires AAA to be invertible (det⁡A≠0\det A\neq0detA=0).
  • θ∼Pθ~\theta\sim_P\tilde\thetaθ∼P​θ~ requires AAA to be both invertible and a block permutation matrix as above.

None of these relations is asserted to be symmetric, reflexive or transitive.

Relations ∼\sim∼, ∼A\sim_A∼A​, ∼P\sim_P∼P​ (almost everywhere). These are defined identically, with the almost-everywhere linear relation in place of the everywhere one:

  • existence of A,cA,cA,c;
  • existence of A,cA,cA,c with det⁡A≠0\det A\neq 0detA=0;
  • existence of A,cA,cA,c with det⁡A≠0\det A\neq0detA=0 and AAA a block permutation matrix.

Identifiability up to a relation. Fix:

  • a measure PεP_\varepsilonPε​ on Rd\mathbb{R}^dRd;
  • a set U⊆RmU\subseteq\mathbb{R}^mU⊆Rm;
  • a set Θ\ThetaΘ of parameters;
  • an arbitrary binary relation RRR on parameters;
  • a parameter θ\thetaθ.

Then θ\thetaθ is identifiable up to RRR when, for every θ~∈Θ\tilde\theta\in\Thetaθ~∈Θ,

(∀u∈U: Pε,uθ=Pε,uθ~) ⟹ R(θ,θ~).\Big(\forall u\in U:\ P^{\theta}_{\varepsilon,u}=P^{\tilde\theta}_{\varepsilon,u}\Big)\ \Longrightarrow\ R(\theta,\tilde\theta).(∀u∈U: Pε,uθ​=Pε,uθ~​) ⟹ R(θ,θ~).

Equality is equality of measures on Rd\mathbb{R}^dRd. The parameter θ\thetaθ itself is not required to lie in Θ\ThetaΘ or to be admissible. If U=∅U=\varnothingU=∅, the hypothesis is vacuous and the condition says R(θ,θ~)R(\theta,\tilde\theta)R(θ,θ~) for every θ~∈Θ\tilde\theta\in\Thetaθ~∈Θ.

Null zero set of the characteristic function. For a measure PεP_\varepsilonPε​ on Rd\mathbb{R}^dRd, define

φε(ω)=∫e i⟨ω,x⟩ dPε(x).\varphi_\varepsilon(\omega)=\int e^{\,i\langle\omega,x\rangle}\,dP_\varepsilon(x).φε​(ω)=∫ei⟨ω,x⟩dPε​(x).

The condition is that {ω∈Rd:φε(ω)=0}\{\omega\in\mathbb{R}^d:\varphi_\varepsilon(\omega)=0\}{ω∈Rd:φε​(ω)=0} has Lebesgue measure 000. If PεP_\varepsilonPε​ has infinite total mass, the integrand is not integrable and φε\varphi_\varepsilonφε​ is 000 by convention, so the condition fails. It also fails for the zero measure. When d=0d=0d=0, it holds exactly when PεP_\varepsilonPε​ has finite nonzero total mass.

Regularity of the sufficient statistics. θ\thetaθ satisfies this when both of the following hold:

  • (a) every Ti,jT_{i,j}Ti,j​ is differentiable at Lebesgue-almost every t∈Rt\in\mathbb{R}t∈R;
  • (b) for every iii, every set S⊆RS\subseteq\mathbb{R}S⊆R of positive Lebesgue (outer) measure, every α=(α1,…,αk)∈Rk\alpha=(\alpha_1,\dots,\alpha_k)\in\mathbb{R}^kα=(α1​,…,αk​)∈Rk and every α0∈R\alpha_0\in\mathbb{R}α0​∈R,
(∀t∈S: ∑j=1kαj Ti,j(t)=α0) ⟹ α=0.\Big(\forall t\in S:\ \sum_{j=1}^k\alpha_j\,T_{i,j}(t)=\alpha_0\Big)\ \Longrightarrow\ \alpha=0.(∀t∈S: j=1∑k​αj​Ti,j​(t)=α0​) ⟹ α=0.

SSS is not required to be measurable. When k=0k=0k=0, part (b) holds trivially.

Invertible matrix LLL. Given θ\thetaθ and U⊆RmU\subseteq\mathbb{R}^mU⊆Rm, the condition is that there exist a point u0∈Rmu^0\in\mathbb{R}^mu0∈Rm and a family of points up∈Rmu^{p}\in\mathbb{R}^mup∈Rm indexed by pairs p=(i′,j′)∈{1,…,n}×{1,…,k}p=(i',j')\in\{1,\dots,n\}\times\{1,\dots,k\}p=(i′,j′)∈{1,…,n}×{1,…,k} such that:

  • u0∈Uu^0\in Uu0∈U;
  • every up∈Uu^p\in Uup∈U;
  • the upu^pup are pairwise distinct;
  • each up≠u0u^p\neq u^0up=u0;
  • the nk×nknk\times nknk×nk matrix LLL with entries
L(i,j), p=λi,j(up)−λi,j(u0)L_{(i,j),\,p}=\lambda_{i,j}(u^{p})-\lambda_{i,j}(u^0)L(i,j),p​=λi,j​(up)−λi,j​(u0)

(row (i,j)(i,j)(i,j), column ppp) has det⁡L≠0\det L\neq0detL=0.

When nk=0nk=0nk=0, LLL is the empty matrix with determinant 111, and the condition reduces to U≠∅U\neq\varnothingU=∅.

Twice-differentiable statistics. For every i,ji,ji,j, the function Ti,jT_{i,j}Ti,j​ is differentiable at every point of R\mathbb{R}R, and its derivative Ti,j′T_{i,j}'Ti,j′​ is also differentiable at every point of R\mathbb{R}R. Continuity of Ti,j′′T_{i,j}''Ti,j′′​ is not required.

Second cross partials of fff. For f:Rn→Rdf:\mathbb{R}^n\to\mathbb{R}^df:Rn→Rd, write ete_tet​ for the ttt-th standard basis vector. Two conditions are required:

  • (a) For every coordinate ttt and every z∈Rnz\in\mathbb{R}^nz∈Rn, the partial derivative ∂tf(z)=ddh∣h=0f(z+het)\partial_t f(z)=\frac{d}{dh}\big|_{h=0}f(z+h e_t)∂t​f(z)=dhd​​h=0​f(z+het​) exists.
  • (b) For all coordinates s≠ts\neq ts=t and every zzz, the function w↦∂tf(w)w\mapsto\partial_t f(w)w↦∂t​f(w) has a partial derivative in direction ese_ses​ at zzz, i.e. ∂s∂tf(z)\partial_s\partial_t f(z)∂s​∂t​f(z) exists.

Nothing is required of the diagonal second derivatives ∂t∂tf\partial_t\partial_t f∂t​∂t​f, nor of any continuity or full (Fréchet) differentiability. When n≤1n\le1n≤1, part (b) is vacuous.

Continuous partials of fff. For every coordinate ttt, the partial derivative ∂tf(z)\partial_t f(z)∂t​f(z), taken along the line h↦z+heth\mapsto z+he_th↦z+het​, exists at every z∈Rnz\in\mathbb{R}^nz∈Rn, and the map z↦∂tf(z)z\mapsto\partial_t f(z)z↦∂t​f(z) is continuous from Rn\mathbb{R}^nRn to Rd\mathbb{R}^dRd.

Non-monotone statistics (case k=1k=1k=1). For a parameter with k=1k=1k=1, for every iii, the single statistic Ti,1:R→RT_{i,1}:\mathbb{R}\to\mathbb{R}Ti,1​:R→R is not strictly increasing on R\mathbb{R}R and is not strictly decreasing on R\mathbb{R}R. Functions that are monotone but not strictly so, e.g. constants, satisfy this condition.

C1C^1C1 embedding. For f:Rn→Rdf:\mathbb{R}^n\to\mathbb{R}^df:Rn→Rd, the condition is the conjunction of:

  1. fff is continuously (Fréchet) differentiable;
  2. fff is a topological embedding, i.e. injective, continuous, and a homeomorphism onto its image with the subspace topology;
  3. at every z∈Rnz\in\mathbb{R}^nz∈Rn, the derivative Df(z):Rn→RdDf(z):\mathbb{R}^n\to\mathbb{R}^dDf(z):Rn→Rd is an injective linear map.

Condition 3 forces n≤dn\le dn≤d. No statement about f~−1∘f\tilde f^{-1}\circ ff~​−1∘f or diffeomorphisms is part of this definition.

Isolated turning points. For g:R→Rg:\mathbb{R}\to\mathbb{R}g:R→R, the condition is that for every t∈Rt\in\mathbb{R}t∈R there is δ>0\delta>0δ>0 such that:

  • on the open interval (t−δ,t)(t-\delta,t)(t−δ,t), ggg is strictly increasing or strictly decreasing;
  • on the open interval (t,t+δ)(t,t+\delta)(t,t+δ), ggg is strictly increasing or strictly decreasing.

No continuity of ggg is required, and nothing is said about the value g(t)g(t)g(t) itself.

Human review
  • Endorsed by Shuze Chen · Nov 24, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Xeroth · Nov 24, 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