login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A339370 a(n) = Sum_{k=1..floor(n/2)} (n-k) * floor((n-k)/k). 4
0, 1, 4, 11, 19, 36, 50, 76, 102, 138, 165, 227, 262, 318, 381, 460, 510, 614, 672, 791, 889, 990, 1064, 1249, 1353, 1477, 1610, 1790, 1891, 2133, 2244, 2455, 2626, 2798, 2983, 3312, 3452, 3649, 3857, 4198, 4356, 4715, 4883, 5190, 5514, 5763, 5949, 6446, 6686, 7045 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
Total area of all y X z rectangles such that x + y = n, with x and y integers, 0 < x <= y and z = floor(y/x). - Wesley Ivan Hurt, Dec 21 2020
LINKS
FORMULA
a(n) ~ n^2*(log(n) + 2*EulerGamma - Pi^2/12 - 3/2). - Rok Cestnik, Dec 20 2020
a(n) = n*A002541(n) - A153485(n). - Vaclav Kotesovec, Dec 21 2020
MATHEMATICA
Table[Sum[(n - k)*Floor[(n - k)/k], {k, Floor[n/2]}], {n, 60}]
PROG
(PARI) a(n) = sum(k=1, n\2, (n-k) * ((n-k)\k)); \\ Michel Marcus, Dec 02 2020
(Python)
from math import isqrt
def A339370(n): return n*(1-n)+(s:=isqrt(n))**2*(s+1-(n<<1))-sum((q:=n//k)*((k-(n<<1)<<1)+q+1) for k in range(1, s+1))>>1 # Chai Wah Wu, Oct 27 2023
CROSSREFS
Sequence in context: A102788 A016433 A049841 * A038439 A038431 A009908
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Dec 01 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 20:33 EDT 2024. Contains 371916 sequences. (Running on oeis4.)