OFFSET
1,2
LINKS
David A. Corneth, Table of n, a(n) for n = 1..2236
EXAMPLE
a(3) = 10 as the product of primes <= (n = 3) is 6 and the smallest integer of the form lcm(3+1, 3+2, ..., 3+k) = lcm(4, 5, 6) = 60 giving a(3) = 60/6 = 10. - David A. Corneth, Dec 05 2023
MATHEMATICA
a75365[n_] := Module[{div, k, pr}, div=Times@@Prime/@Range[PrimePi[n]]; For[k=0; pr=1, True, k++; pr*=n+k, If[Mod[pr, div]==0, Return[k]]]]; a[1]=1; a[n_] := LCM@@Range[n+1, n+a75365[n]]/Times@@Prime/@Range[PrimePi[n]]
PROG
(PARI)
a(n) = {if(n==1, return(1));
my(pp = vecprod(primes(primepi(n))), l = n+1);
for(k = n+2, 2*n,
l = lcm(l, k);
if(l%pp == 0,
return(l\pp)
)
)
} \\ David A. Corneth, Dec 05 2023
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Amarnath Murthy, Sep 20 2002
EXTENSIONS
Edited by Dean Hickerson, Oct 28 2002
STATUS
approved