OFFSET
0,7
FORMULA
a(n) = [x^n] Product_{k=1..n} (x^(k*(k+1)/2) + 1/x^(k*(k+1)/2)).
PROG
(Python)
from functools import lru_cache
@lru_cache(maxsize=None)
def b(n, i):
if n > i*(i+1)*(i+2)//6: return 0
if i == 0: return 1
return b(n+i*(i+1)//2, i-1) + b(abs(n-i*(i+1)//2), i-1)
def a(n): return b(n, n)
print([a(n) for n in range(50)]) # Michael S. Branicky, Jan 29 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Jan 29 2022
STATUS
approved