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-2 of 2 results.

A357575 Half area of the convex hull of {(x,y) | x,y integers and x^2 + y^2 <= n^2}.

Original entry on oeis.org

0, 1, 4, 12, 21, 37, 52, 69, 93, 120, 152, 181, 212, 258, 297, 345, 388, 444, 495, 552, 616, 673, 749, 814, 881, 965, 1046, 1132, 1211, 1301, 1396, 1483, 1589, 1686, 1800, 1907, 2006, 2128, 2235, 2371, 2490, 2607, 2741, 2872, 3020, 3155, 3293, 3442, 3581, 3739
Offset: 0

Views

Author

Gerhard Kirchner, Oct 04 2022

Keywords

Comments

a(n) is odd if there is an edge connecting two corners (x,y) and (y,x), x > y > 0, such that x-y is odd. Otherwise, a(n) is even. a(n)/n^2 is not monotonous but tends to Pi/2. Apparently, a recurrence or another formula for a(n) does not exist. The convex hull has four symmetry axes: x=0, y=0, y=x, y=-x. Therefore it is sufficient to find the least area of a quarter polygon (multiplied by 2). The half area is an integer because the area of any convex polygon whose corner coordinates are integers is a multiple of 1/2.

Examples

			n=2: 1+3 square units -> a(2) = 4.
          ^
        / | \ 1
      /___|___\
    / |   |   | \ 3
  /___|___|___|___\
		

Crossrefs

Programs

  • Maxima
    block(nmax: 60, a: makelist(0,i,1,nmax),
    for n from 1 thru nmax do
    (x0:0, y0:n, xa:0, ya:n, m1:0, m0:2, ar:0,
      while xa
    				
  • Python
    from math import isqrt
    from sympy import convex_hull
    def A357575(n): return int(2*convex_hull(*[(n,0),(0, 0)]+[(x, isqrt((n-x)*(n+x))) for x in range(n)]).area) if n else 0 # Chai Wah Wu, Oct 23 2022

A357577 Least half area of a convex polygon enclosing a circle with radius n and center (0,0) such that all vertex coordinates are integers.

Original entry on oeis.org

2, 7, 16, 26, 42, 59, 80, 104, 132, 163, 194, 229, 274, 312, 360, 406, 465, 516, 573, 637, 698, 772, 838, 910, 993, 1073, 1158, 1238, 1333, 1425, 1520, 1621, 1719, 1835, 1936, 2043, 2165, 2280, 2405, 2525, 2650, 2782, 2919, 3059, 3195, 3340, 3486, 3632, 3786
Offset: 1

Views

Author

Gerhard Kirchner, Oct 17 2022

Keywords

Comments

"Enclosing" means that any edge runs outside the circle or is a tangent.
Such a polygon does not need to be symmetrical, but the partial areas in the four quadrants are equal. Therefore it is sufficient to find the least area of a quarter polygon (multiplied by 2). The half area is an integer because the area of any convex polygon whose vertex coordinates are integers is a multiple of 1/2. The least number of polygons minimizing the area is 16 if x=y is not an axis of symmetry (2 solutions for each quadrant).

Examples

			For n=1: 2 X 2 square: a(1) = 4/2 = 2.
For n=2: Octagon with vertices (1,2) and (2,1) in the first quadrant: a(2) = 14/2 = 7.
For further examples, see "Closest polygons around a circle".
		

Crossrefs

Showing 1-2 of 2 results.