A161533 The smallest of three consecutive primes p1 < p2 < p3, where p2-p1, p3-p2, and p3-p1 are all perfect squares.
623071, 779377, 1744891, 2055853, 2906887, 3168721, 3540793, 4177573, 4245643, 4245679, 4309957, 4449127, 4833271, 4858981, 5541187, 5550583, 5710531, 5710567, 5856931, 6013591, 6789637, 6855493, 7024627, 7162339, 7340383, 7614847, 8143501
Offset: 1
Keywords
Examples
623071 is the smallest of the consecutive primes 623071, 623107, and 623171 with gaps 623107-623071 = 36, 623171-623107 = 64, and the double gap 623171-623071 = 100 each a perfect square.
Links
- T. D. Noe, Table of n, a(n) for n = 1..1000
Programs
-
Mathematica
PerfectSquareQ[n_] := JacobiSymbol[n, 13] =!= -1 && JacobiSymbol[n, 19] =!= -1 && JacobiSymbol[n, 17] =!= -1 && JacobiSymbol[n, 23] =!= -1 && IntegerQ[Sqrt[n]]; t = {}; n = 2; p1 = 1; p2 = 2; p3 = 3; While[Length[t] < 30, n++; p1 = p2; p2 = p3; p3 = Prime[n]; If[PerfectSquareQ[p2 - p1] && PerfectSquareQ[p3 - p2] && PerfectSquareQ[p3 - p1], AppendTo[t, p1]]]; t (* T. D. Noe, Jul 09 2013 *) psQ[{a_,b_,c_}]:=AllTrue[{Sqrt[b-a],Sqrt[c-b],Sqrt[c-a]},IntegerQ]; Transpose[ Select[Partition[ Prime[Range[600000]],3,1],psQ]][[1]] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Aug 20 2014 *)
Extensions
5710567 inserted by R. J. Mathar, Sep 23 2009
Comments