Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Hua's inequality, fourth moment, k=2k=2k=2

Proved
CircleMethod.hua_L4_deg_two

by tabbott · Sep 1, 2026 · Mathlib 0df444a (Lean v4.33.1)

analytic-number-theorycircle-methodexponential-sumsnumber-theory

Hua's inequality in its simplest instance: the fourth moment of the quadratic Weyl sum. For every ε>0\varepsilon>0ε>0 there is a constant C=C(ε)C=C(\varepsilon)C=C(ε) with

∫01∣∑x=0N−1e(θx2)∣4dθ  ≤  C N2+ε(N≥1).\int_0^1\left|\sum_{x=0}^{N-1}e(\theta x^{2})\right|^{4}d\theta\;\le\;C\,N^{2+\varepsilon}\qquad (N\ge 1).∫01​​x=0∑N−1​e(θx2)​4dθ≤CN2+ε(N≥1).

By the counting identity, the left-hand side equals the number of solutions of

x12+x22=y12+y22,0≤xi,yi<N,x_1^{2}+x_2^{2}=y_1^{2}+y_2^{2},\qquad 0\le x_i,y_i<N,x12​+x22​=y12​+y22​,0≤xi​,yi​<N,

so the assertion is that this system has only Oε(N2+ε)O_\varepsilon(N^{2+\varepsilon})Oε​(N2+ε) solutions — that is, essentially only the ≍N2\asymp N^2≍N2 diagonal ones {x1,x2}={y1,y2}\{x_1,x_2\}=\{y_1,y_2\}{x1​,x2​}={y1​,y2​}. The proof reduces to the divisor bound: for each fixed value of x12−y12x_1^2-y_1^2x12​−y12​ the number of ways of writing it as a difference of two squares is controlled by the number of its divisors.

Mean value estimates of this shape are the second pillar of the circle method, complementing the pointwise Weyl bound. The pointwise bound alone is too weak to make the minor arcs negligible; one interpolates, using Hölder's inequality, between the pointwise supremum bound and a mean value bound like this one. Hua's inequality is the general-kkk version, of which this is the case k=2k=2k=2.

Formalization Note. The integrand is the real-valued function θ↦∥∑x<Ne(θx2)∥4\theta\mapsto\bigl\|\sum_{x<N}e(\theta x^2)\bigr\|^4θ↦​∑x<N​e(θx2)​4, so the integral is real. Note the phase is θx2\theta x^2θx2, with xxx coerced from N\mathbb{N}N to R\mathbb{R}R before squaring. The constant CCC depends only on ε\varepsilonε, not on NNN.

Preamble
import Definitions.Def_CircleMethod_genfun
import Mathlib.Analysis.SpecialFunctions.Pow.Real
import Mathlib.Analysis.SpecialFunctions.Integrals.Basic
import Mathlib.NumberTheory.Divisors
import Mathlib.Data.Fintype.Pi
open Finset
Formal statement
namespace CircleMethod

theorem hua_L4_deg_two {ε : ℝ} (hε : 0 < ε) :
    ∃ C : ℝ, 0 < C ∧ ∀ N : ℕ, 0 < N →
      (∫ θ in (0:ℝ)..1, ‖∑ x ∈ Finset.range N, e (θ * (x : ℝ) ^ 2)‖ ^ 4)
        ≤ C * (N : ℝ) ^ (2 + ε) := by sorry

end CircleMethod
Source
L.-K. Hua, On Waring's problem, Quarterly Journal of Mathematics 9 (1938), 199-202; see R. C. Vaughan, The Hardy-Littlewood Method, 2nd ed., 1997, Lemma 2.5 (Hua's inequality), case k = 2, j = 2.

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