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!)
A204389 Number of partitions of n into distinct composite parts. 7

%I #21 Oct 27 2023 20:00:35

%S 1,0,0,0,1,0,1,0,1,1,2,0,2,1,3,2,3,1,5,3,5,4,7,4,9,7,10,9,13,10,17,14,

%T 18,18,25,22,30,27,34,36,44,40,53,52,62,65,76,74,93,95,107,113,131,

%U 133,158,164,182,195,221,229,264,276,304,329,367,383,431

%N Number of partitions of n into distinct composite parts.

%H Alois P. Heinz, <a href="/A204389/b204389.txt">Table of n, a(n) for n = 0..1000</a> (terms n = 0..250 from Reinhard Zumkeller)

%F G.f.: (1/(1 + x))*Product_{k>=1} (1 + x^k)/(1 + x^prime(k)). - _Ilya Gutkovskiy_, Dec 31 2016

%F G.f.: product_(i>=1) (1+x^A002808(i)). - _R. J. Mathar_, Mar 01 2023

%e a(10) = #{10, 6+4} = 2;

%e a(11) = #{ } = 0;

%e a(12) = #{12, 8+4} = 2;

%e a(13) = #{9+4} = 1;

%e a(14) = #{14, 10+4, 8+6} = 3;

%e a(15) = #{15, 9+6} = 2;

%e a(16) = #{16, 12+4, 10+6} = 3;

%e a(17) = #{9+8} = 1;

%e a(18) = #{18, 14+4, 12+6, 10+8, 8+6+4} = 5;

%e a(19) = #{15+4, 10+9, 9+6+4} = 3;

%e a(20) = #{20, 16+4, 14+6, 12+8, 10+6+4} = 5.

%p b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<2, 0,

%p b(n, i-1)+ `if`(i>n or isprime(i), 0, b(n-i, i-1))))

%p end:

%p a:= n-> b(n$2):

%p seq(a(n), n=0..70); # _Alois P. Heinz_, May 29 2013

%t b[n_, i_] := b[n, i] = If[n==0, 1, If[i<2, 0, b[n, i-1] + If[i>n || PrimeQ[i], 0, b[n-i, i-1]]]]; a[n_] := b[n, n]; Table[a[n], {n, 0, 70}] (* _Jean-François Alcover_, Oct 22 2015, after _Alois P. Heinz_ *)

%o (Haskell)

%o a204389 = p a002808_list where

%o p _ 0 = 1

%o p (k:ks) m = if m < k then 0 else p ks (m - k) + p ks m

%Y Cf. A023895, A096258, A000586, A000009.

%K nonn

%O 0,11

%A _Reinhard Zumkeller_, Jan 15 2012

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 April 18 04:56 EDT 2024. Contains 371767 sequences. (Running on oeis4.)