login
A359696
a(n) is the number of points with integer coordinates located between the x-axis and the graph of the function y = n^3 / (n^2 + x^2).
1
1, 6, 15, 28, 49, 72, 103, 138, 177, 228, 275, 330, 397, 464, 543, 620, 707, 800, 891, 1002, 1105, 1220, 1341, 1468, 1605, 1740, 1883, 2032, 2187, 2356, 2517, 2694, 2869, 3058, 3249, 3444, 3645, 3856, 4075, 4294, 4519, 4748, 4987, 5230
OFFSET
1,2
COMMENTS
The graph of the function y = n^3/(n^2+x^2) is called the "Witch of Agnesi". All points with integer coordinates that lie on or below the graph of this function on the interval (-oo; +oo) are considered. Points lying on the x-axis are not taken into account.
FORMULA
a(n) = n + 2*Sum_{x > 0} floor(n^3/(n^2 + x^2)). - Andrew Howroyd, Mar 07 2023
a(n) = n + 2*Sum_{y=1..n-1} floor(sqrt(n^3/y-n^2)). - Chai Wah Wu, Mar 27 2023
EXAMPLE
a(1) = 1;
a(2) = floor(y(-2)) + floor(y(-1)) + floor(y(0)) + floor(y(1)) + floor(y(2)) = 1 + 1 + 2 + 1 + 1 = 6.
MAPLE
f:= proc(n) local y; n + 2 * add(floor(sqrt(n^3/y - n^2)), y=1..n-1); end proc:
map(f, [$1..100]); # Robert Israel, Mar 07 2024
PROG
(PARI) a(n) = {my(t=n, s=0, x=0); while(t > 0, s+=t; x++; t = 2*(n^3\(n^2 + x^2))); s} \\ Andrew Howroyd, Mar 07 2023
(Python)
from math import isqrt
def A359696(n): return (sum(isqrt(n**2*(n-y)//y) for y in range(1, n))<<1)+n # Chai Wah Wu, Mar 27 2023
CROSSREFS
Sequence in context: A164000 A212087 A301292 * A134978 A115742 A026102
KEYWORD
nonn
AUTHOR
Nicolay Avilov, Mar 07 2023
STATUS
approved