OFFSET
0,3
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..550
FORMULA
a(n) = Sum_{j=0..n} binomial(n-1,j) * A099960(n-j).
EXAMPLE
a(3) = 4: 000, 001, 010, 011.
a(4) = 9: 0000, 0001, 0010, 0011, 0100, 0101, 0102, 0110, 0111.
a(5) = 22: 00000, 00001, 00010, 00011, 00100, 00101, 00102, 00110, 00111, 01000, 01001, 01002, 01010, 01011, 01020, 01021, 01022, 01100, 01101, 01102, 01110, 01111.
MAPLE
b:= proc(n, i, t, u) option remember; `if`(n<1, 1, add(
b(n-1, j, t+`if`(j>i, 1, 0), `if`(i=j, u, 1-u)),
j=`if`(u=0, i..t+1, 0..i)))
end:
a:= n-> b(n-1, 0$3):
seq(a(n), n=0..30);
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Oct 26 2017
STATUS
approved