The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A218218 Table read downwards by antidiagonals: T(n,k) is the number of partitions of k into n distinct positive parts, k, n >= 0. 1

%I #65 Jan 01 2018 04:15:10

%S 1,0,0,0,1,0,0,1,0,0,0,1,0,0,0,0,1,1,0,0,0,0,1,1,0,0,0,0,0,1,2,0,0,0,

%T 0,0,0,1,2,0,0,0,0,0,0,0,1,3,1,0,0,0,0,0,0,0,1,3,1,0,0,0,0,0,0,0,0,1,

%U 4,2,0,0,0,0,0,0,0,0,0,1,4,3,0,0,0,0,0,0,0,0,0,0,1,5,4,0,0,0,0,0,0,0,0,0,0

%N Table read downwards by antidiagonals: T(n,k) is the number of partitions of k into n distinct positive parts, k, n >= 0.

%C The array T is basically a transposed version of A008289, padded with zeros where needed.

%C Entry T(n,k) contains the count of the pairs such that <n, k> = <A000120(q), A029931(q)> for any q >= 0.

%C Index of the first nonzero term on the n-th row is k=A000217(n).

%H Sergey Shishmintzev and Andrew Howroyd, <a href="/A218218/b218218.txt">Table of n, a(n) for n = 0..299</a>

%H Sergey Shishmintzev, <a href="https://oeis.org/plot2a?name1=A029931&amp;name2=A000120&amp;tform1=untransformed&amp;tform2=untransformed&amp;shift=0&amp;radiop1=xy&amp;drawpoints=true">Scatter plot of A029931(q) vs. A000120(q) for 0 <= q < 2^10</a>

%H OEIS Wiki, <a href="http://oeis.org/wiki/Empty_sum">Empty sum</a>

%e Array begins:

%e 1,0,0,0,0,0,0,0,0,0,0,0,0,0, 0, 0, 0, 0, 0,...

%e 0,1,1,1,1,1,1,1,1,1,1,1,1,1, 1, 1, 1, 1, 1,...

%e 0,0,0,1,1,2,2,3,3,4,4,5,5,6, 6, 7, 7, 8, 8,...

%e 0,0,0,0,0,0,1,1,2,3,4,5,7,8,10,12,14,16,19,...

%e 0,0,0,0,0,0,0,0,0,0,1,1,2,3, 5, 6, 9,11,15,...

%e 0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0, 1, 1, 2, 3,...

%e ...

%e T(0, 0) = 1, because there is only zero, which has no parts (n=0) and the sum with no parts is zero (k=0). Or, there is only a single q such that <n, k> = <0, 0> = <A000120(q), A029931(q)>, namely q=0.

%e T(1, 10) = 1, because there is only a single partition of k=10 into n=1 positive part. Or, there is only a single pair such that <n, k> = <1, 10> = <A000120(q), A029931(q)> and this pair has q=512.

%e T(2, 3) = 1, because there is only a single partition of k=3 into n=2 positive parts: 3 = 2 + 1. Or, for q>=0, there is only a single pair such that <n, k> = <2, 3> = <A000120(q), A029931(q)> and this pair has q=3.

%e T(3, 3) = 0, because we cannot decompose k=3 into 3 positive parts. Or, there is no q >= 0 such that <n, k> = <3, 3> = <A000120(q), A029931(q)>.

%e T(4, 15) = 6, because there are 6 partitions of 15 into 4 distinct positive parts: 15 = 6 + 4 + 3 + 2; 15 = 6 + 5 + 3 + 1; 15 = 7 + 4 + 3 + 1; 15 = 7 + 5 + 2 + 1; 15 = 8 + 4 + 2 + 1; 15 = 9 + 3 + 2 + 1. Or, there are the corresponding pairs:

%e <4, 15> = <A000120(46), A029931(46)>;

%e <4, 15> = <A000120(53), A029931(53)>;

%e <4, 15> = <A000120(77), A029931(77)>;

%e <4, 15> = <A000120(83), A029931(83)>;

%e <4, 15> = <A000120(139), A029931(139)>;

%e <4, 15> = <A000120(263), A029931(263)>.

%t max = 14; coes = CoefficientList[ Product[1 + t*x^k, {k, 1, max}], {t, x}]; Flatten[ Table[coes[[n, k-n+1]], {k, 1, max}, {n, 1, k}]] (* _Jean-François Alcover_, Nov 08 2012, from given g.f. *)

%o (Python)import math; L = 10

%o def HW(x):

%o ..if x==0: return 0

%o ..return sum([ (x>>i)&1 for i in range(int(math.log(x, 2))+1) ])

%o def TW(x):

%o ..if x==0: return 0

%o ..return sum([ ((x>>i)&1)*(i+1) for i in range(int(math.log(x, 2))+1) ])

%o max_h = L+1; max_t = lambda h: L + (h-1)*h/2 + 1

%o T = [None] * max_h

%o for h in range(max_h): T[h] = [0] * max_t(h)

%o for i in range(2**L):

%o ..h = HW(i); t = TW(i)

%o ..if t < max_t(h): T[h][t] = T[h][t] + 1

%o for h in range(max_h):

%o ..for t in range(max_t(h)): print T[h][t], ';',

%o ..print

%Y Cf. A008289.

%K nonn,tabl

%O 0,31

%A _Sergey Shishmintzev_, Oct 23 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 June 5 01:34 EDT 2024. Contains 373102 sequences. (Running on oeis4.)