login
A049796
a(n) = T(n,n-4), array T as in A049790.
7
1, 2, 3, 4, 5, 9, 16, 22, 32, 39, 53, 64, 79, 91, 113, 124, 147, 166, 188, 208, 238, 256, 288, 313, 344, 371, 411, 434, 473, 509, 548, 580, 629, 657, 709, 749, 796, 837, 893, 928, 987, 1038, 1093, 1136, 1206, 1246, 1314, 1371, 1431
OFFSET
5,2
LINKS
MAPLE
seq( `if`(n<9, n-4, add(floor((n-4)/floor((n-8)/j)), j=1..n-8)), n=5..60); # G. C. Greubel, Dec 10 2019
MATHEMATICA
Table[If[n<9, n-4, Sum[Floor[(n-4)/Floor[(n-8)/j]], {j, n-8}]], {n, 5, 60}] (* G. C. Greubel, Dec 10 2019 *)
PROG
(PARI) a(n) = if(n<9, n-4, sum(j=1, n-8, (n-4)\((n-8)\j)) );
vector(60, n, a(n+4) ) \\ G. C. Greubel, Dec 10 2019
(Magma) [n lt 9 select n-4 else (&+[Floor((n-4)/Floor((n-8)/j)): j in [1..n-8]]): n in [5..60]]; // G. C. Greubel, Dec 10 2019
(Sage)
def a(n):
if (n<9): return n-4
else: return sum(floor((n-4)/floor((n-8)/j)) for j in (1..n-8))
[a(n) for n in (5..60)] # G. C. Greubel, Dec 10 2019
(GAP)
a:= function(n)
if n<9 then return n-4;
else return Sum([1..n-8], j-> Int((n-4)/Int((n-8)/j)) );
fi; end;
List([5..60], n-> a(n) ); # G. C. Greubel, Dec 10 2019
CROSSREFS
KEYWORD
nonn
STATUS
approved