Theorem (ProbabilityTheory.sq_mul_sq_integral_le_integral_sq_mul_measureReal_gt). The Paley–Zygmund inequality. Under a probability measure, for a random variable Z \ge 0 almost surely with \mathbb{E} Z^2 < \infty and 0 \le \theta \le 1, (1 - \theta)^2 (\mathbb{E} Z)^2 \le \mathbb{E} Z^2 \cdot \mathbb{P}\bigl[Z > \theta\,\mathbb{E} Z\bigr]\,. Both hypotheses on \theta are needed: for \theta < 0 and a constant Z > 0 the left side exceeds \mathbb{E}Z^2, and for \theta > 1 the event is empty for a constant Z. [PaleyZygmund1932, Lemma 19] (locator to check: their companion note in vol. 28(3) cites Lemma 19, p. 192, of this paper); the product form avoids dividing by \mathbb{E} Z^2.
Headline
Lean statement and details
ProbabilityTheory.sq_mul_sq_integral_le_integral_sq_mul_measureReal_gt.{u_1} {Ω : Type u_1}
{mΩ : MeasurableSpace Ω} {μ : Measure Ω} [IsProbabilityMeasure μ] {Z : Ω → ℝ} (hZ0 : 0 ≤ᵐ[μ] Z)
(hZ : MemLp Z 2 μ) {θ : ℝ} (hθ0 : 0 ≤ θ) (hθ1 : θ ≤ 1) :
(1 - θ) ^ 2 * (∫ (ω : Ω), Z ω ∂μ) ^ 2 ≤
(∫ (ω : Ω), Z ω ^ 2 ∂μ) * μ.real {ω | θ * ∫ (ω' : Ω), Z ω' ∂μ < Z ω}