OFFSET
1,1
COMMENTS
LINKS
Ray Chandler, Table of n, a(n) for n = 1..10000
EXAMPLE
130 is in the sequence because 130 = 2*5*13, and x^2+y^2=130 has integer solutions (x,y) = (3,11) and (7,9).
1105 is in the sequence because x^2 + y^2 = 1105 = 5*13*17 has solutions (x,y) = (4,33), (9,32), (12,31) and (23,24).
MATHEMATICA
Select[Range[3000], PrimeNu[#]==PrimeOmega[#]==3&&FindInstance[x^2+y^2==#, {x, y}, Integers]!={}&] (* Harvey P. Dale, Dec 16 2023 *)
PROG
(Python)
from math import isqrt
from sympy import primerange, integer_nthroot
from oeis_sequences.OEISsequences import bisection
def A248649(n):
def g(x): return sum(1 for p in primerange(x+1) if p&3!=3)
def h(x, y, i): return enumerate((p for p in primerange(x, y) if p&3!=3), i)
def f(x): return int(n+x-sum(g(x//(k*m))-b for a, k in h(2, integer_nthroot(x, 3)[0]+1, 1) for b, m in h(k+1, isqrt(x//k)+1, a+1)))
return bisection(f, n, n) # Chai Wah Wu, Dec 20 2025
CROSSREFS
KEYWORD
nonn
AUTHOR
Colin Barker, Oct 12 2014
STATUS
approved
