OFFSET
0,4
COMMENTS
Number of partitions of n into parts 1, 3, 7, and 8. - Joerg Arndt, Jun 28 2013
LINKS
Index entries for linear recurrences with constant coefficients, signature (1,0,1,-1,0,0,1,0,-1,-1,0,1,0,0,-1,1,0,1,-1).
FORMULA
a(0)=1, a(1)=1, a(2)=1, a(3)=2, a(4)=2, a(5)=2, a(6)=3, a(7)=4, a(8)=5, a(9)=6, a(10)=7, a(11)=8, a(12)=9, a(13)=10, a(14)=12, a(15)=14, a(16)=16, a(17)=18, a(18)=20, a(n)=a(n-1)+a(n-3)-a(n-4)+a(n-7)- a(n-9)- a(n-10)+a(n-12)-a(n-15)+a(n-16)+a(n-18)-a(n-19) [Harvey P. Dale, Mar 10 2012]
a(n) = floor((504*((floor((n+2)/2)-2*floor((n+2)/4))*(-1)^floor(n/4))+2*n^3+57*n^2+480*n+2088)/2016). - Tani Akinari, Jun 28 2013
MATHEMATICA
CoefficientList[Series[1/((1-x)(1-x^3)(1-x^7)(1-x^8)), {x, 0, 60}], x] (* or *) LinearRecurrence[{1, 0, 1, -1, 0, 0, 1, 0, -1, -1, 0, 1, 0, 0, -1, 1, 0, 1, -1}, {1, 1, 1, 2, 2, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16, 18, 20}, 61] (* Harvey P. Dale, Mar 10 2012 *)
PROG
(PARI) a(n)=(2*n^3+57*n^2+480*n+2088+(n%4<2)*(-1)^(n\4)*504)\2016 \\ Charles R Greathouse IV, Jun 28 2013
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved