cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A259200 Number of partitions of n into nine primes.

Original entry on oeis.org

1, 1, 1, 2, 2, 3, 4, 4, 5, 7, 7, 9, 10, 11, 12, 16, 16, 20, 21, 24, 26, 33, 31, 39, 39, 47, 46, 59, 53, 69, 65, 80, 77, 98, 85, 114, 104, 131, 118, 154, 133, 179, 155, 200, 177, 236, 196, 268, 227, 300, 256
Offset: 18

Views

Author

Doug Bell, Jun 20 2015

Keywords

Examples

			a(23) = 3 because there are 3 partitions of 23 into nine primes: [2,2,2,2,2,2,2,2,7], [2,2,2,2,2,2,3,3,5] and [2,2,2,2,3,3,3,3,3].
		

Crossrefs

Column k=9 of A117278.
Number of partitions of n into r primes for r = 1..10: A010051, A061358, A068307, A259194, A259195, A259196, A259197, A259198, this sequence, A259201.
Cf. A000040.

Programs

  • Magma
    [#RestrictedPartitions(k,9,Set(PrimesUpTo(1000))):k in [18..70]] ; // Marius A. Burtea, Jul 13 2019
  • Maple
    N:= 100: # to get a(0) to a(N)
    Primes:= select(isprime,[$1..N]):
    np:= nops(Primes):
    for j from 0 to np do g[0,j]:= 1 od:
    for n from 1 to 9 do
      g[n,0]:= 0:
      for j from 1 to np do
         g[n,j]:= convert(series(add(g[k,j-1]
              *x^((n-k)*Primes[j]),k=0..n),x,N+1),polynom)
      od
    od:
    seq(coeff(g[9,np],x,i),i=18..N) # Robert Israel, Jun 21 2015
  • Mathematica
    Table[Length[Select[IntegerPartitions[n],Length[#]==9&&AllTrue[ #, PrimeQ]&]], {n,18,70}] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Jul 31 2016 *)
  • PARI
    a(n) = {nb = 0; forpart(p=n, if (#p && (#select(x->isprime(x), Vec(p)) == #p), nb+=1), , [9,9]); nb;} \\ Michel Marcus, Jun 21 2015
    

Formula

a(n) = [x^n y^9] Product_{k>=1} 1/(1 - y*x^prime(k)). - Ilya Gutkovskiy, Apr 18 2019
a(n) = Sum_{q=1..floor(n/9)} Sum_{p=q..floor((n-q)/8)} Sum_{o=p..floor((n-p-q)/7)} Sum_{m=o..floor((n-o-p-q)/6)} Sum_{l=m..floor((n-m-o-p-q)/5)} Sum_{k=l..floor((n-l-m-o-p-q)/4)} Sum_{j=k..floor((n-k-l-m-o-p-q)/3)} Sum_{i=j..floor((n-j-k-l-m-o-p-q)/2)} c(q) * c(p) * c(o) * c(m) * c(l) * c(k) * c(j) * c(i) * c(n-i-j-k-l-m-o-p-q), where c = A010051. - Wesley Ivan Hurt, Jul 13 2019