OFFSET
1,2
COMMENTS
First differences of A097939.
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..1000
FORMULA
G.f.: (1-x) * Sum_{k>=1} x^k/(1-x-x^k). [Joerg Arndt, Jan 01 2013]
a(n) ~ 2^(n-2). - Vaclav Kotesovec, Sep 10 2014
G.f.: Sum_{n>=1} q^n/(1-Sum_{k>=n} q^k). - Joerg Arndt, Jan 03 2024
EXAMPLE
The a(6)=20 such compositions of 6 are
[ 1] [ 1 1 1 1 1 1 ]
[ 2] [ 1 1 1 1 2 ]
[ 3] [ 1 1 1 2 1 ]
[ 4] [ 1 1 1 3 ]
[ 5] [ 1 1 2 1 1 ]
[ 6] [ 1 1 2 2 ]
[ 7] [ 1 1 3 1 ]
[ 8] [ 1 1 4 ]
[ 9] [ 1 2 1 1 1 ]
[10] [ 1 2 1 2 ]
[11] [ 1 2 2 1 ]
[12] [ 1 2 3 ]
[13] [ 1 3 1 1 ]
[14] [ 1 3 2 ]
[15] [ 1 4 1 ]
[16] [ 1 5 ]
[17] [ 2 2 2 ]
[18] [ 2 4 ]
[19] [ 3 3 ]
[20] [ 6 ]
- Joerg Arndt, Jan 01 2013.
MATHEMATICA
nn=37; Drop[CoefficientList[Series[Sum[x^i/(1-x^i/(1-x)), {i, 1, nn}], {x, 0, nn}], x], 1] (* Geoffrey Critzer, Mar 12 2013 *)
PROG
(PARI)
N=66; x='x+O('x^N);
gf= (1-x) * sum(k=1, N, x^k/(1-x-x^k) );
Vec(gf)
/* Joerg Arndt, Jan 01 2013 */
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Vladeta Jovovic, Dec 15 2009
EXTENSIONS
Added more terms, Joerg Arndt, Jan 01 2013
STATUS
approved