A249122 a(n) = floor(n / lpf(n^2 + 1)) where lpf(n^2 + 1) is the smallest prime divisor of n^2 + 1.
0, 0, 1, 0, 2, 0, 3, 1, 4, 0, 5, 2, 6, 0, 7, 0, 8, 3, 9, 0, 10, 4, 11, 0, 12, 0, 13, 5, 14, 1, 15, 6, 16, 2, 17, 0, 18, 7, 19, 0, 20, 8, 21, 3, 22, 1, 23, 9, 24, 1, 25, 10, 26, 0, 27, 0, 28, 11, 29, 4, 30, 12, 31, 3, 32, 0, 33, 13, 34, 5, 35, 14, 36, 0, 37, 1
Offset: 1
Keywords
Examples
a(8) = 1 because 30^2 + 1 = 17*53 and floor(30/17) = 1. Or a(8) = a(A247340(2)) = 1.
Links
- Michel Lagneau, Table of n, a(n) for n = 1..20000
Programs
-
Maple
with(numtheory): for n from 1 to 200 do: p:=n^2+1:x:=factorset(p):d:=floor(n/x[1]): printf(`%d, `, d): od:
-
Mathematica
Table[Floor[n/ FactorInteger[n^2+1][[ 1, 1]]], {n, 100}]
-
PARI
a(n) = n\factor(n^2+1)[1, 1]; \\ Michel Marcus, Oct 25 2014
Comments