Documentation

CslibFrontier.Foundations.Analysis.SpecialFunctions.Sqrt

Square-root averaging and scaling lemmas #

Cauchy–Schwarz bounds the mean square root by the square root of an upper bound on the mean (Finset.sum_sqrt_le_card_mul_sqrt), and Real.sqrt_mul_div_self rescales square-root regret bounds to time averages. Real.natCeil_sqrt_eq writes ⌈√m⌉₊ with the integer square root, the ceiling counterpart of Mathlib's Real.nat_floor_real_sqrt_eq_nat_sqrt.

Real.log_add_one_le_sqrt is the bound log (x + 1) ≤ √x for x ≥ 0, which turns a product of deg v + 1 choices into a sum of square roots of degrees. [KPS26] uses it in the count of successful admissibility tests in batch processing (§3.2, p. 16) and in the proof of Lemma 3.10 (§3.4, p. 20); the paper's log is the natural logarithm (§2, p. 11). Mathlib's Cauchy–Schwarz inequality Real.sum_sqrt_mul_sqrt_le with one factor constant then gives ∑ v ∈ s, √(d v) ≤ √#s * √(∑ v ∈ s, d v).

References #

theorem Finset.sum_sqrt_le_card_mul_sqrt {ι : Type u_1} (s : Finset ι) {F : ι → ℝ} (hF : ∀ i ∈ s, 0 ≤ F i) {B : ℝ} (hB : 0 ≤ B) (hsum : ∑ i ∈ s, F i ≤ ↑s.card * B) :
∑ i ∈ s, √(F i) ≤ ↑s.card * √B

Cauchy–Schwarz averaging: if ∑ i ∈ s, F i ≤ #s * B, then ∑ i ∈ s, √(F i) ≤ #s * √B.

theorem Real.sqrt_mul_div_self {T L : ℝ} (hT : 0 < T) :
√(T * L) / T = √(L / T)

Dividing the square root of T * L by T > 0 yields √(L / T).

theorem Real.log_add_one_le_sqrt {x : ℝ} (hx : 0 ≤ x) :
log (x + 1) ≤ √x

log (x + 1) ≤ √x for x ≥ 0, the bound used in [KPS26] for the count of successful admissibility tests in batch processing (§3.2, p. 16) and in the proof of Lemma 3.10 (§3.4, p. 20). With s = √x, the cubic Taylor polynomial 1 + s + s² / 2 + s³ / 6 ≤ exp s already dominates 1 + s².

theorem Real.natCeil_sqrt_eq (m : ℕ) :
⌈√↑m⌉₊ = if m = 0 then 0 else (m - 1).sqrt + 1

The ceiling of √m as an integer square root: ⌈√m⌉₊ = Nat.sqrt (m - 1) + 1 for m ≠ 0.