Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Utility Lemma 13 — if X ≤ Y a.s. then E|X| ≤ |E X| + 2 E|Y|

Proved
LearnStability.ERMLOO.utility_lemma13

by mikedeng1 · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

p2o-batch-p100bp2o-gran-per-chapterp2o-plan-paperp2o-v1probability

Let XXX and YYY be integrable real random variables on a probability space such that X≤YX\le YX≤Y almost surely. Then

E[∣X∣]≤∣E[X]∣+2 E[∣Y∣].\mathbb E\big[|X|\big]\le\big|\mathbb E[X]\big|+2\,\mathbb E\big[|Y|\big].E[∣X∣]≤​E[X]​+2E[∣Y∣].

The inequality turns a bound on a signed expectation, together with a one-sided pointwise majorant, into a bound on an expected absolute value; it is the step from on-average generalization to generalization in Lemma 14.

Formalization Note. Integrability of XXX and YYY is assumed (the paper leaves it implicit); without it Lean's integrals default to 000.

Preamble
import Mathlib

open MeasureTheory
Formal statement
namespace LearnStability.ERMLOO

theorem utility_lemma13 {Ω : Type*} [MeasurableSpace Ω] {μ : Measure Ω} [IsProbabilityMeasure μ]
    (X Y : Ω → ℝ) (hX : Integrable X μ) (hY : Integrable Y μ) (hXY : X ≤ᵐ[μ] Y) :
    ∫ ω, |X ω| ∂μ ≤ |∫ ω, X ω ∂μ| + 2 * ∫ ω, |Y ω| ∂μ := by sorry

end LearnStability.ERMLOO
Source
Shalev-Shwartz, Shamir, Srebro and Sridharan, Learnability, Stability and Uniform Convergence, JMLR 11 (2010), p. 2650, Utility Lemma 13
Read-back

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

The setting is a probability space (Ω,μ)(\Omega,\mu)(Ω,μ) and two real-valued functions X,YX, YX,Y on Ω\OmegaΩ, both μ\muμ-integrable, with X≤YX \le YX≤Y μ\muμ-almost everywhere. The statement asserts

∫Ω∣X∣ dμ  ≤  ∣∫ΩX dμ∣+2∫Ω∣Y∣ dμ,\int_\Omega |X|\,d\mu \;\le\; \Big|\int_\Omega X\,d\mu\Big| + 2\int_\Omega |Y|\,d\mu,∫Ω​∣X∣dμ≤​∫Ω​Xdμ​+2∫Ω​∣Y∣dμ,

that is, E∣X∣≤∣EX∣+2 E∣Y∣\mathbb{E}|X| \le |\mathbb{E}X| + 2\,\mathbb{E}|Y|E∣X∣≤∣EX∣+2E∣Y∣. No sign condition is placed on YYY, and no independence or other relation between XXX and YYY is assumed beyond X≤YX \le YX≤Y almost everywhere.

Degenerate cases:

  • Nonempty space. Ω\OmegaΩ is necessarily non-empty, since μ\muμ is a probability measure.
  • Y=0Y = 0Y=0 almost surely. Then X≤0X \le 0X≤0 almost surely, and the claim reads E∣X∣≤∣EX∣\mathbb{E}|X| \le |\mathbb{E}X|E∣X∣≤∣EX∣.
  • Integrability. Both functions are assumed integrable, so every integral is a genuine one.
Human review
  • Endorsed by Shuze Chen · Sep 27, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 27, 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