cp's OEIS Frontend

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.

A294016 a(n) = sum of all divisors of all positive integers <= n, minus the sum of remainders of n mod k, for k = 1, 2, 3, ..., n.

This page as a plain text file.
%I A294016 #43 Jul 19 2024 14:37:23
%S A294016 1,4,7,14,17,30,33,48,57,74,77,110,113,134,153,184,187,230,233,278,
%T A294016 301,330,333,406,419,452,479,536,539,624,627,690,721,762,789,900,903,
%U A294016 948,983,1084,1087,1196,1199,1280,1347,1400,1403,1556,1573,1660,1703,1796,1799,1932,1967,2096,2143,2208,2211,2428,2431,2500
%N A294016 a(n) = sum of all divisors of all positive integers <= n, minus the sum of remainders of n mod k, for k = 1, 2, 3, ..., n.
%C A294016 a(n) is also the area (also the number of cells) of the n-th polygon formed by the Dyck path described in A237593 and its mirror, as shown below in the example.
%C A294016 a(n) is also the volume (and the number of cubes) in the n-th level (starting from the top) of the pyramid described in A294017.
%F A294016 a(n) = A024916(n) - A004125(n).
%F A294016 a(n) = A000290(n) - A067436(n).
%F A294016 From _Omar E. Pol_, Nov 05 2017: (Start)
%F A294016 a(n) = A000203(n) + A024816(n) + A153485(n) - A004125(n).
%F A294016 a(n) = A000217(n) + A153485(n) - A004125(n).
%F A294016 a(n) = A000203(n) + A153485(n) + A244048(n). (End)
%F A294016 a(n) = (Pi^2/6 - 1) * n^2 + O(n*log(n)). - _Amiram Eldar_, Mar 30 2024
%e A294016 Illustration of initial terms:
%e A294016 .
%e A294016 .   _ 1
%e A294016 .  |_|_ _ 4
%e A294016 .    |   |
%e A294016 .    |_ _|_ _   7
%e A294016 .        |   |_
%e A294016 .        |_    |
%e A294016 .          |_ _|_ _ _  14
%e A294016 .              |     |_
%e A294016 .              |       |
%e A294016 .              |_      |
%e A294016 .                |_ _ _|_ _ _
%e A294016 .                      |     |  17
%e A294016 .                      |     |_ _
%e A294016 .                      |_ _      |
%e A294016 .                          |     |
%e A294016 .                          |_ _ _|_ _ _ _
%e A294016 .                                |       |_  30
%e A294016 .                                |         |_
%e A294016 .                                |           |
%e A294016 .                                |_          |
%e A294016 .                                  |_        |
%e A294016 .                                    |_ _ _ _|_ _ _ _
%e A294016 .                                            |       |
%e A294016 .                                            |       |_  33
%e A294016 .                                            |         |_ _
%e A294016 .                                            |_ _          |
%e A294016 .                                                |_        |
%e A294016 .                                                  |       |
%e A294016 .                                                  |_ _ _ _|
%e A294016 .
%p A294016 A294016 := proc(n)
%p A294016     A024916(n)-A004125(n) ;
%p A294016 end proc:
%p A294016 seq(A294016(n),n=1..80) ; # _R. J. Mathar_, Nov 07 2017
%t A294016 Accumulate[Table[2*(DivisorSigma[1, n] - n) + 1, {n, 1, 100}]] (* _Amiram Eldar_, Mar 30 2024 *)
%o A294016 (Python)
%o A294016 from math import isqrt
%o A294016 def A294016(n): return -(s:=isqrt(n))**2*(s+1)+sum((q:=n//k)*((k<<1)+q+1) for k in range(1,s+1))-n**2 # _Chai Wah Wu_, Oct 22 2023
%Y A294016 Partial sums of A294015.
%Y A294016 Partial sums gives A294017.
%Y A294016 Cf. A000203, A000217, A000290, A013661, A004125, A024816, A024916, A067436, A153485, A196020, A235791, A236104, A237591, A237593, A244048, A245092.
%K A294016 nonn
%O A294016 1,2
%A A294016 _Omar E. Pol_, Oct 22 2017