login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A237710 Least prime p < n with pi(n-p) a square, or 0 if such a prime p does not exist. 5

%I

%S 0,0,2,2,3,5,5,7,2,2,2,2,3,5,5,7,7,11,11,11,11,13,13,17,2,2,2,2,2,2,3,

%T 5,5,7,7,11,11,11,11,13,13,17,17,17,17,19,19,23,23,23,23,29,29,29,2,2,

%U 2,2,2,2,3,5,5,7,7,11,11,11,11,13

%N Least prime p < n with pi(n-p) a square, or 0 if such a prime p does not exist.

%C According to the conjecture in A237706, a(n) should be positive for all n > 2.

%H Zhi-Wei Sun, <a href="/A237710/b237710.txt">Table of n, a(n) for n = 1..10000</a>

%H Z.-W. Sun, <a href="http://arxiv.org/abs/1402.6641">Problems on combinatorial properties of primes</a>, arXiv:1402.6641, 2014

%e a(5) = 3 since pi(5-3) = 1^2, but pi(5-2) = 2 is not a square.

%t SQ[n_]:=IntegerQ[Sqrt[n]]

%t q[n_]:=SQ[PrimePi[n]]

%t Do[Do[If[q[n-Prime[k]],Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[n-1]}];

%t Print[n," ",0];Label[aa];Continue,{n,1,100}]

%Y Cf. A000040, A000290, A000720, A237706.

%K nonn

%O 1,3

%A _Zhi-Wei Sun_, Feb 12 2014

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 22 16:31 EST 2019. Contains 329396 sequences. (Running on oeis4.)