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.

A128218 First differences of A128217.

Original entry on oeis.org

1, 3, 1, 3, 1, 1, 5, 1, 1, 1, 5, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 1, 9, 1, 1, 1, 1, 1, 1, 1, 9, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 13, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 13, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 15, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

John W. Layman, Feb 19 2007

Keywords

Comments

a(A130883(n-1)) = 2*n-1 and a(m) != 2*n-1 for m < A130883(n-1). - Reinhard Zumkeller, Jun 20 2015

Crossrefs

Cf. A128127.
Cf. A130883, A152271 (run lengths after initial term).

Programs

  • Haskell
    a128218 n = a128218_list !! (n-1)
    a128218_list = zipWith (-) (tail a128217_list) a128217_list
    -- Reinhard Zumkeller, Jun 20 2015
    
  • Mathematica
    nsrQ[n_]:=Module[{sr=Sqrt[n]},Abs[First[sr-Nearest[{Floor[sr], Ceiling[ sr]}, sr]]]<1/4];Differences[Select[Range[0,250],nsrQ]] (* Harvey P. Dale, May 02 2012 *)
  • PARI
    default(realprecision, 10000);
    is_A128217(n) = ((abs(sqrt(n)-sqrtint(n))<(1/4)) || (abs(sqrt(n)-(1+sqrtint(n)))<(1/4)));
    k=0; n=0; prevm=0; while(k<20000, n++; if(is_A128217(n), k++; write("b128218.txt", k, " ", (n-prevm)); prevm = n)); \\ Antti Karttunen, Jan 16 2025

Formula

Let A(1)={1}. Then, for k=2,3,4,..., form A(k) by appending to A(k-1) the term k-1 followed by k-1 1's, if k is even, or by appending to A(k-1) the term k followed by k-1 1's, if k is odd. {a(n)} appears to be the limit of {A(k)} as k->infinity.

Extensions

Offset changed by Reinhard Zumkeller, Jun 20 2015

A128153 The number of regular pentagons found by constructing n equally-spaced points on each side of the pentagon and drawing lines parallel to the pentagon sides, as well as lines connecting vertices.

Original entry on oeis.org

1, 9, 20, 37, 58, 85, 116, 153, 194, 241, 292, 349, 410
Offset: 0

Views

Author

Noah Priluck (npriluck(AT)gmail.com), May 02 2007

Keywords

Comments

Similar to constructions for A002717 (dividing a triangle), A000330 (dividing a square) and sequences pending for dividing other polygons.
Use 1 midpoint (resp. 2 points) on each side placed to divide each side into 2 (resp. 3) equally-sized segments or so on, do the same construction for every side of the pentagon so that each side is equally divided in the same way. Connect all such points to each other with lines that are parallel to at least 1 side of the polygon. Also connect all vertices of the pentagon with lines that are parallel to at least 1 side of the pentagon.

Examples

			With 0 points, there is only 1 pentagon. With 1 point (a midpoint on each side), 9 regular pentagons are found. With 2 points, 20 regular pentagons are found in total.
		

Formula

Conjecture: a(n) = (10*n^2 + 16*n + 9 -(-1)^n)/4 for n > 0.
From Chai Wah Wu, Oct 21 2017: (Start)
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4) for n > 4 (conjectured).
G.f.: (-x^4 + x^3 - 2*x^2 - 7*x - 1)/((x - 1)^3*(x + 1)) (conjectured). (End)

Extensions

Edited by Michel Marcus, Jul 10 2013
a(4)-a(12) from Giovanni Resta, Aug 20 2017

A128828 The number of regular hexagons found by constructing n equally-spaced points on each side of the hexagon and drawing lines parallel to the hexagon side.

Original entry on oeis.org

1, 2, 15, 28, 65, 120
Offset: 0

Views

Author

Noah Priluck (npriluck(AT)gmail.com), May 08 2007

Keywords

Comments

Use 1 midpoint (resp. 2 points) on each side placed to divide each side into 2 (resp. 3) equally-sized segments (or so on), do the same construction for every side of the hexagon so that each side is equally divided in the same way. Connect all such points to each other with lines that are parallel to at least 1 side of the hexagon.
Similar constructions to sequences A002717 (dividing a triangle), A000330 (dividing a square) and other sequences pending for similar constructions in other polygons.

Examples

			With 1 point (a midpoint on each side), 2 regular hexagons are found. With 3 points on each side, 15 regular hexagons are found in total and so on.
		

Crossrefs

Formula

a(n) = (11*n^4 + 78*n^3 + 1413*n^2 - 2322*n + 324)/324 when n = 3k,
(-13*n^4 + 670*n^3 - 3219*n^2 + 9934*n - 6724)/324 when n = 1 + 3k,
(5*n^4-46*n^3 + 1515*n^2 - 6046*n + 7940)/108 when n = 2 + 3k (conjecture).

Extensions

Edited by Michel Marcus, Jul 15 2013
Showing 1-3 of 3 results.