Discovery.InvariantPrediction.LinearGaussian
Self-contained linear-Gaussian formalization of the completeness half of Invariant Causal Prediction (Peters, Bühlmann & Meinshausen, JRSS-B 2016, arXiv:1501.01332, Theorem prop:1(i), the do-intervention version).
Model 8 core · 2 supporting Setup of the linear-Gaussian identifiability theorem of Peters, Bühlmann & Meinshausen, *Causal inference using invariant prediction* (JRSS-B 2016, arXiv:1501.01332), Theorem prop:1(i) (the do-intervention version). ★ ObsSEM★ mem_paY★ EnvFamily
Invariant Causal Prediction — linear-Gaussian model layer
Setup of the linear-Gaussian identifiability theorem of Peters, Bühlmann &
Meinshausen, Causal inference using invariant prediction (JRSS-B 2016,
arXiv:1501.01332), Theorem prop:1(i) (the do-intervention version).
This is a self-contained linear-Gaussian framework, deliberately separate from
the nonparametric SWIG/kernel EnvFamily development in the sibling files. It
uses the random-variable encoding of Discovery/LiNGAM/Kurtosis.lean:
variables are real functions on a probability space, with ∫/E[·] for moments
and IdentDistrib for equality in distribution.
Encoding choices
* Index convention. The paper uses variables X₁,…,X_{p+1} with target
Y = X₁ and predictors X₂,…,X_{p+1}. We index nodes by Fin (p+1) and put
the target at index 0, predictors at 1,…,p. So target = 0 and the
predictor index set is {1,…,p} = {k : k ≠ 0} (Finset.univ.erase 0). This
is a pure 0-based relabelling of the paper's 1,…,p+1; PA(Y) is then a
subset of {k : k ≠ 0}.
* One coefficient matrix, one DAG. The observational SEM e = 1
(eq:semmmmm) carries the coefficients β : Matrix (Fin (p+1)) (Fin (p+1)) ℝ
with Xⱼ = Σ_{k≠j} βⱼₖ Xₖ + εⱼ. Acyclicity is witnessed by a DAG whose
edge k → j holds exactly when βⱼₖ ≠ 0 (hEdge); reusing Causalean.DAG
gives parents / descendants / topological order / the "youngest node" notion
for free. PA(Y) = {k : β 0 k ≠ 0} is then literally dag.parents 0.
* Gaussian noise, random-variable form. The observational SEM has its own
probability space with observed coordinates, and do-intervention environments
live on that same probability space with the same structural noises.
Independence of the noises and their Gaussian marginals are stated on the
observational environment only (that is where the graph/β/Gaussianity live).
* Do-interventions (sec:idfirst). In environment e an intervention set
A e ⊆ {1,…,p} and values a e : Fin (p+1) → ℝ replace the structural
equation of each j ∈ A e by the constant a e j (zeroing its row of β and
replacing εⱼ by a e j). Per the paper, 0 ∉ A e (never intervene on the
target) and A 1 = ∅ (observational).
The do-version's proof (later) is a mean-shift argument
(R^{e₀} = α_{k₀} a_{k₀} + … vs. R^1 = α_{k₀} X_{k₀}^1 + …, eq:help1/help2),
so the model exposes residual means / laws cleanly via IdentDistrib and ∫.
For a model with predictors, the target node is the first of its variables, represented by index zero.
Definition (Lean source)
For a model with predictors, the predictor index set contains precisely the non-target variables among its variables.
The observational linear-Gaussian structural equation model (eq:semmmmm, the e = 1 block): it bundles a sample space with its σ-algebra carrying a probability measure that is a genuine probability measure, together with structural coefficients β obeying Xⱼ = Σ_{k≠j} βⱼₖ Xₖ + εⱼ for measurable observed coordinates X, an acyclic graph whose edge k → j holds exactly when βⱼₖ ≠ 0, and the absence of self-loops in β. The noises ε are declared to be the structural residuals εⱼ = Xⱼ − Σ_{k≠j} βⱼₖ Xₖ, jointly independent, and each centered Gaussian with a positive variance σⱼ², and the target's noise is independent of every parent coordinate of the target.
Definition (Lean source)
For an observational linear-Gaussian structural equation model, the target's parent set is the set of nodes with an arrow into the target in its acyclic graph.
For a predictor index k, k belongs to the target's parent set PA(Y) exactly when the target's structural coefficient on k is nonzero.
Formal statement
A single do-intervention environment for the observational SEM M (sec:idfirst) bundles an intervention set that never includes the target node, the constant values assigned to each intervened coordinate, and measurable post-intervention coordinates that equal their assigned constant, almost surely, on the intervened set, satisfy the same structural equation as M — with M's coefficients and noises — on every coordinate left un-intervened, and for which the target's noise remains independent of each parent coordinate of the target.
Definition (Lean source)
An environment family for the linear-Gaussian ICP problem bundles an observational linear-Gaussian structural equation model together with a finite index set of interventional environments over that model.
For a family of intervention environments, the family's observational target-parent set is the target-parent set of its observational structural equation model.
2 supporting declarations (lemmas, instances)
-
mem_predictorstheorem — A node is a predictor exactly when it is not the target node.Proof (Lean source)
-
paY_subset_predictorstheorem — PA(Y) consists of predictors only (0 ∉ PA(Y)): the target is acyclic, so it is not its own parent.Proof (Lean source)
theorem paY_subset_predictors : M.paY ⊆ predictors p := by intro k hk rw [mem_predictors] rintro rfl exact M.dag.irrefl (target p) (M.dag.mem_parents.mp hk)
Regression 7 core · 2 supporting The observable layer of the linear-Gaussian ICP problem: the regression predictor in each environment, the regression-invariance null H_{0,S}, and the identified set S(E) (Peters–Bühlmann–Meinshausen 2016, eq:betapred, e ★ InvarianceNull★ identifiedSet★ mem_identifiedSet
Invariant Causal Prediction — regression-invariance null and identified set
The observable layer of the linear-Gaussian ICP problem: the regression
predictor in each environment, the regression-invariance null H_{0,S}, and
the identified set S(E) (Peters–Bühlmann–Meinshausen 2016, eq:betapred,
eq:H0Sregr, eq:ident).
Encoding choices (fidelity notes)
* Residual. residual γ env ω := Yᵉ(ω) − Σ_k γ k · Xₖᵉ(ω) with the sum over
all coordinates (γ is supported on S, so k ∉ S contributes nothing).
This is R^e(S) of the paper (R^e = Y^e − X^e β).
* Support on S. "γ supported on S" is ∀ k, γ k ≠ 0 → k ∈ S
(SupportedOn). This is the paper's constraint β_k = 0 if k ∉ S.
* Regression-invariance null H_{0,S}. This file uses a pairwise-coordinate
version of the regression null: there exist a coefficient vector γ
supported on S and a fixed residual law Fε such that for every
environment e, the residual R^e = Y^e − Σ γ_k X_k^e is (i) independent of
each predictor coordinate in S and (ii) has law Fε (the same law across
environments). In this jointly Gaussian linear-Gaussian setting,
coordinatewise independence of the residual from each X_k, k ∈ S, is
equivalent to joint independence from the vector X_S, so this matches the
Peters-Buhlmann-Meinshausen regression null despite the weaker-looking form.
The paper also requires γ = β^{pred,e}(S) (the
population-OLS coefficient); under independence of R^e from X_S^e that is
automatic (the residual is orthogonal to X_S, i.e. the normal equations
hold), so we fold it into the independence clause and do not carry β^{pred}
as a separate object. The observational
environment obs is included as one of the environments (it is e = 1), so
invariance is genuinely across the whole family.
* Residual law as a measure on ℝ. Fε : Measure ℝ; "R^e ∼ Fε" is
Pᵉ.map (residual γ (env e)) = Fε. Equivalently IdentDistrib across
environments; we phrase it via a single shared measure so the "same law" is one
object. The mean-shift proof only needs that the two laws differ, which a
shared-measure formulation exposes directly (hLawObs, hLawEnv).
* Identified set S(E) (eq:ident). S(E) := ⋂ {S : H_{0,S} holds}.
We encode the intersection over the (finite) powerset of predictors that
satisfy the null.
For a model with p predictor coordinates and one target coordinate, a coefficient vector, and a set of coordinate indices, the assertion that the coefficient vector is supported on that set means that every nonzero coefficient has an index in the set.
For a model with p predictor coordinates and one target coordinate, an observational linear structural-equation model, a coefficient vector, and a realization of that model's exogenous variables, the observational regression residual is the target value minus the sum of each coordinate value multiplied by its coefficient.
For a model with p predictor coordinates and one target coordinate, an observational linear structural-equation model, an interventional environment based on that model, a coefficient vector, and a realization of the model's exogenous variables, the interventional regression residual is the intervened target value minus the sum of each intervened coordinate value multiplied by its coefficient.
For a model with p predictor coordinates and one target coordinate, a linear-Gaussian environment family, and a predictor set, the regression-invariance null means that there exist a coefficient vector supported on that set and one residual measure such that (1) the coefficient vector is supported on the predictor set, (2) in the observational environment the residual is independent of each selected predictor, (3) its observational residual law is the common law, (4) in every interventional environment the residual is independent of each selected predictor, and (5) every interventional residual law is the same common law.
Definition (Lean source)
For a model with p predictor coordinates and one target coordinate and a linear-Gaussian environment family, the collection of invariant predictor sets is the finite collection of predictor subsets whose regression-invariance null holds.
Definition (Lean source)
For a model with p predictor coordinates and one target coordinate and a linear-Gaussian environment family, the identified set is the intersection of all predictor sets in that family's collection of invariant predictor sets.
For a predictor index k, k lies in the identified set S(E) exactly when k belongs to every predictor subset whose invariance null holds.
Formal statement
Proof (Lean source)
2 supporting declarations (lemmas, instances)
-
instDecidablePredFinsetFinHAddNatOfNatInvarianceNullinstance — For every number of predictor coordinates and linear-Gaussian environment family with those predictor coordinates and one target coordinate, a decision procedure for whether each predictor set satisfies the regression-invariance null is supplied by classical reasoning.parametersp :sharedℕinstancegiven byfun _ => Classical.dec _ -
mem_invariantSetstheorem — Membership in invariantSets.hypothesesconclusionS ∈ F.invariantSets ↔ S ⊆ predictors p ∧ F.InvarianceNull SProof (Lean source)
theorem mem_invariantSets {S : Finset (Fin (p + 1))} : S ∈ F.invariantSets ↔ S ⊆ predictors p ∧ F.InvarianceNull S := by classical simp [invariantSets, mem_filter, Finset.mem_powerset]
Completeness 7 core · 0 supporting The statement of Peters–Bühlmann–Meinshausen 2016, Theorem prop:1(i): for a linear-Gaussian SEM whose interventions are *do-interventions* with shifted values (a^e_j ≠ E[X¹_j]) and at least one single-node intervention o ★ HasShiftedSingleInterventions★ icp_sound_linearGaussian★ exists_youngest_nonzero★ residual_mean_shift_of_doIntervention★ icp_complete_linearGaussian
Invariant Causal Prediction — completeness for do-interventions (prop:1(i))
The statement of Peters–Bühlmann–Meinshausen 2016, Theorem prop:1(i): for a
linear-Gaussian SEM whose interventions are do-interventions with shifted
values (a^e_j ≠ E[X¹_j]) and at least one single-node intervention on every
predictor, the identified set equals the parents of the target:
S(E) = PA(Y).
The intermediate lemmas mirror the paper's appendix proof (app:proofs, "Proof
of Theorem prop:1 (i)"):
1. Soundness icp_sound_linearGaussian (S(E) ⊆ PA(Y)) — H_{0,PA(Y)}
holds with γ = γ* = β₀,· and residual ε₁, so PA(Y) is one of the
intersected sets (propos:sem).
2. Youngest-node selection exists_youngest_nonzero — among the indices k
with α_k ≠ 0 (α = γ* − β^{pred}(S)) there is one, k₀, with no directed
path to any other such index (a sink in the induced subgraph).
3. Mean-shift residual_mean_shift_of_doIntervention — under the single
do(X_{k₀} = a) intervention with a ≠ E[X¹_{k₀}] and α_{k₀} ≠ 0, the
residual law in that environment differs from the observational one (their
means differ by α_{k₀}·(a − E[X¹_{k₀}]) ≠ 0), contradicting invariance.
4. Completeness icp_complete_linearGaussian — combines 1–3: any
null-satisfying S must contain PA(Y), so S(E) ⊇ PA(Y), and with
soundness S(E) = PA(Y).
Encoding choices (fidelity notes)
* Single-intervention hypothesis (prop:1(i)). HasShiftedSingleInterventions:
for each predictor j, some environment i has A i = {j} (single
intervention on j) and a i j ≠ E[X¹_j] (the shift condition, with the mean
taken under the observational law). This is exactly the paper's "`a^e_j ≠
E(X¹_j) and for each j ∈ {2,…,p+1} there is e with A^e = {j}`".
* E[X¹_j] is the observational mean ∫ ω, M.X ω j ∂P. Finiteness /
integrability of the observational coordinates is bundled as hIntegrable
(the Gaussian SEM has all moments; the theorem keeps this fact as an explicit
integrability hypothesis rather than rebuilding Gaussian moment theory here).
* α and β^{pred}. The proof works with α k = γ*_k − γ_k for the null's
coefficient γ (which, being orthogonal to X_S, is β^{pred}(S)). We do
not introduce a separate β^{pred} object; α is defined inline in the
lemmas.
* Exogeneity (the paper's Assumption 1). Soundness needs ε₀ ⊥ X_k for each
parent k ∈ PA(Y). In a recursive Gaussian SEM this follows from joint noise
independence + acyclicity, but the random-variable encoding here does not expose
the ε → X solve, so it is carried as the structure fields ObsSEM.hYexo and
Env.hExo (stated only for parents — it is false for descendants of Y).
* hyoung at the call site. residual_mean_shift_of_doIntervention takes a
hyoung hypothesis — every other support index k ≠ k₀ with α_k ≠ 0 is not
a descendant of k₀. In the completeness proof this is supplied exactly by the
youngest-node selection (exists_youngest_nonzero over the support of α).
For a model with p predictor coordinates and one target coordinate, a linear-Gaussian environment family, and a coordinate index, the observational mean of that coordinate is its expectation under the family's observational probability law.
For a model with p predictor coordinates and one target coordinate and a linear-Gaussian environment family, the shifted single-intervention condition means that for every predictor coordinate there is an environment such that (1) that environment intervenes on that coordinate alone, and (2) its assigned value differs from the coordinate's observational mean.
Definition (Lean source)
For a model with p predictor coordinates and one target coordinate and a linear-Gaussian environment family, the observational-integrability condition means that every observational coordinate is integrable under the observational probability law.
Definition (Lean source)
Soundness (propos:sem). Assuming the observational predictor coordinates are integrable, so their means E[X¹_j] are well defined, the identified set is contained in the target's parents, S(E) ⊆ PA(Y).
Formal statement
Proof (Lean source)
Youngest-node selection (the "youngest node X_{k₀}" step). Given a nonempty set of coordinate indices , there is an index such that no other element of is a descendant of along the observational DAG's directed edges — i.e. is a sink of the subgraph induced by . This is the "youngest" node with non-zero α of the paper's proof.
Formal statement
Proof (Lean source)
Residual mean-shift (eq:help1/eq:help2). Fix an observational SEM with integrable regressors, a candidate coefficient vector γ, and an index k₀ such that the gap α_{k₀} = β₀,k₀ − γ_{k₀} between the causal coefficient and γ at k₀ is nonzero. Suppose k₀ is a youngest such index: every other index with a nonzero coefficient gap is not a descendant of k₀ in the observational DAG, and let i be an environment consisting of a single do-intervention pinning coordinate k₀ to a value different from its observational mean. Then the residual R^i = Y^i − Σ γ_k X_k^i computed in environment i and the observational residual R¹ computed the same way do not have the same distribution, since they have different means.
Formal statement
Proof (Lean source)
Completeness for do-interventions — Theorem prop:1(i). For an observational linear-Gaussian SEM with integrable regressors such that every predictor receives at least one environment with a single do-intervention whose shifted value differs from its observational mean , the ICP identified set — the intersection of all invariant predictor sets — equals exactly the parent set of the target node, .