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!)
A320387 Number of partitions of n into distinct parts such that the successive differences of consecutive parts are nonincreasing, and first difference <= first part. 35

%I #53 Jan 22 2023 11:35:42

%S 1,1,1,2,1,2,3,2,2,4,3,4,5,3,5,7,4,7,8,6,8,11,7,9,13,9,11,16,12,15,18,

%T 13,17,20,17,21,24,19,24,30,22,28,34,26,34,38,30,37,43,37,42,48,41,50,

%U 58,48,55,64,53,64,71,59,73,81,69,79,89,79,90,101,87,100,111

%N Number of partitions of n into distinct parts such that the successive differences of consecutive parts are nonincreasing, and first difference <= first part.

%C Partitions are usually written with parts in descending order, but the conditions are easier to check "visually" if written in ascending order.

%C Generating function of the "second integrals" of partitions: given a partition (p_1, ..., p_s) written in weakly decreasing order, write the sequence B = (b_1, b_2, ..., b_s) = (p_1, p_1 + p_2, ..., p_1 + ... + p_s). The sequence gives the coefficients of the generating function summing q^(b_1 + ... + b_s) over all partitions of all nonnegative integers. - _William J. Keith_, Apr 23 2022

%C From _Gus Wiseman_, Jan 17 2023: (Start)

%C Equivalently, a(n) is the number of multisets (weakly increasing sequences of positive integers) with weighted sum n. For example, the Heinz numbers of the a(0) = 1 through a(15) = 7 multisets are:

%C 1 2 3 4 7 6 8 10 15 12 16 18 20 26 24 28

%C 5 11 9 17 19 14 21 22 27 41 30 32

%C 13 23 29 31 33 55 39 34

%C 25 35 37 43 45

%C 49 77 47

%C 65

%C 121

%C These multisets are counted by A264034. The reverse version is A007294. The zero-based version is A359678.

%C (End)

%H Fausto A. C. Cariboni, <a href="/A320387/b320387.txt">Table of n, a(n) for n = 0..2000</a> (terms 0..300 from Seiichi Manyama)

%F G.f.: Sum_{k>=1} x^binomial(k,2)/Product_{j=1..k-1} (1 - x^(binomial(k,2)-binomial(j,2))). - _Andrew Howroyd_, Jan 22 2023

%e There are a(29) = 15 such partitions of 29:

%e 01: [29]

%e 02: [10, 19]

%e 03: [11, 18]

%e 04: [12, 17]

%e 05: [13, 16]

%e 06: [14, 15]

%e 07: [5, 10, 14]

%e 08: [6, 10, 13]

%e 09: [6, 11, 12]

%e 10: [7, 10, 12]

%e 11: [8, 10, 11]

%e 12: [3, 6, 9, 11]

%e 13: [5, 7, 8, 9]

%e 14: [2, 4, 6, 8, 9]

%e 15: [3, 5, 6, 7, 8]

%e There are a(30) = 18 such partitions of 30:

%e 01: [30]

%e 02: [10, 20]

%e 03: [11, 19]

%e 04: [12, 18]

%e 05: [13, 17]

%e 06: [14, 16]

%e 07: [5, 10, 15]

%e 08: [6, 10, 14]

%e 09: [6, 11, 13]

%e 10: [7, 10, 13]

%e 11: [7, 11, 12]

%e 12: [8, 10, 12]

%e 13: [3, 6, 9, 12]

%e 14: [9, 10, 11]

%e 15: [4, 7, 9, 10]

%e 16: [2, 4, 6, 8, 10]

%e 17: [6, 7, 8, 9]

%e 18: [4, 5, 6, 7, 8]

%t prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];

%t ots[y_]:=Sum[i*y[[i]],{i,Length[y]}];

%t Table[Length[Select[Range[2^n],ots[prix[#]]==n&]],{n,10}] (* _Gus Wiseman_, Jan 17 2023 *)

%o (Ruby)

%o def partition(n, min, max)

%o return [[]] if n == 0

%o [max, n].min.downto(min).flat_map{|i| partition(n - i, min, i - 1).map{|rest| [i, *rest]}}

%o end

%o def f(n)

%o return 1 if n == 0

%o cnt = 0

%o partition(n, 1, n).each{|ary|

%o ary << 0

%o ary0 = (1..ary.size - 1).map{|i| ary[i - 1] - ary[i]}

%o cnt += 1 if ary0.sort == ary0

%o }

%o cnt

%o end

%o def A320387(n)

%o (0..n).map{|i| f(i)}

%o end

%o p A320387(50)

%o (PARI) seq(n)={Vec(sum(k=1, (sqrtint(8*n+1)+1)\2, my(t=binomial(k,2)); x^t/prod(j=1, k-1, 1 - x^(t-binomial(j,2)) + O(x^(n-t+1)))))} \\ _Andrew Howroyd_, Jan 22 2023

%Y Cf. A007294, A179254, A179255, A179269, A320382, A320385, A320388.

%Y Number of appearances of n > 0 in A304818, reverse A318283.

%Y A053632 counts compositions by weighted sum.

%Y A358194 counts partitions by weighted sum, reverse A264034.

%Y Weighted sum of prime indices: A359497, A359676, A359682, A359754, A359755.

%Y Cf. A029931, A359361, A359397, A359674, A359677, A359678.

%K nonn

%O 0,4

%A _Seiichi Manyama_, Oct 12 2018

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 20 12:36 EDT 2024. Contains 371844 sequences. (Running on oeis4.)