About sets of polynomials that give prime outputs

188 Views Asked by At

It is known that there is no polynomial with natural domain that gives all prime numbers as outputs ( http://mathworld.wolfram.com/Prime-GeneratingPolynomial.html ).

I have two related questions:

1) Could one make a piece-wise defined function of such types (polynomials) that gives all prime numbers and follow some pattern? For example, for the first 40 $n$ the function is given by the Euler example, for the next $a$ numbers, it's given by another polynomial, and so on, and cover ALL prime numbers this way and we can know which polynomials we are to use next (because of a pattern)?

2) Could there be a polynomial that gives all prime numbers after a certain $n$ of input? How to prove that one can't have such polynomial (if this is the case, that I suspect it is)?

I think the questions are closely related, so I've made two questions in one post. Sorry for my English, it's not my mother tongue, so, feel free to edit my question to make it better.

1

There are 1 best solutions below

1
On BEST ANSWER

$1)$ Of course, you can capture , lets say, $100$ primes with some polynomial (interpolattion), the next $100$ primes with another polynomial and so on. But this is of no use because we must already know the primes. There will not be a set of polynomials known before doing the job. The polynomials $4n+1$ and $4n+3$ cover all odd primes but not in the desired sense.

$2)$ No, such a polynomial is impoosible. Lets say, the prime $s$ divides $f(m)$, then $s$ also divides $f(ks+m)$ for all non-negative integers $k$, hence there are infinite many composite values, hence we never have a point where only primes occur afterwards.