login
Number of partitions of n into distinct parts, the least being 4.
4

%I #26 Nov 25 2020 03:11:51

%S 0,0,0,0,1,0,0,0,0,1,1,1,1,1,1,2,2,3,3,4,4,5,6,7,8,10,11,13,15,17,20,

%T 23,26,30,35,39,45,51,58,66,75,84,96,108,122,137,155,173,195,219,245,

%U 274,307,342,383,427,475,529,589,654,727,807,894,991,1098,1214,1343,1485,1638,1809

%N Number of partitions of n into distinct parts, the least being 4.

%H Alois P. Heinz, <a href="/A026825/b026825.txt">Table of n, a(n) for n = 0..1000</a>

%F a(n) = A025150(n-4), n>4. - _R. J. Mathar_, Jul 31 2008

%F G.f.: x^4*Product_{j>=5} (1+x^j). - _R. J. Mathar_, Jul 31 2008

%F G.f.: Sum_{k>=1} x^(k*(k + 7)/2) / Product_{j=1..k-1} (1 - x^j). - _Ilya Gutkovskiy_, Nov 24 2020

%p b:= proc(n, i) option remember;

%p `if`(n=0, 1, `if`((i-4)*(i+5)/2<n, 0,

%p add(b(n-i*j, i-1), j=0..min(1, n/i))))

%p end:

%p a:= n-> `if`(n<4, 0, b(n-4$2)):

%p seq(a(n), n=0..80); # _Alois P. Heinz_, Feb 07 2014

%t b[n_, i_] := b[n, i] = If[n == 0, 1, If[(i-4)*(i+5)/2 < n, 0, Sum[b[n-i*j, i-1], {j, 0, Min[1, n/i]}]]]; a[n_] := If[n<4, 0, b[n-4, n-4]]; Table[a[n], {n, 0, 80}] (* _Jean-François Alcover_, Jun 24 2015, after _Alois P. Heinz_ *)

%t Join[{0}, Table[Count[Last /@ Select[IntegerPartitions@n, DeleteDuplicates[#] == # &], 4], {n, 66}]] (* _Robert Price_, Jun 13 2020 *)

%Y Cf. A025147, A025150.

%K nonn

%O 0,16

%A _Clark Kimberling_