LeanMachineLearning

Learning.Algorithm.density🔗

Definition

If the algorithm alg is absolutely continuous with respect to the algorithm alg₀ and they are both interacting with the same environment, then the law of the history at time n under alg is the law of the history at time n under alg₀ with density alg.density alg₀ n.

🔗def
Learning.Algorithm.density.{u_1, u_2} {𝓐 : Type u_1} {𝓨 : Type u_2} [MeasurableSpace 𝓐] [MeasurableSpace 𝓨] [MeasurableSpace.CountablyGenerated 𝓐] (alg alg₀ : Algorithm 𝓐 𝓨) (n : ) : ((Finset.Iic n) 𝓐 × 𝓨) ENNReal
Learning.Algorithm.density.{u_1, u_2} {𝓐 : Type u_1} {𝓨 : Type u_2} [MeasurableSpace 𝓐] [MeasurableSpace 𝓨] [MeasurableSpace.CountablyGenerated 𝓐] (alg alg₀ : Algorithm 𝓐 𝓨) (n : ) : ((Finset.Iic n) 𝓐 × 𝓨) ENNReal

Code

noncomputable def density [MeasurableSpace.CountablyGenerated 𝓐] (alg alg₀ : Algorithm 𝓐 𝓨) : (n : ) (Iic n 𝓐 × 𝓨) ℝ≥0∞ | 0, h => (alg.p0.rnDeriv alg₀.p0 (h 0, by simp).1) | n + 1, h => let p := MeasurableEquiv.IicSuccProd (fun _ 𝓐 × 𝓨) n h alg.density alg₀ n p.1 * (alg.policy n).rnDeriv (alg₀.policy n) p.1 p.2.1

Actions: Source · Open Issue

Meaning last changed in v4.34.0-rc2-1-g439785b (2026-08-23), the 3th recorded change.

Self-contained, with its dependencies inlined and proofs replaced by sorry: download the raw file · open it in the Lean web editor.

Dependency graph

Audit surface: 2 project declarations, 71 external constants

✓ Proved: no sorry anywhere in its closure

This is the tool's own reading of one build's recorded axioms, and it is not robust against an author who wants it to pass. Checking meant to be relied on should go through Comparator, which replays the proof through the kernel from an export against an explicit list of permitted axioms.