login
a(n) is the number of integers of the form (n^2+1)/(k^2+1), where k = 1,2,3,...,n.
4

%I #35 Sep 18 2019 10:20:12

%S 1,1,3,1,2,1,4,2,2,1,2,2,5,1,2,1,5,3,2,1,4,2,4,1,2,1,4,2,2,2,4,2,4,1,

%T 2,1,4,3,2,1,2,2,6,1,2,1,9,2,2,1,2,2,4,1,3,1,8,2,2,1,2,2,4,2,2,1,4,3,

%U 2,1,2,3,7,1,2,1,4,2,2,2,3,2,7,1,2,1,4,2,3,1,4,2,5,1,2,1,4,3,4,1,2,2,4

%N a(n) is the number of integers of the form (n^2+1)/(k^2+1), where k = 1,2,3,...,n.

%C If Landau's fourth problem is ever answered in the positive, that would imply that there are infinitely many primes of the form n^2+1, in which case a(n) = 1 for infinitely many n (cf. A005574). Note that a(n) = 1 if and only if there is m >= 1 such that A066755(m) = n. - _Petros Hadjicostas_, Sep 18 2019

%H Alois P. Heinz, <a href="/A066743/b066743.txt">Table of n, a(n) for n = 1..10000</a>

%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Landau%27s_problems">Landau's problems</a>.

%F Conjecture: (1/n)*Sum_{i=1..n} a(i) = c*log(log(n)) asymptotically with 1 < c < 2.

%e a(7) = 4 because among the numbers 1^2+1 = 2, 2^2+1 = 5, 3^2+1 = 10, 4^2+1 = 17, 5^2+1 = 26, 6^2+1 = 37, 7^2+1 = 50, exactly 4 of them (2, 5, 10, and 50) divide 7^2+1 = 50. - _Petros Hadjicostas_, Sep 18 2019

%p a:= n-> add(`if`(irem(n^2+1, k^2+1)=0, 1, 0), k=1..n):

%p seq(a(n), n=1..120); # _Alois P. Heinz_, Sep 18 2019

%t a[ n_ ] := Length[ Select[ Range[ 1, n ], IntegerQ[ (n^2+1)/(#^2+1) ]& ] ]

%o (PARI) a(n) = sum(k=1, n, denominator((n^2+1)/(k^2+1)) == 1); \\ _Michel Marcus_, Sep 18 2019

%Y Cf. A002496, A005574, A066755, A069929 (cubic analogue).

%K nonn

%O 1,3

%A _Benoit Cloitre_, Jan 16 2002

%E Edited by _Dean Hickerson_, Jan 20 2002