Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
A248923
a(n) is the smallest k >= n such that prime(n)*prime(k) - prime(n+k) is a perfect square.
1
1, 3, 5, 57, 99, 10, 30, 17, 28, 91, 398, 2638, 292, 1383, 69, 1055, 860, 679, 10782, 5440, 1630, 997, 640, 34, 186, 1248, 102, 2039, 1457, 95, 7621, 3980, 273, 4005, 1071, 889, 56, 6309, 4295, 211, 6423, 1004, 2689, 427, 542, 463, 2430, 4815, 223, 277, 70
OFFSET
1,2
COMMENTS
Conjecture: a(n) exists for all n.
The corresponding squares are 1, 4, 36, 1600, 5184, 324, 1764, 1024, 2304, 12996, 81796, 853776, 76176, 481636, 15876, 438244, 386884, 304704, 7518564, 3732624, 992016, 614656, 389376, ...
LINKS
EXAMPLE
a(3)=5 because prime(3)*prime(5) - prime(3+5) = 5*11 - 19 = 6^2.
a(4)=57 because prime(4)*prime(57) - prime(4+57) = 7*269 - 283 = 40^2.
MAPLE
with(numtheory):nn:=70:
for n from 1 to nn do:
pn:=ithprime(n):ii:=0:
for k from n to 10^9 while(ii=0)do:
pk:=ithprime(k):pnk:=ithprime(n+k):c:=pn*pk-pnk:c2:=sqrt(c):
if c2=floor(c2)
then
printf(`%d, `, k):
ii:=1:
else
fi:
od:
od:
MATHEMATICA
Do[k=n; While[!IntegerQ[Sqrt[Prime[k]*Prime[n]-Prime[n+k]]], k++]; Print [n, " ", k], {n, 1, 60}]
PROG
(PARI) a(n) = {k = n; while(! issquare(prime(n)*prime(k) - prime(n+k)), k++); k; } \\ Michel Marcus, Nov 13 2014
CROSSREFS
Sequence in context: A020462 A087602 A086340 * A155121 A106914 A337924
KEYWORD
nonn
AUTHOR
Michel Lagneau, Oct 16 2014
STATUS
approved