cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A218506 Number of partitions of n in which any two parts differ by at most 4.

This page as a plain text file.
%I A218506 #16 May 20 2018 11:34:19
%S A218506 1,1,2,3,5,7,11,14,20,25,34,41,54,64,81,95,118,136,165,189,226,256,
%T A218506 301,339,395,441,507,564,644,711,804,885,995,1089,1215,1326,1473,1600,
%U A218506 1766,1914,2105,2272,2486,2678,2921,3136,3406,3650,3954,4225,4560,4865
%N A218506 Number of partitions of n in which any two parts differ by at most 4.
%H A218506 Alois P. Heinz, <a href="/A218506/b218506.txt">Table of n, a(n) for n = 0..1000</a>
%H A218506 <a href="/index/Rec#order_14">Index entries for linear recurrences with constant coefficients</a>, signature (1,1,0,1,-3,-1,0,1,3,-1,0,-1,-1,1).
%F A218506 G.f.: 1 + Sum_{j>0} x^j / Product_{i=0..4} (1-x^(i+j)).
%F A218506 G.f.: (x^14-x^13-x^12+2*x^9-x^6-x^5+x^4-1) / ((x-1)^5*(x+1)^3*(x^2+1)^2*(x^2+x+1)). - _Colin Barker_, Mar 05 2015
%p A218506 b:= proc(n, i, k) option remember; `if`(n<0 or k<0, 0,
%p A218506       `if`(n=0, 1, `if`(i<1, 0, b(n, i-1, k-1) +b(n-i, i, k))))
%p A218506     end:
%p A218506 a:= n-> `if`(n=0, 1, 0) +add(b(n-i, i, 4), i=1..n):
%p A218506 seq(a(n), n=0..80);
%t A218506 b[n_, i_, k_] := b[n, i, k] = If[n < 0 || k < 0, 0, If[n == 0, 1, If[i < 1, 0, b[n, i - 1, k - 1] + b[n - i, i, k]]]];
%t A218506 a[n_] := If[n == 0, 1, 0] + Sum[b[n - i, i, 4], {i, 1, n}];
%t A218506 Table[a[n], {n, 0, 80}] (* _Jean-François Alcover_, May 20 2018, after _Alois P. Heinz_ *)
%o A218506 (PARI) Vec((x^14-x^13-x^12+2*x^9-x^6-x^5+x^4-1)/((x-1)^5*(x+1)^3*(x^2+1)^2*(x^2+x+1)) + O(x^100)) \\ _Colin Barker_, Mar 05 2015
%Y A218506 Column k=4 of A194621.
%K A218506 nonn,easy
%O A218506 0,3
%A A218506 _Alois P. Heinz_, Oct 31 2012