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.

A092486 Take natural numbers, exchange first and third quadrisection.

Original entry on oeis.org

3, 2, 1, 4, 7, 6, 5, 8, 11, 10, 9, 12, 15, 14, 13, 16, 19, 18, 17, 20, 23, 22, 21, 24, 27, 26, 25, 28, 31, 30, 29, 32, 35, 34, 33, 36, 39, 38, 37, 40, 43, 42, 41, 44, 47, 46, 45, 48, 51, 50, 49, 52, 55, 54, 53, 56, 59, 58, 57, 60, 63, 62, 61, 64, 67, 66, 65, 68, 71, 70, 69, 72
Offset: 0

Views

Author

Ralf Stephan, Apr 04 2004

Keywords

Crossrefs

Programs

  • Mathematica
    Flatten[Partition[Range[80],4]/.{a_,b_,c_,d_}->{c,b,a,d}] (* Harvey P. Dale, Aug 12 2012 *)
  • PARI
    { f="b092486.txt"; for (n=0, 5000, a0=4*n + 3; a1=a0 - 1; a2=a1 - 1; a3=a0 + 1; write(f, 4*n, " ", a0); write(f, 4*n+1, " ", a1); write(f, 4*n+2, " ", a2); write(f, 4*n+3, " ", a3); ); } \\ Harry J. Smith, Jun 21 2009

Formula

G.f.: (3-4*x+3*x^2)/((1+x^2)*(1-x)^2).
a(4n) = 4n+3, a(4n+1) = 4n+2, a(4n+2) = 4n+1, a(4n+3) = 4n+4.
a(n) = n+1+i^n+(-i)^n, where i is the imaginary unit. - Bruno Berselli, Feb 08 2011
From Wesley Ivan Hurt, May 09 2021: (Start)
a(n) = 2*a(n-1)-2*a(n-2)+2*a(n-3)-a(n-4).
a(n) = 1 + n + 2*cos(n*Pi/2). (End)
Sum_{n>=0} (-1)^n/a(n) = log(2) (A002162). - Amiram Eldar, Nov 28 2023