OFFSET
1,2
COMMENTS
If n > 1 and n-1 is squarefree, then a(n) <= n-1. # Robert Israel, Apr 11 2023
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(5) = 8 because A000005(8^8) = 25 is divisible by 5.
MAPLE
g:= proc(k) option remember;
local F, t;
F:= ifactors(k)[2];
mul(t[2]*k+1, t=F);
end proc:
f:= proc(n) local k;
for k from 1 do if g(k) mod n = 0 then return k fi od
end proc:
map(f, [$1..100]); # Robert Israel, Apr 11 2023
MATHEMATICA
Table[k = 1; While[! Divisible[DivisorSigma[0, k^k], n], k++]; k, {n, 73}] (* Michael De Vlieger, Aug 02 2016 *)
PROG
(PARI) a(n) = {my(k=1); while(numdiv(k^k) % n != 0, k++); k; }
CROSSREFS
KEYWORD
nonn,look
AUTHOR
Altug Alkan, Jul 31 2016
STATUS
approved