arXiv · 2612.00059
A probable-prime test with a proven per-input error bound from anchored roots of unity
Abstract
We describe A4, a probabilistic primality test with one-sided error. A prime is never rejected. For every composite $n$ the answer "probable prime" has probability at most $2^{-e}$ over the random choices of the test (independent, uniform and unknown to whoever chose $n$), where $e\ge k$ is computed from $n$ before any random choice and printed with the answer. The test takes roots of unity from the small prime factors of $n-1$ and $n+1$ that trial division finds, verifies with one or two fixed exponentiations that their orders are exact modulo every prime divisor of $n$, and requires random elements of $(\mathbb{Z}/n)^*$ and of a quadratic extension to project into the cyclic groups that these roots generate. From about 1000 bits on (for $k=128$), one Frobenius condition settles composites with at most four prime factors, by the estimates of Damgård and Frandsen; for five or more, the logarithms of the verified orders, summed over the rounds, must reach $k/4$. On 424 random primes of 512 to 8192 bits, drawn after the planner of version 1 was tuned, a decision with the proven bound $2^{-128}$ cost 5.4 to 7.7 Miller-Rabin rounds on average, against 19 to 26 for Seysen's SQFT3 in the same arithmetic and 64 for Miller-Rabin itself; A4 was faster than SQFT3 on 423 of the 424 primes. Baillie-PSW, which has no proven bound, was 2 to 3 times faster than A4, and SQFT3 rejected products of two random primes slightly faster. Inputs whose $n^2-1$ has few small prime factors gain nothing. The ingredients are published; the contributions are their combination under one exponent proved for each input from the orders verified on both sides of $n$, three refinements, their proofs, and measurements. The counting lemmas and the acceptance sets of the program were checked by exhaustive enumeration on small moduli.
Explore related subjects
Keep this discovery
Explore connections, maps & timelines
Alper Ferudun. 2026-11-29. A probable-prime test with a proven per-input error bound from anchored roots of unity. https://searcharxiv.org/abs/2612.00059
Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite Search arXiv by Indiciae: BibTeX · RIS.