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.
%I A339408 #6 Dec 03 2020 12:49:02 %S A339408 1,0,0,0,1,2,1,2,3,6,9,8,16,24,40,52,72,112,172,256,364,528,804,1188, %T A339408 1757,2548,3782,5614,8308,12214,17979,26586,39352,58044,85608,126248, %U A339408 186630,275556,406737,600066,885952,1308250,1931473,2850692,4207952,6212110,9171800,13538980 %N A339408 Number of compositions (ordered partitions) of n into an even number of primes. %H A339408 <a href="/index/Com#comp">Index entries for sequences related to compositions</a> %F A339408 G.f.: (1/2) * (1 / (1 - Sum_{k>=1} x^prime(k)) + 1 / (1 + Sum_{k>=1} x^prime(k))). %e A339408 a(8) = 3 because we have [5, 3], [3, 5] and [2, 2, 2, 2]. %p A339408 b:= proc(n, t) option remember; `if`(n=0, t, add( %p A339408 b(n-ithprime(j), 1-t), j=1..numtheory[pi](n))) %p A339408 end: %p A339408 a:= n-> b(n, 1): %p A339408 seq(a(n), n=0..55); # _Alois P. Heinz_, Dec 03 2020 %t A339408 nmax = 47; CoefficientList[Series[(1/2) (1/(1 - Sum[x^Prime[k], {k, 1, nmax}]) + 1/(1 + Sum[x^Prime[k], {k, 1, nmax}])), {x, 0, nmax}], x] %Y A339408 Cf. A000040, A023360, A034008, A184198, A339380, A339409. %K A339408 nonn %O A339408 0,6 %A A339408 _Ilya Gutkovskiy_, Dec 03 2020