login
A090667
Number of compositions of 3n with each part less than or equal to n.
2
1, 1, 13, 149, 1490, 13624, 117920, 987568, 8111200, 65866496, 531372800, 4270866688, 34254920192, 274425014272, 2197077311488, 17583865032704, 140702055981056, 1125749585477632, 9006563605151744, 72054913990721536, 576449482336632832, 4611638739487686656
OFFSET
0,3
FORMULA
a(n) = 2^(3n-1)-(2n+1)*2^(2n-2)+(n+2)*(n-1)*2^(n-4), n>0.
G.f.: (896*x^6-1968*x^5+1704*x^4-757*x^3+179*x^2-21*x+1) / ((2*x-1)^3*(4*x-1)^2*(8*x-1)). - Colin Barker, May 15 2013
EXAMPLE
a(2)=13 since there is one composition of 6 of the form 1+1+1+1+1+1, five of the form 2+1+1+1+1, six of the form 2+2+1+1 and one of the form 2+2+2 and 1+5+6+1=13.
MAPLE
A090667:=n->`if`(n=0, 1, 2^(3*n-1)-(2*n+1)*2^(2*n-2)+(n+2)*(n-1)*2^(n-4)); seq(A090667(n), n=0..50); # Wesley Ivan Hurt, Nov 14 2013
MATHEMATICA
LinearRecurrence[{22, -188, 808, -1856, 2176, -1024}, {1, 1, 13, 149, 1490, 13624, 117920}, 30] (* Harvey P. Dale, May 04 2024 *)
CROSSREFS
Cf. A008464.
Sequence in context: A210158 A130611 A127747 * A125448 A163148 A355414
KEYWORD
nonn,easy
AUTHOR
Henry Bottomley, Dec 16 2003
EXTENSIONS
More terms from Colin Barker, May 15 2013
STATUS
approved