OFFSET
0,6
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..10000
MAPLE
a:= proc(n) option remember; local m, c, i, j, h, w;
m, c:= proc() 0 end, 0; forget(m);
for i to iquo(n, 3) do for j from i to iquo(n-i, 2) do
h:= i*j*(n-j-i); w:= m(h);
if w=0 then m(h):= 1; c:= c+1
elif w=1 then m(h):= 2; c:= c-1
fi
od od; c
end:
seq(a(n), n=0..80);
MATHEMATICA
a[n_] := a[n] = Module[{m, c = 0, i, j, h, w}, m[_] = 0; For[i = 1, i <= Quotient[n, 3], i++, For[j = i, j <= Quotient[n-i, 2], j++, h = i*j*(n - j - i); w = m[h]; If[w==0, m[h] = 1; c++; If[w==1, m[h] = 2; c--]]]]; c];
a /@ Range[0, 80] (* Jean-François Alcover, Dec 12 2020, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Feb 15 2019
STATUS
approved