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.

A005895 Weighted count of partitions with distinct parts.

This page as a plain text file.
%I A005895 M1337 #33 Jul 02 2025 16:01:54
%S A005895 1,2,5,7,12,18,26,35,50,67,88,116,149,191,245,306,381,477,585,718,880,
%T A005895 1067,1288,1555,1863,2226,2656,3151,3726,4406,5180,6077,7124,8316,
%U A005895 9691,11278,13080,15146,17517,20204,23264,26759,30705,35182,40274,46000,52473,59795,68018,77279,87711,99395,112508
%N A005895 Weighted count of partitions with distinct parts.
%C A005895 Also sum of largest parts of all partitions of n into distinct parts. - _Vladeta Jovovic_, Feb 15 2004
%D A005895 Andrews, George E.; Ramanujan's "lost" notebook. V. Euler's partition identity. Adv. in Math. 61 (1986), no. 2, 156-164.
%D A005895 S.-Y. Kang, Generalizations of Ramanujan's reciprocity theorem..., J. London Math. Soc., 75 (2007), 18-34. See Eq. (1.5) but beware errors.
%D A005895 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
%H A005895 Alois P. Heinz, <a href="/A005895/b005895.txt">Table of n, a(n) for n = 1..10000</a>
%F A005895 G.f.: sum(n>=0, S(q) - prod(k=1..n, 1+q^k) ), where S(q)=prod(k>=1, 1+q^k) (g.f. for A000009).
%F A005895 G.f. sum(k>=0, (k+1)*x^(k+1) * prod(j=1..k, 1+x^j) ). [_Joerg Arndt_, Sep 17 2012]
%p A005895 M:=201; add( mul( (1+q^j),j=1..M) - mul( (1+q^j),j=1..n), n=0..M);
%p A005895 # second Maple program:
%p A005895 b:= proc(n, i) option remember; `if`(n>i*(i+1)/2, 0, `if`(
%p A005895       n=0, 1, b(n,i-1)+`if`(i>n, 0, b(n-i, min(n-i,i-1)))))
%p A005895     end:
%p A005895 a:= n-> add(j*b(n-j, min(n-j,j-1)), j=1..n):
%p A005895 seq(a(n), n=1..80);  # _Alois P. Heinz_, Feb 03 2016
%t A005895 m = 46; f[q_] :=  Sum[ Product[ (1+q^j), {j, 1, m}] - Product[ (1+q^j), {j, 1, n}], {n, 0, m}]; CoefficientList[ f[q], q][[2 ;; m+1]] (* _Jean-François Alcover_, Apr 13 2012, after Maple *)
%o A005895 (PARI)
%o A005895 N=66;  x='x+O('x^N);
%o A005895 S=prod(k=1,N, 1+x^k); gf=sum(n=0,N, S-prod(k=1,n, 1+x^k));
%o A005895 /* alternative: Arndt's g.f.: */
%o A005895 /* gf=sum(k=0,N, (k+1)*x^(k+1) * prod(j=1,k, 1+x^j) ); */
%o A005895 Vec(gf)
%o A005895 /* _Joerg Arndt_, Sep 17 2012 */
%Y A005895 Cf. A005896, A003406, A336902, A336903.
%K A005895 nonn,easy,nice
%O A005895 1,2
%A A005895 _N. J. A. Sloane_ and _Simon Plouffe_
%E A005895 More terms from _James Sellers_, Dec 24 1999