login
A243980
Four times the sum of all divisors of all positive integers <= n.
10
4, 16, 32, 60, 84, 132, 164, 224, 276, 348, 396, 508, 564, 660, 756, 880, 952, 1108, 1188, 1356, 1484, 1628, 1724, 1964, 2088, 2256, 2416, 2640, 2760, 3048, 3176, 3428, 3620, 3836, 4028, 4392, 4544, 4784, 5008, 5368, 5536, 5920, 6096, 6432, 6744, 7032, 7224, 7720
OFFSET
1,1
COMMENTS
Also number of "ON" cells at n-th stage in a structure which looks like a simple 2-dimensional cellular automaton (see example). The structure is formed by the reflection on the four quadrants from the diagram of the symmetry of sigma in the first quadrant after n-th stage, hence the area in each quadrant equals the area of each wedge and equals A024916(n); the sum of all divisors of all positive integers <= n. For more information about the diagram see A237593 and A237270.
LINKS
FORMULA
a(n) = A016742(n) - 4*A004125(n) = 4*A024916(n).
a(n) = 2*(A006218(n) + A222548(n)) = 2*A327329(n). - Omar E. Pol, Sep 25 2019
EXAMPLE
Illustration of the structure after 16 stages (contains 880 ON cells):
. _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
. | _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ |
. | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
. _ _| | _ _ _ _ _ _ _ _ _ _ _ _ _ _ | |_ _
. _| _ _| |_ _ _ _ _ _ _ _ _ _ _ _ _ _| |_ _ |_
. _| _| _| | _ _ _ _ _ _ _ _ _ _ _ _ | |_ |_ |_
. | _| |_ _| |_ _ _ _ _ _ _ _ _ _ _ _| |_ _| |_ |
. _ _ _| | _ _| | _ _ _ _ _ _ _ _ _ _ | |_ _ | |_ _ _
. | _ _ _|_| | _| |_ _ _ _ _ _ _ _ _ _| |_ | |_|_ _ _ |
. | | | _ _ _| _|_ _| _ _ _ _ _ _ _ _ |_ _|_ |_ _ _ | | |
. | | | | | _ _ _| | _| |_ _ _ _ _ _ _ _| |_ | |_ _ _ | | | | |
. | | | | | | | _ _|_| _| _ _ _ _ _ _ |_ |_|_ _ | | | | | | |
. | | | | | | | | | _ _| |_ _ _ _ _ _| |_ _ | | | | | | | | |
. | | | | | | | | | | | _ _| _ _ _ _ |_ _ | | | | | | | | | | |
. | | | | | | | | | | | | | _|_ _ _ _|_ | | | | | | | | | | | | |
. | | | | | | | | | | | | | | | _ _ | | | | | | | | | | | | | | |
. | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
. | | | | | | | | | | | | | | | |_ _| | | | | | | | | | | | | | | |
. | | | | | | | | | | | | | |_|_ _ _ _|_| | | | | | | | | | | | | |
. | | | | | | | | | | | |_|_ |_ _ _ _| _|_| | | | | | | | | | | |
. | | | | | | | | | |_|_ |_ _ _ _ _ _| _|_| | | | | | | | | |
. | | | | | | | |_|_ _ |_ |_ _ _ _ _ _| _| _ _|_| | | | | | | |
. | | | | | |_|_ _ | |_ |_ _ _ _ _ _ _ _| _| | _ _|_| | | | | |
. | | | |_|_ _ |_|_ _| |_ _ _ _ _ _ _ _| |_ _|_| _ _|_| | | |
. | |_|_ _ _ | |_ |_ _ _ _ _ _ _ _ _ _| _| | _ _ _|_| |
. |_ _ _ | |_|_ | |_ _ _ _ _ _ _ _ _ _| | _|_| | _ _ _|
. | |_ |_ _ |_ _ _ _ _ _ _ _ _ _ _ _| _ _| _| |
. |_ |_ |_ | |_ _ _ _ _ _ _ _ _ _ _ _| | _| _| _|
. |_ |_ _| |_ _ _ _ _ _ _ _ _ _ _ _ _ _| |_ _| _|
. |_ _ | |_ _ _ _ _ _ _ _ _ _ _ _ _ _| | _ _|
. | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
. | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
. |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _|
.
MATHEMATICA
Accumulate[4*DivisorSigma[1, Range[50]]] (* Harvey P. Dale, May 13 2018 *)
PROG
(Python)
from math import isqrt
def A243980(n): return -(s:=isqrt(n))**2*(s+1) + sum((q:=n//k)*((k<<1)+q+1) for k in range(1, s+1))<<1 # Chai Wah Wu, Oct 21 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Omar E. Pol, Jun 18 2014
STATUS
approved