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 A341945 #21 Jan 03 2022 11:12:52 %S A341945 1,1,2,1,2,1,2,1,2,0,2,1,3,1,2,0,3,1,3,1,3,0,4,1,3,0,2,0,4,1,3,1,4,0, %T A341945 4,0,3,1,3,0,5,1,4,1,4,0,6,1,4,0,3,0,6,1,3,0,4,0,7,1,4,1,5,0,6,0,3,1, %U A341945 5,0,7,1,6,1,5,0,7,0,5,1,5,0,9,1,5,0,4,0,10 %N A341945 Number of partitions of n into 2 primes (counting 1 as a prime). %C A341945 Number of partitions of n into 2 noncomposite numbers, A008578. - _Antti Karttunen_, Dec 13 2021 %H A341945 Antti Karttunen, <a href="/A341945/b341945.txt">Table of n, a(n) for n = 2..20000</a> %p A341945 b:= proc(n, i) option remember; series(`if`(n=0, 1, %p A341945 `if`(i<0, 0, (p-> `if`(p>n, 0, x*b(n-p, i)))( %p A341945 `if`(i=0, 1, ithprime(i)))+b(n, i-1))), x, 3) %p A341945 end: %p A341945 a:= n-> coeff(b(n, numtheory[pi](n)), x, 2): %p A341945 seq(a(n), n=2..90); # _Alois P. Heinz_, Feb 24 2021 %t A341945 a[n_] := If[2 == n, 1, Module[{s = 0}, For[p = 2, True, p = NextPrime[p], If[p > n-p, Return[s + Boole[PrimeQ[n-1]]], s += Boole[PrimeQ[n-p]]]]]]; %t A341945 Table[a[n], {n, 2, 100}] (* _Jean-François Alcover_, Jan 03 2022, after _Antti Karttunen_ *) %o A341945 (PARI) A341945(n) = if(2==n,1,my(s=0); forprime(p=2,,if(p>(n-p), return(s+isprime(n-1)), s += isprime(n-p)))); \\ _Antti Karttunen_, Dec 13 2021 %Y A341945 Cf. A001031, A008578, A034891, A061358, A341946, A341947, A341948, A341949, A341950, A341951. %K A341945 nonn,look %O A341945 2,3 %A A341945 _Ilya Gutkovskiy_, Feb 24 2021