Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A096765 Number of partitions of n into distinct parts, the least being 1. 25

%I #41 Aug 19 2020 06:45:37

%S 0,1,0,1,1,1,2,2,3,3,5,5,7,8,10,12,15,17,21,25,29,35,41,48,56,66,76,

%T 89,103,119,137,159,181,209,239,273,312,356,404,460,522,591,669,757,

%U 853,963,1085,1219,1371,1539,1725,1933,2164,2418,2702,3016,3362,3746,4171,4637

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

%C The old entry with this sequence number was a duplicate of A071569.

%C a(n) is also the total number of 1's in all partitions of n into distinct parts. For n=6 there are partitions [6], [5,1], [4,2], [3,2,1] and only two contain a 1, hence a(6) = 2. - _T. Amdeberhan_, May 13 2012

%C a(n), n > 1 is the Euler transform of [0,1,1] joined with period [0,1]. - _Georg Fischer_, Aug 15 2020

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

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

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

%F G.f.: x / ((1 + x) * Product_{k>0} (1 - x^(2*k-1))). - _Michael Somos_, Sep 10 2016

%F G.f.: Sum_{k>0} x^(k*(k+1)/2) / Product_{j=1..k-1} (1 - x^j). - _Michael Somos_, Sep 10 2016

%e G.f. = x + x^3 + x^4 + x^5 + 2*x^6 + 2*x^7 + 3*x^8 + 3*x^9 + 5*x^10 + 5*x^11 + ...

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

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

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

%p end:

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

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

%p # Using the function EULER from Transforms (see link at the bottom of the page).

%p [0,1,op(EULER([0,1,seq(irem(n,2),n=1..56)]))]; # _Peter Luschny_, Aug 19 2020

%t p[_, 0] = 1; p[k_, n_] := p[k, n] = If[n < k, 0, p[k+1, n-k] + p[k+1, n]]; a[n_] := p[2, n-1]; Table[a[n], {n, 0, 59}] (* _Jean-François Alcover_, Apr 17 2014, after _Reinhard Zumkeller_ *)

%t a[ n_] := SeriesCoefficient[ x / ((1 + x) Product[ 1 - x^j, {j, 1, n, 2}]), {x, 0, n}]; (* _Michael Somos_, Sep 10 2016 *)

%t a[ n_] := If[ n < 0, 0, SeriesCoefficient[ Sum[ x^(k (k + 1)/2) / Product[ 1 - x^j, {j, 1, k - 1}], {k, 1, Quotient[-1 + Sqrt[8 n + 1], 2]}], {x, 0, n}]]; (* _Michael Somos_, Sep 10 2016 *)

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

%o (PARI) {a(n) = if( n<1, 0, polcoeff( x / ((1 + x) * prod(k=1, (n+1)\2, 1 - x^(2*k-1), 1 + O(x^n))), n))}; /* _Michael Somos_, Sep 10 2016 */

%Y Cf. A025147, A071569.

%Y Cf. A096749 (least=2), A022824 (3), A022825 (4), A022826 (5), A022827 (6), A022828 (7), A022829 (8), A022830 (9), A022831 (10).

%K nonn

%O 0,7

%A _N. J. A. Sloane_, Sep 28 2008

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 18 20:20 EDT 2024. Contains 375275 sequences. (Running on oeis4.)