reviewed
approved
reviewed
approved
proposed
reviewed
editing
proposed
(PARI) pr(p) = my(pr=1); forprime(q=2, p, pr *= q); pr;
a(n) = my(p=2, P=pr(prime(n))); while (!ispseudoprime(P*pr(p)-1), p = nextprime(p+1)); p; \\ Michel Marcus, Sep 11 2021
proposed
editing
editing
proposed
2*2-1 = 3 is prime , 2 = p(1)# , so a(1) = 2.
2*3*2-1 = 11 is prime , 2*3 = p(2)# , so a(2) = 2.
2*3*5*2-1 = 59 is prime , 2*3*5 = p(3)# , so a(3) = 2.
2*3*5*7*2-1 = 419 is prime , 2*3*5*7 = p(4)# , so a(4) = 2.
2*3*5*7*11*2*3-1 = 13859 is prime , 2*3*5*7*11 = p(5)# , so a(5) = 3.
Cf. A002110.
Least a(n) is the least prime p such that pprime(n)# * p# - 1 is prime.
2, 2, 2, 2, 3, 3, 2, 2, 13, 3, 13, 2, 3, 11, 7, 37, 151, 11, 113, 2, 5, 2, 401, 73, 7, 109, 3, 7, 101, 2, 11, 109, 5, 277, 11, 7, 31, 89, 191, 31, 11, 2713, 11, 13, 73, 461, 17, 17, 5, 41, 257, 17, 127, 1307, 53, 71, 281, 829, 139, 269, 137, 7, 41, 19, 107, 89
pr[n_] := Product[Prime[i], {i, 1, n}]; a[n_] := Module[{prn = pr[n], k = 1}, While[!PrimeQ[prn*pr[k] - 1], k++]; Prime[k]]; Array[a, 50] (* Amiram Eldar, Sep 11 2021 *)
More terms from Amiram Eldar, Sep 11 2021
approved
editing
_Pierre CAMI (pierre-cami(AT)bbox.fr), _, May 15 2006
Pierre CAMI (pierrecamipierre-cami(AT)tele2bbox.fr), May 15 2006
Least prime p such that p(n)#*p#-1 is prime.
2, 2, 2, 2, 3, 3, 2, 2, 13, 3, 13, 2, 3, 11, 7, 37, 151, 11, 113, 2, 5, 2, 401, 73, 7, 109, 3, 7, 101, 2, 11, 109, 5, 277, 11, 7, 31, 89, 191, 31, 11, 2713, 11, 13, 73, 461
1,1
2*2-1=3 prime 2=p(1)# so a(1)=2
2*3*2-1=11 prime 2*3=p(2)# so a(2)=2
2*3*5*2-1=59 prime 2*3*5=p(3)# so a(3)=2
2*3*5*7*2-1=419 prime 2*3*5*7=p(4)# so a(4)=2
2*3*5*7*11*2*3-1=13859 prime 2*3*5*7*11=p(5)# so a(5)=3
nonn,new
Pierre CAMI (pierrecami(AT)tele2.fr), May 15 2006
approved