Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Theorem 2.2 — a continuous function with the mean-value property is smooth and harmonic

Proved
HunterPDE.Harmonic.smooth_of_mean_value_property

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

harmonic-functionsmean-value-propertyp2o-batch-books5p2o-gran-per-chapterp2o-plan-bookp2o-v1pderegularity

Let Ω⊆Rn\Omega \subseteq \mathbb{R}^nΩ⊆Rn be open and let u∈C(Ω)u \in C(\Omega)u∈C(Ω) have the mean-value property (2.3): for every ball Br(x)⋐ΩB_r(x) \Subset \OmegaBr​(x)⋐Ω,

u(x)=⨍Br(x)u dxandu(x)=⨍∂Br(x)u dS.u(x) = ⨍_{B_r(x)} u \, dx \quad\text{and}\quad u(x) = ⨍_{\partial B_r(x)} u \, dS.u(x)=⨍Br​(x)​udxandu(x)=⨍∂Br​(x)​udS.

Then u∈C∞(Ω)u \in C^\infty(\Omega)u∈C∞(Ω) and Δu=0\Delta u = 0Δu=0 in Ω\OmegaΩ.

Together with Theorem 2.1 this characterizes harmonic functions by the mean-value property and shows that every C2C^2C2 harmonic function is C∞C^\inftyC∞, which the proof of analyticity (Theorem 2.10) uses.

Formalization Note. u∈C(Ω)u \in C(\Omega)u∈C(Ω) is ContinuousOn u Ω; the mean-value property is HasMeanValueProperty Ω u from the definition item MeanValue (both identities of (2.3), for every r>0r > 0r>0 with B‾r(x)⊆Ω\overline{B}_r(x) \subseteq \OmegaBr​(x)⊆Ω). C∞C^\inftyC∞ is ContDiffOn ℝ ∞ u Ω with ∞ the smooth order (not ω, which would be analyticity). Δ\DeltaΔ is Mathlib's laplacian.

Preamble
import Mathlib
import Definitions.Def_HunterPDE_Harmonic_MeanValue

open Laplacian
open scoped ContDiff
Formal statement
namespace HunterPDE.Harmonic

/-- Theorem 2.2 of Hunter, *Notes on PDEs* (revised 6/18/2014), p. 21: if `u ∈ C(Ω)` has the
mean-value property (2.3) in the open set `Ω ⊆ ℝⁿ`, then `u ∈ C^∞(Ω)` and `Δu = 0` in `Ω`.
`∞` is `C^∞` (not `ω`, which would be analyticity). -/
theorem smooth_of_mean_value_property {n : ℕ} {Ω : Set (EuclideanSpace ℝ (Fin n))}
    {u : EuclideanSpace ℝ (Fin n) → ℝ} (hΩ : IsOpen Ω) (hu : ContinuousOn u Ω)
    (hmv : HasMeanValueProperty Ω u) :
    ContDiffOn ℝ ∞ u Ω ∧ ∀ x ∈ Ω, Δ u x = 0 := by sorry

end HunterPDE.Harmonic
Source
Hunter, Notes on Partial Differential Equations (revised 6/18/2014), p. 21, Theorem 2.2
Read-back

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

Hypotheses.

  • n∈Nn \in \mathbb{N}n∈N is arbitrary.
  • Ω⊆Rn\Omega \subseteq \mathbb{R}^nΩ⊆Rn is open.
  • u:Rn→Ru : \mathbb{R}^n \to \mathbb{R}u:Rn→R is continuous on Ω\OmegaΩ.
  • uuu has the mean-value property on Ω\OmegaΩ. For every xxx and every r>0r > 0r>0 with B‾r(x)⊆Ω\overline{B}_r(x) \subseteq \OmegaBr​(x)⊆Ω:
u(x)=1λ(Br(x))∫Br(x)u dλandu(x)=1σ(Sn−1)∫Sn−1u(x+ry) dσ(y).u(x) = \frac{1}{\lambda(B_r(x))}\int_{B_r(x)} u\,d\lambda \qquad\text{and}\qquad u(x) = \frac{1}{\sigma(S^{n-1})}\int_{S^{n-1}} u(x+ry)\,d\sigma(y).u(x)=λ(Br​(x))1​∫Br​(x)​udλandu(x)=σ(Sn−1)1​∫Sn−1​u(x+ry)dσ(y).

Here λ\lambdaλ is Lebesgue measure and Sn−1S^{n-1}Sn−1 the unit sphere. The measure is σ(A)=n λ({ta:0<t<1, a∈A})\sigma(A) = n\,\lambda(\{ta: 0<t<1,\ a\in A\})σ(A)=nλ({ta:0<t<1, a∈A}). Each average is 000 when its integrand is non-integrable or the measure of the domain is 000.

Conclusion. Both of the following hold:

  • uuu is infinitely differentiable (C∞C^\inftyC∞) on Ω\OmegaΩ, in the sense of C∞C^\inftyC∞ relative to Ω\OmegaΩ, which for open Ω\OmegaΩ is ordinary smoothness near each point.
  • Δu(x)=0\Delta u(x) = 0Δu(x)=0 for every x∈Ωx \in \Omegax∈Ω, where Δu(x)=∑iD2u(x)(ei,ei)\Delta u(x) = \sum_i D^2u(x)(e_i,e_i)Δu(x)=∑i​D2u(x)(ei​,ei​).

Degenerate cases.

  • Empty Ω\OmegaΩ. Both conclusions hold trivially.
  • n=0n = 0n=0. There is no hypothesis n≥1n \ge 1n≥1. The space is one point, the sphere average is 000, and the ball average is u(0)u(0)u(0). So for Ω={0}\Omega = \{0\}Ω={0} the mean-value hypothesis amounts to u(0)=0u(0) = 0u(0)=0. The conclusion is then automatic: any function is smooth on a point, and the Laplacian on a 000-dimensional space is the empty sum 000.
  • Integrability. Continuity of uuu on Ω\OmegaΩ makes uuu integrable over each admissible compact closed ball and its sphere. So the zero convention for non-integrable integrands is not triggered by admissible balls.
Human review
  • Endorsed by Shuze Chen · Oct 2, 2026

    Confirmed by the moderator at approval.

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