login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A343016
a(n) is the least nonnegative m such that m*n + A001414(n) is not prime.
3
0, 1, 1, 0, 1, 5, 1, 0, 0, 2, 1, 4, 1, 0, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 2, 0, 0, 1, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1, 3, 0, 0, 0, 1, 1, 1, 0, 1, 0, 2, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 6, 0, 0, 0, 0, 0, 2, 1, 0, 1
OFFSET
1,6
COMMENTS
a(n) <= A001414(n).
a(n) = 0 iff n is not in A100118.
a(n) = 1 if n is prime.
a(n) >= 3 iff n is in A342302.
LINKS
EXAMPLE
a(6) = 5 because A001414(6) = 5 and 5, 6+5=11, 2*6+5=17, 3*6+5=23, and 4*6+5=29 are prime but 5*6+5=35 is not.
MAPLE
f:= proc(n) local s, t, k;
s:= add(t[1]*t[2], t = ifactors(n)[2]);
for k from 0 do if not isprime(k*n+s) then return k fi od;
end proc:
map(f, [$1..100]);
MATHEMATICA
Array[Block[{m = 0, k = Plus @@ Times @@@ FactorInteger[#]}, While[PrimeQ[# m + k], m++]; m] &, 105] (* Michael De Vlieger, Apr 13 2021 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Apr 02 2021
STATUS
approved