login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A252096 Largest prime divisor of n^2+1 - smallest prime divisor of n^2+1. 1
0, 0, 3, 0, 11, 0, 3, 8, 39, 0, 59, 24, 15, 0, 111, 0, 27, 8, 179, 0, 15, 92, 51, 0, 311, 0, 71, 152, 419, 36, 35, 36, 107, 76, 611, 0, 135, 12, 759, 0, 27, 348, 35, 136, 1011, 44, 15, 456, 1199, 20, 1299, 536, 279, 0, 87, 0, 11, 668, 1739, 264, 1859, 764, 395 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
LINKS
FORMULA
a(n) = A014442(n) - A089120(n).
a(A005574(n)) = 0. - Michel Marcus, Dec 15 2014
EXAMPLE
a(5)= 11 because 5^2+1 = 2*13 and 13-2 = 11.
MAPLE
with(numtheory):
a:= n-> (f-> max(f[])-min(f[]))(factorset(n^2+1)):
seq(a(n), n=1..100); # Alois P. Heinz, Jan 07 2015
MATHEMATICA
f[n_]:=Transpose[FactorInteger[n^2+1]][[1]]; Table[Last[f[n]-First[f[n]]], {n, 200}]
PROG
(PARI) a(n) = {my(f = factor(n^2+1)); f[#f~, 1] - f[1, 1]; } \\ Michel Marcus, Dec 15 2014
CROSSREFS
Cf. A002522 (n^2+1), A005574 (n^2+1 is prime).
Cf. A014442 (largest prime factor of n2+1), A089120 (smallest prime factor).
Sequence in context: A215681 A215587 A094897 * A346240 A216470 A182259
KEYWORD
nonn,easy
AUTHOR
Michel Lagneau, Dec 14 2014
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 15 07:28 EDT 2024. Contains 374324 sequences. (Running on oeis4.)