Home▸Mathematics▸Gauss Circle Problem: Lattice Points, Error Term and the Sum of Two Squares Function (2D)

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.

Mathematics2DModerate60 FPS📱 Mobile-adapted🟠 Blender⇄ 3D version
Gauss Circle Problem: Lattice Points, Error Term and the Sum of Two Squares Function (2D) ↗ Open standalone

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.

⚙ Under the hood

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.

Gauss Circle ProblemLattice PointsSum of Two SquaresNumber TheoryError Term

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)