login
Integers n with the property that the largest prime factor of n^2 + 1 is less than n.
9

%I #29 Sep 08 2022 08:46:11

%S 7,18,21,38,41,43,47,57,68,70,72,73,83,99,111,117,119,123,128,132,133,

%T 142,157,172,173,174,182,185,191,192,193,200,211,212,216,233,237,239,

%U 242,251,253,255,265,268,273,278,293,294,302,305,307,313,319,322,327

%N Integers n with the property that the largest prime factor of n^2 + 1 is less than n.

%C Every Pythagorean prime, p, can be written as the sum of two positive integers, a and b, such that ab is congruent to 1 (mod p). Further: no number is the addend of two different primes, and the numbers that are NEVER addends are precisely the numbers in this list.

%C In particular: 5 = 2+3 and 2*3 = 6 == 1 (mod 5), 13 = 5+8 and 5*8 = 40 == 1 (mod 13), 17 = 4+13 and 4*13 = 52 == 1 (mod 17), 29 = 12+17 and 12*17 = 204 == 1 (mod 29), and so on.

%C Every integer greater than 1 is in exactly one of A002314, A152676, and the present sequence. - _Michael Kaltman_, May 11 2019

%H Giovanni Resta, <a href="/A256011/b256011.txt">Table of n, a(n) for n = 1..10000</a>

%e 7^2 + 1 = 50 = 2 * 5^2;

%e 18^2 + 1 = 325 = 5^2 * 13;

%e 21^2 + 1 = 442 = 2 * 13 * 17.

%p select(n -> max(numtheory:-factorset(n^2+1))<n, [$1..10^4]); # _Robert Israel_, Jun 09 2015

%t Select[Range[10^4], FactorInteger [#^2 + 1][[-1, 1]] < # &] (* _Giovanni Resta_, Jun 09 2015 *)

%o (PARI) for(n=1,10^3,N=n^2+1;if(factor(N)[,1][omega(N)] < n,print1(n,", "))) \\ _Derek Orr_, Jun 08 2015

%o (PARI) is(n)=my(f=factor(n^2+1)[,1]); f[#f]<n \\ _Charles R Greathouse IV_, Jun 09 2015

%o (Magma) [k:k in [1..330]| Max(PrimeDivisors(k^2+1)) lt k]; // _Marius A. Burtea_, Jul 27 2019

%Y Cf. A002144 (Pythagorean primes), A014442, A002314, A152676.

%K nonn

%O 1,1

%A _Michael Kaltman_, May 31 2015