# Are there infinitely many primes of form $\underbrace{3\dots3}_n{}1$?

The following numbers are prime:

$31$
$331$
$3331$
$33331$
$333331$
$3333331$
$33333331$

Which made me think, is there something we can use to prove/disprove the statement that there are infinitely many primes of this form?

More precisely, can we prove/disprove that there are infinitely many primes of form:

$$\frac{10^{n+1}-7}{3}$$

This is prime for $n=1,2,3,4,5,6,7,17,39,49,59\dots$ since I tested all $n\le60$

The only proofs for "infinitely many primes of form X" I know of are using the Dirichlet's theorem, but I don't see that it would be helpful in cases like this one.

• This seems no easier than the question: are there infinitely many primes of the form $2^n-1$? And that one is a known open question. Apr 9, 2017 at 9:55
• Just for trivia, it was proved (in 1997) that there are infinitely many primes of the form $x^2+y^4$ also. It's called the Friedlander-Iwaniec theorem. However, no results come even close to the kind of result you are asking for. Apr 9, 2017 at 10:31
• Another open problem that looks even easier is whether $x^2+1$ is prime for infinite many positive integers $x$. More general, no polynomial with integer coefficients and degree greater than $1$ is known to produce infinite many primes. Apr 10, 2017 at 12:35
• Apr 19, 2017 at 18:43

A proof that there are infinite many primes of this form seems to be out of reach, but since the sequence is not increasing very fast and the $$gcd$$ of the numbers seems to be $$1$$, there are probably infinite many. The first few $$n$$ giving proven primes , calculated with PARI/GP are :

? for(n=1,500,m=(10^(n+1)-7)/3;if(isprime(m,2)==1,print1(n," ")))
1 2 3 4 5 6 7 17 39 49 59 77 100 150 318 381
?


You can also look up the known primes in this superb factorization database :

http://factordb.com/index.php?query=%2810%5E%28n%2B1%29-7%29%2F3&use=n&n=1&sent=Show&VP=on&VC=on&EV=on&OD=on&PR=on&PRP=on&U=on&perpage=20&format=1

• The database approves that $n=783,1731$ and $1917$ give the next primes coinciding with my pseudoprime-rotuine PARI/GP giving the same values. Apr 10, 2017 at 10:54
• Note that the isprime test is not pseudo Apr 10, 2017 at 10:58
• @HagenvonEitzen isprime(n,2) proves the prime and isprime gives a "very probable" prime. But for numbers with more than $500$ digits it is generally quite slow. Apr 10, 2017 at 11:01
• Hm, according to what my PARi tells me in documentation, the result of isprime is always based on proven primality or compositeness, no matter if/what you have as second parameter (hough the proof may not always be output). Only ispseudoprime test for "very probable" prime .. Apr 10, 2017 at 12:11
• Since this question won't get an answer with a proof unless there is some significant breakthrough, I'll accept this answer. Jun 6, 2017 at 16:14