SearcharxivSearch

arXiv · 2604.02383

Neural Prime Sieves: Density-Driven Generalization and Empirical Evidence for Hardy-Littlewood Asymptotics

Abstract

Special prime families (twin, Sophie Germain, safe, cousin, sexy, Chen, and isolated primes) are central objects of analytic number theory, yet no efficiently computable probabilistic filter exists for identifying likely members among known primes at large scale. Classical sieves assign no probability weights to surviving candidates, and prior machine learning approaches are limited by the algorithmic randomness of the prime indicator sequence, yielding near-zero true positive rates. We present PrimeFamilyNet, a multi-head residual network conditioned on the backward prime gap and modular primorial residues of a known prime $p$, learning probabilistic filters for all seven families simultaneously and generalising across nine orders of magnitude from training ($10^7$--$10^9$) to evaluation at $10^{16}$. Isolated prime recall increased monotonically from $0.809$ at $5\times10^8$ to $0.984$ at $10^{16}$, a gain of $17.5$ percentage points and the only family among seven to improve with scale. Because recall is invariant to class prevalence, this reflects genuine decision boundary sharpening, not the rising isolated-prime fraction at extreme scales. A model trained only to $10^9$ reproduced the correct asymptotic direction without density supervision, corroborating Hardy--Littlewood $k$-tuple predictions. The causal model retained over $95\%$ recall for five families near $10^{10}$ while reducing the search space by $62$--$88\%$. For Chen primes, causal recall exceeded non-causal recall at every scale (margin $+0.245$ at $10^{16}$) because $g^+=2$ encodes only the prime case of the Chen condition. Focal Loss collapsed sparse algebraic family recall to $0.000$. Asymmetric Loss outperformed weighted BCE in-distribution but degraded more steeply out-of-distribution, showing that in-distribution recall alone is a misleading criterion for scale-generalisation tasks.

Explore related subjects

Keep this discovery

BibTeXRIS

Manik Kakkar. 2026-04-01. Neural Prime Sieves: Density-Driven Generalization and Empirical Evidence for Hardy-Littlewood Asymptotics. https://arxiv.org/abs/2604.02383

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

Average Chord Lengths in a Triangle

Let $P$ be a point inside a triangle $T$. We consider the average length of the chords of $T$ through $P$, where the direction of the chord is chosen uniformly. An elementary formula is obtained in terms of the distances from $P$ to the sides and vertices of the triangle. Several classical triangle centers give especially simple specializations. For example, if $I$ is the incenter, then \[ M_T(I)=\frac{2r}{\pi} \log\left(\cot\frac A4\cot\frac B4\cot\frac C4\right). \] Our main result is the sharp inequality \[ M_T(P)\le \frac{p}{\pi\sqrt3}\log(2+\sqrt3), \] valid simultaneously for every triangle of perimeter $p$ and every interior point $P$. Thus, among all such pairs $(T,P)$, the largest possible average chord length occurs only when $T$ is equilateral and $P$ is its center. The proof is an elementary symmetrization argument. We close with brief remarks relating the problem to the radial center of a convex body, the electrostatic potential center of a triangle, and dual quermassintegrals.

math.GM

A Proof of Liu's Conjecture on the Fundamental Triangle Inequality

Let $a,b,c$ be the side lengths of a triangle, and let $R$ and $r$ denote its circumradius and inradius, respectively. We prove a conjecture of Liu stating that \[\sum_{\mathrm{cyc}} \left(\frac{a(b+c-a)}{bc}\right)^k \geq 2+\left(\frac{2r}{R}\right)^k,~~k>1, \] with the reverse inequality for $0<k<1$. The proof reduces the problem to three positive variables with fixed sum and product. We also determine the equality cases.

math.GM