\documentclass[11pt]{amsart} \usepackage[margin=2.6cm]{geometry} \usepackage{lmodern} \usepackage[T1]{fontenc} \usepackage{amsmath,amssymb,amsthm} \usepackage[hidelinks]{hyperref} \newtheorem{theorem}{Theorem} \newtheorem{corollary}[theorem]{Corollary} \newtheorem{lemma}[theorem]{Lemma} \theoremstyle{remark} \newtheorem{remark}[theorem]{Remark} \newcommand{\Fh}{\widehat F} \title{Explicit prime gaps and prime counts in short intervals\\ on the Riemann hypothesis} \author{David Niedbala Giraudin} \address{Independent researcher, France} \email{} \thanks{ORCID 0009-0009-1526-1178. This note was produced with Claude (Anthropic): the author directed the work and Claude carried it out. Nothing in this note has been checked by a third party.} \date{24 November 2026} \begin{document} \sloppy \begin{abstract} Assuming the Riemann hypothesis, Carneiro, Milinovich and Soundararajan proved that the interval $[x,x+\tfrac{22}{25}\sqrt{x}\log x]$ contains a prime for every $x\ge 4$. We show that $22/25=0.88$ can be replaced by $0.8513$, and we also prove the sharper explicit form $[x,\,x+0.8513\sqrt{x}\,(\log x-2\log\log x+2)]$ for every $x\ge 2$. The proof follows their Fourier-optimization framework, with a new bandlimited test function and a self-contained treatment of every error term; the range $x<10^{7}$ is checked by direct computation. We also prove that $[x,\,x+2.064\sqrt{x}\log x]$ contains more than $\sqrt x$ primes for every $x\ge6$, with similar explicit statements for $\tfrac12\sqrt x$, $2\sqrt x$ and $5\sqrt x$ primes; the previous explicit result of this kind needs length $(3+4/\log x)\sqrt x\log x$. We also prove that $[x,\,x+\sqrt x\log x]$ contains fewer than $2.044\sqrt x$ primes for every $x\ge2$. As by-products, the asymptotic constant $\limsup (p_{n+1}-p_n)/(\sqrt{p_n}\log p_n)$ on RH drops from $0.8358$ to $0.8345$, and the constant $0.8531$ of Chirre, Pereira J\'unior and de Laat for primes in arithmetic progressions on GRH drops to $0.8513$. \end{abstract} \maketitle \section{Results} Throughout, RH denotes the Riemann hypothesis. Labels: \textsc{proved} means proved here under the stated hypothesis, with the numerical inputs certified by the computation of Section~4 (double-precision floating point with explicit error terms and safety margins; not interval arithmetic). \begin{theorem}[\textsc{proved} on RH]\label{thm:main} For every real $x\ge 4$ the interval $[x,\;x+0.8513\sqrt{x}\log x]$ contains a prime. Consequently $p_{n+1}-p_n\le 0.8513\sqrt{p_n}\log p_n$ for every prime $p_n\ge 5$. \end{theorem} \begin{theorem}[\textsc{proved} on RH]\label{thm:refined} For every real $x\ge 2$ the interval $[x,\;x+0.8513\sqrt{x}\,(\log x-2\log\log x+2)]$ contains a prime. Consequently $p_{n+1}-p_n\le 0.8513\sqrt{p_n}\,(\log p_n-2\log\log p_n+2)$ for every $n\ge1$. \end{theorem} \begin{theorem}[\textsc{proved} on RH]\label{thm:count} For every real $x\ge 6$ the interval $[x,\;x+2.064\sqrt{x}\log x]$ contains more than $\sqrt x$ primes. \end{theorem} \begin{theorem}[\textsc{proved} on RH]\label{thm:alpha} Let $(\alpha,c,x_0)$ be one of $(\tfrac12,\,1.491,\,6)$, $(1,\,2.064,\,6)$, $(2,\,3.157,\,14)$, $(5,\,6.332,\,114)$. Then for every real $x\ge x_0$ the interval $[x,\;x+c\sqrt x\log x]$ contains more than $\alpha\sqrt x$ primes. \end{theorem} \begin{corollary}[\textsc{proved} on RH]\label{cor:line} Let $(A,B)$ be one of $(0.8468,\,0.7625)$, $(0.8940,\,0.8448)$, $(0.9310,\,0.9385)$, $(0.9495,\,1.0118)$. For every fixed $c>0$ and $\varepsilon>0$, and all sufficiently large $x$, \[ \pi(x+c\sqrt x\log x)-\pi(x)\;>\;(A\,c-B-\varepsilon)\sqrt x . \] \end{corollary} \begin{theorem}[\textsc{proved} on RH]\label{thm:upper} Let $(c,C)$ be one of $(\tfrac12,\,1.428)$, $(1,\,2.044)$, $(2,\,3.172)$, $(5,\,6.373)$. Then for every real $x\ge 2$ the interval $[x,\;x+c\sqrt x\log x]$ contains fewer than $C\sqrt x$ primes. \end{theorem} Unconditionally, the Brun--Titchmarsh inequality of \cite{MV} gives about $4c\sqrt x$ here. On RH, the explicit short-interval estimate of Cully-Hugill and Dudek \cite{CHD} implies about $(c+2+\tfrac1\pi\log c)\sqrt x$ for $c\ge1$, that is about $3$, $4.22$, $7.51$ for $c=1,2,5$. For comparison with Theorems~\ref{thm:count} and~\ref{thm:alpha}, with the same notation: Dudek \cite{Dud} has $c=3+\varepsilon$ for $\alpha=1$ and large $x$; Dudek, Greni\'e and Molteni \cite{DGM} prove, for all $x\ge2$, that an interval of length $(3+4/\log x)\sqrt x\log x$ centred at $x$ contains at least $\sqrt x$ primes; and \cite{CMS,CPL} give $c=(1+2\alpha)/\mathcal C^+(36/11)<0.8358(1+2\alpha)$ for large $x$, that is $1.672$, $2.508$, $4.179$, $9.194$ for the four values of $\alpha$ above. We have not found the constants of Theorems~\ref{thm:count} and~\ref{thm:alpha}, of Corollary~\ref{cor:line} or of Theorem~\ref{thm:upper} in the literature; this novelty has not been checked by anyone else. \begin{remark} A formal proof of the Riemann hypothesis, written in Lean, was released by L.~Alp\"oge on 20 November 2026, and on 21 November 2026 the Lean and Mathlib communities issued a joint statement certifying its statement and proof. If that proof stands, every result of this note stated ``on RH'' holds unconditionally. \end{remark} Theorem~\ref{thm:refined} implies Theorem~\ref{thm:main} for $x\ge e^{e}$. Its interval has length $0.693\sqrt x\log x$ at $x=10^{10}$ and $0.747\sqrt x\log x$ at $x=10^{20}$. The previous explicit constant is $22/25$ \cite[Theorem~5]{CMS}; it is still the one in use in 2024--2026 \cite{Car24,Joh26}. Each proof rests on a test function: an even function $F\in L^1(\mathbb R)$ whose Fourier transform $\Fh(t)=\int F(x)e^{-2\pi i x t}\,dx$ is supported in $[-N,N]$. For $A\ge1$ put \[ J_A(F)=\frac{F(0)-A\int_{|t|\ge1}\Fh(t)_+\,dt}{\|F\|_1}. \] In the notation of \cite{CMS}, $\mathcal C^+(A)\ge J_A(F)$ for every such $F$. \begin{theorem}[\textsc{proved}, computer-assisted]\label{thm:J} For the functions $F_4,F_{36}$ of Section~2, \[ J_4(F_4)\ge 1.174722,\qquad J_{36/11}(F_{36})\ge 1.198397 . \] Hence $\mathcal C^+(4)\ge1.174722$ and $\mathcal C^+(36/11)\ge 1.198397$. The previous bounds were $\mathcal C^+(4)\ge1.17233$ and $\mathcal C^+(36/11)\ge1.1965$ \cite{CPL}; \cite{CMS} had $\mathcal C^+(36/11)>1.1943$. \end{theorem} \begin{corollary}[\textsc{proved} on RH, via {\cite[Cor.~4]{CMS}}] $\displaystyle\limsup_{n\to\infty}\frac{p_{n+1}-p_n}{\sqrt{p_n}\log p_n}\le\frac{1}{\mathcal C^+(36/11)}<0.8345$. The previous constant was $0.8358$ \cite{CPL}. \end{corollary} \begin{corollary}[\textsc{proved} on GRH, via {\cite[Thm.~1, Cor.~2]{CPL}}] Let $q\ge3$ and $(b,q)=1$. In \cite[Theorem~1]{CPL} the bound $(1+2\alpha)/\mathcal C^+(4)<0.8531(1+2\alpha)$ may be replaced by $<0.8513(1+2\alpha)$. In particular $\limsup (p_{n+1,q,b}-p_{n,q,b})/(\sqrt{p_{n,q,b}}\log p_{n,q,b})<0.8513\,\varphi(q)$. \end{corollary} \begin{corollary}[\textsc{proved} on RH]\label{cor:back} \textup{(a)} For every $y\ge 11$ the interval $[\,y-0.8513\sqrt y\log y,\;y\,]$ contains a prime. \textup{(b)} For every $x\ge 8\cdot10^{88}$ the interval $[x,\;x+x^{1/2+1/40}]$ contains a prime. With the constant $22/25$ the corresponding threshold is $3.5\cdot10^{90}$ \cite{Joh26}. \end{corollary} \begin{proof} (a) Put $x=y-0.8513\sqrt y\log y$. This is increasing in $y$ for $y\ge11$ and exceeds $4.2$ at $y=11$, so $x\ge4$. Since $x\le y$, we have $x+0.8513\sqrt x\log x\le y$, and Theorem~\ref{thm:main} gives a prime in $[x,y]$. (b) Put $\ell=\log x$ and $f(\ell)=0.8513(\ell-2\log\ell+2)-e^{\ell/40}$. Then $f(\log(8\cdot10^{88}))<-0.03$ and $f'(\ell)=0.8513(1-2/\ell)-e^{\ell/40}/40<0$ for $\ell\ge 204$. So $0.8513\sqrt x(\ell-2\log\ell+2)\le x^{1/2+1/40}$ for $x\ge8\cdot10^{88}$, and Theorem~\ref{thm:refined} applies. \end{proof} \section{The test functions} Fix $N>1$ and real $b_0,\dots,b_{K-1}$, and put $\omega_k=(2k+1)\pi/(2N)$. Define \[ g(t)=\sum_{kN),\qquad F(x)=\int_{-N}^{N} g(t)e^{2\pi i x t}\,dt . \] Since $\cos(\omega_k N)=0$, $g$ is continuous with $g(\pm N)=0$, and \[ F(x)=\cos(2\pi N x)\sum_{k0$ on $[N-0.05,N]$ with $g(N)=0$. Hence on $[1,N]$ the function $g_+$ is non-increasing, positive on $[1,t^*)$ and zero on $[t^*,N]$. Then $J_4(F_4)=(F(0)-8I)/\|F\|_1\ge(F(0)-8I)/U\ge1.174722$, and $1/1.174722<0.851266$. For $F=F_{36}$: $J_{36/11}\ge 1.198397$, so $1/J<0.834448$. \section{How the numbers are certified} $F(0)$ is a finite sum. For $\int_1^N g_+$, $[1,N]$ is cut into $2\cdot10^6$ cells of width $w$, and on each cell $g\le g(\text{mid})+\tfrac w2\sum|b_k|\omega_k$. For $\|F\|_1$ and $L_F$, $[0,4000]$ is cut into cells of width $2\cdot10^{-4}$ on $[0,10]$ and $10^{-3}$ beyond. On a cell with midpoint $m$ we use \[ \Bigl|\,|F(x)|-|F(m)+F'(m)(x-m)|\,\Bigr|\le \tfrac12(x-m)^2\sup_{\text{cell}}|F''|, \] so that $\int_{\text{cell}}|F|$ lies within $h^3\sup|F''|/24$ of the exactly computed integral of $|F(m)+F'(m)(x-m)|$. Here $|F''|\le 4\pi^2\sum|b_k|\cdot 2N^3/3$ on $[0,10]$. For $x\ge10$, writing $C=\sum_k 2\omega_k|b_k|$ (note $4\pi^2x^2\ge2\max\omega_k^2$), \[ |F''(x)|\le \frac{2N^2C}{x^2}+\frac{8NC}{\pi x^3}+\frac{18C}{\pi^2x^4},\qquad |F(x)|\le\frac{C}{2\pi^2x^2}. \] The tails beyond $4000$ are bounded by $C/(2\pi^2X)$ and $C(\log X+1)/(2\pi^2X)$. A relative margin $10^{-9}$ is added for rounding. The same scheme, with a first-order remainder, bounds $\int|F'|$. \section{Proof of Theorems \ref{thm:main} and \ref{thm:refined} for $x\ge10^7$} Assume RH and let $x\ge10^{7}$. Write $h=0.8513\sqrt x\log x$ for Theorem~\ref{thm:main}, or $h=0.8513\sqrt x(\log x-2\log\log x+2)$ for Theorem~\ref{thm:refined}. Suppose that $[x,x+h]$ contains no prime. Put \[ a=\sqrt{x(x+h)},\qquad 2\pi\Delta=\tfrac12\log(1+h/x), \] so that $[x,x+h]=[ae^{-2\pi\Delta},ae^{2\pi\Delta}]$. Put $v=h/x$, $\Lambda_0=2\pi\Delta\sqrt a$ and $u_n=\log(n/a)/(2\pi\Delta)$. Let $F=F_4$, $g=\Fh$. \subsection*{Explicit formula} Apply the Guinand--Weil explicit formula \cite[Ch.~5]{IK} to $\phi(r)=F(\Delta r)\cos(r\log a)$. This $\phi$ is entire, and $\phi(r)\ll(1+|r|)^{-2}$ in $|\operatorname{Im}r|\le1$: integrate $\int g(t)e^{2\pi i\Delta rt}dt$ by parts twice, using $g(\pm N)=0$. Its Fourier transform is $\tfrac12[G(u-\log a)+G(u+\log a)]$ with $G(u)=g(u/2\pi\Delta)/(2\pi\Delta)$, which vanishes near $0$ since $\log a>2\pi\Delta N$. Summing over the zeros $\tfrac12+i\gamma$ of $\zeta$, multiplying by $2\pi\Delta$ and rearranging gives \begin{equation}\label{eq:EF} 2\pi\Delta(\sqrt a+a^{-1/2})\int g(t)\cosh(\pi\Delta t)\,dt =2\pi\Delta\sum_\gamma \phi(\gamma)-2\pi\Delta\,\Gamma_\phi+\sum_{n}\frac{\Lambda(n)}{\sqrt n}\,g(u_n), \end{equation} where $\Gamma_\phi=\frac1{2\pi}\int \phi(r)\operatorname{Re}\psi(\tfrac14+\tfrac{ir}2)dr$. From $\psi(z)=\int_0^\infty(e^{-s}/s-e^{-zs}/(1-e^{-s}))ds$ and the vanishing of the transform near $0$, \[ \Gamma_\phi=-\int_{\mathbb R}\hat \phi(u)\,\frac{e^{-|u|/2}}{1-e^{-2|u|}}\,du,\qquad\text{so}\qquad 2\pi\Delta|\Gamma_\phi|\le\varepsilon_\Gamma:=2\pi\Delta\int|g|\cdot\frac{e^{-u_0/2}}{1-e^{-2u_0}}, \] with $u_0=\log a-2\pi\Delta N$. On the left of \eqref{eq:EF}, $\bigl|\int g(\cosh(\pi\Delta t)-1)\bigr|\le(\cosh(\pi\Delta N)-1)\int|g|$. \subsection*{Zeros} On RH, $2\pi\Delta\sum_\gamma|\phi(\gamma)|\le 4\pi\Delta\sum_{\gamma>0}|F(\Delta\gamma)|$. Write $N(t)=M(t)+R(t)$ with $M(t)=\frac t{2\pi}\log\frac t{2\pi e}+\frac78$. Trudgian's bound \cite{Tru} gives $|R(t)|\le0.112\log t+0.278\log\log t+2.51+0.2/t\le0.39\log t+2.53$ for $t\ge14$. Also $N(14)=0$ and $M(14)<0.433$. Stieltjes integration by parts then gives \[ 2\pi\Delta\sum_\gamma|\phi(\gamma)|\le\|F\|_1\log\frac1{2\pi\Delta}+L_F+\varepsilon_Z, \] where \[ \varepsilon_Z=2\pi\Delta\Bigl(2\max|F|+2\bigl[0.433\max|F|+(0.39\log\tfrac1\Delta+2.53)\!\int\!|F'|+0.39\!\int\!|F'|\log^+\bigr]\Bigr), \] and $\max|F|\le\int|g|$. \subsection*{Primes and prime powers} Prime powers $p^k$ with $k\ge2$ and $|u|\le N$ contribute at most $\varepsilon_{pp}=\max|g|\,\frac{\log a_+}{\sqrt{a_-}}\sum_{2\le k\le\log_2a_+}(a_+^{1/k}-a_-^{1/k}+1)$, where $a_\pm=ae^{\pm2\pi\Delta N}$. No prime has $|u_p|\le1$. For $10$). We evaluated $S(x)$ at $6001$ points $\log_{10}x\in[7,150]$: it is negative and decreasing, with maximum $-2.2985$ (Theorem~\ref{thm:main}) and $-0.2972$ (Theorem~\ref{thm:refined}), both attained at $x=10^7$; consecutive grid values differ by less than $0.009$. For $x>10^{150}$ write $\ell=\log x\ge345$. All $\varepsilon$ terms and $v$ are below $10^{-60}$, so $0.8513\,J_\varepsilon(1-v/2)\ge1$ (recall $0.8513\,J_4(F_4)>1.00004$), and $Q/\|F\|_1\le-0.593+10^{-60}$. Using $\Lambda_0\ge\frac h{2\sqrt x}(1-\frac v2)$ and $\log\frac1{2\pi\Delta}\le\log\frac2v+v=\frac\ell2+\log\frac{2\sqrt x}{h}+v$, one gets $S(x)\le\log\frac2{0.8513}-\log\ell-0.593+10^{-50}<0$ for Theorem~\ref{thm:main}, and $S(x)\le\log\frac{\ell}{\ell-2\log\ell+2}-1+\log\frac2{0.8513}-0.593+10^{-50}\le0.029-0.146-0.593<0$ for Theorem~\ref{thm:refined}. Since the inequality above says $S(x)\ge0$, this is a contradiction. Hence $[x,x+h]$ contains a prime for all $x\ge10^7$. \section{The range $x<10^7$} A sieve up to $1.01\cdot10^7$ shows that every gap between consecutive primes $p<10^7$ satisfies $p_{n+1}-p_n\le0.8513\sqrt{p_n}\log p_n$ for $p_n\ge5$ (largest ratio $0.913$, at $p=7$), and $p_{n+1}-p_n\le0.8513\sqrt{p_n}(\log p_n-2\log\log p_n+2)$ for all $p_n\ge2$. The function $\sqrt x\log x$ increases for $x\ge1$, and $\sqrt x(\log x-2\log\log x+2)$ increases for $x\ge e^{0.8}$ (its derivative has the sign of $\ell-2\log\ell-4/\ell+4$ with $\ell=\log x$, which is increasing in $\ell$ and positive at $\ell=0.8$). So the check at primes covers all $x\in[5,10^7]$ for Theorem~\ref{thm:main} and all $x\in[3.4,10^7]$ for Theorem~\ref{thm:refined}. Direct inspection covers $x\in[4,5)$ for Theorem~\ref{thm:main} and $x\in[2,3.4]$ for Theorem~\ref{thm:refined}. For $x$ just below $10^7$ the next prime $10000019$ is used. \section{Counting primes: proof of Theorems \ref{thm:count}, \ref{thm:alpha} and Corollary \ref{cor:line}} Let $F$ be a test function as in Section~2, $g=\Fh$, and put \[ m=\sup_{|t|\le1}g(t)_+,\qquad I=\int_1^N g_+,\qquad V=\int_1^N|g'|,\qquad c^*(\alpha)=\frac{\|F\|_1+2\alpha m}{F(0)-8I}. \] Let $x\ge10^7$, $h=c\sqrt x\log x$, and suppose that $[x,x+h]$ contains at most $\alpha\sqrt x$ primes. We repeat the argument of Section~5 with two changes. First, a prime $p\in[x,x+h]$ has $|u_p|\le1$ and contributes at most $m\log p/\sqrt p\le m\log x/\sqrt x$ to the prime sum in \eqref{eq:EF}, so these primes contribute at most $\alpha m\log x$ in total. Second, we no longer assume that $g_+$ is monotone on $[1,N]$: with the same cells as in Section~5, the sum over cells of $\sup g_+$ is at most $V+\Lambda_0(1+a^{-1/2})I$, so $g(1)$ is replaced by $V$. This gives \begin{align*} \Lambda_0\Bigl[F(0)-2(\cosh(\pi\Delta N)-1)\!\int\!|g|&-8(1+\varepsilon_1)(1+a^{-1/2})I\Bigr]\\ &\le\|F\|_1\log\frac1{2\pi\Delta}+L_F+\varepsilon_Z+\varepsilon_\Gamma+\varepsilon_{pp}+8(1+\varepsilon_1)V+\alpha m\log x . \end{align*} Since $\Lambda_0\sim\tfrac c2\log x$ and $\log\frac1{2\pi\Delta}=\tfrac12\log x-\log\log x+O(1)$, this fails for all large $x$ as soon as $c>c^*(\alpha)$, that is, as soon as $\alpha10^{150}$ the same asymptotic argument as in Section~5 applies, since $c-c^*(1)>0$ and the term $-\|F\|_1\log\log x$ is negative. So the interval contains more than $\sqrt x$ primes for all $x\ge10^7$. For $x<10^7$ we use the sieve. For consecutive primes $p_n\sqrt{p_{n+1}}$ in every case (smallest ratio $1.83$ for $p_n>1000$). Since $x+2.064\sqrt x\log x$ is increasing, this covers every $x\in[11,10^7]$. The range $6\le x\le11$ is checked directly. The other three cases of Theorem~\ref{thm:alpha} are proved in the same way with $F^{(1/2)},F^{(2)},F^{(5)}$; all their data are printed by the ancillary script. The maximum of the corresponding function $S_3$ on $[10^7,10^{150}]$ is $-3.7503$, $-4.7377$ and $-4.7454$ respectively, attained at $x=10^7$. Below $10^7$, the sieve condition $A_n>\alpha\sqrt{p_{n+1}}$ holds for all $p_n\ge7$, $29$, $127$ respectively, and the ranges $[6,7]$, $[14,29]$, $[114,127]$ are checked directly. \section{Upper bounds: proof of Theorem \ref{thm:upper}} Let $F$ be a test function as in Section~2 with $g=\Fh\ge0$ on $[-N,N]$, and let $\mu=\min_{|t|\le1}g(t)>0$. Let $x\ge10^7$, $h=c\sqrt x\log x$, and let $M$ be the number of primes in $[x,x+h]$. In \eqref{eq:EF} every term of the sum over $n$ is non-negative, and a prime $p\in[x,x+h]$ contributes at least $\mu\log p/\sqrt p\ge\mu\log(x+h)/\sqrt{x+h}$. Bounding the right side of \eqref{eq:EF} as in Section~5 gives \[ M\,\mu\,\frac{\log(x+h)}{\sqrt{x+h}}\le\Lambda_0(1+a^{-1})\Bigl[F(0)+(\cosh(\pi\Delta N)-1)\!\int\! g\Bigr]+\|F\|_1\log\frac1{2\pi\Delta}+L_F+\varepsilon_Z+\varepsilon_\Gamma . \] Write this as $M\le T(x)\sqrt x$. Since $\Lambda_0\le\frac c2\log x\cdot(1+v)^{1/4}$ and $\log\frac1{2\pi\Delta}\le\frac12\log x-\log\log x+\log\frac2c+v$, we get $\limsup T(x)\le C_\infty:=(cF(0)+\|F\|_1)/(2\mu)$. The ancillary file gives four such functions (with $K=22$ and $N=1.8,\,1.45,\,1.3,\,1.1$ for $c=\tfrac12,1,2,5$). For each, the script certifies $g>0$ on $[1,N-0.05]$, $g'<0$ on $[N-0.05,N]$ (so $g\ge0$ on $[1,N]$ because $g(N)=0$), $\mu\ge0.9999$, and \[ C_\infty\le1.426727,\quad 2.042276,\quad 3.170473,\quad 6.371236 \] respectively. On $3001$ grid points $\log_{10}x\in[7,150]$ the maximum of $T$ is $1.39851$, $2.00863$, $3.13073$, $6.32142$, each below the corresponding $C$. For $x>10^{150}$ we have $\|F\|_1(\log\frac2c-\log\log x)+L_F<0$ in all four cases, so $T(x)\le C_\infty(1+10^{-50})