Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Proposition 4, p. 16 — trimmed mean of N samples, ζN arbitrarily corrupted: |µ̂ − µ| ≥ C₀ max σⱼ (3ζ+4η)√log(3/η) w.p. ≤ 3exp(−Nη²/9)

Proved
RobustMultitask.Estimator.proposition_4

by mikedeng1 · Oct 13, 2026 · Mathlib 0df444a (Lean v4.33.1)

concentrationp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1robust-statisticsstatisticssubgaussiantrimmed-mean

Let Z1,…,ZNZ_1,\dots,Z_NZ1​,…,ZN​ be random variables on a probability space and J⊆[N]\mathcal J\subseteq[N]J⊆[N] a set of indices with ∣J∣<ζN|\mathcal J|<\zeta N∣J∣<ζN, where 0<ζ<1/20<\zeta<1/20<ζ<1/2. Suppose that the samples {Zj}j∈Jc\{Z_j\}_{j\in\mathcal J^c}{Zj​}j∈Jc​ are independent and that each ZjZ_jZj​, j∈Jcj\in\mathcal J^cj∈Jc, is σj\sigma_jσj​-subgaussian with mean μ\muμ (Definition 1), σj>0\sigma_j>0σj​>0; the samples {Zj}j∈J\{Z_j\}_{j\in\mathcal J}{Zj​}j∈J​ may be arbitrarily corrupted. Let μ^=TrimmedMean({Zj}j∈[N],ω)\widehat\mu=\mathrm{TrimmedMean}(\{Z_j\}_{j\in[N]},\omega)μ​=TrimmedMean({Zj​}j∈[N]​,ω) with ω=ζ+η\omega=\zeta+\etaω=ζ+η. Then for every constant C0>2C_0>2C0​>2 and every 0<η≤1/2−1/C0−ζ0<\eta\le 1/2-1/C_0-\zeta0<η≤1/2−1/C0​−ζ,

P[ ∣μ^−μ∣ ≥ C0max⁡j∈Jcσj (3ζ+4η)log⁡(3/η) ] ≤ 3exp⁡(−Nη29).\mathbb P\Big[\,|\widehat\mu-\mu|\ \ge\ C_0\max_{j\in\mathcal J^c}\sigma_j\,(3\zeta+4\eta)\sqrt{\log(3/\eta)}\,\Big]\ \le\ 3\exp\Big(-\frac{N\eta^2}{9}\Big).P[∣μ​−μ∣ ≥ C0​j∈Jcmax​σj​(3ζ+4η)log(3/η)​] ≤ 3exp(−9Nη2​).

This is the robust-statistics step of the paper: unlike the classical results, the uncorrupted samples need only be independent, not identically distributed, so the bound applies to per-task least-squares estimates with different variances.

Formalization Note The corrupted samples ZjZ_jZj​, j∈Jj\in\mathcal Jj∈J, are arbitrary functions of the sample point: no independence, measurability or integrability is assumed. Definition 1 is Mathlib's HasSubgaussianMGF (Z j − µ) (σ j ^ 2) (written with mu), which forces E[Zj]=μ\mathbb E[Z_j]=\muE[Zj​]=μ. Independence is iIndepFun over the subtype Jc\mathcal J^cJc. The constant C0C_0C0​ is universally quantified ("with some constant C0>2C_0>2C0​>2" holds for every such C0C_0C0​ in the proof, p. 40), and the trimming level is fixed to ω=ζ+η\omega=\zeta+\etaω=ζ+η. The probability is the outer measure of the failure event, so no measurability of the trimmed mean is needed. The maximum over Jc\mathcal J^cJc is a supremum over that (nonempty, since ∣J∣<N/2|\mathcal J|<N/2∣J∣<N/2) subtype. The trimmed mean removes ⌊Nω⌋\lfloor N\omega\rfloor⌊Nω⌋ values from each end. The hypothesis σj>0\sigma_j>0σj​>0 is added: with all σj=0\sigma_j=0σj​=0 the threshold is 000 and the event "≥0\ge 0≥0" is certain, so the printed inequality would fail.

Preamble
import Mathlib
import Definitions.Def_RobustMultitask_Estimator_TrimmedMean
Formal statement
namespace RobustMultitask.Estimator

open MeasureTheory ProbabilityTheory
open scoped NNReal

/-- Proposition 4, p. 16 (trimmed mean under corruption). `N` samples `Z j`; a set `𝒥` of
corrupted indices with `|𝒥| < ζN`, `0 < ζ < 1/2`. The uncorrupted samples `Z j`, `j ∉ 𝒥`, are
independent, `σ_j`-subgaussian about the common mean `µ` (written `mu`; `σ_j > 0`); the corrupted ones are
arbitrary functions of the sample point. Then for every `C₀ > 2` and `0 < η ≤ 1/2 − 1/C₀ − ζ`,
with `µ̂ = TrimmedMean({Z_j}, ω)` and `ω = ζ + η`,
`P[|µ̂ − µ| ≥ C₀ max_{j∈𝒥ᶜ} σ_j (3ζ + 4η) √log(3/η)] ≤ 3 exp(−Nη²/9)`. -/
theorem proposition_4 {Ω : Type*} [MeasurableSpace Ω] (P : Measure Ω) [IsProbabilityMeasure P]
    {N : ℕ} (Z : Fin N → Ω → ℝ) (𝒥 : Finset (Fin N)) (σ : Fin N → ℝ≥0) (mu ζ η C₀ : ℝ)
    (hC₀ : 2 < C₀) (hζ0 : 0 < ζ) (hζ1 : ζ < 1 / 2) (hcard : (𝒥.card : ℝ) < ζ * N)
    (hη0 : 0 < η) (hη1 : η ≤ 1 / 2 - 1 / C₀ - ζ)
    (hσ : ∀ j ∉ 𝒥, 0 < σ j)
    (hsub : ∀ j ∉ 𝒥, HasSubgaussianMGF (fun ω => Z j ω - mu) (σ j ^ 2) P)
    (hind : iIndepFun (fun j : {j : Fin N // j ∉ 𝒥} => Z j) P) :
    P {ω | C₀ * (⨆ j : {j : Fin N // j ∉ 𝒥}, (σ j : ℝ)) * (3 * ζ + 4 * η)
            * Real.sqrt (Real.log (3 / η))
          ≤ |trimmedMean (fun j => Z j ω) (ζ + η) - mu|}
      ≤ ENNReal.ofReal (3 * Real.exp (-((N : ℝ) * η ^ 2) / 9)) := by sorry

end RobustMultitask.Estimator
Source
Xu & Bastani, Multitask Learning and Bandits via Robust Statistics, arXiv:2112.14233v5, p. 16, Proposition 4 (proof pp. 39–40)
Human review
  • Endorsed by Shuze Chen · Oct 14, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 14, 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