login
A158529
List of primes p with following properties: p = prime(m-1) for some m, p+7 is a square and is equal to prime(m+1)-1.
1
29, 569, 1289, 41609, 147449, 2322569, 2842589, 7096889, 7485689, 10074269, 16208669, 21288989, 33802589, 54819209, 56610569, 57699209, 59814749, 115218749, 118069949, 126427529, 134235389, 149670749, 196448249, 240746249
OFFSET
1,1
COMMENTS
Conjecture: If the condition holds, prime(m-1) and prime(m) are twin primes of the form 10k+9 and 10k+11, i.e. the last digits of the twin prime pairs are 9 and 1. The 9 ending is obvious in this sequence. The table of the first 101 terms was computed using Zak Seidov's table.
Proof of conjecture: Suppose p = prime(m-1) is a term with p + 7 = x^2. Now prime(m) must be p + 2 (it can't be p + 4 because one of p, p+4 and p+8 would be divisible by 3, and it can't be p + 6 = x^2-1 = (x-1)*(x+1)). As an even square, p + 7 ends in 0, 4 or 6, but it can't be 0 because p + 2 would be divisible by 5 and can't be 4 because p + 8 would be divisible by 5. The only possibility is that p + 7 ends in 6, i.e. p ends in 9. - Robert Israel, Jun 12 2026
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000 (first 101 terms from Cino Hilliard)
Sebastian Martin Ruiz, Integer then equal [Broken link]
Sebastian Martin Ruiz and others, Integers then Equals, digest of 7 messages in primenumbers Yahoo group, Mar 14 - Mar 20, 2009.
EXAMPLE
For m = 11, prime(11-1)=29, 29+7=36; prime(11+1)=37, 37-1=36. So 29 is the first entry in the sequence.
MAPLE
R:= NULL: count:= 0:
for y from 0 by 10 while count < 100 do
for x in [y+4, y+6] do
p:= x^2-7;
if isprime(p) and isprime(p+2) and isprime(p+8) then
R:= R, p; count:= count+1;
fi od od:
R; # Robert Israel, Jun 12 2026
MATHEMATICA
ppQ[{a_, b_}]:=Module[{s=Prime[a+1]-1}, IntegerQ[Sqrt[s]]&&b+7==s]; Select[ Table[ {n, Prime[n-1]}, {n, 2, 133*10^5}], ppQ][[All, 2]] (* Harvey P. Dale, Jul 31 2020 *)
PROG
(PARI) isok(p) = if (isprime(p), my(x); issquare(x=p+7) && (x==nextprime(nextprime(p+1)+1)-1)); \\ Michel Marcus, Jun 12 2026
CROSSREFS
Sequence in context: A023948 A020974 A167740 * A020766 A069295 A103723
KEYWORD
nonn,changed
AUTHOR
Cino Hilliard, Mar 20 2009
EXTENSIONS
Edited by N. J. A. Sloane Aug 31 2009 (rephrased definition, corrected offset).
STATUS
approved