OFFSET
0,4
COMMENTS
For m >= 1, let S(m) = { f(m/2), c(m/2) }, where f = floor and c = ceiling. A halving partition of n is a partition p(1) + p(2) + ... + p(k) of n such that p(1) is in S(n) and p(i) is in S(p(i-1)) for i = 2, 3, ..., k. The basic idea is that each term after the first is about half of the preceding term.
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..32768
FORMULA
EXAMPLE
a(9) = 3 counts these partitions:
c(9/2) + f(5/2) + (2/2) + c(1/2) = 5 + 2 + 1 + 1;
c(9/2) + c(5/2) + f(3/2) = 5 + 3 + 1;
f(9/2) + (4/2) + (2/2) + c(1/2) = 4 + 2 + 1 + 1.
a(13) = 5 counts these partitions:
c(13/2) + c(7/2) + (4/2) = 7 + 4 + 2;
c(13/2) + f(7/2) + c(3/2) + (2/2) = 7 + 3 + 2 + 1;
c(13/2) + f(7/2) + f(3/2) + (2/2) + c(1/2) = 7 + 3 + 1 + 1 + 1;
f(13/2) + (6/2) + c(3/2) + (2/2) + c(1/2) = 6 + 3 + 2 + 1 + 1;
f(13/2) + (6/2) + f(3/2) + (2/2) + c(1/2) + c(1/2) = 6 + 3 + 1 + 1 + 1 + 1.
PROG
(PARI) { a349552(n, p=n) = if(n==0, 1, if(n<0||p==0, 0, if(p%2, a(n-p\2-1, p\2+1))+a(n-p\2, p\2))); } \\ Max Alekseyev, Sep 30 2024
CROSSREFS
KEYWORD
nonn,look
AUTHOR
Clark Kimberling, Dec 26 2021
EXTENSIONS
Corrected and extended by Max Alekseyev, Sep 30 2024
STATUS
approved