A119677 a(n) is the number of complete squares that fit inside the circle with radius n, drawn on squared paper at (0, 0).
0, 0, 4, 16, 32, 60, 88, 120, 164, 216, 276, 332, 392, 476, 556, 648, 732, 832, 936, 1052, 1176, 1288, 1428, 1560, 1696, 1860, 2016, 2180, 2340, 2512, 2700, 2876, 3080, 3276, 3488, 3712, 3908, 4144, 4360, 4620, 4864, 5096, 5356, 5616, 5900
Offset: 0
Keywords
Links
- David Dewan, Table of n, a(n) for n = 0..10000
- David Dewan, Drawings for n=1..12
Crossrefs
Cf. A001182.
Programs
-
Mathematica
a[n_] := 4 Sum[Floor[Sqrt[n^2 - k^2]], {k, n - 1}]; Array[a, 45, 0] (* David Dewan, May 27 2024 *)
-
Python
from math import isqrt def A119677(n): return sum(isqrt(k*((n<<1)-k)) for k in range(1,n))<<2 # Chai Wah Wu, Jul 18 2024
Formula
a(n) = 4 * A001182(n).
Limit_{n->oo} a(n)/(n^2) = Pi.
Extensions
More terms from Don Reble, Aug 01 2006
Name clarified by Kirill Zolotuskiy, Apr 15 2023