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.

A338041 Draw n rays from each of two distinct points in the plane; a(n) is the number of regions thus created. See Comments for details.

Original entry on oeis.org

1, 2, 7, 6, 15, 12, 25, 20, 37, 30, 51, 42, 67, 56, 85, 72, 105, 90, 127, 110, 151, 132, 177, 156, 205, 182, 235, 210, 267, 240, 301, 272, 337, 306, 375, 342, 415, 380, 457, 420, 501, 462, 547, 506, 595, 552, 645, 600, 697, 650, 751, 702, 807, 756, 865, 812, 925
Offset: 1

Views

Author

Lars Blomberg, Oct 08 2020

Keywords

Comments

The rays are evenly spaced around each point. The first ray of one point goes opposite to the direction to the other point. Should a ray hit the other point it terminates there, that is, it is converted to a line segment.
To produce the illustrations below, all pairwise intersections between the rays is calculated and the maximum distance to the center, incremented by 20%, is taken as radius of a circle. Then all intersections between the rays and the circle defines a polygon which is used as limit.

Examples

			For n=1:    <-----x     x----->   so a(1)=1.
For n=2:    <-----x<--->x----->   so a(2)=2.
		

Crossrefs

Cf. A338042 (vertices), A338043 (edges).

Programs

  • PARI
    a(n)=if(n%2==1,(n^2 + 8*n - 5)/4,(n^2 + 2*n)/4);
    vector(200, n, a(n))

Formula

a(n) = (n^2 + 8*n - 5)/4, n odd; (n^2 + 2*n)/4, n even (conjectured).
Conjectured by Stefano Spezia, Oct 08 2020 after Lars Blomberg: (Start)
G.f.: x*(1 + x + 3*x^2 - 3*x^3)/((1 - x)^3*(1 + x)^2).
a(n) = a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) + a(n-5) for n > 5. (End)