OFFSET
1,4
COMMENTS
If a(n) = -1, then a(m) = -1 for all multiples of n.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(7) = 2 because 1 + 2^2 + 3^2 = 14 is divisible by 7 while 1 + 2^0 + 3^0 = 3 and 1 + 2^1 + 3^1 = 6 are not.
MAPLE
f:= proc(n) local k;
for k from 0 to numtheory:-phi(n) + max(padic:-ordp(n, 2), padic:-ordp(n, 3)) do
if 1 + 2&^k + 3&^k mod n = 0 then return k fi
od;
-1
end proc:
map(f, [$1..100]);
CROSSREFS
KEYWORD
sign,look
AUTHOR
Robert Israel, Aug 02 2023
STATUS
approved