Dual View Random Solved Random Open
OPEN This is open, and cannot be resolved with a finite computation.
Is every sufficiently large integer of the form\[ap^2+b\]for some prime $p$ and integer $a\geq 1$ and $0\leq b<p$?
Disclaimer: The open status of this problem reflects the current belief of the owner of this website. There may be literature on this problem that I am unaware of, which may partially or completely solve the stated problem. Please do your own literature search before expending significant effort on solving this problem. If you find any relevant literature not mentioned here, please add this in a comment.
The sieve of Eratosthenes implies that almost all integers are of this form, and the Brun-Selberg sieve implies the number of exceptions in $[1,x]$ is $\ll x/(\log x)^c$ for some constant $c>0$. Erdős [Er79] believed it is 'rather unlikely' that all large integers are of this form.

What if the condition that $p$ is prime is omitted? Selfridge and Wagstaff made a 'preliminary computer search' and suggested that there are infinitely many $n$ not of this form even without the condition that $p$ is prime. It should be true that the number of exceptions in $[1,x]$ is $<x^c$ for some constant $c<1$.

Most generally, given some infinite set $A\subseteq \mathbb{N}$ and function $f:A\to \mathbb{N}$ one can ask for sufficient conditions on $A$ and $f$ that guarantee every large number (or almost all numbers) can be written as\[am^2+b\]for some $m\in A$ and $a\geq 1$ and $0\leq b<f(m)$.

In another direction, one can ask what is the minimal $c_n$ such that $n$ can be written as $n=ap^2+b$ with $0\leq b<c_np$ for some $p\leq \sqrt{n}$. This problem asks whether $c_n\leq 1$ eventually, but in [Er79d] Erdős suggests that in fact $\limsup c_n=\infty$. Is it true that $c_n<n^{o(1)}$?

View the LaTeX source

External data from the database - you can help update this
Formalised statement? No (Create a formalisation here)
Related OEIS sequences: A390181 in progress
Likes this problem old-bielefelder
Interested in collaborating None
Currently working on this problem None
This problem looks difficult None
This problem looks tractable None

When referring to this problem, please use the original sources of Erdős. If you wish to acknowledge this website, the recommended citation format is:

T. F. Bloom, Erdős Problem #676, https://www.erdosproblems.com/676, accessed 2026-01-16