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.
%I A147810 #45 Dec 01 2023 15:52:51 %S A147810 1,1,2,1,2,1,3,2,2,1,2,2,4,1,2,1,4,3,2,1,4,2,4,1,2,1,4,2,2,2,4,3,4,2, %T A147810 2,1,4,3,2,1,3,2,6,2,2,2,8,2,2,2,2,2,4,1,4,1,8,2,2,2,2,2,4,2,2,1,4,4, %U A147810 2,3,2,4,8,1,4,2,4,2,2,2,4,3,8,1,2,2,4,2,4,1,4,2,6,1,2,2,4,4,6 %N A147810 Half the number of divisors of n^2+1. %C A147810 For any n>0, n^2+1 cannot be a square and thus has an even number of divisors which always include 1 and n^2+1, therefore a(n) is always a positive integer. %C A147810 Also number of ways to write n^2+1 as n^2+1 = x*y with 1 <= x <= y. - _Michel Lagneau_, Mar 10 2014 %C A147810 Also number of ways to write arctan(1/n) = arctan(1/x)+arctan(1/y), for integral 0 < n < x < y. - _Matthijs Coster_, Dec 09 2014 %C A147810 Number of ways that n can be expressed as (j*k-1)/(j+k) with j >= k > n. For any nonnegative integer n, the equation j*k = 1+n*(j+k) always has at least one integer solution with j >= k > n. As j >= k > n, let k=n+c (c is a positive integer), then j=n+(n^2+1)/c; we can easily conclude that c <= n, i.e., for n > 0, a(n) is the number of divisors of (n^2+1) which are <= n. - _Zhining Yang_, May 18 2023 %H A147810 Amiram Eldar, <a href="/A147810/b147810.txt">Table of n, a(n) for n = 1..10000</a> %H A147810 Shouen Wang, <a href="https://bbs.emath.ac.cn/forum.php?mod=redirect&goto=findpost&ptid=15411&pid=95672&fromuid=46">The general term formula of an integer sequence</a>. %F A147810 a(n) = A000005(A002522(n))/2 = A147809(n)+1. %F A147810 Sum_{k=1..n} a(k) ~ c * n * log(n), where c = 3/(2*Pi) = 0.477464... (A093582). - _Amiram Eldar_, Dec 01 2023 %e A147810 For n = 7 the a(7) = 3 solutions are (17,12), (32,9), (57,8). For n = 13 the a(13) = 4 solutions are (30,23), (47,18), (98,15), (183,14). - _Zhining Yang_, May 18 2023 %p A147810 with(numtheory); A147810:=n->tau(n^2+1)/2; seq(A147810(n), n=1..100); # _Wesley Ivan Hurt_, Mar 10 2014 %t A147810 Table[c=0; Do[If[i<=j && i*j==n^2+1, c++], {i, t=Divisors[n^2+1]}, {j, t}]; c, {n, 100}] (* _Michel Lagneau_, Mar 10 2014 *) %o A147810 (PARI) A147810(n)=numdiv(n^2+1)/2 %o A147810 (Python) %o A147810 from sympy import divisor_count %o A147810 def A147810(n): return divisor_count(n**2+1)>>1 if n else 1 # _Chai Wah Wu_, Jul 09 2023 %Y A147810 Cf. A048691, A093582, A290332, A290333, A359225. %K A147810 easy,nonn %O A147810 1,3 %A A147810 _M. F. Hasler_, Dec 13 2008