The fundamental counting identity of the circle method
ProvedCircleMethod.circle_method_countThe identity on which the entire Hardy--Littlewood circle method rests.
Let be a finite set of integers and let
be its exponential generating function. Then for every and every ,
The proof is a single expansion followed by orthogonality: , and is when and otherwise, so every tuple whose sum differs from is annihilated.
The significance is that an arithmetic quantity — a count of representations — has been written as an analytic one, an integral over the circle. The method then estimates that integral by splitting the circle into major arcs, where is large and computable, and minor arcs, where is small. Nothing in the method is possible before this identity is available.
Formalization Note. Tuples are functions , so they are ordered and repetitions are allowed. No hypotheses are placed on , or : the degenerate cases and are included, and for both sides reduce to .
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
namespace CircleMethod
theorem circle_method_count (A : Finset ℤ) (s : ℕ) (n : ℤ) :
(∫ θ in (0:ℝ)..1, (f A θ) ^ s * e (-(n : ℝ) * θ))
= ((((Fintype.piFinset (fun _ : Fin s => A)).filter
(fun v => ∑ i, v i = n)).card : ℕ) : ℂ) := by sorry
end CircleMethodRead-back
What the Lean code literally says, in plain math · claude-opus-5
Read-back of CircleMethod.circle_method_count
The statement is universally quantified over three explicit arguments, with no hypotheses of any kind on them: a finite set of integers (a Finset of , so its elements are distinct integers, and it is allowed to be empty, and its elements may be negative or zero), a natural number (allowed to be ), and an integer (allowed to be negative or zero). There are no typeclass assumptions beyond those already carried by , , and , and no positivity, nonemptiness, or size condition is imposed.
Two auxiliary notions from the bundle enter the statement and are unfolded here. First, for a real number ,
the complex exponential of times (with and viewed as complex numbers). Second, for a finite set and a real ,
where each integer is first cast to a real number and multiplied by ; the sum ranges over the elements of the finite set , each occurring once. (An additional definition in scope, , the distance from to a nearest integer, plays no role in this statement.)
The assertion is an equality of two complex numbers. The left-hand side is the oriented interval integral of a complex-valued function of the real variable , taken from to :
where is the exponent of an ordinary power in (so the integrand is the constant function times when , including at points where ), and the integer is cast to a real number and then negated before being multiplied by . This is an interval integral in the Bochner sense; by the convention attached to that construction it would evaluate to if the integrand failed to be integrable on , so the equation is an equation between two complex numbers in all cases, with no integrability hypothesis stated.
The right-hand side is a cardinality, first as a natural number and then cast into . Consider the set of all functions
(indexed by the -element type ) such that for every index — that is, the set of ordered -tuples of elements of , with repetitions allowed and order significant. Among these, keep exactly those satisfying
the sum being over all indices, and take the number of tuples so retained. The claim is that this count, viewed as a complex number, equals the integral above:
Several degenerate instances are silently included by the quantifiers. If , the left-hand side is and the right-hand side counts the tuples indexed by the empty index set: there is exactly one such (the empty tuple), its sum is the empty sum , so the count is when and otherwise — and this holds regardless of , in particular for . If and , then for every , the left-hand side is , and there are no admissible tuples, so the right-hand side is as well. Since is a finite set rather than a multiset, repeated integers cannot occur among the summands of , though a single element of may of course be reused across several coordinates of a tuple . The equation is asserted for every integer , including those that are not representable as such a sum, in which case the right-hand side is the cast of .
The declaration is stated as a theorem whose proof is left as sorry, i.e. no proof is supplied.
Confirmed by the mission captain (proposal self-audit).