Gauss Circle Problem: Lattice Points, Error Term and the Sum of Two Squares Function (2D)
Lattice points inside a circle with the live count, the error term against the circle area, and the number of ways to write n as a sum of two squares. The same shared model as the 3D scene, with numerical checks.
Count the integer lattice points inside a circle and compare with its area. Grow the radius, shift the centre, and watch the count N(r) step up at every sum of two squares while the error N(r) minus pi r squared stays far smaller than the circumference. A Blender-built board and ring with instanced lattice points, and numerical checks including Jacobi sum of two squares formula and brute-force counts.
Lattice points inside a circle with the live count, the error term against the circle area, and the number of ways to write n as a sum of two squares. The same shared model as the 3D scene, with numerical checks.
2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install