OFFSET
0,3
COMMENTS
Number of unit square lattice cells inside quadrant of origin centered circle of radius n+1/2.
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
FORMULA
EXAMPLE
a(2) = 3 because a circle of radius 2+1/2 in the first quadrant encloses (2,1), (1,1), (1,2).
MATHEMATICA
Table[Sum[Floor[Sqrt[(n+1/2)^2 - k^2]], {k, n}], {n, 0, 100}]
PROG
(Magma)
A136484:= func< n | n eq 0 select 0 else (&+[Floor(Sqrt((n+1/2)^2-j^2)): j in [1..n]]) >;
[A136484(n): n in [0..100]]; // G. C. Greubel, Jul 29 2023
(SageMath)
def A136484(n): return sum(floor(sqrt((n+1/2)^2-k^2)) for k in range(1, n+1))
[A136484(n) for n in range(101)] # G. C. Greubel, Jul 29 2023
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Glenn C. Foster (gfoster(AT)uiuc.edu), Jan 02 2008
STATUS
approved