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.

A372496 Integers of the form k^2 + 1, where k >= 1, that are the product of two other integers of the form k^2 + 1, where k >= 1.

This page as a plain text file.
%I A372496 #36 May 10 2024 04:09:02
%S A372496 10,50,170,290,325,442,962,1850,2210,3250,5330,8282,9802,12322,15130,
%T A372496 17425,17690,24650,33490,44522,58082,58565,64010,65026,74530,94250,
%U A372496 103685,117650,145162,177242,191845,214370,237170,257050,305810,332930,361202
%N A372496 Integers of the form k^2 + 1, where k >= 1, that are the product of two other integers of the form k^2 + 1, where k >= 1.
%C A372496 This sequence is the sequence of possible c^2 + 1 values of all triples of positive integers (a,b,c) such that (a^2 + 1)*(b^2 + 1) = c^2 + 1.
%C A372496 A001541(n)^2 + 1 is always a term of this sequence for all n > 0. This is because A001541 consists of the x-values of the solutions to the Pell equation x^2 - 2y^2 = 1 which is equivalent to x^2 + 1 = 2*(y^2 + 1) = (1^2 + 1)*(y^2 + 1).
%C A372496 A002061(n)^2 + 1 is always a term of this sequence for all n > 1. This is because A002061 consists of the integers of the form k^2 + k + 1 and (k^2 + k + 1)^2 + 1 = (k^2 + 1)*((k+1)^2 + 1).
%H A372496 Ely Golden, <a href="/A372496/b372496.txt">Table of n, a(n) for n = 1..10667</a> (terms <= 10^16)
%e A372496 50 is a term since 50 = 7^2 + 1 = 10 * 5 = (3^2 + 1)*(2^2 + 1).
%t A372496 formQ[k_] := k >= 1 && IntegerQ@Sqrt[k - 1];
%t A372496 prodQ[k_] := AnyTrue[Divisors[k][[2 ;; -2]], formQ[#] && formQ[k/#]&];
%t A372496 okQ[k_] := formQ[k] && prodQ[k];
%t A372496 Select[Range[2, 10^6], okQ] (* _Jean-François Alcover_, May 10 2024 *)
%o A372496 (Python)
%o A372496 from math import isqrt
%o A372496 def is_perfect_square(n): return isqrt(abs(n))**2 == n
%o A372496 limit = 10**16
%o A372496 sequence_entries = set()
%o A372496 for a in range(1, isqrt(isqrt(limit))+1):
%o A372496     u = a**2 + 1
%o A372496     for b in range(a+1, isqrt(limit//u)+1):
%o A372496         v = b**2 + 1
%o A372496         if(is_perfect_square(u*v - 1)): sequence_entries.add(u*v)
%o A372496 sequence_entries = sorted(sequence_entries)
%o A372496 for i, j in enumerate(sequence_entries, 1):
%o A372496     print(i, j)
%o A372496 (PARI) isok1(k) = issquare(k-1) && (k>1);
%o A372496 isok2(k) = fordiv(k, d, if (isok1(d) && isok1(k/d), return(1)));
%o A372496 isok(k) = isok1(k) && isok2(k); \\ _Michel Marcus_, May 04 2024
%Y A372496 Intersection of A002522 and A135280.
%Y A372496 Cf. A001541, A002061.
%K A372496 nonn
%O A372496 1,1
%A A372496 _Ely Golden_, May 03 2024