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.

A121303 Triangle read by rows: T(n,k) is the number of compositions of n into k primes (i.e., ordered sequences of k primes having sum n; n>=2, k>=1).

This page as a plain text file.
%I A121303 #19 Feb 13 2021 07:57:20
%S A121303 1,1,0,1,1,2,0,1,1,1,2,3,0,2,3,1,0,2,4,4,0,3,6,6,1,1,0,6,8,5,0,2,9,13,
%T A121303 10,1,1,2,6,16,15,6,0,3,6,22,25,15,1,0,2,10,24,36,26,7,0,4,9,22,50,45,
%U A121303 21,1,1,0,12,32,65,72,42,8,0,4,12,34,70,106,77,28,1,1,2,12,40,90,150
%N A121303 Triangle read by rows: T(n,k) is the number of compositions of n into k primes (i.e., ordered sequences of k primes having sum n; n>=2, k>=1).
%C A121303 Row n has floor(n/2) terms.
%C A121303 Sum of terms in row n = A023360(n).
%C A121303 T(n,1) = A010051(n) (characteristic function of primes); T(n,2) = A073610(n); T(n,3) = A098238(n).
%C A121303 Sum_{k=1..floor(n/2)} k*T(n,k) = A121304(n).
%H A121303 Alois P. Heinz, <a href="/A121303/b121303.txt">Rows n = 2..200, flattened</a>
%F A121303 G.f.: 1/(1 - t*Sum_{i>=1} z^prime(i)).
%e A121303 T(9,3) = 4 because we have [2,2,5], [2,5,2], [5,2,2] and [3,3,3].
%e A121303 Triangle starts:
%e A121303   1;
%e A121303   1;
%e A121303   0, 1;
%e A121303   1, 2;
%e A121303   0, 1, 1;
%e A121303   1, 2, 3;
%e A121303   0, 2, 3, 1;
%e A121303   0, 2, 4, 4;
%e A121303   ...
%p A121303 G:=1/(1-t*sum(z^ithprime(i),i=1..30))-1: Gser:=simplify(series(G,z=0,25)): for n from 2 to 21 do P[n]:=sort(coeff(Gser,z,n)) od: for n from 2 to 21 do seq(coeff(P[n],t,j),j=1..floor(n/2)) od; # yields sequence in triangular form
%p A121303 # second Maple program:
%p A121303 with(numtheory):
%p A121303 b:= proc(n) option remember; local j; if n=0 then [1]
%p A121303       else []; for j to pi(n) do zip((x, y)->x+y, %,
%p A121303       [0, b(n-ithprime(j))[]], 0) od; % fi
%p A121303     end:
%p A121303 T:= n-> subsop(1=NULL, b(n))[]:
%p A121303 seq(T(n), n=2..20);  # _Alois P. Heinz_, May 23 2013
%t A121303 nn=20;a[x_]:=Sum[x^Prime[n],{n,1,nn}];CoefficientList[Series[1/(1-y a[x]),{x,0,nn}],{x,y}]//Grid (* _Geoffrey Critzer_, Nov 08 2013 *)
%Y A121303 Cf. A010051, A023360, A073610, A098238, A121304, A224344.
%Y A121303 T(n^2,n) gives A341459.
%K A121303 nonn,tabf
%O A121303 2,6
%A A121303 _Emeric Deutsch_, Aug 06 2006