login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A302480 Number of partitions of n into two parts with the smaller part nonprime and the larger part prime. 1

%I #9 Apr 09 2018 22:36:59

%S 0,0,1,1,0,1,0,1,1,0,1,1,1,1,1,0,2,1,2,2,3,1,3,1,3,1,3,1,3,1,3,3,4,1,

%T 4,0,4,3,3,1,4,1,4,3,5,2,5,1,5,2,6,3,6,2,6,4,7,3,6,1,6,5,6,2,7,1,7,6,

%U 7,3,8,3,8,5,8,4,9,2,9,6,9,5,9,2,9,5

%N Number of partitions of n into two parts with the smaller part nonprime and the larger part prime.

%H <a href="/index/Par#part">Index entries for sequences related to partitions</a>

%F a(n) = Sum_{i=1..floor(n/2)} (1 - A010051(i)) * A010051(n-i).

%e a(17) = 2; 17 = 13+4 = 11+6, smaller parts are nonprimes larger are prime.

%t Table[Sum[(PrimePi[n - i] - PrimePi[n - i - 1]) (1 - (PrimePi[i] - PrimePi[i - 1])), {i, Floor[n/2]}], {n, 100}]

%o (PARI) a(n) = sum(i=1, n\2, (1-isprime(i))*isprime(n-i)); \\ _Michel Marcus_, Apr 09 2018

%Y Cf. A010051, A302481.

%K nonn,easy

%O 1,17

%A _Wesley Ivan Hurt_, Apr 08 2018

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 03:08 EDT 2024. Contains 371918 sequences. (Running on oeis4.)