login
A340170
a(n) is the least x such that x-1 and x+1 are prime and there are exactly n primes of the form x-1+t or x+1+t where t divides x.
0
1698, 4, 6, 12, 30, 60, 72, 192, 240, 1428, 180, 420, 432, 2592, 2268, 2340, 2688, 15288, 3360, 9000, 46440, 9720, 6300, 6552, 53550, 23040, 16632, 7560, 21600, 13680, 63840, 140760, 93240, 88800, 81900, 33600, 121440, 55440, 102000, 109200, 130200, 35280, 325080, 127680, 118800, 245520, 569160
OFFSET
1,1
COMMENTS
There is always at least one prime of the given form, namely x+1 = x-1+2.
Primes are counted only once even if they are of both forms.
EXAMPLE
a(4)=12 with 4 primes of the given form for x=12: 13 = 11+2, 17 = 11+6 = 13+4, 19 = 13+6 and 23 = 11+12.
MAPLE
f:= proc(x) local d;
d:= numtheory:-divisors(x);
nops(select(isprime, map(`+`, d, x-1) union map(`+`, d, x+1)))
end proc:
T:= select(t -> isprime(t-1) and isprime(t+1), [4, seq(i, i=6..10^6, 6)]):
fT:= map(f, T):
V:= Vector(max(fT)):
for i from 1 to nops(T) do
if V[fT[i]] = 0 then V[fT[i]]:= T[i] fi
od:
if not member(0, V, 'm') then m:=nops(T)+1 fi:
convert(V[1..m-1], list);
CROSSREFS
Cf. A340160.
Sequence in context: A237170 A301985 A237845 * A083610 A020405 A091368
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Dec 30 2020
STATUS
approved