cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A036695 a(n)=number of Gaussian integers z=a+bi satisfying |z|<=n, b>=0.

Original entry on oeis.org

1, 4, 9, 18, 29, 46, 63, 82, 107, 136, 169, 200, 233, 278, 321, 370, 415, 468, 523, 584, 649, 708, 781, 850, 921, 1006, 1087, 1172, 1255, 1344, 1441, 1532, 1637, 1738, 1847, 1962, 2063, 2184, 2295, 2428, 2553, 2672, 2805, 2938
Offset: 0

Views

Author

Keywords

Comments

Number of ordered pairs of integers (x,y) with x^2 + y^2 <= n^2 and y >= 0. [Reinhard Zumkeller, Jan 23 2012]

Crossrefs

Programs

  • Haskell
    a036695 n = length [(x,y) | x <- [-n..n], y <- [0..n], x^2 + y^2 <= n^2]
    -- Reinhard Zumkeller, Jan 23 2012
  • Mathematica
    a[n_] := (k = 0; Do[If[x^2 + y^2 <= n^2, k++], {x, -n, n}, {y, 0, n}]; k); Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Oct 08 2016 *)

Formula

Partial sums of A036696. - Sean A. Irvine, Nov 22 2020