OFFSET
0,3
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..500
FORMULA
a(n) ~ c * d^n, where d = 1.7502412917183090312497386246... (see A241902) and c = 0.5940298439978189763822100914... - Vaclav Kotesovec, May 01 2014
EXAMPLE
The a(6) = 18 such compositions of 6 are
01: [ 1 1 2 2 ]
02: [ 1 1 4 ]
03: [ 1 2 2 1 ]
04: [ 1 2 3 ]
05: [ 1 3 2 ]
06: [ 1 5 ]
07: [ 2 1 1 2 ]
08: [ 2 1 3 ]
09: [ 2 2 1 1 ]
10: [ 2 3 1 ]
11: [ 2 4 ]
12: [ 3 1 2 ]
13: [ 3 2 1 ]
14: [ 3 3 ]
15: [ 4 1 1 ]
16: [ 4 2 ]
17: [ 5 1 ]
18: [ 6 ]
MAPLE
b:= proc(n, i, j) option remember; `if`(n=0, 1, add(`if`(k=j, 0,
b(n-k, `if`(n-k<k, 0, k), `if`(n-k<i, 0, i))), k=1..n))
end:
a:= n-> b(n, 0, 0):
seq(a(n), n=0..50); # Alois P. Heinz, May 02 2013
MATHEMATICA
b[n_, i_, j_] := b[n, i, j] = If[n==0, 1, Sum[If[k==j, 0, b[n-k, If[n-k < k, 0, k], If[n-k < i, 0, i]]], {k, 1, n}]]; a[n_] := b[n, 0, 0]; Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Apr 08 2015, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Joerg Arndt, Apr 21 2013
STATUS
approved