The OEIS is supported by the many generous donors to the OEIS Foundation. Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A274851 Smallest prime q larger than p=prime(n) such that (p+1)(q+1) is a square m^2; a(n)=0 if there is no such q. 1

%I

%S 11,0,23,17,47,223,31,79,53,269,71,151,167,1583,107,149,239,557,271,

%T 97,2663,179,2099,359,127,2549,233,191,439,1823,199,1187,2207,1259,

%U 293,607,631,4099,1049,4349,499,727,431,6983,3167,241,1907,349,911,919,1663,1499,337,2267,1031,593,479

%N Smallest prime q larger than p=prime(n) such that (p+1)(q+1) is a square m^2; a(n)=0 if there is no such q.

%H Zak Seidov, <a href="/A274851/a274851.txt">Table of n, p=prime(n), q=a(n), m=sqrt((p+1)(q+1)), for n=1..102. </a>

%e n=1: p=2, q=11, (p+1)(q+1)=36=6^2, m=6;

%e a(2)=0 because there is no q > 3 such that (3+1)(q+1) is a square (because, for prime q >3, (q+1) cannot be a square);

%e n=3: p = 5, q = 23, (p + 1) (q + 1) = 144 = 12^2, m=12.

%t Table[SelectFirst[Prime@ Range[n + 1, 10^4], IntegerQ@ Sqrt[(Prime@ n + 1) (# + 1)] &], {n, 102}] /. k_ /; MissingQ@ k -> 0 (* _Michael De Vlieger_, Jul 09 2016, Version 10.2 *)

%Y Cf. A274848.

%K nonn

%O 1,1

%A _Zak Seidov_, Jul 09 2016

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.

Last modified January 28 12:46 EST 2023. Contains 359892 sequences. (Running on oeis4.)