Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Theorem (2.1)(1) — the max function is locally Lipschitz

Proved
ClarkeGradients.MaxFunctions.maxFunction_lipschitzOnBounded

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

lipschitzmax-functionnonsmooth-analysisp2o-batch-p100bp2o-gran-per-chapterp2o-plan-paperp2o-v1

Let UUU be a nonempty sequentially compact topological space and g:Rn×U→Rg:\mathbb R^n\times U\to\mathbb Rg:Rn×U→R satisfy

  • (a) g(x,u)g(x,u)g(x,u) is upper semicontinuous in (x,u)(x,u)(x,u);
  • (b) ggg is locally Lipschitz in xxx, uniformly for u∈Uu\in Uu∈U: for every bounded B⊆RnB\subseteq\mathbb R^nB⊆Rn there is one constant KKK with ∣g(x1,u)−g(x2,u)∣≤K∣x1−x2∣|g(x_1,u)-g(x_2,u)|\le K|x_1-x_2|∣g(x1​,u)−g(x2​,u)∣≤K∣x1​−x2​∣ for all x1,x2∈Bx_1,x_2\in Bx1​,x2​∈B and all u∈Uu\in Uu∈U.

Then the max function f(x)=max⁡{g(x,u):u∈U}f(x)=\max\{g(x,u):u\in U\}f(x)=max{g(x,u):u∈U} is locally Lipschitz (Lipschitz on every bounded set).

This is the first assertion of Theorem (2.1); the rest of that theorem is about ∂f\partial f∂f and f∘f^\circf∘, which are meaningful only because fff is locally Lipschitz.

Formalization Note Only hypotheses (a) and (b) of Theorem (2.1) are assumed, since the paper's proof of (1) uses only these, the sequential compactness of UUU, and U≠∅U\neq\emptysetU=∅ (which the paper uses implicitly in "max" and makes explicit here as [Nonempty U]). The max is ⨆ u, g x u.

Preamble
import Mathlib
import Definitions.Def_ClarkeGradients_Shared_LipschitzOnBounded
import Definitions.Def_ClarkeGradients_MaxFunctions_maxFunction
Formal statement
namespace ClarkeGradients.MaxFunctions

/-- Clarke (1975), Theorem (2.1), assertion (1): if `U` is a nonempty sequentially compact
space, `g(x, u)` is upper semicontinuous in `(x, u)` (hypothesis (a)) and `g` is locally
Lipschitz in `x` uniformly for `u ∈ U` (hypothesis (b)), then `f(x) = max_u g(x, u)` is
locally Lipschitz. -/
theorem maxFunction_lipschitzOnBounded
    {n : ℕ} {U : Type*} [TopologicalSpace U] [SeqCompactSpace U] [Nonempty U]
    (g : EuclideanSpace ℝ (Fin n) → U → ℝ)
    (ha : UpperSemicontinuous (fun p : EuclideanSpace ℝ (Fin n) × U => g p.1 p.2))
    (hb : ∀ B : Set (EuclideanSpace ℝ (Fin n)), Bornology.IsBounded B →
      ∃ K : NNReal, ∀ u : U, LipschitzOnWith K (fun y => g y u) B) :
    Shared.LipschitzOnBounded (maxFunction g) := by sorry

end ClarkeGradients.MaxFunctions
Source
Clarke, Generalized gradients and applications, Trans. Amer. Math. Soc. 205 (1975), p. 251, Theorem (2.1), assertion (1); proof p. 252
Read-back

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

This statement uses LipschitzOnBounded\mathrm{LipschitzOnBounded}LipschitzOnBounded, imported from another file with its code not shown; its name suggests "Lipschitz on every bounded set". It also uses f=maxFunction gf = \mathrm{maxFunction}\,gf=maxFunctiong, defined by

f(x)=sup⁡u∈Ug(x,u)f(x) = \sup_{u \in U} g(x, u)f(x)=u∈Usup​g(x,u)

as a real supremum. That supremum takes the default value 000 when the set {g(x,u):u∈U}\{g(x,u) : u \in U\}{g(x,u):u∈U} is not bounded above.

The data are:

  • a natural number nnn;
  • a type UUU carrying a topology, which is sequentially compact (every sequence in UUU has a convergent subsequence) and nonempty;
  • a function g:Rn×U→Rg : \mathbb{R}^n \times U \to \mathbb{R}g:Rn×U→R, where Rn\mathbb{R}^nRn is Euclidean space.

The hypotheses are:

  • (a) The map (x,u)↦g(x,u)(x, u) \mapsto g(x, u)(x,u)↦g(x,u) is upper semicontinuous on the product space Rn×U\mathbb{R}^n \times URn×U. That is, for every point ppp and every real y>g(p)y > g(p)y>g(p), we have g<yg < yg<y on some neighbourhood of ppp.
  • (b) For every bounded set B⊆RnB \subseteq \mathbb{R}^nB⊆Rn there is a single constant K≥0K \ge 0K≥0 such that, for every u∈Uu \in Uu∈U and all y,y′∈By, y' \in By,y′∈B,
∣g(y,u)−g(y′,u)∣≤K ∥y−y′∥.|g(y, u) - g(y', u)| \le K\,\|y - y'\|.∣g(y,u)−g(y′,u)∣≤K∥y−y′∥.

The constant KKK may depend on BBB but not on uuu.

The conclusion is LipschitzOnBounded(f)\mathrm{LipschitzOnBounded}(f)LipschitzOnBounded(f). The statement does not separately assume that the supremum defining fff is finite or attained.

Degenerate cases:

  • Case n=0n = 0n=0. R0\mathbb{R}^0R0 is a single point, so (b) holds automatically, and (a) reduces to upper semicontinuity of u↦g(0,u)u \mapsto g(0, u)u↦g(0,u). The conclusion is then whatever LipschitzOnBounded\mathrm{LipschitzOnBounded}LipschitzOnBounded says about a function on a one-point space.
  • One-point U={u0}U = \{u_0\}U={u0​}. Here f=g(⋅,u0)f = g(\cdot, u_0)f=g(⋅,u0​).
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