A minimax problem asks how accurately a function can be approximated by a polynomial of a given degree on a specified set. The domain and normalization matter: a residual polynomial constrained at zero is a different problem from unconstrained approximation of a function.
Definition (Best uniform polynomial error). For a continuous function f on a compact set S, define
For linear-system bounds, a common alternative is to minimize \sup_{t\in S}|p(t)| over degree-at-most-k polynomials satisfying p(0)=1. Equioscillation characterizes optimal approximants under the corresponding hypotheses.
for a < b, f continuous on [a, b] and p a best approximation of degree at most n, there are n + 1 distinct points of (a, b) at which p = f; p is the Lagrange interpolant of f there (Lagrange.eq_interpolate_of_eval_eq). [Trefethen2019, Ch. 10] (locator to check); there on [-1, 1].
Lean statement and details
NLAlib.exists_eval_eq_of_isUniformApproxOn_minimaxError {f : ℝ → ℝ} {a b : ℝ} (hab : a < b)
(hf : ContinuousOn f (Set.Icc a b)) {n : ℕ} {p : Polynomial ℝ} (hp : p.degree ≤ ↑n)
(hbest :
Metric.IsUniformApproxOn (fun x ↦ Polynomial.eval x p) f (Set.Icc a b)
(minimaxError f (Set.Icc a b) n)) :
∃ t, t.card = n + 1 ∧ ↑t ⊆ Set.Ioo a b ∧ ∀ x ∈ t, Polynomial.eval x p = f x
for s compact and f continuous on s there is a real polynomial p of degree at most n with \lvert f(x) - p(x) \rvert \le E_n(f; s) on s. This is how a bound stated for an arbitrary approximant is restated with E_n. [Trefethen2019, Theorem 10.1]; [Rivlin1981, Ch. 1] (locators to check); there on [-1, 1] or an interval, here on any compact set, the empty set included.
Lean statement and details
NLAlib.exists_degree_le_isUniformApproxOn_minimaxError {f : ℝ → ℝ} {s : Set ℝ} (hs : IsCompact s)
(hf : ContinuousOn f s) (n : ℕ) :
∃ p,
p.degree ≤ ↑n ∧ Metric.IsUniformApproxOn (fun x ↦ Polynomial.eval x p) f s (minimaxError f s n)
Theorem (Every best approximation is the chosen one).
for a < b, f continuous on [a, b] and p a real polynomial of degree at most n with \lvert f - p \rvert \le E_n(f; [a, b]) on [a, b], p = \mathrm{minimaxPoly}\ f\ [a, b]\ n. [Trefethen2019, Theorem 10.1].
Lean statement and details
NLAlib.eq_minimaxPoly_of_isUniformApproxOn_minimaxError {f : ℝ → ℝ} {a b : ℝ} (hab : a < b)
(hf : ContinuousOn f (Set.Icc a b)) {n : ℕ} {p : Polynomial ℝ} (hp : p.degree ≤ ↑n)
(hbest :
Metric.IsUniformApproxOn (fun x ↦ Polynomial.eval x p) f (Set.Icc a b)
(minimaxError f (Set.Icc a b) n)) :
p = minimaxPoly f (Set.Icc a b) n
Theorem (The minimax error of \mathbf{x}^{n + 1}).
on [-1, 1], the best approximation of x^{n + 1} by polynomials of degree at most n has error E_n(x^{n + 1}; [-1, 1]) = 2^{-n}, attained by x^{n + 1} - 2^{-n}T_{n + 1}; equivalently, 2^{-n}T_{n + 1} is the monic polynomial of degree n + 1 of least uniform norm on [-1, 1]. [GolubMeurant2010, §2.5.1, Theorem 2.15]; [Trefethen2019, Ch. 10].
Lean statement and details
NLAlib.minimaxError_pow_Icc_neg_one_one (n : ℕ) :
minimaxError (fun x ↦ x ^ (n + 1)) (Set.Icc (-1) 1) n = (2 ^ n)⁻¹
If \deg p \le n, p is within some finite \eta of f on s, and f - p alternates on s at n + 2 points with level \varepsilon, then \varepsilon \le E_n(f; s). The set s is arbitrary (a finite spectrum, a union of intervals); the finite \eta only excludes the junk value of minimaxError. [Rivlin1981, Ch. 1]; [Trefethen2019, Ch. 10] (locators to check).
Lean statement and details
NLAlib.AlternatesOn.le_minimaxError {f : ℝ → ℝ} {s : Set ℝ} {n : ℕ} {p : Polynomial ℝ} {ε : ℝ}
(h : AlternatesOn (fun x ↦ f x - Polynomial.eval x p) s (n + 2) ε) (hp : p.degree ≤ ↑n) {η : ℝ}
(hη : Metric.IsUniformApproxOn (fun x ↦ Polynomial.eval x p) f s η) : ε ≤ minimaxError f s n
Theorem (An equioscillating error is the minimax error).
if \deg p \le n, \lvert f - p \rvert \le \varepsilon on s and f - p alternates on s at n + 2 points with level \varepsilon, then E_n(f; s) = \varepsilon, and p is a best approximation. On any set, for any f: the certificate direction of the equioscillation theorem. [Trefethen2019, Theorem 10.1]; [Rivlin1981, Ch. 1] (locators to check).
Lean statement and details
NLAlib.AlternatesOn.minimaxError_eq {f : ℝ → ℝ} {s : Set ℝ} {n : ℕ} {p : Polynomial ℝ} {ε : ℝ}
(h : AlternatesOn (fun x ↦ f x - Polynomial.eval x p) s (n + 2) ε) (hp : p.degree ≤ ↑n)
(hε : Metric.IsUniformApproxOn (fun x ↦ Polynomial.eval x p) f s ε) : minimaxError f s n = ε