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.

A219201 Number of partitions of n into 7 distinct primes.

This page as a plain text file.
%I A219201 #17 Apr 26 2025 08:28:03
%S A219201 1,0,1,0,0,0,2,0,1,0,1,0,4,0,3,0,3,1,6,0,6,1,5,1,10,0,11,2,9,3,16,1,
%T A219201 17,3,15,5,25,4,24,5,25,10,35,6,34,10,36,15,48,10,50,17,52,23,65,17,
%U A219201 69,27,70,32,89,30,93,38,93,48,116,43,121,56,125,70,148
%N A219201 Number of partitions of n into 7 distinct primes.
%H A219201 Alois P. Heinz, <a href="/A219201/b219201.txt">Table of n, a(n) for n = 58..10000</a>
%F A219201 G.f.: Sum_{0<i_1<i_2<...<i_7} x^(Sum_{j=1..7} prime(i_j)).
%F A219201 a(n) = [x^n*y^7] Product_{i>=1} (1+x^prime(i)*y).
%p A219201 b:= proc(n, i) option remember; `if`(n=0, [1,0$7], `if`(i<1, [0$8],
%p A219201        zip((x, y)->x+y, b(n, i-1), [0, `if`(ithprime(i)>n, [0$7],
%p A219201        b(n-ithprime(i), i-1)[1..7])[]], 0)))
%p A219201     end:
%p A219201 a:= n-> b(n, numtheory[pi](n))[8]:
%p A219201 seq(a(n), n=58..140);
%t A219201 k = 7; b[n_, i_] := b[n, i] = If[n == 0, Join[{1}, Array[0&, k]], If[i<1, Array[0&, k+1], Plus @@ PadRight[{b[n, i-1], Join[{0}, If[Prime[i]>n, Array[0&, k], Take[b[n-Prime[i], i-1], k]]]}]]]; a[n_] := b[n, PrimePi[n]][[k+1]]; Table[a[n], {n, 58, 140}] (* _Jean-François Alcover_, Jan 30 2014, after _Alois P. Heinz_ *)
%t A219201 Table[Length@Select[IntegerPartitions[k,{7}, Prime@Range@100], #[[1]] > #[[2]] > #[[3]] > #[[4]] > #[[5]] > #[[6]] > #[[7]] &], {k, 58, 140}] (* _Robert Price_, Apr 25 2025 *)
%Y A219201 Column k=7 of A219180.
%K A219201 nonn
%O A219201 58,7
%A A219201 _Alois P. Heinz_, Nov 14 2012