OFFSET
1,1
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..991
Cathal O'Sullivan, Jonathan P. Sorenson, and Aryn Stahl, An Algorithm to Find Sums of Consecutive Powers of Primes, arXiv:2204.10930 [math.NT], 2022-2023. See 4.2 Duplicates p. 8-9.
Michael S. Branicky, Python Program
PROG
(Python) # see link for a version suitable for producing b-file
from sympy import primerange, integer_nthroot
def aupto(limit):
adict = dict()
rootlimit = integer_nthroot(limit, 2)[0]
for x in primerange(2, rootlimit+1):
s = x**2
adict[s] = 1
for y in primerange(x+1, rootlimit+1):
s += y**2
if s <= limit:
if s not in adict:
adict[s] = 1
else:
adict[s] += 1
else:
break
return sorted(s for s in adict if adict[s] == 2)
print(aupto(6*10**10)) # Michael S. Branicky, Apr 26 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Marcus, Apr 26 2022
STATUS
approved