OFFSET
1,2
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..2363
EXAMPLE
a(4) = lcm(lcm(4)/lcm(1), lcm(4,3)/lcm(1,2), lcm(4,3,2)/lcm(1,2,3), lcm(4,3,2,1)/lcm(1,2,3,4)) = lcm(4,6,2,1) = 12.
MAPLE
T:=(n, k)->lcm(seq(i, i=n-k+1..n))/lcm(seq(j, j=1..k)): seq(lcm(seq(T(n, k), k=1..n)), n=1..35); # Emeric Deutsch, Jan 30 2006
# second Maple program:
b:= proc(n) option remember; `if`(n=1, 1, ilcm(b(n-1), n)) end:
a:= proc(n) option remember; local k, r, s; r, s:= 1, 1;
for k to n do s:= ilcm(s, n-k+1); r:= ilcm(r, s/b(k)) od; r
end:
seq(a(n), n=1..40); # Alois P. Heinz, Mar 17 2018
MATHEMATICA
b[n_] := b[n] = If[n == 1, 1, LCM[b[n - 1], n]];
a[n_] := a[n] = Module[{k, r = 1, s = 1}, For[k = 1, k <= n, k++, s = LCM[s, n - k + 1]; r = LCM[r, s/b[k]]]; r];
Array[a, 40] (* Jean-François Alcover, Jun 18 2018, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Mar 31 2004
EXTENSIONS
Corrected and extended by Emeric Deutsch, Jan 30 2006
STATUS
approved