A085752 Duplicate of A074966.
1, 1, 2, 1, 12, 7, 4, 43, 10, 19, 62, 35, 16, 27, 28, 13, 74, 107, 18, 91, 32, 87, 14, 95, 96
Offset: 1
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.
PrimePrevDelta[n_]:=Module[{k},k=n-1;While[ !PrimeQ[k],k-- ];k=n-k]; lst={};Do[AppendTo[lst,PrimePrevDelta[n^n]],{n,2,5!}];lst (* Vladimir Joseph Stephan Orlovsky, Jun 11 2009 *) lk[n_]:=Module[{nn=n^n},nn-NextPrime[nn,-1]]; Array[lk,70,2] (* Harvey P. Dale, Jan 20 2019 *)
a(n)=(x->x-precprime(x))(n^n) \\ Charles R Greathouse IV, Nov 25 2014
[NextPrime(n^n): n in [1..20]]; // Vincenzo Librandi, Sep 04 2017
Table[NextPrime[n^n], {n, 20}] (* Vincenzo Librandi, Sep 04 2017 *)
a(n) = nextprime(n^n); \\ Michel Marcus, Aug 20 2019
3 <- 2^2 -> 5; 5 - 3 = 2; 23 <- 3^3 -> 29; 29 - 23 = 6.
for n from 2 to 100 do nn := n^n ; printf("%d,",nextprime(nn)-prevprime(nn) ) ; od: # R. J. Mathar, Jun 12 2009
PrimeNext[n_]:=Module[{k},k=n+1;While[ !PrimeQ[k],k++ ];k]; PrimePrev[n_]:=Module[{k}, k=n-1;While[ !PrimeQ[k],k-- ];k]; DeltaY[n_]:=PrimeNext[n]-PrimePrev[n]; lst={};Do[AppendTo[lst,DeltaY[n^n]],{n,2,5!}];lst npnn[n_]:=Module[{nn=n^n},NextPrime[nn]-NextPrime[nn,-1]]; Array[npnn,60,2] (* Harvey P. Dale, Dec 07 2013 *)
n Previous P n^n Next P a(n) A098681(n) A000312(n) A098682(n) 2 3 4 5 0 3 23 27 29 1 4 251 256 257 2 5 3121 3125 3137 -4 6 46649 46656 46663 0 7 823541 823543 823547 -1 8 16777213 16777216 16777259 -20 9 387420479 387420489 387420499 0 10 9999999967 10000000000 10000000019 7
a:= n-> (m-> m-(prevprime(m)+nextprime(m))/2)(n^n): seq(a(n), n=2..65); # Alois P. Heinz, Mar 10 2020
for(n=2,61, my(f=n^n); print1(f-(precprime(f)+nextprime(f))/2,", "))
isok(k) = ispseudoprime(k^k + 9); \\ Altug Alkan, Mar 16 2018
a(5)=2994 because 5^5^5 + 2994 is prime and 5^5^5 + k is composite for 0<k<2994.
a(n)=(x->nextprime(x)-x)(n^n^n) \\ Charles R Greathouse IV, Nov 25 2014
a(5)=10978 because 5^5^5 - 10978 is a prime and 5^5^5 - k is composite for 0<k<10978.
a(n)=(x->x-precprime(x))(n^n^n) \\ Charles R Greathouse IV, Nov 25 2014
Previous P k^k Next P a(n) A098681(a(n)) A000312(a(n)) A098682(a(n)) 2 3 4 5 6 46649 46656 46663 9 387420479 387420489 387420499 940 940^940-3063 940^940 940^940+3063
isok(k) = if (k>1, my(x=k^k); precprime(x-1)+nextprime(x+1) == 2*x); \\ Michel Marcus, Mar 14 2020
Comments