OFFSET
0,4
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..15000
MAPLE
b:= proc(n) option remember; local r;
`if`(n=0, 1, `if`(irem(n, 2, 'r')=0, b(r), b(r)*(-1)^r))
end:
s:= proc(j) option remember; `if`(j<0, 0, s(j-1)+b(j) ) end:
t:= proc(k) option remember; `if`(k<1, 0, t(k-1)+b(k)*s(k-1)) end:
a:= proc(n) option remember; `if`(n<2, 0, a(n-1)+b(n)*t(n-1)) end:
seq(a(n), n=0..100);
MATHEMATICA
b[n_] := b[n] = Module[{q, r}, If[n==0, 1, {q, r}=QuotientRemainder[n, 2]; If[r == 0, b[q], b[q]*(-1)^q]]];
s[j_] := s[j] = If[j < 0, 0, s[j-1] + b[j]];
t[k_] := t[k] = If[k < 1, 0, t[k-1] + b[k]*s[k-1]];
a[n_] := a[n] = If[n < 2, 0, a[n-1] + b[n]*t[n-1]];
Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Jun 01 2022, after Alois P. Heinz *)
PROG
(Python)
def A213626(n): return sum((-1 if (i&(i>>1)).bit_count()&1 else 1)*sum((-1 if (j&(j>>1)).bit_count()&1 else 1)*sum(-1 if (k&(k>>1)).bit_count()&1 else 1 for k in range(j+1, n+1)) for j in range(i+1, n+1)) for i in range(n+1)) # Chai Wah Wu, Feb 12 2023
CROSSREFS
KEYWORD
sign,look
AUTHOR
Alois P. Heinz, Jun 23 2012
STATUS
approved