login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A222656 Number T(n,k) of partitions of n using exactly k primes; triangle T(n,k), n>=0, 0<=k<=floor(n/2), read by rows. 8
1, 1, 1, 1, 1, 2, 2, 2, 1, 2, 3, 2, 3, 4, 3, 1, 3, 6, 4, 2, 5, 7, 6, 3, 1, 6, 9, 8, 5, 2, 8, 11, 12, 7, 3, 1, 8, 17, 14, 10, 5, 2, 12, 20, 19, 14, 8, 3, 1, 13, 26, 25, 19, 11, 5, 2, 17, 31, 35, 24, 16, 8, 3, 1, 19, 41, 42, 34, 21, 12, 5, 2, 26, 47, 56, 44, 29 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,6

LINKS

Alois P. Heinz, Rows n = 0..200, flattened

FORMULA

Sum_{k=1..floor(n/2)} k * T(n,k) = A037032(n).

G.f.: G(t,x) = Product_{i>=1} (1 - x^prime(i))/((1 - x^i)*(1 - t*x^prime(i))). - Emeric Deutsch, Nov 11 2015

EXAMPLE

T(6,0) = 3: [6], [4,1,1], [1,1,1,1,1,1].

T(6,1) = 4: [5,1], [4,2], [3,1,1,1], [2,1,1,1,1].

T(6,2) = 3: [3,3], [3,2,1], [2,2,1,1].

T(6,3) = 1: [2,2,2].

Triangle T(n,k) begins:

  1;

  1;

  1,  1;

  1,  2;

  2,  2,  1;

  2,  3,  2;

  3,  4,  3,  1;

  3,  6,  4,  2;

  5,  7,  6,  3, 1;

  6,  9,  8,  5, 2;

  8, 11, 12,  7, 3, 1;

  8, 17, 14, 10, 5, 2;

  ...

MAPLE

b:= proc(n, i) option remember; local j; if n=0 then 1 elif i<1 then 0

      else []; for j from 0 to n/i do zip((x, y)->x+y, %,

      [`if`(isprime(i), 0$j, NULL), b(n-i*j, i-1)], 0) od; %[] fi

    end:

T:= n-> b(n$2):

seq(T(n), n=0..16);

MATHEMATICA

zip[f_, x_List, y_List, z_] := With[{m = Max[Length[x], Length[y]]}, Thread[f[PadRight[x, m, z], PadRight[y, m, z]]]]; b[n_, i_] := b[n, i] = Module[{j, pc}, Which[n == 0, {1}, i<1, {0}, True, pc = {}; For[j = 0, j <= n/i, j++, pc = zip[Plus, pc, Join[If[PrimeQ[i], Array[0&, j], {}], b[n-i*j, i-1]], 0]]; pc]]; T[n_] := b[n, n]; Table[T[n], {n, 0, 16}] // Flatten (* Jean-Fran├žois Alcover, Jan 29 2014, after Alois P. Heinz *)

CROSSREFS

Column k=0 gives: A002095.

Row sums give: A000041.

Cf. A000040, A004526, A224344.

Sequence in context: A006371 A000177 A319815 * A162545 A162544 A209323

Adjacent sequences:  A222653 A222654 A222655 * A222657 A222658 A222659

KEYWORD

nonn,tabf

AUTHOR

Alois P. Heinz, May 29 2013

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 2 17:02 EDT 2020. Contains 334787 sequences. (Running on oeis4.)