OFFSET
1,3
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
MATHEMATICA
a[n_] := Module[{d = Divisors[n]}, GCD[LCM @@ (d + 1), LCM @@ (Rest @ d - 1)]]; a[1] = 1; Array[a, 100]
PROG
(PARI) a(n) = {my(d = divisors(n)); gcd(lcm(apply(x->x+1, d)), lcm(apply(x -> if(x > 1, x-1, x), d))); }
CROSSREFS
KEYWORD
nonn
AUTHOR
Amiram Eldar, Nov 15 2024
STATUS
approved