\subsection{The analytic hypotheses}\label{sec:hypotheses} Throughout this subsection, $p$ denotes a prime and $\Fp=\mathbb Z/p\mathbb Z$. \begin{definition}[Additive character]\label{def:ep} For $x\in\Fp$, define \[ \ep(x)=\exp\Big(\frac{2\pi i x}{p}\Big). \] Any integer representative of $x$ may be used in this expression. \end{definition} \begin{definition}[Kloosterman sums]\label{def:kloosterman} For $t,a\in\Fp$, define \[ \Kl_3(t)=\frac1p\sum_{u,v\in\Fp^\times}\ep\Big(u+v+\frac{t}{uv}\Big) \qquad\text{and}\qquad S(a)=\sum_{x\in\Fp^\times}\ep\Big(x+\frac ax\Big). \] Here $\Fp^\times$ denotes the nonzero elements of $\Fp$. Division in these sums is division in the finite field. \end{definition} The meanings assigned below to $A$, $B$, $C$, $K$, $Z$, $P$, $m$, $n$, $h$, $k$ and $\alpha$ apply only in this subsection and in \Supp{app:numerics}. \begin{hypothesis}[Deligne; Katz {\cite[Thm.~4.1.1]{katz-gkm}}]\label{hyp:A1} $|\Kl_3(c)|\le 3$ for every prime $p$ and every $c\in\Fp^\times$. \end{hypothesis} \begin{hypothesis}[Birch--Bombieri {\cite{fi-1985}}, with the constant of Fouvry--Kowalski--Michel {\cite[Prop.~2]{fkm-fi}}]\label{hyp:A2} For every prime $p$ and all $A,B\in\Fp^\times$, including $A=B$, \[ \Big|\sum_{t\ne0,-1}S(A/t)\,S\big(B/(t+1)\big)\Big|\le 8p^{3/2}. \] \end{hypothesis} \begin{hypothesis}[Deligne; Katz {\cite[Thm.~4.1.1]{katz-gkm}}]\label{hyp:A3} For every prime $p$ and every $c\in\Fp^\times$, \[ \Big|\sum_{u,v,w\in\Fp^\times}\ep\Big(u+v+w+\frac{c}{uvw}\Big)\Big|\le 4p^{3/2}. \] \end{hypothesis} The last hypothesis concerns a two-variable Fourier transform built from correlations of $\Kl_3$. For $A,B,\alpha,m,n\in\Fp^\times$ put \[ C(A,B)=\sum_{h\in\Fp^\times}\Kl_3(Ah)\overline{\Kl_3(Bh)}\,\ep(h),\qquad K_{m,n}(r_1,r_2)=C\Big(\frac{\alpha r_2}{m r_1^2},\frac{\alpha r_1}{n r_2^2}\Big)\quad(r_1r_2\ne0), \] with $K_{m,n}=0$ when $r_1r_2=0$. For $m,m',n,n'\in\Fp^\times$ set \[ \mathcal V=K_{m,n}\,\overline{K_{m',n}}\,K_{m',n'}\,\overline{K_{m,n'}},\qquad \widehat{\mathcal V}(h,k)=\sum_{r_1,r_2\in\Fp}\mathcal V(r_1,r_2)\,\ep(hr_1+kr_2). \] \begin{hypothesis}[{\cite[Prop.~3.1]{astra31}}; see {\cite[Thm.~1.1]{allahyar-fourier}}]\label{hyp:A4} There are $C_4>0$, $\Delta_4\in\mathbb N$ and $p_0$ such that for every prime $p>p_0$ and all $\alpha,m,m',n,n'\in\Fp^\times$ the following hold. \begin{enumerate} \item If $m\ne m'$ and $n\ne n'$, there is a set $Z\subset\Fp^2$ with $|Z|\le \Delta_4$ and \[|\widehat{\mathcal V}(h,k)|\le C_4p^3\big(1+\sqrt p\,\mathbf 1_Z(h,k)\big)\quad\text{for all }(h,k).\] \item Otherwise there is a nonzero polynomial $P$ over $\overline{\Fp}$ of total degree at most $\Delta_4$ with \[|\widehat{\mathcal V}(h,k)|\le C_4p^3\big(1+\sqrt p\,\mathbf 1_{P(h,k)=0}+p\,\mathbf 1_{(h,k)=(0,0)}\big)\quad\text{for all }(h,k).\] \end{enumerate} \end{hypothesis} \begin{remark}[Normalisations and constants]\label{rem:status} A1 uses Katz's normalisation \cite[Thm.~4.1.1]{katz-gkm}, while A3 is stated in unnormalised form. The constant $8$ in A2 does not affect the bound on prime gaps. A2 enters only the distribution theorems of \cite{openai186} (items I9 and I11 of Appendix~\ref{app:imported}), where it gives the bound $9\sqrt p$ for a twisted correlation of $\Kl_3$ at a prime. Over a squarefree modulus $q$ these local bounds multiply to $9^{\omega(q)}\sqrt q$, and for the moduli $q\le x^{O(1)}$ that occur the factor $9^{\omega(q)}$ is $O_\varepsilon(x^{\varepsilon})$ and is absorbed. Any absolute constant in place of $8$ would change only the base $9$ and would be absorbed in the same way. The Lean statement of A2, however, uses the constant $8$. \end{remark} \begin{remark}[The role of Hypothesis~\ref{hyp:A4}]\label{rem:A4} Theorem~1.1 of the companion paper \cite{allahyar-fourier} concerns the same sum $\widehat{\mathcal V}$ and gives A4, with $p_0\ge3$. Its case of distinct indices is case~(1). In its case of a repeated index the exceptional set is contained in $\{\Omega=0\}\cup Z$, for a nonzero polynomial $\Omega$ and a finite set $Z$ whose degree and size are bounded by a constant $N$; the polynomial $P=\Omega\cdot\prod_{(z_1,z_2)\in Z}(h-z_1)$ is nonzero, has degree at most $2N$ and vanishes on this set, which gives case~(2) with $\Delta_4=2N$. Without A4, the general stratification results of Katz--Laumon \cite{katz-laumon} and Fouvry--Katz \cite{fouvry-katz}, made uniform by quantitative sheaf theory \cite{qst}, give the weaker conclusion that $|\widehat{\mathcal V}|$ is $O(p^3)$ off a curve and $O(p^{7/2})$ on it, except at a bounded set of points where only the trivial bound $O(p^4)$ is known. A single such point in case~(1) would make the resulting estimate trivial. In the formal proof Hypothesis~\ref{hyp:A4} is a premise of the dense Type~III theorems, but it is needed only for $5{,}520$ of the $21{,}763$ Type~III parameter choices in our argument (Section~\ref{sec:distribution}). The remaining choices use only Hypotheses~\ref{hyp:A1}--\ref{hyp:A3}, as in \cite{openai186}. The supplement reports a heuristic numerical test of A4 for primes up to $1009$ (\Supp{app:numerics}). \end{remark} \subsection{The numerical condition and the formal statement}\label{sec:numerical-condition} \begin{definition}[Numerical condition]\label{def:numerical} We write \textsf{Numerical} for the condition that all fourteen inequalities \textup{(N1)--(N14)} of Section~\ref{sec:fields} hold. These inequalities concern the fixed sieve weight used in this paper. \end{definition} The supporting computations use exact integer and rational arithmetic, ball arithmetic and IEEE double precision. Their error analyses are given in the supplement (Supplement, \S\S\sref{app:trust} and~\sref{app:errors}) but have not been machine-checked. Section~\ref{sec:weak} identifies the numerical inputs that still require justification. \begin{remark}[Archived data]\label{rem:tables} Statements (N9)--(N14), and the definition of the profile $F$ on which all fourteen depend, refer to stored data. The spline coefficients, knots and restriction tables are stored in \texttt{lean/proof/frozen\_band\_tables.json} in the archived release \cite{release}. The same release contains the schedule for (N9) and the constants for (N12)--(N14). Their locations in the Lean sources are listed in Supplement, \S\sref{sec:concordance}. We use the Lean definitions in the archived release \cite{release} for the function $F$ defined in Section~\ref{sec:spline}, the restriction defining $G$ in Section~\ref{sec:restriction}, and the numerical inequalities (N1)--(N14) stated in Section~\ref{sec:fields}. Supplement, \S\sref{sec:faithful-numerical} checks that the printed inequalities agree with their Lean definitions. \end{remark} \begin{remark}[The formal statement]\label{rem:formal} The implication in Theorem~\ref{thm:main} is proved in Lean~4, with A1--A4 and \textsf{Numerical} supplied as assumptions. From these inputs, the formal proof establishes the multidimensional sieve, the required distribution estimates, and the passage from the sieve inequality to the prime-gap bound. The proof uses only the three standard axioms of Lean's logic, in addition to the stated assumptions. \Supp{thm:formal} displays the formal statement. Supplement, \S\sref{sec:faithful-numerical} matches the printed inequalities (N1)--(N14) with their Lean definitions, and Supplement, \S\sref{sec:faithful} compares the formal statements of A1--A4 with those of Section~\ref{sec:hypotheses}. \end{remark}