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.

Showing 1-3 of 3 results.

A232705 Number of Gaussian integers z satisfying (n-1)/2 < |z| < n/2.

Original entry on oeis.org

0, 0, 4, 0, 8, 4, 8, 8, 20, 0, 16, 12, 24, 8, 28, 16, 28, 24, 40, 12, 32, 24, 44, 16, 48, 28, 48, 32, 52, 32, 40, 44, 64, 28, 72, 32, 76, 40, 72, 44, 56, 56, 84, 56, 80, 52, 88, 48, 92, 56, 92, 56, 96, 68, 88, 72, 108, 56, 104, 76, 112, 64, 124, 80, 104, 92, 112, 92, 120, 96, 116, 80, 144, 84
Offset: 1

Views

Author

Ralf Stephan, Nov 28 2013

Keywords

Comments

Number of integer Cartesian grid points covered by a ring with width 1/2 and outer radius n/2.
For symmetry reasons, a(n) is a multiple of 4.
By bounds on the Gauss circle problem, a(n)/n -> Pi/2 as n -> infinity (see Wikipedia link). - Robert Israel and Peter Bala, Mar 26 2020

Crossrefs

Programs

  • Maple
    N:= 100: # for a(1)..a(N)
    V:= Vector(N):
    for x from 1 to N/2 do
      for y from 1 to x do
        r:= 2*sqrt(x^2 + y^2);
        if r::integer then next fi;
        n:= ceil(r);
        if n > N then break fi;
        if x = y then V[n]:= V[n]+4 else V[n]:= V[n]+8 fi
    od od:
    convert(V,list); # Robert Israel, Mar 26 2020
  • PARI
    a(n)=sum(i=-n,n,sum(j=-n,n,d=sqrt(i*i+j*j);if(d>(n-1)/2&&d
    				

A333572 a(n) is the number of Gaussian integers z with 0 < |z| <= n/2.

Original entry on oeis.org

0, 4, 8, 12, 20, 28, 36, 48, 68, 80, 96, 112, 136, 148, 176, 196, 224, 252, 292, 316, 348, 376, 420, 440, 488, 528, 576, 612, 664, 708, 748, 796, 860, 900, 972, 1008, 1084, 1128, 1200, 1256, 1312, 1372, 1456, 1516, 1596, 1652, 1740, 1792, 1884, 1960, 2052, 2120
Offset: 1

Views

Author

Hugo Pfoertner, Mar 27 2020

Keywords

Crossrefs

Programs

  • Maple
    N:= 100: # for a(1)..a(N)
    V:= Vector(N):
    for x from 1 to N/2 do
      for y from 0 to x do
        v:= ceil(2*sqrt(x^2+y^2));
        if v > N then break fi;
        if y=x or y=0 then V[v]:= V[v]+4 else V[v]:= V[v]+8 fi
    od od:
    ListTools:-PartialSums(convert(V,list)); # Robert Israel, Mar 29 2020

A333573 a(n) = A333572(n)/4.

Original entry on oeis.org

0, 1, 2, 3, 5, 7, 9, 12, 17, 20, 24, 28, 34, 37, 44, 49, 56, 63, 73, 79, 87, 94, 105, 110, 122, 132, 144, 153, 166, 177, 187, 199, 215, 225, 243, 252, 271, 282, 300, 314, 328, 343, 364, 379, 399, 413, 435, 448, 471, 490, 513, 530, 554, 572, 594, 613, 640, 657
Offset: 1

Views

Author

Hugo Pfoertner, Mar 27 2020

Keywords

Crossrefs

Showing 1-3 of 3 results.