cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A345706 a(n) is the least exponent k > 0 of the n-th prime such that (Product_{j=1..n-1} prime(j)) * prime(n)^k + 1 is a Euclid-Pocklington prime (A053341).

This page as a plain text file.
%I A345706 #6 Jun 25 2021 02:35:30
%S A345706 1,1,2,2,3,6,5,12,9,8,10,9,20,14,24,18,12,16,58,26,20,30,42,322,276,
%T A345706 27,25,48,27,208,38,77,48,55,414,94,67,107,53,33,56,38,34,52,60,60,
%U A345706 483,41,155,105,43,476,68,126,51,387,49,121,46,65,395,68,78,308
%N A345706 a(n) is the least exponent k > 0 of the n-th prime such that (Product_{j=1..n-1} prime(j)) * prime(n)^k + 1 is a Euclid-Pocklington prime (A053341).
%C A345706 The corresponding primes are 3, 7, 151, 1471, 279511, 11149928791, 42638305711, 1129919399332465852111, ...
%e A345706 a(1) = 1 since prime(1) = 2, 2^1 > 1 and 2 + 1 = 3 is a prime.
%e A345706 a(2) = 1 since prime(2) = 3, 3^1 > 2 and 2*3 + 1 = 7 is a prime.
%e A345706 a(3) = 2 since prime(3) = 5, 5^2 > 2*3 and 2*3*5^2 + 1 = 151 is a prime.
%t A345706 a[n_] := Module[{r = Product[Prime[j], {j, 1, n - 1}], p = Prime[n], k}, k = Max[1, Ceiling @ Log[p, r]]; While[!PrimeQ[r*p^k + 1], k++]; k]; Array[a, 64]
%Y A345706 Cf. A053341.
%K A345706 nonn
%O A345706 1,3
%A A345706 _Amiram Eldar_, Jun 24 2021