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.

A347788 Number of compositions (ordered partitions) of n into at most 2 nonprime parts.

This page as a plain text file.
%I A347788 #12 Nov 28 2022 03:39:50
%S A347788 1,1,1,0,1,2,1,2,2,3,5,2,4,4,5,5,8,4,8,6,8,7,11,6,12,9,13,9,14,10,16,
%T A347788 12,14,13,19,13,22,14,17,17,22,16,24,18,22,19,25,18,28,21,28,21,28,22,
%U A347788 32,25,30,25,33,26,38,28,31,29,38,29,42,30,34,33,42
%N A347788 Number of compositions (ordered partitions) of n into at most 2 nonprime parts.
%H A347788 Antti Karttunen, <a href="/A347788/b347788.txt">Table of n, a(n) for n = 0..10000</a>
%t A347788 Table[Length@Flatten[Permutations/@IntegerPartitions[n,2,Select[Range@n,!PrimeQ@#&]],1],{n,0,70}] (* _Giorgos Kalogeropoulos_, Sep 13 2021 *)
%o A347788 (PARI) A347788(n) = if(n<2,1,!isprime(n)+sum(k=1,n-1,!(isprime(k)+isprime(n-k)))); \\ _Antti Karttunen_, Nov 25 2022
%Y A347788 Cf. A005171, A018252, A052284, A076608, A347796, A347797, A347798, A347799, A358638.
%K A347788 nonn
%O A347788 0,6
%A A347788 _Ilya Gutkovskiy_, Sep 13 2021