cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A384101 a(n) is the least positive integer y such that y^2 = x^3 + x + n^2 for some positive integer x, or 0 if no such y exists.

This page as a plain text file.
%I A384101 #24 May 26 2025 16:16:42
%S A384101 0,611,265222,23,134316044,1000300015,292,20662660277,68722622488,
%T A384101 198364959099,512009600030,1207284678721,2641831428132,5429539323143,
%U A384101 44,19683072900045,18,60717129072787,182,165216338968409,262144307200060,31,618122334258242,922190780558053
%N A384101 a(n) is the least positive integer y such that y^2 = x^3 + x + n^2 for some positive integer x, or 0 if no such y exists.
%C A384101 Otherwise said, second component of the lexicographically earliest positive integer solution (x, y) to x^3 + x + n^2 = y^2. See A384100 for the first component, x.
%C A384101 For any positive n, there is always the solution (x, y) = (4*n^2*(16*n^4 + 2), 2*n*(16*n^4 + 1)(16*n^4 + 2) - n). Therefore we have the inequality given in formula.
%C A384101 a(n) is even if and only if n is even. - _Chai Wah Wu_, May 24 2025
%F A384101 0 < a(n) <= 2*n*(16*n^4 + 1)*(16*n^4 + 2) - n for all n > 0.
%e A384101 For n = 0, there can't be any positive x for which x^3 + x = x*(x^2 + 1) = y^2, therefore a(0) = 0. (Indeed, x^2 + 1 == 1 (mod x), so x has no factor in common with x^2 + 1 = y^2/x, so x must be a square itself, x = m^2. But then, x^2 + 1 = (y/m)^2 can't have a solution, since x^2 + 1 can't be a square.)
%e A384101 For n = 1, we can check that for x = 1, 2, 3, ..., value of x^3 + x + 1 = 3, 10, 31, ... isn't a square for any x < 72 which is the least positive integer so that x^3 + x + 1 = 72*(72^2 + 1) + 1 = 373321 = (13*47)^2 is a perfect square, thus a(1) = 13*47 = 611.
%e A384101 For n = 2, there is no x < 4128 for which x^3 + x + 2^2 is a square, but 4128*(4128^2+1) + 4 = (2*132611)^2 is indeed the least square of that form, so a(2) = 2*132611 = 265222. (As for n = 1, this is the upper limit for a(n), given in FORMULA.)
%e A384101 For n = 3, there is already x = 8 for which x^3 + x + 3^2 = 529 = 23^2 is a square, therefore a(3) = 23 is much smaller than the before mentioned upper limit.
%o A384101 (PARI) A384101(n, x=A384100(n))=sqrtint(n^2+x^3+x)
%o A384101 (Python)
%o A384101 from math import isqrt
%o A384101 from sympy.ntheory.primetest import is_square
%o A384101 def A384101(n):
%o A384101     if n==0: return 0
%o A384101     m = n**2
%o A384101     for x in range(1,n*(n**4*((n**4<<9)+96)+3)+1):
%o A384101         if is_square(k:=x*(x**2+1)+m): return isqrt(k) # _Chai Wah Wu_, May 24 2025
%Y A384101 Cf. A384100 (the corresponding x-values).
%K A384101 nonn
%O A384101 0,2
%A A384101 _M. F. Hasler_, May 19 2025
%E A384101 a(9)-a(21) from _Chai Wah Wu_, May 24 2025
%E A384101 a(22)-a(23) from _Jinyuan Wang_, May 26 2025