|
|
A115987
|
|
Numbers m such that 3^m is the average of two primes p and nextprime(p).
|
|
3
|
|
|
2, 4, 18, 20, 71, 80, 216, 496, 546, 817, 985, 1341, 1412
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
EXAMPLE
|
Nextprime(387420479) = 387420499 and (387420479 + 387420499)/2 = 387420489 = 3^18, so 18 belongs to the sequence.
|
|
MATHEMATICA
|
okQ[n_] := Module[{x = 3^n}, (NextPrime[x, -1] + NextPrime[x])/2 == x]; Select[Range[500], okQ] (* Harvey P. Dale, Jan 19 2011 *)
|
|
PROG
|
(PARI) isok(m) = precprime(3^m-1)+nextprime(3^m+1)==2*3^m; \\ Jinyuan Wang, Feb 26 2020
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,more
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|