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.

A234904 a(n)*Pi is the total length of irregular spiral (center points: 2, 1, 3) after n rotations.

Original entry on oeis.org

3, 12, 18, 21, 30, 36, 39, 48, 54, 57, 66, 72, 75, 84, 90, 93, 102, 108, 111, 120, 126, 129, 138, 144, 147, 156, 162, 165, 174, 180, 183, 192, 198, 201, 210, 216, 219, 228, 234, 237, 246, 252, 255, 264, 270, 273, 282, 288, 291, 300, 306, 309, 318, 324, 327, 336, 342, 345, 354, 360, 363, 372, 378, 381, 390, 396, 399, 408
Offset: 1

Views

Author

Kival Ngaokrajang, Jan 01 2014

Keywords

Comments

Let points 2, 1 & 3 be placed on a straight line at intervals of 1 unit. At point 1 make a half unit circle then at point 2 make another half circle and maintain continuity of circumferences. Continue using this procedure at points 3, 1, 2, and so on. The form of spiral is non-expanded loop. See illustration in links.

Crossrefs

Cf. A014105*Pi (total spiral length, 2 inline center points).

Programs

  • Magma
    I:=[3,12,18,21]; [n le 4 select I[n] else Self(n-1)+Self(n-3)-Self(n-4): n in [1..70]]; // Vincenzo Librandi, May 10 2015
  • Mathematica
    RecurrenceTable[{a[n] == a[n - 1] + a[n - 3] - a[n - 4], a[1] == 3,
    a[2] == 12, a[3] == 18, a[4] == 21}, a, {n, 1, 68}] (* Michael De Vlieger, May 09 2015 *)
    LinearRecurrence[{1, 0, 1, -1}, {3, 12, 18, 21}, 70] (* Vincenzo Librandi, May 10 2015 *)
  • PARI
    Vec(3*x*(x+1)*(2*x+1)/((x-1)^2*(x^2+x+1)) + O(x^100)) \\ Colin Barker, Jul 12 2014
    

Formula

a(n) = 3*A047234(n+1).
From Colin Barker, Jul 12 2014: (Start)
a(n) = a(n-1) + a(n-3) - a(n-4).
G.f.: 3*x*(x+1)*(2*x+1) / ((x-1)^2*(x^2+x+1)). (End)
Interlaced polynomials: a(3n) = 18*n; a(3n+1) = 18*n+3; a(3n+2) = 18*n + 12 for n > 0. - Avi Friedlich, May 16 2015